mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-06-30 21:08:59 +08:00
PNG 16-bit gray decoding support
Originally committed as revision 6779 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
@ -567,6 +567,9 @@ static int decode_frame(AVCodecContext *avctx,
|
||||
} else if (s->bit_depth == 8 &&
|
||||
s->color_type == PNG_COLOR_TYPE_GRAY) {
|
||||
avctx->pix_fmt = PIX_FMT_GRAY8;
|
||||
} else if (s->bit_depth == 16 &&
|
||||
s->color_type == PNG_COLOR_TYPE_GRAY) {
|
||||
avctx->pix_fmt = PIX_FMT_GRAY16BE;
|
||||
} else if (s->bit_depth == 1 &&
|
||||
s->color_type == PNG_COLOR_TYPE_GRAY) {
|
||||
avctx->pix_fmt = PIX_FMT_MONOBLACK;
|
||||
|
Reference in New Issue
Block a user