From: Tim-Philipp Müller Date: Fri, 10 Jul 2015 00:00:15 +0000 (+0100) Subject: mpegtsmux: don't wait for data on sparse inputs like metadata or subtitle streams X-Git-Tag: 1.19.3~507^2~8334 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=ec309dbd64e696d7ecffccdb87d6d0bd6570eb67;p=platform%2Fupstream%2Fgstreamer.git mpegtsmux: don't wait for data on sparse inputs like metadata or subtitle streams --- diff --git a/gst/mpegtsmux/mpegtsmux.c b/gst/mpegtsmux/mpegtsmux.c index 74ea142..4cc4a03 100644 --- a/gst/mpegtsmux/mpegtsmux.c +++ b/gst/mpegtsmux/mpegtsmux.c @@ -882,6 +882,19 @@ mpegtsmux_sink_event (GstCollectPads * pads, GstCollectData * data, forward = gst_tag_list_get_scope (list) == GST_TAG_SCOPE_GLOBAL; break; } + case GST_EVENT_STREAM_START:{ + GstStreamFlags flags; + + gst_event_parse_stream_flags (event, &flags); + + /* Don't wait for data on sparse inputs like metadata streams */ + if ((flags & GST_STREAM_FLAG_SPARSE)) { + GST_COLLECT_PADS_STATE_UNSET (data, GST_COLLECT_PADS_STATE_LOCKED); + gst_collect_pads_set_waiting (pads, data, FALSE); + GST_COLLECT_PADS_STATE_SET (data, GST_COLLECT_PADS_STATE_LOCKED); + } + break; + } default: break; }