[FFmpeg-cvslog] avcodec/mjpegdec: dont try to combine fields for decimated multiscope 2 material
Michael Niedermayer
git at videolan.org
Sun Jun 21 02:54:09 CEST 2015
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sun Jun 21 02:39:38 2015 +0200| [dde6b2a3554553434c9e3435de3c7e94c3affe03] | committer: Michael Niedermayer
avcodec/mjpegdec: dont try to combine fields for decimated multiscope 2 material
Fixes Ticket4535
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=dde6b2a3554553434c9e3435de3c7e94c3affe03
---
libavcodec/mjpegdec.c | 3 +++
libavcodec/mjpegdec.h | 1 +
2 files changed, 4 insertions(+)
diff --git a/libavcodec/mjpegdec.c b/libavcodec/mjpegdec.c
index 1ce3328..87c5862 100644
--- a/libavcodec/mjpegdec.c
+++ b/libavcodec/mjpegdec.c
@@ -367,6 +367,7 @@ int ff_mjpeg_decode_sof(MJpegDecodeContext *s)
/* test interlaced mode */
if (s->first_picture &&
+ (s->multiscope != 2 || s->avctx->time_base.den >= 25 * s->avctx->time_base.num) &&
s->org_height != 0 &&
s->height < ((s->org_height * 3) / 4)) {
s->interlaced = 1;
@@ -1830,6 +1831,8 @@ static int mjpeg_decode_com(MJpegDecodeContext *s)
else if ((!strncmp(cbuf, "Intel(R) JPEG Library, version 1", 32) && s->avctx->codec_tag) ||
(!strncmp(cbuf, "Metasoft MJPEG Codec", 20)))
s->flipped = 1;
+ else if (!strcmp(cbuf, "MULTISCOPE II"))
+ s->multiscope = 2;
av_free(cbuf);
}
diff --git a/libavcodec/mjpegdec.h b/libavcodec/mjpegdec.h
index 28d3e4a..fb81129 100644
--- a/libavcodec/mjpegdec.h
+++ b/libavcodec/mjpegdec.h
@@ -114,6 +114,7 @@ typedef struct MJpegDecodeContext {
int buggy_avid;
int cs_itu601;
int interlace_polarity;
+ int multiscope;
int mjpb_skiptosod;
More information about the ffmpeg-cvslog
mailing list