mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-23 10:11:08 +00:00
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.
This commit is contained in:
parent
7e1e169b1b
commit
8e114c427a
1 changed files with 11 additions and 4 deletions
|
@ -1423,10 +1423,17 @@ analyze_new_pad (GstDecodeBin * dbin, GstElement * src, GstPad * pad,
|
|||
dpad = gst_decode_pad_new (dbin, pad, chain);
|
||||
|
||||
/* 1. Emit 'autoplug-continue' the result will tell us if this pads needs
|
||||
* further autoplugging. */
|
||||
g_signal_emit (G_OBJECT (dbin),
|
||||
gst_decode_bin_signals[SIGNAL_AUTOPLUG_CONTINUE], 0, dpad, caps,
|
||||
&apcontinue);
|
||||
* further autoplugging. Only do this for fixed caps, for unfixed caps
|
||||
* we will later come here again from the notify::caps handler. The
|
||||
* problem with unfixed caps is that we can reliably tell if the output
|
||||
* is e.g. accepted by a sink because only parts of the possible final
|
||||
* caps might be accepted by the sink. */
|
||||
if (gst_caps_is_fixed (caps))
|
||||
g_signal_emit (G_OBJECT (dbin),
|
||||
gst_decode_bin_signals[SIGNAL_AUTOPLUG_CONTINUE], 0, dpad, caps,
|
||||
&apcontinue);
|
||||
else
|
||||
apcontinue = TRUE;
|
||||
|
||||
/* 1.a if autoplug-continue is FALSE or caps is a raw format, goto pad_is_final */
|
||||
if ((!apcontinue) || are_final_caps (dbin, caps))
|
||||
|
|
Loading…
Reference in a new issue