diff options
author | Tim-Philipp Müller <tim.muller@collabora.co.uk> | 2013-05-01 17:36:47 +0100 |
---|---|---|
committer | Tim-Philipp Müller <tim@centricular.net> | 2013-05-18 11:29:47 +0100 |
commit | 2b1e96db996a7cb0660004688299ed6035f4e353 (patch) | |
tree | f79f759a92b74501cc38e4069fa22bff04550710 | |
parent | de78ef45f7ab214564f538c73b9cb198fabd6358 (diff) | |
download | gstreamer-plugins-bad-2b1e96db996a7cb0660004688299ed6035f4e353.tar.gz |
mpegvideoparse: don't announce incomplete source caps
Don't send any source caps yet if we're still in
drop-buffers-until-we-get-a-sequence-header mode.
Fixes transmuxing of many MPEG-TS/PS streams into
formats which require things like width, height or
codec_data on the input caps.
Also fixes issues when using playbin with decoder
sinks that want width/height etc.
https://bugzilla.gnome.org/show_bug.cgi?id=695879
-rw-r--r-- | gst/videoparsers/gstmpegvideoparse.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/gst/videoparsers/gstmpegvideoparse.c b/gst/videoparsers/gstmpegvideoparse.c index 4d34f6ce6..1e5390e32 100644 --- a/gst/videoparsers/gstmpegvideoparse.c +++ b/gst/videoparsers/gstmpegvideoparse.c @@ -762,8 +762,6 @@ gst_mpegv_parse_parse_frame (GstBaseParse * parse, GstBaseParseFrame * frame) GstMpegvParse *mpvparse = GST_MPEGVIDEO_PARSE (parse); GstBuffer *buffer = frame->buffer; - gst_mpegv_parse_update_src_caps (mpvparse); - if (G_UNLIKELY (mpvparse->pichdr.pic_type == GST_MPEG_VIDEO_PICTURE_TYPE_I)) GST_BUFFER_FLAG_UNSET (buffer, GST_BUFFER_FLAG_DELTA_UNIT); else @@ -786,8 +784,10 @@ gst_mpegv_parse_parse_frame (GstBaseParse * parse, GstBaseParseFrame * frame) if (G_UNLIKELY (mpvparse->drop && !mpvparse->config)) { GST_DEBUG_OBJECT (mpvparse, "dropping frame as no config yet"); return GST_BASE_PARSE_FLOW_DROPPED; - } else - return GST_FLOW_OK; + } + + gst_mpegv_parse_update_src_caps (mpvparse); + return GST_FLOW_OK; } static GstFlowReturn |