From b0791f75ad219152873e58e00166366cf4028fa9 Mon Sep 17 00:00:00 2001 From: Glenn Randers-Pehrson Date: Wed, 15 Jun 2011 12:07:20 -0500 Subject: [PATCH] [devel] Added PNG_TRANSFORM_CHOP_16 to the high-level read transforms. --- ANNOUNCE | 1 + CHANGES | 1 + pngread.c | 5 +++++ 3 files changed, 7 insertions(+) diff --git a/ANNOUNCE b/ANNOUNCE index 41ae62572..eec50a2e4 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -215,6 +215,7 @@ Version 1.5.4beta03 [June 15, 2011] Version 1.5.4beta04 [June 15, 2011] Added a missing "#ifdef PNG_READ_BACKGROUND_SUPPORTED/#endif" in pngrtran.c + Added PNG_TRANSFORM_CHOP_16 to the high-level read transforms. Send comments/corrections/commendations to png-mng-implement at lists.sf.net: (subscription required; visit diff --git a/CHANGES b/CHANGES index 155c3cdf1..a4d76dabd 100644 --- a/CHANGES +++ b/CHANGES @@ -3478,6 +3478,7 @@ Version 1.5.4beta03 [June 15, 2011] Version 1.5.4beta04 [June 15, 2011] Added a missing "#ifdef PNG_READ_BACKGROUND_SUPPORTED/#endif" in pngrtran.c + Added PNG_TRANSFORM_CHOP_16 to the high-level read transforms. Send comments/corrections/commendations to png-mng-implement at lists.sf.net (subscription required; visit diff --git a/pngread.c b/pngread.c index a39c83b99..493166f64 100644 --- a/pngread.c +++ b/pngread.c @@ -1291,6 +1291,11 @@ png_read_png(png_structp png_ptr, png_infop info_ptr, */ if (transforms & PNG_TRANSFORM_STRIP_16) png_set_strip_16(png_ptr); +# ifdef PNG_READ_CHOP_16_TO_8_SUPPORTED + else + if (transforms & PNG_TRANSFORM_CHOP_16) + png_set_chop_16(png_ptr); +#endif #endif #ifdef PNG_READ_STRIP_ALPHA_SUPPORTED