mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
snow: yuv410 support
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
fba18ef8cc
commit
1e7943c315
@ -295,6 +295,8 @@ static int decode_header(SnowContext *s){
|
|||||||
s->avctx->pix_fmt= PIX_FMT_YUV420P;
|
s->avctx->pix_fmt= PIX_FMT_YUV420P;
|
||||||
}else if(s->chroma_h_shift == 0 && s->chroma_v_shift==0){
|
}else if(s->chroma_h_shift == 0 && s->chroma_v_shift==0){
|
||||||
s->avctx->pix_fmt= PIX_FMT_YUV444P;
|
s->avctx->pix_fmt= PIX_FMT_YUV444P;
|
||||||
|
}else if(s->chroma_h_shift == 2 && s->chroma_v_shift==2){
|
||||||
|
s->avctx->pix_fmt= PIX_FMT_YUV410P;
|
||||||
} else {
|
} else {
|
||||||
av_log(s, AV_LOG_ERROR, "unsupported color subsample mode %d %d\n", s->chroma_h_shift, s->chroma_v_shift);
|
av_log(s, AV_LOG_ERROR, "unsupported color subsample mode %d %d\n", s->chroma_h_shift, s->chroma_v_shift);
|
||||||
s->chroma_h_shift = s->chroma_v_shift = 1;
|
s->chroma_h_shift = s->chroma_v_shift = 1;
|
||||||
|
@ -220,7 +220,7 @@ static av_cold int encode_init(AVCodecContext *avctx)
|
|||||||
case PIX_FMT_YUV420P:
|
case PIX_FMT_YUV420P:
|
||||||
// case PIX_FMT_GRAY8:
|
// case PIX_FMT_GRAY8:
|
||||||
// case PIX_FMT_YUV411P:
|
// case PIX_FMT_YUV411P:
|
||||||
// case PIX_FMT_YUV410P:
|
case PIX_FMT_YUV410P:
|
||||||
s->colorspace_type= 0;
|
s->colorspace_type= 0;
|
||||||
break;
|
break;
|
||||||
/* case PIX_FMT_RGB32:
|
/* case PIX_FMT_RGB32:
|
||||||
|
Loading…
Reference in New Issue
Block a user