Commit graph

2695 commits

Author SHA1 Message Date
Thibault Saunier
099ac9faf2 docs: Convert gtkdoc comments to markdown
Modernizing the documentation, making it simpler to read an
modify and allowing us to possibly switch to hotdoc in the
future.
2017-03-10 18:19:17 -03:00
Jan Schmidt
8596ec23cb oggdemux: Fix reverse playback
Fix various issues with reverse playback by clearing tracking
vars when working in reverse, and where possible using the
timestamp interpolation code to generate timestamps for
outgoing buffers. Make sure to mark things as discontinuous
only when looping backward to a new position and fix seeking
to the next page when starting.
2017-03-04 00:30:37 +11:00
Jan Schmidt
fe1f47aa17 oggdemux: Timestamp tracking fixes
In gst_ogg_demux_do_seek() when calculating the
keyframe time, account for a non-zero start-time

Handle a discontinuous first packet in
gst_ogg_demux_setup_first_granule() because that's pretty
normal after a seek. Also differentiate between a genuinely
truncated first packet and just bailing out early, by not using
granule = -1 as an error code.

Make the debug output logs clearer about which timestamps
are stream times (PTS) and which are ogg timestamps.
2017-03-04 00:30:37 +11:00
Jan Schmidt
342132a700 oggdemux: Don't arbitrarily guess a timestamp of 0
When we haven't managed to manufacture a timestamp for
a packet, don't just guess '0', leave it at none and
let downstream decide
2017-03-04 00:30:37 +11:00
Jan Schmidt
924c44f369 theoradec: Make the keyframe condition check clearer
Make the keyframe checking if statement easier to
read, and add some debug when detecting a keyframe
2017-03-04 00:30:37 +11:00
Edward Hervey
e575be6dc6 vorbisdec: Reset decoder in more situations
This is a followup commit to b95725c37e

* Resetting the decoder should only happen when we get a new initialization
header (0x01) and not on the other headers
* The initialized variable only gets set to TRUE once all headers have
been parsed. Also check if the vorbis_info struct has been properly resetted
also. Failure to do that would cause vorbisdec to error if it got
two initialization header in a row (the first would configure the underlying
library and the second one would error out because it's already initialized)

https://bugzilla.gnome.org/show_bug.cgi?id=779515
2017-03-03 10:56:22 +01:00
Jochen Henneberg
b95725c37e vorbisdec: reset decoder on vorbis headers update
if the vorbis encoder receives new headers it must be
reset and re-initialized to continue decoding, e. g.
for live streams
2017-02-27 19:17:58 +02:00
Sebastian Dröge
bb051c14b3 vorbisenc: Resend (new, updated) headers when the caps are changing
The headers are usually changing together with the caps, and they are
nedeed for correct decoding.
2017-02-27 19:04:30 +02:00
Jochen Henneberg
0c2c82ad69 vorbis: Fix channel reorder map for 5.1, 6.1 and 7.1 2017-02-20 13:45:09 +02:00
Sebastian Dröge
9795115564 gst: Don't declare variables inside the for loop header
This is a C99 feature.
2016-12-13 22:26:08 +02:00
Jan Schmidt
226dfc3f32 ogg: Fix element factory klass for OGM parsers
They're parsers, not decoders, so fix the klass info
accordingly.
2016-12-09 18:06:35 +11:00
Sebastian Dröge
732ecf0925 oggdemux: Don't end up ignoring caps just because there are no headers for this stream
https://bugzilla.gnome.org/show_bug.cgi?id=775459
2016-12-01 15:12:59 +02:00
Sebastian Dröge
d34e326425 textoverlay: Mark pad as needing reconfiguration again if it failed
And return FLUSHING instead of NOT_NEGOTIATED on flushing pads.

https://bugzilla.gnome.org/show_bug.cgi?id=774623
2016-11-18 12:04:27 +02:00
Scott D Phillips
115ccfe679 meson: vorbis: Add -DTREMOR to flags for gstivorbisdec
Matching the flags set by Makefile.am

https://bugzilla.gnome.org/show_bug.cgi?id=774445
2016-11-15 12:45:42 +11:00
Scott D Phillips
ab3c8caeed Remove 'return' from void functions
https://bugzilla.gnome.org/show_bug.cgi?id=774293
2016-11-12 10:51:30 +02:00
Vincent Penquerc'h
9121131f31 opusdec: fix 120 ms buffers being wrongly emitted
Using the max 120 ms buffer size to ensure we have enough space
for decoded data meant that Opus could actually return 120 ms'
worth of data.

https://bugzilla.gnome.org/show_bug.cgi?id=771723
2016-11-04 16:59:26 +00:00
Vincent Penquerc'h
b0866b9cc1 opusdec: interpret zero duration as unknown
This fixes missing audio when we get buffers with zero
duration, denoting unknown duration. When several such
buffers are received in a row, they're all at the same
timestamp, with zero duration.

https://bugzilla.gnome.org/show_bug.cgi?id=771723
2016-11-01 19:58:42 +02:00
Vincent Penquerc'h
a6ced9cbc8 opusdec: fix "buffer too small" error
Always supply a buffer with max size to the decoder, as we
can't really decide how many samples will be in the lost packet
based on the timestamps we get.

https://bugzilla.gnome.org/show_bug.cgi?id=771723
2016-11-01 19:58:42 +02:00
Nicolas Dufresne
7a40442ad5 video: Add VYUY pixel format
This format is sometimes the output of JPEG decoders. It is the same as
YUY2 and UYVY but with a different component order.

https://bugzilla.gnome.org/show_bug.cgi?id=767450
2016-11-01 19:55:20 +02:00
Vincent Penquerc'h
667931e52a vorbisenc: correct codebooks packet identifier from 3 to 5
https://bugzilla.gnome.org/show_bug.cgi?id=768763
2016-10-07 12:54:12 +01:00
Vincent Penquerc'h
9599c3416c opusenc: remove segment stop modification on eos
https://bugzilla.gnome.org/show_bug.cgi?id=768763
2016-10-05 14:49:52 +01:00
Vincent Penquerc'h
a30c713e43 oggmux: take audio clip meta into account for buffer duration
https://bugzilla.gnome.org/show_bug.cgi?id=768763
2016-10-05 14:49:52 +01:00
Vincent Penquerc'h
1a4ba79044 vorbisenc: strip after-eos samples from the end of the eos buffer
https://bugzilla.gnome.org/show_bug.cgi?id=768763
2016-10-05 14:49:52 +01:00
Vincent Penquerc'h
31438ef49b oggdemux: safety for failing to determine time length in push mode
If we can't find a valid granule near the end of the file, we
disable seeking. This guards against the whole file being then
read and never going to PLAYING.

https://bugzilla.gnome.org/show_bug.cgi?id=770314
2016-09-05 11:42:44 +01:00
Vincent Penquerc'h
6f856cb54d oggdemux: increase EOS granpos detection chunk size
This can be too small on some files to find a valid granule.

https://bugzilla.gnome.org/show_bug.cgi?id=770314
2016-09-05 11:41:43 +01:00
Thibault Saunier
bc6aae6ca7 Use the new API to post flow ERROR messages on the bus
https://bugzilla.gnome.org/show_bug.cgi?id=770158
2016-08-26 19:23:24 -03:00
Nirbheek Chauhan
5c4f4ac1bd Add support for Meson as alternative/parallel build system
https://github.com/mesonbuild/meson

With contributions from:

Tim-Philipp Müller <tim@centricular.com>
Jussi Pakkanen <jpakkane@gmail.com> (original port)

Highlights of the features provided are:
* Faster builds on Linux (~40-50% faster)
* The ability to build with MSVC on Windows
* Generate Visual Studio project files
* Generate XCode project files
* Much faster builds on Windows (on-par with Linux)
* Seriously fast configure and building on embedded

... and many more. For more details see:

http://blog.nirbheek.in/2016/05/gstreamer-and-meson-new-hope.html
http://blog.nirbheek.in/2016/07/building-and-developing-gstreamer-using.html

Building with Meson should work on both Linux and Windows, but may
need a few more tweaks on other operating systems.
2016-08-20 11:09:51 +01:00
Vincent Penquerc'h
273d35ce20 oggdemux: remove eos avoidance workaround
This workaround tried to avoid an EOS event when seeking to the
end of an Ogg stream in order to find its duration. At some point,
an EOS event there would cause any queue2 upstream to pause and
not restart on a seek back to the beginning. This now appears to
not be the case anymore, and so the workaround can be removed.

https://bugzilla.gnome.org/show_bug.cgi?id=767689
2016-08-05 07:50:35 +02:00
Vivia Nikolaidou
a993dd40b6 timeoverlay: Add support to display timecode
Choosing time-mode=time-code will display the time code attached to the
buffer, or 00:00:00:00 if no time code is found.

https://bugzilla.gnome.org/show_bug.cgi?id=766419
2016-08-04 18:59:57 +03:00
Luis de Bethencourt
7ae577dc3a ogg: check return values in gst_ogg_parse_new_stream
Return NULL in gst_ogg_parse_new_stream when either ogg_stream_pagein() or
gst_ogg_stream_setup_map() failed.

https://bugzilla.gnome.org/show_bug.cgi?id=769299
2016-08-03 17:12:55 +01:00
Luis de Bethencourt
5cab723651 ogg: fix memory leak in gst_ogg_parse_new_stream
Avoid leaking the stream object

https://bugzilla.gnome.org/show_bug.cgi?id=769299
2016-08-03 17:12:43 +01:00
Arun Raghavan
6c84f4e743 Revert "vorbisenc: push an updated segment stop time when we know it"
This reverts commit a16cd5d2a5.

Setting the stop time on the segment breaks reconfiguration, as the
encoder signals an EOS, but we reconfigure it an continue to produce
buffers.

This information  should not be required via the segment downstream
since we already have the sample count being used to generate buffer
durations.

https://bugzilla.gnome.org/show_bug.cgi?id=768763
2016-07-21 15:26:21 +05:30
Vincent Penquerc'h
714e3b9741 oggdemux: fix unknown duration playing Ogg over HTTP
If the duration is not known from the chain, it might be known
by the startup seek.

This fixes failure to seek.

Merged with a patch from Tim-Philipp Müller <tim@centricular.com>

https://bugzilla.gnome.org/show_bug.cgi?id=768991
2016-07-21 10:40:07 +01:00
Jan Schmidt
614ddaa739 alsasink: Remove unused hwparam/swparam pointers
The ALSA params structures aren't kept. The pointers
aren't used anywhere, so remove them from the struct.
2016-07-15 22:51:35 +10:00
Vincent Penquerc'h
528f030eff oggdemux: demote an expected error to debug
Dropping a buffer because we have a seek pending is normal,
and will now happen when we trigger a seek while going through
the packets in a page. So this should not be an error.
2016-06-23 10:24:55 +01:00
Vincent Penquerc'h
6bc6b6ebbf opusdec: handle missing buffers with no duration
If buffer duration is missing, it is parsed from the packet data.
This is not foolproof, since Opus can change durations on the
fly.

https://bugzilla.gnome.org/show_bug.cgi?id=767826
2016-06-21 10:48:40 +01:00
Vincent Penquerc'h
2ac5bd293b oggdemux: fix audio glitches with low bitrate vorbis
A low bitrate stream which can pack more than 2 seconds of audio
in a page would cause the stream's position to be updated not
often enough, and would trigger a spurious "jump" via a GAP
event. Instead, we update the stream position after calculating
the new overall segment position.

https://bugzilla.gnome.org/show_bug.cgi?id=764966
2016-06-16 11:10:08 +01:00
Guillaume Desmottes
afdb7d3f32 opusenc, subtitleoverlay: use MAY_BE_LEAKED flag
Flag caps that are cached locally and will never be freed.

https://bugzilla.gnome.org/show_bug.cgi?id=767155
2016-06-02 13:11:11 +01:00
Tim-Philipp Müller
eb9750d96e textoverlay: enable shaded background drawing for new IYU2 format 2016-06-01 12:36:38 +01:00
Nirbheek Chauhan
ba9bf26f4b libvisual: Factor out endian-order RGB formats
MSVC seems to ignore preprocessor conditionals inside static
pad templates. Also remove unnecessary quotes inside caps strings.
2016-05-24 19:49:38 +01:00
Tim-Philipp Müller
108c7d6b3c opus: use default error messages in some more cases 2016-05-23 19:28:39 +01:00
Tim-Philipp Müller
c056b99f94 opusdec: use default error message strings in more cases
Details should go into the debug message. We should probably
make up new codes for encoder/decoder lib init failures too.
2016-05-23 15:36:47 +01:00
Olivier Crête
0bfed26f56 opus: Post error message on GST_FLOW_ERROR
https://bugzilla.gnome.org/show_bug.cgi?id=766265
2016-05-19 12:27:57 -04:00
Olivier Crête
1a700c3ae6 opusdec: Use GST_AUDIO_DECODER_ERROR
This way, the first invalid stream won't break all decoding.

https://bugzilla.gnome.org/show_bug.cgi?id=766265
2016-05-18 15:25:38 -04:00
Edward Hervey
98c9eb9858 oggdemux: Reset keyframe_granule when needed
This avoids ending up with bogus values when doing flushing seeks
in push-mode.

https://bugzilla.gnome.org/show_bug.cgi?id=766467
2016-05-15 14:39:25 +02:00
Thiago Santos
60c765174f opusdec: intersect with the filter before returning on getcaps
So upstream gets a smaller set to decide upon as it is what it requested
with the filter

https://bugzilla.gnome.org/show_bug.cgi?id=765684
2016-05-02 14:29:25 -03:00
Thiago Santos
7a5797d3a6 opusdec: improve getcaps to return all possible rates
The library is capable of converting to different rates.

Includes tests.

https://bugzilla.gnome.org/show_bug.cgi?id=765684
2016-05-02 14:29:25 -03:00
Thiago Santos
823832e293 opusdec: remove artificial restriction on rate negotiation
Remove restrictions when rate is 48000, the underlying lib supports
converting any of the input to any of the output rates.

https://bugzilla.gnome.org/show_bug.cgi?id=765684
2016-05-02 14:29:25 -03:00
Thiago Santos
b1153e0f7d opusdec: refactor getcaps repeated code into a function
Easier to read and maintain
2016-05-02 14:23:54 -03:00
Guillaume Desmottes
8d6e315b01 opusdec: fix caps leaks
The caps returned by gst_pad_get_allowed_caps() was leaked.

https://bugzilla.gnome.org/show_bug.cgi?id=765706
2016-04-28 09:18:53 +01:00
Guillaume Desmottes
6e7fa6659f alsa: properly convert position-less channels from ALSA
The only way for ALSA to expose a position-less multi channels is to
return an array full of SND_CHMAP_MONO. Converting this to a
GST_AUDIO_CHANNEL_POSITION_MONO array would be invalid as
GST_AUDIO_CHANNEL_POSITION_MONO is meant to be used only with one
channel.

Fix this by using GST_AUDIO_CHANNEL_POSITION_NONE which is meant to be
used for position-less channels.

https://bugzilla.gnome.org/show_bug.cgi?id=763799
2016-04-12 14:48:30 -04:00
Guillaume Desmottes
eef7312169 alsa: add some debugging output to alsa_detect_channels_mapping()
https://bugzilla.gnome.org/show_bug.cgi?id=763985
2016-04-12 14:48:30 -04:00
Guillaume Desmottes
d9268a50f1 alsa: factor out alsa_detect_channels_mapping()
This code was duplicated in alsasrc and alsasink.

https://bugzilla.gnome.org/show_bug.cgi?id=763985
2016-04-12 14:34:13 -04:00
Guillaume Desmottes
592b87a463 alsa: coding style fix
Was using tabs instead of spaces.

https://bugzilla.gnome.org/show_bug.cgi?id=763985
2016-04-12 14:34:13 -04:00
Vineeth TM
44b70ca3a1 base: use new gst_element_class_add_static_pad_template()
https://bugzilla.gnome.org/show_bug.cgi?id=763075
2016-03-24 14:25:41 +02:00
Lubosz Sarnecki
8a443784c4 basetextoverlay: Add new properties and alignment type for unclamped absolute positions
Introduces [x-absolute, y-absolute] properties
for positioning in +/- MAX_DOUBLE range.

Adds new (h/v)alignment type "absolute" where coordinates
map the text area to be exactly inside of video canvas for [0, 0] - [1, 1]:

[0, 0]: Top-Lefts of video and text are aligned
[0.5, 0.5]: Centers are aligned
[1, 1]: Bottom-Rights are aligned

https://bugzilla.gnome.org/show_bug.cgi?id=761251
2016-03-11 13:20:26 +00:00
Tim-Philipp Müller
241fcaa645 Revert "textoverlay: Do not limit positioning to video area."
This reverts commit a48daf6dd8.

This changed behaviour in a way that's not always
backwards-compatible.

https://bugzilla.gnome.org/show_bug.cgi?id=761251
2016-03-11 13:15:53 +00:00
Tim-Philipp Müller
aade5515ac theora: fix performance category initialisation
Remove unused _register() functions and look up the performance
debug category in a function that's actually called at some point.
2016-03-09 09:56:52 +00:00
Vincent Penquerc'h
603e2fe24a oggdemux: fix chaining causing running time to restart from 0
This fixes:
gst-play-1.0 http://relay-nyc.gameowls.com:8000/chiptune.ogg

https://bugzilla.gnome.org/show_bug.cgi?id=758282
2016-03-04 12:18:53 +00:00
Havard Graff
461cdd8c26 opusdec: plug caps leak
https://bugzilla.gnome.org/show_bug.cgi?id=763059
2016-03-03 20:10:09 +00:00
Vincent Penquerc'h
625bd68da7 opus: fix mono<->stereo up/down-mixing
https://bugzilla.gnome.org/show_bug.cgi?id=761588
2016-02-26 16:15:20 +00:00
Tim-Philipp Müller
8b48fc1569 opusenc: remove deprecated "cbr", "audio", and "constrained-vbr" properties
They have been replaced by "audio-type" and "bitrate-type".

https://bugzilla.gnome.org/show_bug.cgi?id=756282
2016-02-26 06:51:17 +00:00
Tim-Philipp Müller
f331412a37 opus: move Opus audio decoder and encoder from -bad to -base
Hook into build system after moving history.

https://bugzilla.gnome.org/show_bug.cgi?id=756282
2016-02-26 00:20:10 +00:00
Tim-Philipp Müller
a2eb430010 Merge branch 'plugin-move-opus'
Move Opus decoder and encoder from -bad to -base.

https://bugzilla.gnome.org/show_bug.cgi?id=756282
2016-02-25 23:51:42 +00:00
Tim-Philipp Müller
a62c7bd54c Fix use of undeclared core debug category symbols
libgstreamer currently exports some debug category
symbols GST_CAT_*, but those are not declared in any
public headers.

Some plugins and libgstvideo just use GST_DEBUG_CATEGORY_EXTERN()
to declare and use those, but that's just not right at
all, and it won't work on Windows with MSVC. Instead look
up the categories via the API.
2016-02-20 11:31:43 +00:00
Lubosz Sarnecki
8e07203798 textoverlay: Expose rendering dimensions as properties.
In order to detect graphical user input on the
textoverlay, the resulting rendering properties
need to be exposed to applications.

Fixes delayx property declaration.

https://bugzilla.gnome.org/show_bug.cgi?id=761251
2016-02-04 13:25:48 +01:00
Lubosz Sarnecki
a48daf6dd8 textoverlay: Do not limit positioning to video area.
The current position property is limited to X,Y positions
in the range of [0, 1]. This patch allows full control
over the overlay position, including partially outside
of the video area.

https://bugzilla.gnome.org/show_bug.cgi?id=761251
2016-02-04 13:25:48 +01:00
Vincent Penquerc'h
1ef601e7d3 opus: fix FEC
FEC may only be used when PLC is enabled on the audio decoder,
as it relies on empty buffers to generate audio from the next
buffer. Hooking to the gap events doesn't work as the audio
decoder does not like more buffers output than it sends.

The length of data to generate using FEC from the next packet
is determined by rounding the gap duration to nearest. This
ensures that duration imprecision does not cause quantization
to 2.5 milliseconds less than available. Doing so causes the
Opus API to fail decoding. Such duration imprecision is common
in live cases.

The buffer to consider when determining the length of audio
to be decoded is the previous buffer when using FEC, and the
new buffer otherwise. In the FEC case, this means we determine
the amount of audio from the previous buffer, whether it was
missing or not (and get the data either from this buffer, or
the current one if the previous one was missing).
2016-02-03 16:36:10 +00:00
Vincent Penquerc'h
8e9345ec86 opusdec: fix wrong buffer being checked for missing data
This caused a decoding error if the resulting (wrong) buffer size
was passed to the Opus decoding API.

https://bugzilla.gnome.org/show_bug.cgi?id=758158
2016-02-02 15:22:55 +00:00
Arun Raghavan
af091928f3 alsa: Trivial doc update
alsasink now does more than just raw audio.
2016-01-25 18:31:17 +05:30
Vineeth TM
95bf0ae2ae plugins-bad: Fix example pipelines
rename gst-launch --> gst-launch-1.0
replace old elements with new elements(ffmpegcolorspace -> videoconvert, ffenc_** -> avenc_**)
fix caps in examples

https://bugzilla.gnome.org/show_bug.cgi?id=759432
2015-12-15 10:30:49 +00:00
Nicolas Dufresne
e7a59d2e08 Revert "alsasrc: Disable HW timestamp"
This reverts commit 3642e9a391.
2015-12-14 13:59:02 -05:00
Nicolas Dufresne
3642e9a391 alsasrc: Disable HW timestamp
This is a workaround for broken pulse module.
2015-12-14 13:39:02 -05:00
Reynaldo H. Verdejo Pinochet
71c2ddd07d Remove unnecessary NULL checks before g_free()
g_free() is NULL-safe
2015-11-18 16:05:42 -08:00
Luis de Bethencourt
6463ff198e opusenc: avoid potential overflow expression
The result of the two expressions will be promoted to guint64 anyway,
perform all the arithmetic in 64 bits to avoid potential overflows.

CID 1338690, CID 1338691
2015-11-12 12:29:33 +00:00
Jan Schmidt
797a0ca376 vorbisdec: Re-init on new caps
If we get new input caps, then reset the decoder
ready for new headers and fresh data. Makes
chained oggs work when reusing the decoder.
2015-11-11 01:33:55 +11:00
Sebastian Dröge
dd741e6412 opusdec: Update sink pad templates
We always require the channel-mapping-field. If it's 0 we require nothing
else, otherwise we need channels, stream-count and coupled count to be
available.
2015-11-05 12:11:19 +01:00
Sebastian Dröge
85984fa946 opusenc: Create an empty taglist if there is none
There always have to be 2 buffers in the streamheaders, even if
the comment buffer is basically empty.
2015-11-04 00:14:13 +02:00
Sebastian Dröge
4ca84a9b1a opus: Add proper support for multichannel audio
https://bugzilla.gnome.org/show_bug.cgi?id=757152
2015-11-03 20:35:41 +02:00
Sebastian Dröge
fc475ce01a opusdec: Handle GstAudioClippingMeta instead of the pre-skip field in the OpusHead
oggdemux is outputting the meta now, and only outputs if it should really
apply to the current buffer. Previously we would skip N samples also if we
started the decoder in the middle of the stream.

https://bugzilla.gnome.org/show_bug.cgi?id=757153
2015-11-03 20:35:41 +02:00
Sebastian Dröge
328f9088f3 opusenc: Add GstAudioClippingMeta to buffers that need to be clipped
https://bugzilla.gnome.org/show_bug.cgi?id=757153
2015-11-03 20:35:41 +02:00
Sebastian Dröge
6b751360ae opusenc: Disable granule position calculations by the base class
It is doing the wrong thing because of the Opus pre-skip: while the timestamps
are shifted by the pre-skip, the granule positions are not shifted.

oggmux is doing the right thing here already.

https://bugzilla.gnome.org/show_bug.cgi?id=757153
2015-11-03 20:35:41 +02:00
Sebastian Dröge
7773e1eb58 opusenc: Add some FIXME comments about calculating padding with LPC
https://bugzilla.gnome.org/show_bug.cgi?id=757153
2015-11-03 20:35:41 +02:00
Sebastian Dröge
4df2ffaad6 opusenc: Encode exactly the amount of samples we got as input and put correct timestamps on it
The first frame has lookahead less samples, the last frame might have some
padding or we might have to encode another frame of silence to get all our
input into the encoded data.

This is because of a) the lookahead at the beginning of the encoding, which
shifts all data by that amount of samples and b) the padding needed to fill
the very last frame completely.

Ideally we would use LPC to calculate something better than silence for the
padding to make the encoding as smooth as possible.

With this we get exactly the same amount of samples again in an
opusenc ! opusdec pipeline.

https://bugzilla.gnome.org/show_bug.cgi?id=757153
2015-11-03 20:35:41 +02:00
Sebastian Dröge
6ffb90e037 opusenc: Put lookahead/pre-skip into the OpusHead header
https://bugzilla.gnome.org/show_bug.cgi?id=757153
2015-11-03 20:35:41 +02:00
Sebastian Dröge
cab8671f0c oggdemux: Create full Opus caps with all fields
https://bugzilla.gnome.org/show_bug.cgi?id=757152
2015-11-03 20:35:33 +02:00
Sebastian Dröge
0fa8d284c7 oggmux: Use GstAudioClippingMeta for Opus for accurate end clipping
... instead of relying on the segment. For the clipping at the start we assume
a proper value in the OpusHead, as generated by opusparse or opusenc.

Transmuxing in general is not guaranteed to produce the correct values, or
even have a OpusHead (e.g. when having RTP input).

https://bugzilla.gnome.org/show_bug.cgi?id=757153
2015-11-03 20:35:33 +02:00
Sebastian Dröge
a135868262 oggdemux: Add GstAudioClippingMeta for Opus for accurate start/end clipping
https://bugzilla.gnome.org/show_bug.cgi?id=757153
2015-11-03 20:35:33 +02:00
Sebastian Dröge
8a3be7323a oggdemux: Allow start clipping for Opus
The granulepos does not have the pre-skip subtracted while timestamps do,
and the last granulepos will be shorter by the number of samples that should
be dropped because of padding in the end.

As such, extrapolating the granule of the beginning of the first frame will
lead to a negative value, which is not a problem but intentional.

https://bugzilla.gnome.org/show_bug.cgi?id=757153
2015-11-03 20:35:33 +02:00
Luis de Bethencourt
2206ba473f oggmux: Print GstClockTimeDiff as a signed integer in debug logs 2015-11-02 16:36:35 +00:00
Luis de Bethencourt
799020804f oggdemux: Use GstClockTimeDiff and print signed integer in debug logs
Use GstClockTimeDiff and Clock macros to print signed integer time
differences in the debug logs.

https://bugzilla.gnome.org/show_bug.cgi?id=757480
2015-11-02 16:10:07 +00:00
Sebastian Dröge
9c195e37da opusdec: Assume 48kHz if no sample rate is given in the header 2015-11-02 09:36:46 +02:00
Sebastian Dröge
7cadfcb0b0 opusenc: Place 48kHz first in the caps
For all the other sample rates the encoder will have to resample internally.
2015-11-02 09:36:43 +02:00
Sebastian Dröge
4fe12c1b09 alsa: Use 8 bit pointer type for byte-based pointer arithmetic
Usually these loops only run once, so there's no problem here. But sometimes
they run twice, and by adding the number of bytes to a 16 bit pointer type we
would advance twice as much as we should.

Also use snd_pcm_frames_to_bytes() in alsasrc to calculate
the number of bytes to skip, same as we do in alsasink.

Thanks to Lucio A. Hernandez <lucio.a.hernandez@gmail.com> for reporting.
2015-10-14 00:33:49 +03:00
Antonio Ospite
2c7ed42292 midi: add an ALSA MIDI sequencer source
The alsamidisrc element allows to get input event from ALSA MIDI
sequencer devices, and possibly convert them to sound using some
downstream element like fluiddec.

Fixes #738687
2015-10-01 21:43:21 +02:00
Luis de Bethencourt
8ae0fd3990 visual: merge audiovisalizer base classes
Move the audiovisualizer base class to pbutils, so it can be used by plugins
from other modules

https://bugzilla.gnome.org/show_bug.cgi?id=742875
2015-10-01 16:05:58 +01:00
Prashant Gotarne
e58ad7a2b4 basetextoverlay: fix typo in debug log message
https://bugzilla.gnome.org/show_bug.cgi?id=755198
2015-09-18 08:50:52 +01:00
Thiago Santos
54a5859960 opusdec: remove check for number of channels
opus decoder can convert from different number of channels, no
need to check, just let it negotiate and create a new decoder if
needed.

https://bugzilla.gnome.org/show_bug.cgi?id=755059
2015-09-15 16:00:43 -03:00
Miguel París Díaz
a4ffb14c55 opusenc: improve deprecated properties docs
https://bugzilla.gnome.org/show_bug.cgi?id=754819
2015-09-11 23:33:19 +02:00
Miguel París Díaz
16e93d206f opusenc: do not throw g_warning when getting deprecated properties
https://bugzilla.gnome.org/show_bug.cgi?id=754819
2015-09-11 23:33:19 +02:00