mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-29 18:48:44 +00:00
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.
This commit is contained in:
parent
4009d4d7bf
commit
f536e57b2f
2 changed files with 17 additions and 2 deletions
|
@ -1,3 +1,11 @@
|
|||
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;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue