mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-18 05:16:05 +00:00
qtdemux: Use upstream's StreamFlags if there are
When multiple demuxer's are used, upstream might want to indicate default streams using GST_STREAM_FLAG_{SELECT, UNSELECT} https://bugzilla.gnome.org/show_bug.cgi?id=775440
This commit is contained in:
parent
af47e93b97
commit
d3f5aa2689
1 changed files with 6 additions and 3 deletions
|
@ -7769,12 +7769,13 @@ gst_qtdemux_configure_stream (GstQTDemux * qtdemux, QtDemuxStream * stream)
|
|||
if (stream->new_stream) {
|
||||
gchar *stream_id;
|
||||
GstEvent *event;
|
||||
GstStreamFlags stream_flags;
|
||||
GstStreamFlags stream_flags = GST_STREAM_FLAG_NONE;
|
||||
|
||||
event =
|
||||
gst_pad_get_sticky_event (qtdemux->sinkpad, GST_EVENT_STREAM_START,
|
||||
0);
|
||||
if (event) {
|
||||
gst_event_parse_stream_flags (event, &stream_flags);
|
||||
if (gst_event_parse_group_id (event, &qtdemux->group_id))
|
||||
qtdemux->have_group_id = TRUE;
|
||||
else
|
||||
|
@ -7792,11 +7793,13 @@ gst_qtdemux_configure_stream (GstQTDemux * qtdemux, QtDemuxStream * stream)
|
|||
event = gst_event_new_stream_start (stream_id);
|
||||
if (qtdemux->have_group_id)
|
||||
gst_event_set_group_id (event, qtdemux->group_id);
|
||||
stream_flags = GST_STREAM_FLAG_NONE;
|
||||
if (stream->disabled)
|
||||
stream_flags |= GST_STREAM_FLAG_UNSELECT;
|
||||
if (stream->sparse)
|
||||
if (stream->sparse) {
|
||||
stream_flags |= GST_STREAM_FLAG_SPARSE;
|
||||
} else {
|
||||
stream_flags &= ~GST_STREAM_FLAG_SPARSE;
|
||||
}
|
||||
gst_event_set_stream_flags (event, stream_flags);
|
||||
gst_pad_push_event (stream->pad, event);
|
||||
g_free (stream_id);
|
||||
|
|
Loading…
Reference in a new issue