Commit graph

2299 commits

Author SHA1 Message Date
Tim-Philipp Müller b0ff1d22e9 video: add fallbacks for compilation without orc 2011-12-05 15:36:56 +00:00
Thibault Saunier 80054a3b1e video: add some internal helper functions for image blending
This could be improved if we decide we don't need it to
be this generic/flexible.
2011-12-05 15:03:47 +00:00
Sebastian Dröge b0f4085f22 xoverlay: Fix mistakes in the sample code
Fixes bug #665430.
2011-12-05 09:39:08 +01:00
Tim-Philipp Müller 5440ae3c18 Suppress deprecation warnings in selected files, for g_static_rec_mutex_* mostly
GStaticRecMutex is part of our API/ABI, not much we can do here
in 0.10 for most of these.
2011-12-04 20:50:25 +00:00
Tim-Philipp Müller 0d98aa25b8 Work around deprecated thread API in glib master
Add private replacements for deprecated functions such as
g_mutex_new(), g_mutex_free(), g_cond_new() etc., mostly
to avoid the deprecation warnings. We'll change these
over to the new API once we depend on glib >= 2.32.

Replace g_thread_create() with g_thread_try_new().
2011-12-04 17:16:30 +00:00
Tim-Philipp Müller 6098442bd0 xmpwriter: update for thread API deprecations in glib master 2011-12-04 15:23:21 +00:00
Piotr Fusik 14644457b0 various: typo fixes
Fix typos in code and docs. Fixes. #658984
2011-12-02 12:03:27 +01:00
Alessandro Decina 848711706b libgstvideo: minor fixes to key unit events
Make out args to gst_video_event_parse_{downstream|upstream}_force_key_unit
optional, update libgstvideo.def and fix docs a bit.

API: gst_video_event_new_upstream_force_key_unit
API: gst_video_event_new_downstream_force_key_unit
API: gst_video_event_is_force_key_unit
API: gst_video_event_parse_upstream_force_key_unit
API: gst_video_event_parse_downstream_force_key_unit

https://bugzilla.gnome.org/show_bug.cgi?id=607742
2011-11-29 09:15:59 +01:00
Andoni Morales Alastruey df44e771f1 libgstvideo: Add force key unit events 2011-11-29 08:58:28 +01:00
Philippe Normand 0a841f6712 fft: Bracket public headers
This is especially needed if the gstfftw library is used from C++
code.

Fixes #665074
2011-11-28 20:28:19 +01:00
Vincent Penquerc'h ea78b060a7 Revert "libgstvideo: add a new API to handle QoS events and dropping logic"
This reverts commit eb03323fb6.

*grumble* I managed to merge something I did not mean to.
2011-11-28 13:26:53 +00:00
Vincent Penquerc'h 96374054ac various: fix pad template leaks
https://bugzilla.gnome.org/show_bug.cgi?id=662664
2011-11-28 13:09:02 +00:00
Vincent Penquerc'h eb03323fb6 libgstvideo: add a new API to handle QoS events and dropping logic
https://bugzilla.gnome.org/show_bug.cgi?id=658241
2011-11-28 12:34:43 +00:00
Mark Nauwelaerts 4a58223e4c audioencoder: elaborate some documentation 2011-11-28 11:37:33 +01:00
Mark Nauwelaerts 9f57d91137 audiodecoder: add some documentation 2011-11-28 11:37:27 +01:00
Mark Nauwelaerts 856a5dd581 audiodecoder: really discard NULL decoded frame altogether
... including any timestamp, rather than having that one influence base_ts.
2011-11-28 11:37:23 +01:00
Tim-Philipp Müller a0639dad38 audio: remove unstable API guards from the audio decoder and encoder base classes 2011-11-25 13:11:54 +00:00
Vincent Penquerc'h 44ec58b41b libgstriff: add a couple tags that need skipping
Found in a sample in the wild, appears to be ID3 tag.

https://bugzilla.gnome.org/show_bug.cgi?id=660249
2011-11-24 17:04:19 +00:00
Mark Nauwelaerts 69c2c46472 audioencoder: invalidate format info when setup negotiation failed
... which ensures nothing subsequently tries to slip past _chain
and into a possibly improperly setup subclass.
2011-11-16 19:03:47 +01:00
Vincent Penquerc'h f17f918b75 audiodecoder: accept dropped buffers before we know the format
This allows flacdec to not emit audio for headers, while allowing
the base audio decoder to keep its timestamps in sync.
2011-11-16 16:54:03 +00:00
Robert Swain a23dff1fbb audio: Remove some unused variables 2011-11-14 12:49:50 +01:00
Olivier Crête 82827df405 rtcpbuffer: Add feedback message types from RFC 5104
These are Codec Control messages (CCM)

https://bugzilla.gnome.org/show_bug.cgi?id=658419
2011-11-14 12:24:16 +01:00
Mark Nauwelaerts 38615abdd8 audiodecoder: improve reverse playback
... by doing some more (reverse) timestamp interpolating and
refactoring downstream pushing.

Fixes #661983.
2011-11-14 12:00:06 +01:00
Tim-Philipp Müller cd21e69913 audio: add GST_AUDIO_INFO_IS_VALID macro and use in audio decoder base class
API: GST_AUDIO_INFO_IS_VALID
2011-11-13 13:18:16 +00:00
Tim-Philipp Müller 394b1f8c3c audio: fix order in LIBADD
Local libs must come first.
2011-11-12 12:13:05 +00:00
Vincent Penquerc'h 0d47c615ad baseaudiosink: make unsigned properties unsigned, not signed 2011-11-10 15:55:31 +00:00
Tim-Philipp Müller d7fc45f42e docs: fix up some Since: markers 2011-11-07 23:05:44 +00:00
Felipe Contreras 3df415d4c7 baseaudiosink: make discont-wait configurable
Now we can configure how much time to wait before deciding that a
discont has happened.

Also, adds getter and setter to allow derived implementations to set
this value upon construction.

Suggestions and several improvements by Havard Graff.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
2011-11-07 11:58:46 +01:00
Felipe Contreras 0a111bf26e baseaudiosink: delay the resyncing of timestamp vs ringbuffertime
A common problem for audio-playback is that the timestamps might not
be completely linear. This is specially common when doing streaming over
a network, where you can have jittery and/or bursty packettransmission,
which again will often be reflected on the buffertimestamps.

Now, the current implementation have a threshold that says how far the
buffertimestamp is allowed o drift from the ideal aligned time in the
ringbuffer. This was an instant reaction, and ment that if one buffer
arrived with a timestamp that would breach the drift-tolerance, a resync
would take place, and the result would be an audible gap for the
listener.

The annoying thing would be that in the case of a "timestamp-outlier",
you would first resync one way, say +100ms, and then, if the next
timestamp was "back on track", you would end up resyncing the other way
(-100ms) So in fact, when you had only one buffer with slightly off
timestamping, you would end up with *two* audible gaps. This is the
problem this patch addresses.

The way to "fix" this problem with the previous implementation, would
have been to increase the "drift-tolerance" to a value that was greater
than the largest timestamp-outlier one would normally expect.  The big
problem with this approach, however, is that it will allow normal
operations with a huge offset timestamp vs running-time, which is
detrimental to lip-sync. If the drift-tolerance is set to 200ms, it
basically means that lip-sync can easily end up being off by that much.

This patch will basically start a timer when the first breach of
drift-tolerance is detected. If any following timestamp for the next n
nanoseconds gets "back on track" within the threshold, it has basically
eliminated the effect of an outlier, and the timer is stopped.  If,
however, all timestamps within this time-limit are breaching the
threshold, we are probably facing a more permanent offset in the
timestamps, and a resync is allowed to happen.

So basically this patch offers something as rare as both higher
accuracy, it terms of allowing smaller drift-tolerances, as well as much
smoother, less glitchy playback!

Commit message and improvments by Havard Graff.

Fixes bug #640859.
2011-11-07 11:33:32 +01:00
Felipe Contreras 3f1395afae baseaudiosink: rename some variables 2011-11-07 11:18:34 +01:00
Felipe Contreras fbde258be6 baseaudiosink: use gst_util_uint64_scale_int when appropriate
It's probably safer this way.
2011-11-07 11:11:08 +01:00
Felipe Contreras 369cf3f14a baseaudiosink: split drift-tolerance into alignment-threshold
So that drift-tolerance is used for clock slaving resync, and
alignment-threshold is for timestamp drift.
2011-11-07 11:10:05 +01:00
Felipe Contreras 58b9818853 baseaudiosink: trivial comment fixes
Some found by Havard Graff.

Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com>
2011-11-07 10:57:56 +01:00
Reynaldo H. Verdejo Pinochet 7559fb29a4 Add missing default include paths to androgenizer call
Fixes building tag/ with Android's NDK
2011-11-03 21:35:38 -03:00
Mersad Jelacic d430eb65c5 audiosink: avoid deadlocking audioringbuffer thread
... when it goes into wait for ringbuffer starting just after such
having been signalled.

Fixes #661738.
2011-10-28 14:07:40 +02:00
Mark Nauwelaerts 981070eb44 audiodecoder: having gather queue contents implies some draining is in order
... which ensures e.g. processing and sending last fragment of reverse playback
downstream at EOS.
2011-10-19 16:51:09 +02:00
Tim-Philipp Müller 4e59e63ff7 baseaudiosink: fix unused variable compiler warning if debugging in core is disabled
https://bugzilla.gnome.org/show_bug.cgi?id=660150
2011-10-19 00:32:13 +01:00
Alessandro Decina bc6f00becb audioencoder: fix compile warning 2011-10-09 16:48:18 +02:00
Mark Nauwelaerts 871b1584c9 audioencoder: only resync to upstream upon discont in perfect ts mode
... as documented, where discont is marked here if tolerance has been
exceeded.
2011-10-08 20:20:10 +02:00
Mark Nauwelaerts a7ce550d04 audiodecoder: fix timestamp tolerance handling 2011-10-08 20:20:06 +02:00
Mark Nauwelaerts d8312994aa audiodecoder: handle empty input by discarding 2011-10-08 20:20:03 +02:00
Mark Nauwelaerts 37c629fcc6 audioencoder: make upstream queries MT-safe 2011-10-07 14:52:50 +02:00
Mark Nauwelaerts 77069f01b1 audiodecoder: make upstream queries and events MT-safe 2011-10-07 14:52:48 +02:00
Vincent Penquerc'h 93900d47ed encoding-profile: add a function to create a profile from a discoverer info
Only A/V streams are added at the moment, there does not seem to be
a similar way to add other streams (eg, subtitles).

https://bugzilla.gnome.org/show_bug.cgi?id=642878
2011-10-03 11:51:23 +02:00
Mark Nauwelaerts 8633eb391d audiodecoder: really push pending events 2011-09-28 15:42:46 +02:00
Tim-Philipp Müller e4e2e3c7b0 audioencoder: remove more tags from upstream tag events such as bitrate tags
We want to remove all codec specific tags.
2011-09-28 14:32:20 +01:00
Mark Nauwelaerts 01d27ee084 audioencoder: only got_data if we really got some
... which avoids going loopy with casual subclass.
2011-09-27 16:58:44 +02:00
Mark Nauwelaerts 24d71cf7a6 audioencoder: really push pending events 2011-09-27 16:58:41 +02:00
Mark Nauwelaerts 803b65613b audioencoder: send tag event after pending events
... which probably includes a pending newsegment event.
2011-09-27 16:21:55 +02:00
Mark Nauwelaerts 89f6720545 audioencoder: protect pending_events with proper lock 2011-09-27 16:21:45 +02:00