Commit 4e49d589 authored by Sebastian Dröge's avatar Sebastian Dröge
Browse files

playbin2: Only consider the audio/video sinks in autoplug_continue for the normal uridecodebin

Considering them for the subtitle uridecodebin will add audio/video
streams that might be in a file used as subtitle file.
parent a0822750
...@@ -2972,9 +2972,17 @@ autoplug_continue_cb (GstElement * element, GstPad * pad, GstCaps * caps, ...@@ -2972,9 +2972,17 @@ autoplug_continue_cb (GstElement * element, GstPad * pad, GstCaps * caps,
ret = !gst_caps_can_intersect (caps, subcaps); ret = !gst_caps_can_intersect (caps, subcaps);
gst_caps_unref (subcaps); gst_caps_unref (subcaps);
} }
/* If autoplugging can stop don't do additional checks */
if (!ret) if (!ret)
goto done; goto done;
/* If this is from the subtitle uridecodebin we don't need to
* check the audio and video sink */
if (group->suburidecodebin
&& gst_object_has_ancestor (GST_OBJECT_CAST (element),
GST_OBJECT_CAST (group->suburidecodebin)))
goto done;
if ((sink = group->playbin->audio_sink)) { if ((sink = group->playbin->audio_sink)) {
sinkpad = gst_element_get_static_pad (sink, "sink"); sinkpad = gst_element_get_static_pad (sink, "sink");
if (sinkpad) { if (sinkpad) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment