1
mirror of https://git.videolan.org/git/ffmpeg.git synced 2024-07-18 02:11:37 +02:00

avcodec/tiff: Support 410 and 440 YCbCr

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2014-04-30 17:41:31 +02:00
parent 5e7d21c7ad
commit 1e25afc181

View File

@ -594,8 +594,12 @@ static int init_image(TiffContext *s, ThreadFrame *frame)
s->avctx->pix_fmt = AV_PIX_FMT_YUV422P;
} else if (s->subsampling[0] == 4 && s->subsampling[1] == 1) {
s->avctx->pix_fmt = AV_PIX_FMT_YUV411P;
} else if (s->subsampling[0] == 1 && s->subsampling[1] == 2) {
s->avctx->pix_fmt = AV_PIX_FMT_YUV440P;
} else if (s->subsampling[0] == 2 && s->subsampling[1] == 2) {
s->avctx->pix_fmt = AV_PIX_FMT_YUV420P;
} else if (s->subsampling[0] == 4 && s->subsampling[1] == 4) {
s->avctx->pix_fmt = AV_PIX_FMT_YUV410P;
} else {
av_log(s->avctx, AV_LOG_ERROR, "Unsupported YCbCr subsampling\n");
return AVERROR_PATCHWELCOME;