mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
jpegdec: Only enable rgb mode when there are 3 components.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
0af34c4d2c
commit
24964f21e4
@ -279,7 +279,7 @@ int ff_mjpeg_decode_sof(MJpegDecodeContext *s)
|
||||
return -1;
|
||||
}
|
||||
|
||||
if(s->v_max==1 && s->h_max==1 && s->lossless==1) s->rgb=1;
|
||||
if(s->v_max==1 && s->h_max==1 && s->lossless==1 && nb_components==3) s->rgb=1;
|
||||
|
||||
/* if different size, realloc/alloc picture */
|
||||
/* XXX: also check h_count and v_count */
|
||||
|
Loading…
Reference in New Issue
Block a user