Just counting how many messages were sent and how many were received
is not good enough because they might've been duplicated (e.g. by the
visualization audio tee). Comparing the sequence numbers should give
better results in that case.
Otherwise the async state change from READY->PAUSED of the
uridecodebins will take playbin2 from PLAYING->PAUSED again
during gapless group switches.
Fixes bug #602000.
When a decodebin2 receives no-more-pads of a group it
can set that group's multiqueue buffering thresholds to
'playing' buffering method, avoiding that it buffers
too long and cause problems when using with queue2.
See the associated bug for details.
Fixes#600787
During a group switch return the cached duration of the old group
because the old group still didn't finish playback. If we have no
cached duration return FALSE.
Fixes bug #585969.
Make sure, to only "simulate" subtitle no-more-pads if it was still
pending and also handle errors in the subtitle pipeline as warnings
after the subtitles prerolled.
Don't set the suburidecodebin to READY after errors, handle_message
will usually be called from the streaming thread and doing that
from there is obviously not a good idea.
Now the caps property isn't set anymore for the subtitle caps
but instead in the autoplug-continue signal it is detected
if the caps belong to a supported subtitle stream.
This makes automatic use of newly installed plugins.
First of all, make sure that suburidecodebin never
errors out because of not-linked in case external subtitles
are used but then subtitles are disabled.
And then make sure that external subtitles always start from
the correct position and are not racing until EOS if they
get unselected and selected again.
This will make sure that no subparse is ever plugged and subtitleoverlay,
that subpicture streams are handled the same was as subtitles and that
subtitle renderers are used if available.
Fixes bugs #595123, #570753, #591662, #591706.
Using the object lock here can and will lead to deadlocks because
of deep-notifies of property changes: the deep-notify handler will
get the parent of objects, which will take the object lock again.
Fixes bug #600479.
Use the faster gst_element_link_pads because we know for sure the sinkpad name
and we don't need to have the function search for a suitable pad anymore.
We want to return NOT_LINKED for unselected pads but only for pads
from the normal uridecodebin. This makes sure that subtitle streams
are not raced past audio/video from decodebin2's multiqueue.
For pads from suburidecodebin OK should always be returned, otherwise
it will most likely stop with an error.