Commit graph

1524 commits

Author SHA1 Message Date
Sebastian Dröge
4dd30bbd16 playsink: Only remove the complete text chain if the text pad goes away
If the text pads does not go away we just set the overlay to silent, which
allows us to immediately re-enable subs later again. However before this
change we also released the streamsynchronizer text pads, which deadlocked
because there was still dataflow going on. Just do this only if we remove
the complete chain.

https://bugzilla.gnome.org/show_bug.cgi?id=683504
2014-02-16 15:35:31 +01:00
Sebastian Dröge
2ddc07e93e uridecodebin: Don't leak pad references 2014-02-12 17:34:32 +01:00
Sebastian Dröge
a02678057e playbin: First try to get the pad's current caps, then query caps
The caps query might give us ANY caps while the pad has fixed caps
configured currently.
2014-02-11 16:36:20 +01:00
Sebastian Dröge
57295753d5 playbin: Fix memory leak in autoplugging code
We should not leak element factories ideally.
2014-02-10 16:33:50 +01:00
Sebastian Dröge
c91a4af9ab subtitleoverlay: Remove unused function 2014-02-09 23:17:03 +01:00
Alessandro Decina
6a699b6c40 decodebin: make it possible to register multiple handlers for autoplug-select
Change the way autoplug-select is accumulated so that it's possible to have
multiple handlers. The handlers keep getting called as long as they keep
returning GST_AUTOPLUG_SELECT_TRY.

One practical example of when this is needed is when hooking into playbin's
uridecodebin, which is perhaps not very elegant but the only way to influence
which streams playbin autoplugs/exposes.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=723096
2014-01-28 13:45:07 +11:00
Sjoerd Simons
43237ad0e2 uridecodebin: Drop hardcoded list of media suitable for download buffering
Discussion on IRC indicated that the main reason for this list was to
prevent demuxers that can trigger a lot of seeking from using
progressive buffering using queue2 (which due to being seekable triggers
that behaviour).

However given that upstream can indicate seeks are possible but should
be avoided via a scheduling query, this extra whitelisting shouldn't be
necessary for well-behaved demuxers.

https://bugzilla.gnome.org/show_bug.cgi?id=704933
2014-01-24 22:34:51 +01:00
Wonchul Lee
c2746d753e playbin: Remove unnecessary assignment
Remove duplicated assignment

https://bugzilla.gnome.org/show_bug.cgi?id=722491
2014-01-18 13:33:57 +01:00
Sebastian Dröge
4f8f5918be playbin: Insert decoders without GstAVElement information between the other decoders
Otherwise they would be preferred over all decoders independent
of their ranks.

https://bugzilla.gnome.org/show_bug.cgi?id=722316
2014-01-18 13:33:57 +01:00
Sebastian Dröge
6b46019abf playbin: Only put parsers and sinks first, not all non-decoders
https://bugzilla.gnome.org/show_bug.cgi?id=722316
2014-01-18 13:33:57 +01:00
Matthieu Bouron
98e0dec715 playback: add ANY caps features to default audio/video raw caps
Allows elements using audio/video caps features to be used by playbin.
2013-12-30 11:25:49 +01:00
Wim Taymans
6db3b535eb uridecodebin: copy sticky events 2013-11-29 17:30:09 +01:00
Wim Taymans
a7151d0b3e decodebin2: copy sticky events 2013-11-29 17:26:13 +01:00
Wim Taymans
65e492a403 decodebin2: activate ghost pad before targetting
Activate the decodebin2 pad before setting the target. This makes sure
that the events are copied.
2013-11-28 11:27:23 +01:00
Sebastian Dröge
0e9806a03e playsink: Fix visualizations if no visualization plugin was set
https://bugzilla.gnome.org/show_bug.cgi?id=712280
2013-11-26 12:03:24 +01:00
Tim-Philipp Müller
b1ff48c1a1 docs: remove old 0.10 Since markers
They're just confusing.
2013-11-16 16:10:07 +00:00
Thibault Saunier
ddf4ca2203 playback: Add subpicture/x-dvb as raw caps
https://bugzilla.gnome.org/show_bug.cgi?id=710325
2013-10-30 22:28:43 +01:00
Sebastian Dröge
dd4fe544bc playsink: If the visualisation is changing and reconfiguration is pending, do it all during reconfiguration
Otherwise we will have two pad blocks that want to use the same mutex
and block each other via the streamlock.

https://bugzilla.gnome.org/show_bug.cgi?id=709210
2013-10-02 15:03:46 +02:00
Thiago Santos
f8d8a56d7b playbin: make sure elements are in null before disposing
If a pipeline fails to preroll, it might happen that the sinks are
put into READY state from playbin's sink activation, but they are never
set to playsink, so they aren't being managed by a GstBin and will keep
their READY state until they are unreffed, leading to a warning.

Prevent this by always forcing them to NULL when deactivating a group

https://bugzilla.gnome.org/show_bug.cgi?id=708789
2013-10-01 17:53:05 -03:00
Sebastian Dröge
cac572ec5d playbin: Make sure to cache context types we did not store yet
https://bugzilla.gnome.org/show_bug.cgi?id=708668
2013-09-24 12:47:26 +02:00
Sebastian Dröge
78b0e16773 playbin: Implement context caching for sinks that are not in playsink yet 2013-09-18 22:39:25 +02:00
Sebastian Dröge
e21d3d214a playbin: No need to set the GstContext on the sink before activating it
This is all handled by the GstBin code now.
2013-09-18 22:39:25 +02:00
Loïc Minier
8492b956cd playback: fix docs of convert-sample action signal
convert-sample returns a GstSample, not a GstBuffer.

https://bugzilla.gnome.org/show_bug.cgi?id=707660
2013-09-07 14:58:46 +01:00
Sebastian Dröge
61c1d15ce7 playsink: Don't set sink to NULL if a new one is set while the old one is still in use 2013-08-14 15:43:53 +02:00
Sebastian Dröge
b22f046cbc streamsynchronizer: Set proxy flags on the pads and use default event handler for simplicity
https://bugzilla.gnome.org//show_bug.cgi?id=705555
2013-08-12 13:02:15 +02:00
Arnaud Vrac
a8df760c96 playbin: check for tags on the right combiner instance
The get-tags actions are not working in all cases, because the track
number is used to resolve the stream combiner instead of the stream
type.

https://bugzilla.gnome.org/show_bug.cgi?id=705369
2013-08-03 17:17:10 +01:00
Edward Hervey
9dd0e6cccc ext/gst: Ensure default query/event handlers are used
And in some cases, just remove our implementation that does nothing
2013-07-26 16:08:35 +02:00
Sebastian Dröge
0bd0c925e3 playsink: Remove two unused variables 2013-07-23 13:42:40 +02:00
Sebastian Dröge
e4b1a58675 subtitleoverlay: Remove some more unneeded segment tracking 2013-07-23 13:41:55 +02:00
Sebastian Dröge
436ea03362 playsinkconvertbin: Remove obsolete segment tracking
This is now all handled automatically with sticky events.
2013-07-23 13:36:09 +02:00
Sebastian Dröge
f92da706fd playbin: Ensure that everything in a GstSourceGroup gets the same group-id
Including streams from external subtitle files. If not everything implements
the group-ids playbin invents its own.
2013-07-23 12:42:50 +02:00
Sebastian Dröge
94fc577dd5 playsink: Fix handling of colorbalance element if the sink does not implement it 2013-07-23 12:35:46 +02:00
Sebastian Dröge
0947c7ab30 playsink: Improve segment handling in the custom flushing for subtitle stream switches
This code needs a lot more work to be improved for 1.0.
2013-07-23 11:13:19 +02:00
Sebastian Dröge
33cba1054d subtitleoverlay: Segment events are sticky now and propagated automatically when needed 2013-07-23 11:11:33 +02:00
Sebastian Dröge
2465895266 streamsynchronizer: Implement grouping of streams via the group-id
https://bugzilla.gnome.org/show_bug.cgi?id=704427
https://bugzilla.gnome.org/show_bug.cgi?id=704408
2013-07-22 15:24:13 +02:00
Sebastian Dröge
432b092247 playbin: Don't prefer decoders for which we found a matching sink
It doesn't make much sense.
2013-07-16 12:21:44 +02:00
Sebastian Dröge
4cfda00120 playbin: Also consider possible converters for raw streams when selecting compatible sink/source combinations
https://bugzilla.gnome.org/show_bug.cgi?id=704285
2013-07-16 11:22:35 +02:00
Sebastian Dröge
5ee98c146e playbin: Fix sorting for decoder factories for which we didn't find a compatible sink
They might just need some converters for raw audio/video.

https://bugzilla.gnome.org/show_bug.cgi?id=704285
2013-07-16 09:32:31 +02:00
Sebastian Dröge
10c91ea5b5 playbin: Don't print a warning when setting a sink to NULL
https://bugzilla.gnome.org/show_bug.cgi?id=704194
2013-07-15 09:10:30 +02:00
Sebastian Dröge
edecd7eec3 playbin: Properly destroy and set to NULL sinks that don't work 2013-07-12 12:05:37 +02:00
Alban Browaeys
f174c450c9 playbin: Fix logic to detect if a stream-change is currently pending
Fixes duration reporting in gapless playback between files.

https://bugzilla.gnome.org/show_bug.cgi?id=585969
2013-07-12 09:54:06 +02:00
Sebastian Dröge
9ab6ab4257 playbin: Only give sinks a new bus if they have no parent yet
Otherwise we will remove the bus that would proxy messages to playsink
and never set it again. If the sink is already in playsink, all failures
are fatal anyway as it's either a sink that worked before or one that
was set by the user.

https://bugzilla.gnome.org/show_bug.cgi?id=701997
2013-07-10 17:17:05 +02:00
Sebastian Dröge
d7f1d9954f playbin: Store a/v/t sinks locally too, not just in playsink 2013-07-10 13:22:04 +02:00
Sebastian Dröge
4c1fc76407 playsink: ref_sink() any sinks that are set on playsink
Otherwise the behaviour of the properties is inconsistent.
2013-07-10 13:21:29 +02:00
Sebastian Dröge
043c1888f3 streamsynchronizer: Non-TIME segment streams are not waiting automatically
This was leftover code from porting to 1.0 and fixes the playbin
unit test.

https://bugzilla.gnome.org/show_bug.cgi?id=701943
2013-07-10 13:00:21 +02:00
Sebastian Dröge
f68b6c2626 playbin: Change sink ownership handling to be a bit more sane
playbin will now only activate the sinks in a single place and
will never change the states of any sinks that are owned by
playsink.

Also handle text-sinks the same way as audio/video sinks inside
playbin.
2013-07-09 14:57:05 +02:00
Sebastian Dröge
7c28c180ec playbin: If we had a previous autoplugged sink, try to reuse it
https://bugzilla.gnome.org/show_bug.cgi?id=701997
2013-07-02 14:25:28 +02:00
Sebastian Dröge
b3a15872b7 playsink: If we switch sinks, make sure that the old sink is set to NULL 2013-07-02 14:18:20 +02:00
Sebastian Dröge
841d738f7c playbin: Don't change the state of sinks that we passed to playsink already 2013-07-02 14:02:57 +02:00
Sebastian Dröge
c725591010 playsink: Consider new audio/video sinks when reconfiguring 2013-07-02 14:01:52 +02:00
Sebastian Dröge
a0e61534ef playbin: Improve debug output regarding sink selection 2013-07-02 12:27:03 +02:00
Brendan Long
d3acb2b01a playbin: Post an error message if a stream combiner doesn't return a request pad. 2013-07-02 09:34:19 +02:00
Sebastian Dröge
f39d1dc3b4 playbin: Only intersect to check if a sink can handle raw caps
Doing a subset check requires fixed caps, which we might not have here.

https://bugs.webkit.org/show_bug.cgi?id=116042
2013-07-01 13:46:51 +02:00
Sreerenj Balachandran
8a2dbeb1ef playsink: Fix the block diagram of deinterlace bin.
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=702465
2013-06-17 16:28:44 +02:00
Brendan Long
b5f7a621bb playbin: Emit {audio,text,video}-changed signals when pads are removed
https://bugzilla.gnome.org/show_bug.cgi?id=702195
2013-06-14 14:23:11 +02:00
Sebastian Dröge
4465741222 playbin: When activating a fixed sink, proxy error messages too
If activating a fixed sink fails, everything will fail later anyway
and we can just error out early.
2013-06-08 23:51:13 +02:00
Sebastian Dröge
44352deadb playbin: Improve autoplugging of decoder/sink combinations by trying to activate the sink
And if that fails don't bother autoplugging that sink. Also gives
us more accurate sink caps.
2013-06-08 23:34:53 +02:00
Sebastian Dröge
ff8839d97b playbin: Proxy the playbin context to the sinks 2013-06-08 23:22:54 +02:00
Sebastian Dröge
77af24c493 playbin: Proxy sink messages if we activate a sink in playbin already
This makes sure the application gets any context related messages and
can do whatever is required to a) get the sink a context or b) share
the context with other elements in the pipeline.

The proxying is necessary because the sink is not a child element of
playbin, but instead will at a later point be a child of some bin
inside playsink.

https://bugzilla.gnome.org/show_bug.cgi?id=700967
2013-06-08 23:22:54 +02:00
Sebastian Dröge
c49531f1b7 decodebin: Let serialize queries before caps events through
Otherwise we're going to deadlock forever because no autoplugging
happens without having caps, but caps can never be send because
we're blocking.

Serialized queries before caps should never be sent unless really
necessary.
2013-06-06 15:57:49 +02:00
Daniel Drake
d32d2f0b14 playsink: pass translated color balance value to channel
We found a case where untranslated values were being passed from the
proxy to the underlying channel, causing bad color balance values
in some setups.

Thanks to Sebastian Dröge for clarifying how the code works, and
suggesting the fix.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=701202
2013-05-29 20:20:10 +02:00
Brendan Long
96aab6d8a5 playbin: Don't take an extra reference to the custom stream combiners
They are automatically reffed when added to the bin because they're
already not floating anymore.
2013-05-29 20:12:48 +02:00
Sebastian Dröge
0dee7777ff playbin: Set custom stream-combiners to NULL and unref before finalizing 2013-05-29 10:35:11 +02:00
Brendan Long
53caa99a59 playbin: Rename select to combine and selector to combiner in playbin 2013-05-29 09:53:34 +02:00
Brendan Long
ba5f6cfe72 playbin: Add support for custom stream-combiners
This allows to chose something else than input-selector
for multiple audio/video/text streams, e.g. an adder could
be used for audio.

It is needed for example to implement some of the more
advanced HTML5 video features.

https://bugzilla.gnome.org/show_bug.cgi?id=698851
2013-05-29 09:52:32 +02:00
Sebastian Dröge
14192c031a decodebin: Don't call autoplug-query on shutdown
And remove leftover debug code
2013-05-28 13:32:23 +02:00
Sebastian Dröge
e482b5b8e6 playbin: In autoplug-queries, add the actual decoder/parser/etc template caps
Add the actual decoder/parser/etc caps at the very end to
make sure we don't cause empty caps to be returned, e.g.
if a parser asks us but a decoder is required after it
because no sink can handle the format directly.
2013-05-28 13:23:40 +02:00
Sebastian Dröge
a4ec6fe0b7 playbin: Forward CONTEXT queries to the corresponding sink if we have one
https://bugzilla.gnome.org/show_bug.cgi?id=700967
2013-05-28 13:14:15 +02:00
Sebastian Dröge
e5064ee723 playbin: Refactor autoplug-query handling
We now only check sinks and factories of the corresponding media
type. It doesn't make sense to pass audio/subtitle caps to a video
decoder.
2013-05-28 13:08:00 +02:00
Sebastian Dröge
d366613401 decodebin: Block on serialized queries too
Otherwise we will only block after the serialized, non-sticky event
after the CAPS event or the first buffer. If we're waiting for another
pad to finish autoplugging after we got final caps on this pad, it
will mean that we will let the ALLOCATION query pass although the
pad is not exposed yet.
2013-05-28 13:06:15 +02:00
Sebastian Dröge
9513b770f4 decodebin: Pass the element in the autoplug-query signal too 2013-05-28 12:10:33 +02:00
Sebastian Dröge
730e633d58 decodebin: Need to lock the chain mutex in autoplug_query 2013-05-28 11:40:51 +02:00
Sebastian Dröge
b86267b5be playsinkconvertbin: Fix leak of the downstream caps filter 2013-05-28 11:36:58 +02:00
Sebastian Dröge
db8d53bc17 playbin: Refactor autoplug-query handling a bit 2013-05-28 11:05:21 +02:00
Sebastian Dröge
fa7ad8743c decodebin: Lock the state of child elements as long as we manage their states
https://bugzilla.gnome.org/show_bug.cgi?id=690420
2013-05-24 13:41:46 +02:00
Sebastian Dröge
be4dba23ea Revert "decodebin2: use NO_RESYNC flag"
This reverts commit 0feecef275.
2013-05-24 11:47:13 +02:00
Sebastian Dröge
ca1279e4a3 decodebin: Use signal handler IDs instead of disconnecting by function
This is cleaner and faster.
2013-05-22 17:29:17 +02:00
Sebastian Dröge
504e57ccc5 decodebin: Connect and disconnect the have-type signal of typefind before starting/shutting down 2013-05-22 13:49:18 +02:00
Sebastian Dröge
1756f86042 playsink: Use signal handler IDs instead of disconnecting/blocking by function
This is cleaner and faster.
2013-05-21 16:35:18 +02:00
Sebastian Dröge
d802c7395a playback: Only do a subset filtering for the factories if we have fixed caps
Otherwise we're plugging a parser/converter currently and have unfixed caps.
2013-05-15 17:15:18 +02:00
Sebastian Dröge
062246fc6e decodebin: Return immediately from checking if a chain is complete if we're shutting down 2013-05-15 14:51:16 +02:00
Sebastian Dröge
83f2476976 decodebin: Hold the expose lock when freeing a chain
https://bugzilla.gnome.org/show_bug.cgi?id=700342
2013-05-15 14:47:53 +02:00
Sebastian Dröge
74a31a02fc playbin: Fix deadlock caused by lock order inversion
First the source group lock, then the elements list lock.
2013-05-15 13:38:32 +02:00
Sebastian Dröge
450a47c0a5 playback: Use subset checks instead of intersection
https://bugzilla.gnome.org/show_bug.cgi?id=700272
2013-05-14 10:07:44 +02:00
Sebastian Dröge
b0ec886cb9 playbin2: Chose more balanced metric to compare ranks of decoder/sink combinations 2013-05-09 15:05:21 +02:00
Sebastian Dröge
b23f4e4ab9 playbin: Fix infinite loop in GSequence iteration code 2013-05-08 21:27:17 +02:00
Sebastian Dröge
4c52518ef5 uridecodebin: Always store queue2 elements for later removal
Otherwise we accumulate more and more queue2 elements, and let each
of them start a thread doing nothing but waiting each time uridecodebin
goes to PAUSED.

https://bugzilla.gnome.org/show_bug.cgi?id=699794
2013-05-08 14:52:18 +02:00
Sebastian Dröge
7ff4f8f4d4 playbin: Use the GSequence more efficiently
This makes it possible to take advantage of the O(log n) lookups
of GSequence on the ~1000 element lists and only do iterations
on <10 element lists. Previously the code iterated over ~1000 element
lists multiple times.
2013-05-07 15:23:05 +02:00
Sreerenj Balachandran
52c5115ff0 playbin: Use GSequence instead of GList to store the GstAVElement list.
The GstAVElement list might be big. Use GSequence to optimize it.
2013-05-07 15:23:05 +02:00
Sreerenj Balachandran
a8d1b45491 playbin: autoplug the audio/video decoders and sinks based on capsfeatures.
Autoplug the decoder elements and sink elements based on
the number of common capsfeatures if the ranks are the same.
This will also helps to autoplug the h/w_decoder and h/w_renderer.

https://bugzilla.gnome.org/show_bug.cgi?id=698712
2013-05-07 15:23:05 +02:00
Sebastian Dröge
b719dd9f89 decodebin: Expose pads when they receive EOS before any buffers
Stops decodebin from waiting forever to expose a pad if there
is never data on it.

https://bugzilla.gnome.org/show_bug.cgi?id=691072
2013-05-06 15:49:00 +02:00
Sebastian Dröge
9c5c0ca878 streamsynchronizer: Fix check for belonging to another stream
https://bugzilla.gnome.org/show_bug.cgi?id=697820
2013-04-24 11:11:41 +02:00
Wim Taymans
c5840ebbd9 decodebin2: also remove the bytes limit
Remove the byte limit for adaptive http streaming. Because some fragments might
be very big, we might need a lot of buffering. I also suspect another problem
where data is actually missing and things go out of sync somehow.
2013-04-23 11:20:28 -03:00
Wim Taymans
26c5bc1ce4 decodebin2: update buffer size in multiqueue
When we disable buffering in the more upstream multiqueue elements,
we need to also update the queue limits. In particular, the max_size_time should
be set to 0 or else we might simply deadlock.
2013-04-23 11:20:28 -03:00
Thiago Santos
5cd07bd2af decodebin2: only allow 'lower' multiqueues to emit buffering messages
When we have a scenario of demuxers linked to demuxers, decodebin2
will create multiqueue at different levels of the pipeline. The problem
is that only the lowest multiqueue's should do the buffering messaging,
as they will handle with the raw streams data.

When all multiqueues are doing buffering, the upper ones can handle
large buffers that easily fill them, moving from 0% to 100% from
buffer to buffer, causing too much buffering messages to be posted.
This hangs the pipeline unnecessarily and might lead to deadlocks.
2013-04-23 11:20:28 -03:00
Thiago Santos
6382d4c0ad decodebin2: do not handle the next-groups list as if it was a single item
Decodebin2's chains store a next_groups list that was being handled as
it could only have a single element. This is true for most of the
chaining streams scenarios where streams change not very often.

In more stressfull changing scenarios, like adaptive streams, those
changes can happen very often, and in short time intervals. This could
confuse decodebin2 as this list was always being used as a single
element list.

This patches makes it handle as a real list, using iteration instead
of picking the first element as the correct one always.
2013-04-23 10:32:19 -03:00
Thiago Santos
054ffc6e2b decodebin2: preserve next groups order 2013-04-23 10:32:19 -03:00
Thiago Santos
42db7c7b08 decodebin2: still report chain as drained when not 'handled'
Even if the chain hasn't been 'handled' in this switching round,
report it as drained so upper chains/groups know abou it.

This makes switching happen on upper levels of the groups/chain
trees
2013-04-23 10:32:19 -03:00
Sebastian Dröge
d77f76049e streamsynchronizer: Don't consider a stream added for an already running one as "new"
Fixes enabling visualizations after disabling them after they were enabled already.
2013-04-23 13:54:49 +02:00
Sebastian Dröge
2e017bd595 streamsynchronizer: If a stream belongs to an already running stream, don't wait
This fixes enabling visualizations after the audio stream already started.

https://bugzilla.gnome.org/show_bug.cgi?id=697820
2013-04-23 13:19:38 +02:00
Tim-Philipp Müller
830926e47d uridecodebin: don't report 'no uri handler found' if the URI was rejected by a source
If a source element could be created for a URI, but all elements rejected
the URI for some reason, propagate the error from the URI handler instead
of reporting a 'no uri handler found for protocol xyz' error, which is
confusing. Fixes error reporting with dvb:// URIs when the channel config
file could not be found or not be parsed or the channel isn't listed.

https://bugzilla.gnome.org/show_bug.cgi?id=678892
2013-04-21 17:30:58 +01:00
Sreerenj Balachandran
9c94a1812f playbin: use _plugin_feature_rank_compare API instead of duplicating the code. 2013-04-18 13:59:52 +02:00
Sreerenj Balachandran
8cf6049643 decodebin: use _plugin_feature_rank_compare API instead of duplicating the code. 2013-04-18 13:59:36 +02:00
Philippe Normand
26fb72cf65 uridecodebin: query bandwidth capability to source element
Use a scheduling query to check if the source element has some
bandwidth limitations. If this is the case on-disk buffering might be
used. If the source element doesn't handle the scheduling query then
fallback to checking the URI protocol against the hardcoded list of
protocols known to handle buffering already.

Fixes bug 693484.
2013-04-16 16:47:28 +02:00
Sebastian Dröge
948a4a3632 gst: Add better support for static plugins 2013-04-15 15:52:58 +02:00
Sreerenj Balachandran
9b33c75cd4 playbin: use ascending order for name based sorting of pluginfeatures.
The compare_factories_func() should return negative value
if the rank of both PluginFeatures are equal and the name of
first PluginFeature comes before the second one (== ascending order).
2013-04-15 12:05:22 +02:00
Sreerenj Balachandran
f07eb23728 decodebin: use ascending order for name based sorting of pluginfeatures.
The _decode_bin_compare_factories_func() should return negative
value if the rank of both PluginFeatures are equal and the name of
first PluginFeature comes before the second one (== ascending order).
2013-04-15 12:05:16 +02:00
Tim-Philipp Müller
1c0288db38 playbin: fix jpeg passthrough to decoder sinks by marking image/* as video stream 2013-04-12 11:51:30 +01:00
Wim Taymans
92b77c5aa4 decodebin2: forward all sticky events to decodepad
Forward all sticky events to the decodepad before exposing the pads. This makes
sure all sticky events are on the exposed pad.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=696915
2013-04-04 15:00:52 +02:00
Wim Taymans
c082c06b6c decodebin: debug sticky events on exposed pads 2013-04-04 14:53:32 +02:00
Wim Taymans
08dd2454cd decodebin2: small cleanup
Take the event from the probe just once.
2013-04-04 14:37:15 +02:00
Wim Taymans
34eea4d5f2 streamsynchronizer: update position for reverse
When doing reverse playback the positino advances from timestamp_end to
timestamp.
2013-03-31 12:57:35 +02:00
Sebastian Dröge
3475d4f457 decodebin: Remove GstdecodePads that are not going to be exposed
This makes sure that they're unlnked and don't cause any errors or
block the pipeline.
2013-03-30 17:17:04 +01:00
Sebastian Dröge
7f78f7f9e3 playbin: Ignore caps from audio/video sink factories if there are fixed sinks already 2013-03-30 12:15:38 +01:00
Sebastian Dröge
57a0806b3a playbin: Handle caps queries from unlinked elements
Pass them to all possible sinks and the current sinks to
allow elements to chose a more optimal initial caps.
2013-03-30 11:49:42 +01:00
Sebastian Dröge
0932391d3f decodebin: Add autoplug-query signal to handle queries for yet unconnected elements
This allows playbin to answer the CAPS query with the possible sink
caps for example, and allows decoders to chose more optimal caps.
2013-03-30 11:49:42 +01:00
Sebastian Dröge
9ce0818c7d decodebin: Don't add a children to a decode group twice
This can happen if a demuxer does not provide fixed caps from the
beginning but only sets them later.
2013-03-30 11:49:42 +01:00
Stefan Sauer
f19acfc60b uridecodebin: remove commented code
This is dead since ~6 years.
2013-03-28 12:36:51 +01:00
Sebastian Dröge
383f58b0ed subtitleoverlay: Return ANY caps for the GET_CAPS query
subtitleoverlay handles any caps, not just the ones
for which a subtitle parser/renderer exist. It will
just ignore any unsupported streams instead of causing
an error.

https://bugzilla.gnome.org/show_bug.cgi?id=688476
2013-03-21 15:37:31 +01:00
Sebastian Dröge
9084bc151b playsinkconvertbin: Make sure to return all allowed caps in the GET_CAPS query
Add all the caps that we can convert to to the filter caps,
otherwise downstream might just return EMPTY caps because
it doesn't handle the filter caps but we could still convert
to these caps, causing us to return EMPTY caps although
conversion would be possible.

https://bugzilla.gnome.org/show_bug.cgi?id=688803
2013-03-21 13:42:41 +01:00
Sebastian Dröge
d06c332655 playsinkconvertbin: Use gst_caps_is_subset() for handling the ACCEPT_CAPS query 2013-03-21 11:42:43 +01:00
Tim-Philipp Müller
7dd2fad888 uridecodebin: minor GValue handling optimisation 2013-03-03 17:44:11 +00:00
Matej Knopp
1e5b50e94c decodebin: don't block on caps 2013-02-14 11:37:54 +01:00
Sebastian Dröge
cfd73a8cf7 decodebin: Remove left-over line from last commit 2013-02-14 11:25:37 +01:00
Matej Knopp
872cc295a6 decodebin: Check if value is set before unsetting it
https://bugzilla.gnome.org/show_bug.cgi?id=693401
2013-02-14 11:22:34 +01:00
Alexander Schrab
e7caef6b29 decodebin: Push caps event immediately to ghost pad to avoid exposing pads without caps 2013-02-12 10:12:14 +01:00
Marc Leeman
f704b3f975 decodebin: g_mutex_new -> g_mutex_init
Don't use deprecated GLib API.

https://bugzilla.gnome.org/show_bug.cgi?id=693302
2013-02-07 13:51:17 +00:00
Tim-Philipp Müller
500b864899 decodebin: try harder to always expose pads in the same order
Use stream-id as sort criterion in addition to the media type.

https://bugzilla.gnome.org/show_bug.cgi?id=634407
2013-01-19 13:03:03 +00:00
Wim Taymans
0feecef275 decodebin2: use NO_RESYNC flag
to avoid the state change function from messing with the state of the elements
that we add.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=690420
2012-12-21 16:38:36 +01:00
Wim Taymans
66cafcc34d playsink: fix vis switch with format change
Block the pad before the resample and convertor elements to give the a chance to
negotiate new caps with the newly switched vis plugin.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=679976
2012-12-13 11:34:54 +01:00
Tim-Philipp Müller
7c89a7298a streamsynchronizer: don't send gap events with huge bogus durations when advancing EOS streams
When the input buffers for a stream don't have a duration set,
timestamp_end might still be GST_CLOCK_TIME_NONE. When advancing
EOSed streams via GAP events (with other streams not yet EOS), we
would then use the invalid timestamp_end to calculate the duration
of the gap. This in turn would make baseaudiosink abort, because it
would try to allocate memory for a trizillion samples.

So if buffers don't have a duration set, assume a duration of
one second for stream catch-up purposes, just so we can still
continue to catch up in those cases. And make sure that
timestamp_end is valid before doing calculations with it.

http://bugzilla.gnome.org/show_bug.cgi?id=678530
2012-11-26 19:03:38 +00:00
Tim-Philipp Müller
601aabdf9c streamsynchronizer: reduce debug log spam a bit
Log locking/unlocking with TRACE debug level.
2012-11-25 18:07:04 +00:00
Sebastian Dröge
830b500d40 decodebin: Set element to NULL state before removing it from the bin 2012-11-22 13:09:46 +01:00
Sebastian Dröge
2faef82b9a decodebin: Check if the element really accepts the caps after setting it to READY
It might know the caps constraints for sure only after opening a decoder.
2012-11-22 13:07:11 +01:00
Sebastian Dröge
4f480612e9 streamsynchronizer: Make the element public
https://bugzilla.gnome.org/show_bug.cgi?id=688240
2012-11-21 10:29:44 +01:00
Tim-Philipp Müller
5f59b4f7ee Fix FSF address
https://bugzilla.gnome.org/show_bug.cgi?id=687520
2012-11-03 23:05:09 +00:00
Sebastian Dröge
b9d4d0cd29 streamsynchronizer: Also send a GAP event to let audio sinks start their clock in case they did not have enough data yet 2012-10-24 13:34:15 +02:00
Sebastian Dröge
6a31051feb streamsynchronizer: Use correct timestamp/duration for the GAP events 2012-10-24 13:29:45 +02:00
Sebastian Dröge
3c1041d5eb Revert "gst: Add better support for static plugins"
This reverts commit d2d79e3bc2,
which was accidentially pushed.
2012-10-24 13:26:26 +02:00
Sebastian Dröge
52d48109bc streamsynchronizer: Send GAP events to advance streams 2012-10-24 13:25:19 +02:00
Sebastian Dröge
d2d79e3bc2 gst: Add better support for static plugins 2012-10-24 12:10:44 +02:00
Sebastian Dröge
7b12afa4cb streamsynchronizer: Create a GAP event with a sensible timestamp 2012-10-24 11:19:06 +02:00
Sebastian Dröge
356579157e streamsynchronizer: Also propagate return value of pushing GAP event upstream 2012-10-23 18:21:32 +02:00
Sebastian Dröge
120c7be970 streamsynchronizer: Return TRUE from the EOS handler 2012-10-23 17:38:43 +02:00
David Corvoysier
87fd43aaaa decodebin2: Fix group switching algorithm
There were two issues with the previous decodebin2 group switching algorithm:

Issue 1: It operated with no memory of what has been drained or not, leading to
multiple checks for chains/groups that were already drained.

Issue 2: When receiving an EOS, it only detected that a higher-level chain
was drained if it contained the pad receiving the EOS.

The following modifications have been applied:
- a new drained property has been added to GstDecodeChain
- both drained properties of chain/group are set as soon as they are detected
- the algorithm now tests agains these values

See https://bugzilla.gnome.org/show_bug.cgi?id=685938
2012-10-14 10:58:18 +02:00
Sebastian Dröge
80e4f3e912 playsinkconvertbin: Change GST_WARNING to GST_INFO
It's not a problem if we have no converters, this only means
that none were requested at this point.
2012-10-10 11:50:12 +02:00
Wim Taymans
3591df23b1 docs: playbin2 -> playbin 2012-10-09 12:20:10 +02:00
Tim-Philipp Müller
81097f485a playback: class_ref() some types so we can create multiple playback elements at the same time
Should fix "cannot register existing type `GstPlaybinSelectorPad'" warnings
and subsequent errors when creating multiple players at the same time.

Conflicts:
	gst/playback/gststreamselector.c
2012-10-03 11:48:25 +01:00
Tim-Philipp Müller
6842698f0d Purge all references to liboil
And remove unused ffmpegcolorspace tests in the process.

https://bugzilla.gnome.org/show_bug.cgi?id=673285
2012-09-29 11:47:52 +01:00
Sebastian Dröge
b19944d1e4 gst: Update for link/unlink function API change 2012-09-17 13:24:52 +02:00