1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-11-21 10:55:51 +02:00

Do not try to use lowres for unusual jpg subsampling.

Fixes ticket #1144.
This commit is contained in:
Carl Eugen Hoyos 2012-03-29 13:09:37 +02:00
parent 9a0f2b7b3a
commit 282ec7289d

View File

@ -411,6 +411,10 @@ int ff_mjpeg_decode_sof(MJpegDecodeContext *s)
av_log(s->avctx, AV_LOG_ERROR, "Unhandled pixel format 0x%x\n", pix_fmt_id); av_log(s->avctx, AV_LOG_ERROR, "Unhandled pixel format 0x%x\n", pix_fmt_id);
return -1; return -1;
} }
if ((s->upscale_h || s->upscale_v) && s->avctx->lowres) {
av_log(s->avctx, AV_LOG_ERROR, "lowres not supported for weird subsampling\n");
return AVERROR_PATCHWELCOME;
}
if (s->ls) { if (s->ls) {
s->upscale_h = s->upscale_v = 0; s->upscale_h = s->upscale_v = 0;
if (s->nb_components > 1) if (s->nb_components > 1)