Commit graph

414 commits

Author SHA1 Message Date
Thiago Santos
cf50b45ff6 decodebin: add missing 'time' word to debug message
It prints the buffers, bytes and time limits, but 'time' was missing
from the string.
2014-07-29 15:55:27 -03:00
Sebastian Dröge
f173fa15b1 decodebin: Don't unref caps for which we don't own a reference... get one first
https://bugzilla.gnome.org/show_bug.cgi?id=733615
2014-07-23 19:51:36 +02:00
Sebastian Dröge
b15a47aa19 decodebin: Link Parser/Converter directly and already connect to pad-added and other signals before setting elements to PAUSED
otherwise we're going to
a) start Parser/Converter before they are linked to their capsfilter,
   breaking their negotiation of a proper stream format
b) start demuxers without having connected to their pad-added signals. We
   miss pads and in the worst case don't link any pads at all
2014-07-21 09:35:36 +02:00
Sebastian Dröge
57999c28fd decodebin: Send sticky events to the new element after setting it to PAUSED
... and if this fails for whatever reason we skip the element and instead
try with the next element. This allows us to handle elements that fail
when setting caps on them by just skipping to the next alternative element.
2014-07-21 09:35:36 +02:00
Sebastian Dröge
994680b04e decodebin: Only link elements further after setting them to PAUSED
They might fail to go to PAUSED, and when connecting them further
we might already expose their srcpads on decodebin if we're unlucky.
This prevents us to handle failures going to PAUSED gracefully.
2014-07-21 09:35:36 +02:00
Sebastian Dröge
83d508a552 decodebin: Remove ERROR message filter after we set the element to PAUSED
This allows us to catch more errors gracefully and switch to an alternative
element instead.
2014-07-21 09:35:05 +02:00
Sebastian Dröge
f66555668a decodebin: Only continue autoplugging once the pad has final caps
If the caps query returned us fixed caps this doesn't mean yet
that these caps are actually complete (fields might be missing).

It allows to do us some decisions, but the selection of the next
element should be delayed as only complete caps allow proper selection
of the next element.
2014-07-21 09:35:05 +02:00
Sebastian Dröge
424ff91394 decodebin: Consider the caps after the capsfilter after parsers for autoplugging
Otherwise we might try to continue autoplugging e.g. for a specific
stream-format although the parser could convert to something else, thus giving
us potentially less options for decoders.
2014-07-21 09:35:05 +02:00
Sebastian Dröge
393f090197 decodebin: Do async-done on expose errors too 2014-06-04 17:00:43 +02:00
Thiago Santos
783195ccef decodebin: aggregate buffering messages
Aggregate buffering messages to only post the lower value
to avoid setting pipeline to playing while any multiqueue
is still buffering.

There are 3 scenarios where the entries should be removed from
the list:

1) When decodebin is set to READY
2) When an element posts a 100% buffering (already implemented)
3) When a multiqueue is removed from decodebin.

For item 3 we don't need to handle it because this should only
happen when either 1 is hapenning or when it is playing a
chained file, for which number 2 should have happened for the
previous stream to finish

https://bugzilla.gnome.org/show_bug.cgi?id=726423
2014-05-29 18:59:30 -03:00
Vincent Penquerc'h
9e99a1ca41 decodebin: consider "no demuxer" case to not have dynamic pads
This fixes a possible NULL dereference.

Coverity 1195146
2014-04-10 13:51:18 +01:00
Sebastian Dröge
2c2e286c38 decodebin: In adaptive streaming mode, only have a fixed buffer limit for the non-buffering multiqueue 2014-04-09 16:06:06 +02:00
Sebastian Dröge
5e364c1d7b decodebin: Buffer up to 5 seconds in multiqueue buffering mode
2 seconds might be too small for some container formats, e.g.
MPEGTS with some video codec and AAC/ADTS audio with 700ms
long buffers. The video branch of multiqueue can run full while
the audio branch is completely empty, especially because there
are usually more queues downstream on the audio branch.
2014-03-07 17:09:24 +01:00
Sebastian Dröge
539eaf73e5 decodebin: Keep the number of buffers after an adaptive streaming demuxer lower
Usually these buffers are multiple seconds large, and having a maximum
of 5 buffers in the multiqueue there can use a lot of memory. Lower
this to 2 for adaptive streaming demuxers.
2014-03-06 22:45:30 +01:00
Sebastian Dröge
274b4eb870 decodebin: Simplify adaptive streaming demuxer code a bit 2014-03-06 22:45:30 +01:00
Sebastian Dröge
2df1e56bb7 decodebin: If we have a demuxer without dynamic srcpads, just assume no-more-pads
Otherwise we will wait until the multiqueue after the demuxer will
overrun, which is clearly not needed then.
2014-02-23 00:10:01 +01:00
Sebastian Dröge
f149c27a61 decodebin: Also make sure to not duplicate an element factory after a group
If we are using an adaptive stream demuxer, which outputs a non-container
stream, we are putting another multiqueue after the *parser* following
the adaptive stream demuxer. We do not want to add another instance of
the same parser right after this multiqueue.
2014-02-23 00:10:01 +01:00
Sebastian Dröge
41117606dd decodebin: During pre-rolling always use the auto-preroll limits on multiqueues
Even if we're buffering in the multiqueues.
2014-02-23 00:10:01 +01:00
Sebastian Dröge
2d2aa02b77 decodebin: Pass through the seekability information when setting multiqueue limits 2014-02-23 00:10:01 +01:00
Sebastian Dröge
db771185ed decodebin: During exposing of pads don't set the multiqueue limits multiple times to different values
Instead just set them once in the very end to the correct values.
2014-02-23 00:10:01 +01:00
Sebastian Dröge
c4caeb73ce decodebin: Only enable multiqueue buffering once we're pre-rolled
Otherwise we will emit buffering messages not just from the last
multiqueue but also from previous multiqueues... confusing the
application with different percentages during pre-rolling.
2014-02-23 00:10:01 +01:00
Sebastian Dröge
4f32010916 decodebin: Make sure that we always have a second multiqueue for adaptive streaming demuxers
For adaptive streaming demuxer we insert a multiqueue after
this demuxer. This multiqueue will get one fragment per buffer.
Now for the case where we have a container stream inside these
buffers, another demuxer will be plugged and after this second
demuxer there will be a second multiqueue. This second multiqueue
will get smaller buffers and will be the one emitting buffering
messages.
If we don't have a container stream inside the fragment buffers,
we'll insert a multiqueue below right after the next element after
the adaptive streaming demuxer. This is going to be a parser or
decoder, and will output smaller buffers.
2014-02-23 00:10:00 +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
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
Tim-Philipp Müller
b1ff48c1a1 docs: remove old 0.10 Since markers
They're just confusing.
2013-11-16 16:10:07 +00: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
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
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
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
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
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
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
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
Sreerenj Balachandran
8cf6049643 decodebin: use _plugin_feature_rank_compare API instead of duplicating the code. 2013-04-18 13:59:36 +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
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
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
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
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
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
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
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
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
Mark Nauwelaerts
e491d24341 use gst_element_factory_get_metadata to replace obsolete API 2012-09-15 18:57:09 +02:00
Tim-Philipp Müller
2079a8c12b Remove glib-compat-private.h stuff we don't need any more
It's all been ported to the latest GLib API now.
2012-09-09 18:36:49 +01:00
Edward Hervey
2f37ba60a2 decodebin2: Mark streams as complete on CAPS event but don't block
This allows the following use-cases to expose the group and pads
before an ALLOCATION query comes through:
* Single stream use-cases
* Multi stream use-cases where all streams sent the CAPS event before
  the first ALLOCATION query

Some cases will still make the initial ALLOCATION query fail though,
which isn't optimal, but not fatal (it will recover when pads are
exposed, a RECONFIGURE event is sent upstream and elements can
re-send an ALLOCATION query which will reach downstream elements).

https://bugzilla.gnome.org/show_bug.cgi?id=680262
2012-07-24 10:53:19 +02:00
Edward Hervey
c5901cebca decodebin: Block on caps event
A caps event is also used to establish that a stream has prerolled.

Without this, we end up allowing negotiation queries to fail, ending
in decoders (and other elements) to not be configured right from the
start with the most optimal settings.
2012-07-18 18:17:57 +02:00
Edward Hervey
dad72182a0 decodebin2: Demote WARNING to DEBUG
Delaying auto-plugging is quite common
2012-07-12 09:51:36 +02:00
Wim Taymans
a476b6cbfb decodebin2: improve debug 2012-07-11 15:39:37 +02:00
Tim-Philipp Müller
1dea99ded3 decodebin: make GValueArray arguments in autoplug-* signals static scope to avoid copies 2012-07-09 08:35:22 +01:00
Wim Taymans
655fef3dbf update for message api change 2012-06-13 11:04:34 +02:00
Sebastian Dröge
e729ad1c9c playback: Always prefer parsers over decoders
...and in playbin2 additionally prefer sinks over parsers.

This makes sure that we a) always directly plug a sink if it supports
the (compressed) format and b) always plug parsers in front of decoders.
2012-06-12 11:59:39 +02:00
Wim Taymans
cd1d6f7d2d decodebin2: fix format strings 2012-05-11 15:33:31 +02:00
Wim Taymans
163720246e decodebin2: fix compilation 2012-05-11 09:26:47 +02:00
Thibault Saunier
445c41963b playback: Check type when setting "connection-speed" on unknown elements
Clamp the values if needed
2012-05-10 13:21:04 -04:00
Thibault Saunier
ee4ae0041c decodebin2: Add a connection-speed property to set it on demuxers when needed
Proxy it from uridecodebin
2012-05-10 13:11:47 -04:00
Matej Knopp
b6765417e1 decodebin: Do not block on sticky and oob events 2012-04-16 13:49:07 +02:00
Sebastian Dröge
fe9041bd05 decodebin2: Check that properties have the correct type before using them 2012-04-16 08:27:20 +02:00
Tim-Philipp Müller
3c6a3ad629 Use new gst_element_class_set_static_metadata() 2012-04-10 00:45:16 +01:00
Wim Taymans
25137962ad fix for caps API changes 2012-03-11 19:04:41 +01:00
Sebastian Dröge
006f8f8275 gst: Update for gstmarshal.[ch] removal 2012-03-02 11:15:02 +01:00
Tim-Philipp Müller
4738e02bbf playback: suppress GValueArray deprecation warnings for the time being
until this gets sorted out and we have a viable alternative.

https://bugzilla.gnome.org/show_bug.cgi?id=667228
2012-02-01 15:50:52 +00:00
Sebastian Dröge
130a8335a0 Merge branch 'master' into 0.11
Conflicts:
	gst/playback/gstdecodebin2.c
2012-01-25 12:29:11 +01:00
Sebastian Dröge
711e6a12ef Revert "decodebin2: Prune old groups before switching to the new one"
This reverts commit e2a038acee.

This wasn't entirely correct yet and needs some changes here
and there.
2012-01-25 12:25:05 +01:00
Sebastian Dröge
7e5aeba02f decodebin2: Fix merge error 2012-01-25 12:04:24 +01:00
Sebastian Dröge
68c0790817 Merge branch 'master' into 0.11
Conflicts:
	gst-libs/gst/interfaces/propertyprobe.c
	sys/xvimage/xvimagesink.c
2012-01-25 11:50:54 +01:00
Wim Taymans
3d42f0f6ed port to new glib thread API 2012-01-19 11:36:17 +01:00
Youness Alaoui
e2a038acee decodebin2: Prune old groups before switching to the new one
In order to allow for proper functionality when a decoder only supports
one instance at a time (dsp), we must block the demuxer pads when they
get created if they are not part of the active group, preventing buffers
from being sent to the decoder (and initializing it through setcaps),
then after we switch to a new group, we unblock the demuxer pads for
the active groups. In the callback for the unblock, we prune the old
groups, making sure the previous decoder instance is destroyed before
we push a buffer to the new instance.
2012-01-19 09:04:52 +01:00
Edward Hervey
f5f781e8fb Revert "decodebin2: Try harder to get initial topology caps"
This reverts commit 6b3e3544d4.

I really shouldn't put WIP commits in my main branch ...
2012-01-06 15:40:06 +01:00
Edward Hervey
6b3e3544d4 decodebin2: Try harder to get initial topology caps
Since caps are no longer 'shared' between two pads (but forwarded from
source pad to sink pad) we end up with the first chain pad not having
specified caps (i.e. typefind:src).

This solves the issues by getting the pad's peer caps.

It is not optimal since it will (for most demuxers) return the pad
template caps, which might contain non-fixed caps (ex : with
qtdemux "video/quicktime; video/mj2; audio/x-m4a; application/x-3gp")

https://bugzilla.gnome.org/show_bug.cgi?id=667337
2012-01-06 14:40:25 +01:00
Tim-Philipp Müller
26e612aeda playback, mixerutils: gst_registry_get_default() -> gst_registry_get() 2012-01-02 14:32:11 +00:00
Edward Hervey
f562a29284 Merge remote-tracking branch 'origin/master' into 0.11
Conflicts:
	ext/theora/gsttheoraenc.c
	gst-libs/gst/tag/gstexiftag.c
	gst/adder/gstadder.c
	gst/adder/gstadder.h
	gst/playback/gstdecodebin2.c
	gst/playback/gstsubtitleoverlay.c
	tests/check/libs/tag.c
2011-12-30 13:21:35 +01:00
Mark Nauwelaerts
60d5d08fbb decodebin2: tweak chain topology description
... to also properly indicate chain's endpad if no elements are in the
chain (due to the endpad being a raw demuxer pad, or one setup without
decoders since uridecodebin or higher up decided not to need those).
2011-12-14 17:53:38 +01:00
Tim-Philipp Müller
fb6d09055a Merge remote-tracking branch 'origin/master' into 0.11
Conflicts:
	ext/alsa/gstalsadeviceprobe.c
	ext/alsa/gstalsamixer.c
	ext/pango/gsttextoverlay.c
	ext/pango/gsttextoverlay.h
	gst-libs/gst/audio/gstaudiobasesink.c
	gst-libs/gst/audio/gstaudioringbuffer.c
	gst-libs/gst/audio/gstaudiosrc.c
	gst-libs/gst/video/Makefile.am
	gst-libs/gst/video/video.c
	gst/encoding/gststreamcombiner.c
	gst/encoding/gststreamsplitter.c
	gst/playback/gstplaybasebin.c
	gst/playback/gststreamsynchronizer.c
	gst/playback/gstsubtitleoverlay.c
	gst/playback/gsturidecodebin.c
	sys/xvimage/xvimagesink.c
	tests/examples/Makefile.am
	win32/common/libgstvideo.def

Video overlay composition disabled for now, needs
porting to buffer meta.
2011-12-08 01:19:03 +00: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
177525f89f Merge remote-tracking branch 'origin/master' into 0.11
Conflicts:
	gst-libs/gst/netbuffer/gstnetbuffer.c
	gst/ffmpegcolorspace/avcodec.h
	gst/ffmpegcolorspace/gstffmpegcodecmap.c
	gst/ffmpegcolorspace/imgconvert.c
	gst/ffmpegcolorspace/imgconvert_template.h
	gst/ffmpegcolorspace/mem.c
	gst/playback/README
	gst/playback/gstplaybasebin.c
	gst/playback/gstplaybasebin.h
	gst/playback/gstplaybin.c
	sys/v4l/v4lmjpegsrc_calls.c
	sys/v4l/videodev_mjpeg.h
	tests/check/elements/gnomevfssink.c
2011-12-02 11:10:17 +00:00
Piotr Fusik
14644457b0 various: typo fixes
Fix typos in code and docs. Fixes. #658984
2011-12-02 12:03:27 +01: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
Tim-Philipp Müller
32b14c6ed3 Merge remote-tracking branch 'origin/master' into 0.11
Conflicts:
	ext/vorbis/gstvorbisenc.c
	gst/playback/gstdecodebin2.c
	gst/playback/gstplaysinkconvertbin.c
	gst/videorate/gstvideorate.c
2011-11-26 12:12:59 +00:00
Sebastian Dröge
a5535e76e0 decodebin2: Set the multiqueue limits to the playing limits after overrun too
We don't expect any new pads anymore and prerolling is finished now.
2011-11-25 11:12:10 +01:00
Sebastian Dröge
494b2cb1a7 decodebin2: Cache the upstream seekability for demuxer decode chains and use it for the non-preroll multiqueue limits
After preroll the multiqueue limits are still set to the preroll
limits if use-buffering is set to TRUE. In that case we only want
time limits on the multiqueue if upstream is seekable.
2011-11-25 11:12:10 +01:00
Vincent Penquerc'h
59f5d980f6 decodebin2: fix prerolling for low bitrate streams from hlsdemux
Such streams were detected as seekable, as the query on the typefind
element was testing the m3u8 file listing the actual streams, and
not going through the demuxer(s).

We now check for seekability for each multiqueue following a demuxer,
so the query will flow through the elements which might prevent seeking.

https://bugzilla.gnome.org/show_bug.cgi?id=647769
2011-11-25 11:12:10 +01:00
Wim Taymans
28157e6f21 _query_peer_*() -> _peer_query_*() 2011-11-15 18:04:17 +01:00
Wim Taymans
7402d3a3d2 update for _get_caps() -> _query_caps() 2011-11-15 18:04:17 +01:00
Wim Taymans
308f6301a8 update for pad probe api changes 2011-11-08 11:08:21 +01:00
Wim Taymans
616e9b706e fix for new pad probe types
Restore the previous behaviour by only blocking downstream items and not
upstream events.
2011-11-07 17:10:48 +01:00
Wim Taymans
7ac25e9b26 Merge branch 'master' into 0.11
Conflicts:
	common
	configure.ac
	gst-libs/gst/audio/gstbaseaudiosink.c
	gst/playback/gstdecodebin2.c
	gst/playback/gstplaysinkaudioconvert.c
	gst/playback/gstplaysinkaudioconvert.h
	gst/playback/gstplaysinkvideoconvert.c
	gst/playback/gstplaysinkvideoconvert.h
2011-11-07 12:23:15 +01:00
Wim Taymans
cf8481b990 fix pad template names for request pads 2011-11-04 10:49:48 +01:00
Wim Taymans
57fe2addef update for request pads change. 2011-11-03 17:58:57 +01:00
Mart Raudsepp
5c58bcfd15 decodebin2: Post all source pads in stream-topology messages as "element-srcpad" values
This allows us to easily get ahold of all pads on a stream-topology message, including
pre-decoder ones, while "pad" only gives us access to the raw pads (as used by discoverer).
2011-11-03 14:41:08 +01:00
Mart Raudsepp
cee8710817 decodebin2: Use existing "caps" quark for one of the structure sets 2011-11-03 14:40:51 +01:00
Wim Taymans
5bdfd6d899 structure: fix for api update 2011-11-02 09:04:27 +01:00
Tim-Philipp Müller
b52c5819fb Update for pad API changes
GstProbeType, GstProbeReturn and GstActivateMode -> GstPad*
2011-11-01 00:34:28 +00:00
Wim Taymans
016d036137 Merge branch 'master' into 0.11
Conflicts:
	configure.ac
	gst-libs/gst/audio/gstbaseaudiosink.c
	gst/audioconvert/channelmixtest.c
	gst/playback/gstplaybasebin.c
	gst/playback/gstsubtitleoverlay.c
	tests/examples/Makefile.am
	tests/examples/audio/Makefile.am
2011-10-27 15:44:58 +02:00
Nicolas Dufresne
cf9da5c280 decodebin2: Link elements before testing if they can reach the READY state
This is made possible by filtering errors. This is required to let
harware accelerated element query the video context. The video context
is used to determine if the HW is capable, and thus if the element is
supported or not.

Fixes bug #662330.
2011-10-22 08:27:31 +02:00
Vincent Penquerc'h
5e9862b2ba decodebin2: fire drained signal where appropriate
This will allow playbin2 to send its about-to-finish signal.
Taken out (apparently by mistake) by the EOS rewrite in july.

https://bugzilla.gnome.org/show_bug.cgi?id=661202
2011-10-17 15:36:25 +02:00
Wim Taymans
a00927ad03 Merge branch 'master' into 0.11 2011-10-04 17:58:49 +02:00
Sebastian Dröge
9117681b35 decodebin2: Use a TIME limit for pre-rolling in live streams and not in non-live streams
Fixes bug #647769 for real.
2011-10-03 10:55:53 +02:00
Edward Hervey
17bfba09f1 Merge branch 'master' into 0.11
Conflicts:
	ext/ogg/gstoggdemux.c
	ext/pango/gsttextoverlay.c
	gst-libs/gst/audio/gstaudioencoder.c
	gst-libs/gst/audio/gstbaseaudiosrc.c
	gst/playback/gstsubtitleoverlay.c
	gst/videorate/gstvideorate.c
2011-09-23 18:27:11 +02:00
Sebastian Dröge
61c6fcb2cd decodebin2: Only check if this is a discarded type if we have fixed caps
For unfixed caps we will get here again later when the caps are fixed.
2011-09-20 14:06:51 +02:00
Sebastian Dröge
8e114c427a decodebin2: Only call autoplug-continue with fixed caps
With unfixed caps we can't reliably decide if the final caps
are going to be "raw" (e.g. supported by a sink) or not.

We will get here again later when the caps are fixed.
2011-09-20 14:06:42 +02:00
Youness Alaoui
27058c1bc6 decodebin2: Initialize variable correctly
If subdrained isn't initialized to FALSE then a chain might think
that its group is drained when in fact it's not and this can cause
a switch too early or even cause a deadlock.
2011-09-19 12:36:48 +02:00
Edward Hervey
9d2bcb08fe decodebin2: Rewrite EOS-handling code
This is now really threadsafe and improves switching
between different groups.
2011-09-19 12:34:51 +02:00
Sebastian Dröge
936e87cdcf decodebin2: Fix non-prerolling pipelines and not-linked errors if a parser is available but no decoder
Fixes bug #658846.
2011-09-19 11:54:27 +02:00
Sebastian Dröge
21bc8ddcb7 Revert "Revert "decodebin2: Do a subset check before actually using a factory""
This reverts commit 5f5d832a3b.
2011-09-08 14:42:13 +02:00
Sebastian Dröge
0f654f3feb Merge branch 'master' into 0.11
Conflicts:
	docs/libs/Makefile.am
	tests/check/elements/decodebin2.c
2011-09-08 14:42:00 +02:00
Sebastian Dröge
5f5d832a3b Revert "decodebin2: Do a subset check before actually using a factory"
This reverts commit 50a88396ae.

See bug #658541.
2011-09-08 13:25:27 +02:00
Sebastian Dröge
9e2ce5bbb5 decodebin2: Make sure to fixate Parser/Converter caps before continuing autoplugging 2011-09-07 16:44:59 +02:00
Sebastian Dröge
46e26824d4 decodebin2: Intersect the factory caps with the current caps for the capsfilter
Otherwise we'll include many incompatible caps in the capsfilter that
will only slow down negotiation.
2011-09-07 14:20:36 +02:00
Tim-Philipp Müller
f93748fbd4 decodebin2: fix element factory refcounting
g_value_get_object() does not give us our own ref.

Fixes "Trying to dispose object "flacparse", but it still has a parent "registry0".
You need to let the parent manage the object instead of unreffing the object directly."
and similar warnings.

https://bugzilla.gnome.org/show_bug.cgi?id=658416
2011-09-07 12:34:06 +01:00
Wim Taymans
8ee3da5bba Merge branch 'master' into 0.11
Conflicts:
	gst/playback/gstsubtitleoverlay.c
	tests/check/elements/decodebin2.c
2011-09-06 15:31:53 +02:00
Wim Taymans
7012e88090 Merge branch 'master' into 0.11
Conflicts:
	gst-libs/gst/audio/audio.h
	gst-libs/gst/audio/gstaudiodecoder.c
	gst-libs/gst/audio/gstaudiodecoder.h
	gst-libs/gst/audio/gstaudioencoder.c
	gst-libs/gst/audio/gstbaseaudioencoder.h
	gst/playback/Makefile.am
	gst/playback/gstplaybin.c
	gst/playback/gstplaysink.c
	gst/playback/gstplaysinkvideoconvert.c
	gst/playback/gstsubtitleoverlay.c
	gst/videorate/gstvideorate.c
	gst/videoscale/gstvideoscale.c
	win32/common/libgstaudio.def
2011-09-06 15:24:32 +02:00
Sebastian Dröge
50a88396ae decodebin2: Do a subset check before actually using a factory
This prevents autoplugging if the caps have a non-empty intersection
but are not accepted by the next element's pad.
2011-09-06 14:16:10 +02:00
Sebastian Dröge
4be8c44b08 decodebin2: Fix memory leak 2011-09-06 13:16:44 +02:00
Sebastian Dröge
20f9d0bec5 decodebin2: Correctly negotiate format for parsers that can convert different stream formats
This is done by adding a capsfilter after every parser/converter that contains
all possible caps supported by downstream elements. A capsfilter is necessary
here because the decoder is only selected after the parser selected a format
and the parser can't know what downstream would support otherwise.
2011-09-06 13:16:44 +02:00
Sebastian Dröge
de4fc848fa decodebin2: Actually iterate over the factories instead of only taking the first one 2011-09-05 20:32:42 +02:00
Sebastian Dröge
425d3ae7bc decodebin2: Keep the chain mutex locked while connecting to the notify::caps signal 2011-08-31 12:40:30 +02:00
Wim Taymans
33467d9629 Merge branch 'master' into 0.11
Conflicts:
	configure.ac
	ext/pango/gsttextoverlay.c
	ext/theora/gsttheoradec.c
	gst/adder/gstadder.c
	gst/adder/gstadder.h
	gst/audioresample/gstaudioresample.c
	gst/encoding/gstencodebin.c
	gst/playback/gstdecodebin.c
	gst/playback/gstdecodebin2.c
	tests/check/elements/decodebin2.c
	tests/check/elements/playbin-compressed.c
	win32/common/libgsttag.def
2011-08-16 18:01:14 +02:00
Wim Taymans
e904c529e3 fix for _negotiated_caps() change 2011-08-15 12:18:15 +02:00
Tim-Philipp Müller
bb65192151 ext,gst: update for query API changes 2011-07-27 01:16:53 +01:00
Edward Hervey
38a6919a7b decodebin2: Allow all EOS to go through if we don't have a next group
Only drop them if the current group isn't drained .. AND there is a
next group to switch to.

Should Fix #655268
2011-07-26 12:33:56 +02:00
Edward Hervey
c91928f7a2 decodebin2: Properly handle multi-stream chains
When we have a multi-stream (i.e. audio and video) input and the demuxer
adds/removes pads for a new stream (common in a mpeg-ts stream when the
program stream mapping is updated), the algorithm for EOS handling was
previously wrong (it would only drop the EOS of the *last* pad but would
let the EOS on the other pads go through).

The logic has only been changed a tiny bit for EOS handling resulting in:
* If there is no next group, let the EOS go through
* If there is a next group, but not all pads are drained in the active
  group, drop the EOS event
* If there is a next group and all pads are drained, then the ghostpads
  will be removed and the EOS event will be dropped automatically.
2011-07-25 10:45:36 +02:00
Wim Taymans
d06f599193 -base: port elements to new video caps 2011-06-16 12:52:13 +02:00
Tim-Philipp Müller
59581d464f uridecodebin, decodebin: remove new-decoded-pad and removed-decoded-pad signals
They were deprecated, use "pad-added" and "pad-removed" instead.
2011-06-15 00:32:23 +01:00
Tim-Philipp Müller
5fd073e070 playback: merge playbin and decodebin plugins into one single playback plugin again 2011-06-15 00:02:13 +01:00