summaryrefslogtreecommitdiff
path: root/libavcodec/pngdec.c
diff options
context:
space:
mode:
authorCarl Eugen Hoyos <cehoyos@ag.or.at>2012-01-31 00:13:24 +0100
committerCarl Eugen Hoyos <cehoyos@ag.or.at>2012-01-31 00:13:24 +0100
commit97da38c99bf5ad619ea15f2f1b4c050f0f44d11f (patch)
tree082ec9d2f5780015e18a71bdc65e2790b1830850 /libavcodec/pngdec.c
parentea604de91eaa69dece127a3755ba5d39705428af (diff)
downloadffmpeg-97da38c99bf5ad619ea15f2f1b4c050f0f44d11f.tar.gz
Allow decoding of 64bit png images.
Fixes a part of ticket #639.
Diffstat (limited to 'libavcodec/pngdec.c')
-rw-r--r--libavcodec/pngdec.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/pngdec.c b/libavcodec/pngdec.c
index 75f882c6ca..41a91f2381 100644
--- a/libavcodec/pngdec.c
+++ b/libavcodec/pngdec.c
@@ -485,6 +485,9 @@ static int decode_frame(AVCodecContext *avctx,
} else if (s->bit_depth == 16 &&
s->color_type == PNG_COLOR_TYPE_RGB) {
avctx->pix_fmt = PIX_FMT_RGB48BE;
+ } else if (s->bit_depth == 16 &&
+ s->color_type == PNG_COLOR_TYPE_RGB_ALPHA) {
+ avctx->pix_fmt = PIX_FMT_RGBA64BE;
} else if (s->color_type == PNG_COLOR_TYPE_PALETTE) {
avctx->pix_fmt = PIX_FMT_PAL8;
} else if (s->bit_depth == 1) {