mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-26 06:54:49 +00:00
decodebin2: move error path down
This commit is contained in:
parent
1c982d0dbe
commit
cffe4d7bd3
1 changed files with 13 additions and 8 deletions
|
@ -2256,14 +2256,8 @@ gst_decode_group_new (GstDecodeBin * dbin, GstDecodeChain * parent)
|
||||||
group->parent = parent;
|
group->parent = parent;
|
||||||
|
|
||||||
mq = group->multiqueue = gst_element_factory_make ("multiqueue", NULL);
|
mq = group->multiqueue = gst_element_factory_make ("multiqueue", NULL);
|
||||||
if (G_UNLIKELY (!group->multiqueue)) {
|
if (G_UNLIKELY (!group->multiqueue))
|
||||||
gst_element_post_message (GST_ELEMENT_CAST (dbin),
|
goto missing_multiqueue;
|
||||||
gst_missing_element_message_new (GST_ELEMENT_CAST (dbin),
|
|
||||||
"multiqueue"));
|
|
||||||
GST_ELEMENT_ERROR (dbin, CORE, MISSING_PLUGIN, (NULL), ("no multiqueue!"));
|
|
||||||
g_slice_free (GstDecodeGroup, group);
|
|
||||||
return NULL;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* takes queue limits, initially we only queue up up to the max bytes limit,
|
/* takes queue limits, initially we only queue up up to the max bytes limit,
|
||||||
* with a default of 2MB. */
|
* with a default of 2MB. */
|
||||||
|
@ -2285,6 +2279,17 @@ gst_decode_group_new (GstDecodeBin * dbin, GstDecodeChain * parent)
|
||||||
gst_element_set_state (mq, GST_STATE_PAUSED);
|
gst_element_set_state (mq, GST_STATE_PAUSED);
|
||||||
|
|
||||||
return group;
|
return group;
|
||||||
|
|
||||||
|
/* ERRORS */
|
||||||
|
missing_multiqueue:
|
||||||
|
{
|
||||||
|
gst_element_post_message (GST_ELEMENT_CAST (dbin),
|
||||||
|
gst_missing_element_message_new (GST_ELEMENT_CAST (dbin),
|
||||||
|
"multiqueue"));
|
||||||
|
GST_ELEMENT_ERROR (dbin, CORE, MISSING_PLUGIN, (NULL), ("no multiqueue!"));
|
||||||
|
g_slice_free (GstDecodeGroup, group);
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* gst_decode_group_control_demuxer_pad
|
/* gst_decode_group_control_demuxer_pad
|
||||||
|
|
Loading…
Reference in a new issue