Commit f536e57b authored by Ronald S. Bultje's avatar Ronald S. Bultje

ext/ffmpeg/gstffmpegdec.c: Disable parsing for MJPEG input since that's...

ext/ffmpeg/gstffmpegdec.c: Disable parsing for MJPEG input since that's already cut at frame-boundaries. Fixes #163340.

Original commit message from CVS:
Reviewed by:  Ronald S. Bultje  <rbultje@ronald.bitfreak.net>
* ext/ffmpeg/gstffmpegdec.c: (gst_ffmpegdec_chain):
Disable parsing for MJPEG input since that's already cut at
frame-boundaries. Fixes #163340.
parent 4009d4d7
2005-01-09 Luca Ognibene <luogni@tin.it>
Reviewed by: Ronald S. Bultje <rbultje@ronald.bitfreak.net>
* ext/ffmpeg/gstffmpegdec.c: (gst_ffmpegdec_chain):
Disable parsing for MJPEG input since that's already cut at
frame-boundaries. Fixes #163340.
2005-01-06 Ronald S. Bultje <rbultje@ronald.bitfreak.net>
* ext/ffmpeg/gstffmpegcodecmap.c: (gst_ffmpeg_codecid_to_caps),
......
......@@ -472,7 +472,12 @@ gst_ffmpegdec_chain (GstPad * pad, GstData * _data)
/* parse cache joining */
if (ffmpegdec->pcache) {
GST_LOG ("Joining %p[%lld/%d]&&%p[%lld/%d]",
ffmpegdec->pcache, GST_BUFFER_OFFSET (ffmpegdec->pcache),
GST_BUFFER_SIZE (ffmpegdec->pcache), inbuf,
GST_BUFFER_OFFSET (inbuf), GST_BUFFER_SIZE (inbuf));
inbuf = gst_buffer_join (ffmpegdec->pcache, inbuf);
GST_LOG ("done");
ffmpegdec->pcache = NULL;
bdata = GST_BUFFER_DATA (inbuf);
bsize = GST_BUFFER_SIZE (inbuf);
......@@ -493,7 +498,8 @@ gst_ffmpegdec_chain (GstPad * pad, GstData * _data)
do {
/* parse, if at all possible */
if (ffmpegdec->pctx && ffmpegdec->context->codec_id != CODEC_ID_MP3) {
if (ffmpegdec->pctx && ffmpegdec->context->codec_id != CODEC_ID_MP3 &&
ffmpegdec->context->codec_id != CODEC_ID_MJPEG) {
gint res;
res = av_parser_parse (ffmpegdec->pctx, ffmpegdec->context,
......@@ -613,7 +619,8 @@ gst_ffmpegdec_chain (GstPad * pad, GstData * _data)
gst_buffer_unref (outbuf);
}
if (!ffmpegdec->pctx || ffmpegdec->context->codec_id == CODEC_ID_MP3) {
if (!ffmpegdec->pctx || ffmpegdec->context->codec_id == CODEC_ID_MP3 ||
ffmpegdec->context->codec_id == CODEC_ID_MJPEG) {
bsize -= len;
bdata += len;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment