mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-28 04:31:06 +00:00
avidemux: get the index writer id when the pad has a parent
Otherwise the index writer has a weired name, as the pad has no parent yet.
This commit is contained in:
parent
99e4bdd8f2
commit
80d820ff29
1 changed files with 5 additions and 4 deletions
|
@ -1858,6 +1858,11 @@ gst_avi_demux_expose_streams (GstAviDemux * avi, gboolean force)
|
||||||
GST_LOG_OBJECT (avi, "Added pad %s with caps %" GST_PTR_FORMAT,
|
GST_LOG_OBJECT (avi, "Added pad %s with caps %" GST_PTR_FORMAT,
|
||||||
GST_PAD_NAME (stream->pad), GST_PAD_CAPS (stream->pad));
|
GST_PAD_NAME (stream->pad), GST_PAD_CAPS (stream->pad));
|
||||||
gst_element_add_pad ((GstElement *) avi, stream->pad);
|
gst_element_add_pad ((GstElement *) avi, stream->pad);
|
||||||
|
|
||||||
|
if (avi->element_index)
|
||||||
|
gst_index_get_writer_id (avi->element_index,
|
||||||
|
GST_OBJECT_CAST (stream->pad), &stream->index_id);
|
||||||
|
|
||||||
stream->exposed = TRUE;
|
stream->exposed = TRUE;
|
||||||
if (avi->main_stream == -1)
|
if (avi->main_stream == -1)
|
||||||
avi->main_stream = i;
|
avi->main_stream = i;
|
||||||
|
@ -2265,10 +2270,6 @@ gst_avi_demux_parse_stream (GstAviDemux * avi, GstBuffer * buf)
|
||||||
GST_DEBUG_FUNCPTR (gst_avi_demux_src_convert));
|
GST_DEBUG_FUNCPTR (gst_avi_demux_src_convert));
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (avi->element_index)
|
|
||||||
gst_index_get_writer_id (avi->element_index, GST_OBJECT_CAST (stream->pad),
|
|
||||||
&stream->index_id);
|
|
||||||
|
|
||||||
stream->num = avi->num_streams;
|
stream->num = avi->num_streams;
|
||||||
|
|
||||||
stream->start_entry = 0;
|
stream->start_entry = 0;
|
||||||
|
|
Loading…
Reference in a new issue