gst/playback/gstdecodebin2.c: Expose the right pad in the right place with the right element.
Original commit message from CVS: * gst/playback/gstdecodebin2.c: (analyze_new_pad), (connect_pad): Expose the right pad in the right place with the right element.
This commit is contained in:
parent
41e54ce132
commit
74e5172181
@ -1,3 +1,8 @@
|
|||||||
|
2007-12-13 Wim Taymans <wim.taymans@collabora.co.uk>
|
||||||
|
|
||||||
|
* gst/playback/gstdecodebin2.c: (analyze_new_pad), (connect_pad):
|
||||||
|
Expose the right pad in the right place with the right element.
|
||||||
|
|
||||||
2007-12-13 Tim-Philipp Müller <tim at centricular dot net>
|
2007-12-13 Tim-Philipp Müller <tim at centricular dot net>
|
||||||
|
|
||||||
* gst-libs/gst/pbutils/descriptions.c: (formats):
|
* gst-libs/gst/pbutils/descriptions.c: (formats):
|
||||||
|
@ -846,7 +846,7 @@ static gboolean is_demuxer_element (GstElement * srcelement);
|
|||||||
|
|
||||||
static gboolean connect_pad (GstDecodeBin * dbin, GstElement * src,
|
static gboolean connect_pad (GstDecodeBin * dbin, GstElement * src,
|
||||||
GstPad * pad, GstCaps * caps, GValueArray * factories,
|
GstPad * pad, GstCaps * caps, GValueArray * factories,
|
||||||
GstDecodeGroup * group, gboolean * expose);
|
GstDecodeGroup * group);
|
||||||
static gboolean connect_element (GstDecodeBin * dbin, GstElement * element,
|
static gboolean connect_element (GstDecodeBin * dbin, GstElement * element,
|
||||||
GstDecodeGroup * group);
|
GstDecodeGroup * group);
|
||||||
static void expose_pad (GstDecodeBin * dbin, GstElement * src, GstPad * pad,
|
static void expose_pad (GstDecodeBin * dbin, GstElement * src, GstPad * pad,
|
||||||
@ -884,7 +884,6 @@ analyze_new_pad (GstDecodeBin * dbin, GstElement * src, GstPad * pad,
|
|||||||
{
|
{
|
||||||
gboolean apcontinue = TRUE;
|
gboolean apcontinue = TRUE;
|
||||||
GValueArray *factories = NULL, *result = NULL;
|
GValueArray *factories = NULL, *result = NULL;
|
||||||
gboolean expose;
|
|
||||||
|
|
||||||
GST_DEBUG_OBJECT (dbin, "Pad %s:%s caps:%" GST_PTR_FORMAT,
|
GST_DEBUG_OBJECT (dbin, "Pad %s:%s caps:%" GST_PTR_FORMAT,
|
||||||
GST_DEBUG_PAD_NAME (pad), caps);
|
GST_DEBUG_PAD_NAME (pad), caps);
|
||||||
@ -936,13 +935,10 @@ analyze_new_pad (GstDecodeBin * dbin, GstElement * src, GstPad * pad,
|
|||||||
|
|
||||||
/* 1.e else continue autoplugging something from the list. */
|
/* 1.e else continue autoplugging something from the list. */
|
||||||
GST_LOG_OBJECT (pad, "Let's continue discovery on this pad");
|
GST_LOG_OBJECT (pad, "Let's continue discovery on this pad");
|
||||||
connect_pad (dbin, src, pad, caps, factories, group, &expose);
|
connect_pad (dbin, src, pad, caps, factories, group);
|
||||||
|
|
||||||
g_value_array_free (factories);
|
g_value_array_free (factories);
|
||||||
|
|
||||||
if (expose)
|
|
||||||
goto expose_pad;
|
|
||||||
|
|
||||||
return;
|
return;
|
||||||
|
|
||||||
expose_pad:
|
expose_pad:
|
||||||
@ -1015,8 +1011,7 @@ setup_caps_delay:
|
|||||||
*/
|
*/
|
||||||
static gboolean
|
static gboolean
|
||||||
connect_pad (GstDecodeBin * dbin, GstElement * src, GstPad * pad,
|
connect_pad (GstDecodeBin * dbin, GstElement * src, GstPad * pad,
|
||||||
GstCaps * caps, GValueArray * factories, GstDecodeGroup * group,
|
GstCaps * caps, GValueArray * factories, GstDecodeGroup * group)
|
||||||
gboolean * expose)
|
|
||||||
{
|
{
|
||||||
gboolean res = FALSE;
|
gboolean res = FALSE;
|
||||||
GstPad *mqpad = NULL;
|
GstPad *mqpad = NULL;
|
||||||
@ -1024,8 +1019,6 @@ connect_pad (GstDecodeBin * dbin, GstElement * src, GstPad * pad,
|
|||||||
g_return_val_if_fail (factories != NULL, FALSE);
|
g_return_val_if_fail (factories != NULL, FALSE);
|
||||||
g_return_val_if_fail (factories->n_values > 0, FALSE);
|
g_return_val_if_fail (factories->n_values > 0, FALSE);
|
||||||
|
|
||||||
*expose = FALSE;
|
|
||||||
|
|
||||||
GST_DEBUG_OBJECT (dbin, "pad %s:%s , group:%p",
|
GST_DEBUG_OBJECT (dbin, "pad %s:%s , group:%p",
|
||||||
GST_DEBUG_PAD_NAME (pad), group);
|
GST_DEBUG_PAD_NAME (pad), group);
|
||||||
|
|
||||||
@ -1043,6 +1036,7 @@ connect_pad (GstDecodeBin * dbin, GstElement * src, GstPad * pad,
|
|||||||
|
|
||||||
if (!(mqpad = gst_decode_group_control_demuxer_pad (group, pad)))
|
if (!(mqpad = gst_decode_group_control_demuxer_pad (group, pad)))
|
||||||
goto beach;
|
goto beach;
|
||||||
|
src = group->multiqueue;
|
||||||
pad = mqpad;
|
pad = mqpad;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1069,7 +1063,9 @@ connect_pad (GstDecodeBin * dbin, GstElement * src, GstPad * pad,
|
|||||||
break;
|
break;
|
||||||
case GST_AUTOPLUG_SELECT_EXPOSE:
|
case GST_AUTOPLUG_SELECT_EXPOSE:
|
||||||
GST_DEBUG_OBJECT (dbin, "autoplug select requested expose");
|
GST_DEBUG_OBJECT (dbin, "autoplug select requested expose");
|
||||||
*expose = TRUE;
|
/* expose the pad, we don't have the source element */
|
||||||
|
expose_pad (dbin, src, pad, group);
|
||||||
|
res = TRUE;
|
||||||
goto beach;
|
goto beach;
|
||||||
case GST_AUTOPLUG_SELECT_SKIP:
|
case GST_AUTOPLUG_SELECT_SKIP:
|
||||||
GST_DEBUG_OBJECT (dbin, "autoplug select requested skip");
|
GST_DEBUG_OBJECT (dbin, "autoplug select requested skip");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user