From e2b46a776f365a86c6f48f14294ebce6515ce41c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= Date: Tue, 11 Jun 2013 13:54:53 +0200 Subject: [PATCH] matroskademux: Send stream headers after the segment event https://bugzilla.gnome.org/show_bug.cgi?id=700799 --- gst/matroska/matroska-demux.c | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/gst/matroska/matroska-demux.c b/gst/matroska/matroska-demux.c index 023c670c06..86271413d2 100644 --- a/gst/matroska/matroska-demux.c +++ b/gst/matroska/matroska-demux.c @@ -3238,23 +3238,6 @@ gst_matroska_demux_parse_blockgroup_or_simpleblock (GstMatroskaDemux * demux, break; } - if (stream->send_stream_headers) { - if (stream->stream_headers != NULL) { - ret = gst_matroska_demux_push_stream_headers (demux, stream); - } else { - /* FIXME: perhaps we can just disable and skip this stream then */ - GST_ELEMENT_ERROR (demux, STREAM, DECODE, (NULL), - ("Failed to extract stream headers from codec private data")); - } - stream->send_stream_headers = FALSE; - } - - if (stream->send_dvd_event) { - gst_matroska_demux_push_dvd_clut_change_event (demux, stream); - /* FIXME: should we send this event again after (flushing) seek ? */ - stream->send_dvd_event = FALSE; - } - if (ret != GST_FLOW_OK) break; @@ -3391,6 +3374,23 @@ gst_matroska_demux_parse_blockgroup_or_simpleblock (GstMatroskaDemux * demux, demux->need_segment = FALSE; } + if (stream->send_stream_headers) { + if (stream->stream_headers != NULL) { + ret = gst_matroska_demux_push_stream_headers (demux, stream); + } else { + /* FIXME: perhaps we can just disable and skip this stream then */ + GST_ELEMENT_ERROR (demux, STREAM, DECODE, (NULL), + ("Failed to extract stream headers from codec private data")); + } + stream->send_stream_headers = FALSE; + } + + if (stream->send_dvd_event) { + gst_matroska_demux_push_dvd_clut_change_event (demux, stream); + /* FIXME: should we send this event again after (flushing) seek ? */ + stream->send_dvd_event = FALSE; + } + if (block_duration != -1) { if (stream->timecodescale == 1.0) duration = gst_util_uint64_scale (block_duration,