summaryrefslogtreecommitdiff
path: root/libavcodec/pnmdec.c
diff options
context:
space:
mode:
authorCarl Eugen Hoyos <cehoyos@rainbow.studorg.tuwien.ac.at>2010-07-07 21:23:36 +0000
committerCarl Eugen Hoyos <cehoyos@rainbow.studorg.tuwien.ac.at>2010-07-07 21:23:36 +0000
commit0fd0ef7947ad31b2e1b9506cb70d85dcfdf6cba6 (patch)
treec79745bc17e836f9438ae968085c2997a5f8c3a5 /libavcodec/pnmdec.c
parent38b04109028fdeb4009f74e7467f90f3083a897a (diff)
Add new decoder property max_lowres and do not init decoder if requested value is higher.
Originally committed as revision 24098 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/pnmdec.c')
-rw-r--r--libavcodec/pnmdec.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/libavcodec/pnmdec.c b/libavcodec/pnmdec.c
index 66033c1f4e..4ccaa457fc 100644
--- a/libavcodec/pnmdec.c
+++ b/libavcodec/pnmdec.c
@@ -199,6 +199,7 @@ AVCodec pgm_decoder = {
pnm_decode_frame,
CODEC_CAP_DR1,
.pix_fmts = (const enum PixelFormat[]){PIX_FMT_GRAY8, PIX_FMT_GRAY16BE, PIX_FMT_NONE},
+ .max_lowres = 5,
.long_name = NULL_IF_CONFIG_SMALL("PGM (Portable GrayMap) image"),
};
#endif
@@ -215,6 +216,7 @@ AVCodec pgmyuv_decoder = {
pnm_decode_frame,
CODEC_CAP_DR1,
.pix_fmts = (const enum PixelFormat[]){PIX_FMT_YUV420P, PIX_FMT_NONE},
+ .max_lowres = 5,
.long_name = NULL_IF_CONFIG_SMALL("PGMYUV (Portable GrayMap YUV) image"),
};
#endif
@@ -231,6 +233,7 @@ AVCodec ppm_decoder = {
pnm_decode_frame,
CODEC_CAP_DR1,
.pix_fmts = (const enum PixelFormat[]){PIX_FMT_RGB24, PIX_FMT_RGB48BE, PIX_FMT_NONE},
+ .max_lowres = 5,
.long_name = NULL_IF_CONFIG_SMALL("PPM (Portable PixelMap) image"),
};
#endif
@@ -247,6 +250,7 @@ AVCodec pbm_decoder = {
pnm_decode_frame,
CODEC_CAP_DR1,
.pix_fmts = (const enum PixelFormat[]){PIX_FMT_MONOWHITE, PIX_FMT_NONE},
+ .max_lowres = 5,
.long_name = NULL_IF_CONFIG_SMALL("PBM (Portable BitMap) image"),
};
#endif
@@ -263,6 +267,7 @@ AVCodec pam_decoder = {
pnm_decode_frame,
CODEC_CAP_DR1,
.pix_fmts = (const enum PixelFormat[]){PIX_FMT_RGB24, PIX_FMT_RGB32, PIX_FMT_GRAY8, PIX_FMT_MONOWHITE, PIX_FMT_NONE},
+ .max_lowres = 5,
.long_name = NULL_IF_CONFIG_SMALL("PAM (Portable AnyMap) image"),
};
#endif