[libpng16] Fixed some indentation to comply with our coding style.
This commit is contained in:
parent
1b9f4817c8
commit
192e92d681
5
ANNOUNCE
5
ANNOUNCE
@ -1,4 +1,4 @@
|
|||||||
Libpng 1.6.24beta05 - July 8, 2016
|
Libpng 1.6.24beta05 - July 13, 2016
|
||||||
|
|
||||||
This is not intended to be a public release. It will be replaced
|
This is not intended to be a public release. It will be replaced
|
||||||
within a few weeks by a public version or by another test version.
|
within a few weeks by a public version or by another test version.
|
||||||
@ -82,7 +82,8 @@ Version 1.6.24beta04 [July 8, 2016]
|
|||||||
filter is a candidate for selection. This trades off code size (added
|
filter is a candidate for selection. This trades off code size (added
|
||||||
private png_setup_*_row_only() functions) for speed.
|
private png_setup_*_row_only() functions) for speed.
|
||||||
|
|
||||||
Version 1.6.24beta05 [July 8, 2016]
|
Version 1.6.24beta05 [July 13, 2016]
|
||||||
|
Fixed some indentation to comply with our coding style.
|
||||||
|
|
||||||
Send comments/corrections/commendations to png-mng-implement at lists.sf.net
|
Send comments/corrections/commendations to png-mng-implement at lists.sf.net
|
||||||
(subscription required; visit
|
(subscription required; visit
|
||||||
|
3
CHANGES
3
CHANGES
@ -5653,7 +5653,8 @@ Version 1.6.24beta04 [July 8, 2016]
|
|||||||
filter is a candidate for selection. This trades off code size (added
|
filter is a candidate for selection. This trades off code size (added
|
||||||
private png_setup_*_row_only() functions) for speed.
|
private png_setup_*_row_only() functions) for speed.
|
||||||
|
|
||||||
Version 1.6.24beta05 [July 8, 2016]
|
Version 1.6.24beta05 [July 13, 2016]
|
||||||
|
Fixed some indentation to comply with our coding style.
|
||||||
|
|
||||||
Send comments/corrections/commendations to png-mng-implement at lists.sf.net
|
Send comments/corrections/commendations to png-mng-implement at lists.sf.net
|
||||||
(subscription required; visit
|
(subscription required; visit
|
||||||
|
24
png.c
24
png.c
@ -775,14 +775,14 @@ png_get_copyright(png_const_structrp png_ptr)
|
|||||||
#else
|
#else
|
||||||
# ifdef __STDC__
|
# ifdef __STDC__
|
||||||
return PNG_STRING_NEWLINE \
|
return PNG_STRING_NEWLINE \
|
||||||
"libpng version 1.6.24beta05 - July 8, 2016" PNG_STRING_NEWLINE \
|
"libpng version 1.6.24beta05 - July 13, 2016" PNG_STRING_NEWLINE \
|
||||||
"Copyright (c) 1998-2002,2004,2006-2016 Glenn Randers-Pehrson" \
|
"Copyright (c) 1998-2002,2004,2006-2016 Glenn Randers-Pehrson" \
|
||||||
PNG_STRING_NEWLINE \
|
PNG_STRING_NEWLINE \
|
||||||
"Copyright (c) 1996-1997 Andreas Dilger" PNG_STRING_NEWLINE \
|
"Copyright (c) 1996-1997 Andreas Dilger" PNG_STRING_NEWLINE \
|
||||||
"Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc." \
|
"Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc." \
|
||||||
PNG_STRING_NEWLINE;
|
PNG_STRING_NEWLINE;
|
||||||
# else
|
# else
|
||||||
return "libpng version 1.6.24beta05 - July 8, 2016\
|
return "libpng version 1.6.24beta05 - July 13, 2016\
|
||||||
Copyright (c) 1998-2002,2004,2006-2016 Glenn Randers-Pehrson\
|
Copyright (c) 1998-2002,2004,2006-2016 Glenn Randers-Pehrson\
|
||||||
Copyright (c) 1996-1997 Andreas Dilger\
|
Copyright (c) 1996-1997 Andreas Dilger\
|
||||||
Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.";
|
Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.";
|
||||||
@ -4090,9 +4090,9 @@ png_build_gamma_table(png_structrp png_ptr, int bit_depth)
|
|||||||
|
|
||||||
/* Remove any existing table; this copes with multiple calls to
|
/* Remove any existing table; this copes with multiple calls to
|
||||||
* png_read_update_info. The warning is because building the gamma tables
|
* png_read_update_info. The warning is because building the gamma tables
|
||||||
* multiple times is a performance hit - it's harmless but the ability to call
|
* multiple times is a performance hit - it's harmless but the ability to
|
||||||
* png_read_update_info() multiple times is new in 1.5.6 so it seems sensible
|
* call png_read_update_info() multiple times is new in 1.5.6 so it seems
|
||||||
* to warn if the app introduces such a hit.
|
* sensible to warn if the app introduces such a hit.
|
||||||
*/
|
*/
|
||||||
if (png_ptr->gamma_table != NULL || png_ptr->gamma_16_table != NULL)
|
if (png_ptr->gamma_table != NULL || png_ptr->gamma_16_table != NULL)
|
||||||
{
|
{
|
||||||
@ -4103,7 +4103,8 @@ png_build_gamma_table(png_structrp png_ptr, int bit_depth)
|
|||||||
if (bit_depth <= 8)
|
if (bit_depth <= 8)
|
||||||
{
|
{
|
||||||
png_build_8bit_table(png_ptr, &png_ptr->gamma_table,
|
png_build_8bit_table(png_ptr, &png_ptr->gamma_table,
|
||||||
png_ptr->screen_gamma > 0 ? png_reciprocal2(png_ptr->colorspace.gamma,
|
png_ptr->screen_gamma > 0 ?
|
||||||
|
png_reciprocal2(png_ptr->colorspace.gamma,
|
||||||
png_ptr->screen_gamma) : PNG_FP_1);
|
png_ptr->screen_gamma) : PNG_FP_1);
|
||||||
|
|
||||||
#if defined(PNG_READ_BACKGROUND_SUPPORTED) || \
|
#if defined(PNG_READ_BACKGROUND_SUPPORTED) || \
|
||||||
@ -4115,7 +4116,8 @@ png_build_gamma_table(png_structrp png_ptr, int bit_depth)
|
|||||||
png_reciprocal(png_ptr->colorspace.gamma));
|
png_reciprocal(png_ptr->colorspace.gamma));
|
||||||
|
|
||||||
png_build_8bit_table(png_ptr, &png_ptr->gamma_from_1,
|
png_build_8bit_table(png_ptr, &png_ptr->gamma_from_1,
|
||||||
png_ptr->screen_gamma > 0 ? png_reciprocal(png_ptr->screen_gamma) :
|
png_ptr->screen_gamma > 0 ?
|
||||||
|
png_reciprocal(png_ptr->screen_gamma) :
|
||||||
png_ptr->colorspace.gamma/* Probably doing rgb_to_gray */);
|
png_ptr->colorspace.gamma/* Probably doing rgb_to_gray */);
|
||||||
}
|
}
|
||||||
#endif /* READ_BACKGROUND || READ_ALPHA_MODE || RGB_TO_GRAY */
|
#endif /* READ_BACKGROUND || READ_ALPHA_MODE || RGB_TO_GRAY */
|
||||||
@ -4146,8 +4148,8 @@ png_build_gamma_table(png_structrp png_ptr, int bit_depth)
|
|||||||
* pow(iv, gamma).
|
* pow(iv, gamma).
|
||||||
*
|
*
|
||||||
* Thus the gamma table consists of up to 256 256-entry tables. The table
|
* Thus the gamma table consists of up to 256 256-entry tables. The table
|
||||||
* is selected by the (8-gamma_shift) most significant of the low 8 bits of
|
* is selected by the (8-gamma_shift) most significant of the low 8 bits
|
||||||
* the color value then indexed by the upper 8 bits:
|
* of the color value then indexed by the upper 8 bits:
|
||||||
*
|
*
|
||||||
* table[low bits][high 8 bits]
|
* table[low bits][high 8 bits]
|
||||||
*
|
*
|
||||||
@ -4180,8 +4182,8 @@ png_build_gamma_table(png_structrp png_ptr, int bit_depth)
|
|||||||
|
|
||||||
/* NOTE: prior to 1.5.4 this test used to include PNG_BACKGROUND (now
|
/* NOTE: prior to 1.5.4 this test used to include PNG_BACKGROUND (now
|
||||||
* PNG_COMPOSE). This effectively smashed the background calculation for
|
* PNG_COMPOSE). This effectively smashed the background calculation for
|
||||||
* 16-bit output because the 8-bit table assumes the result will be reduced
|
* 16-bit output because the 8-bit table assumes the result will be
|
||||||
* to 8 bits.
|
* reduced to 8 bits.
|
||||||
*/
|
*/
|
||||||
if ((png_ptr->transformations & (PNG_16_TO_8 | PNG_SCALE_16_TO_8)) != 0)
|
if ((png_ptr->transformations & (PNG_16_TO_8 | PNG_SCALE_16_TO_8)) != 0)
|
||||||
png_build_16to8_table(png_ptr, &png_ptr->gamma_16_table, shift,
|
png_build_16to8_table(png_ptr, &png_ptr->gamma_16_table, shift,
|
||||||
|
23
png.h
23
png.h
@ -1,7 +1,7 @@
|
|||||||
|
|
||||||
/* png.h - header file for PNG reference library
|
/* png.h - header file for PNG reference library
|
||||||
*
|
*
|
||||||
* libpng version 1.6.24beta05, July 8, 2016
|
* libpng version 1.6.24beta05, July 13, 2016
|
||||||
*
|
*
|
||||||
* Copyright (c) 1998-2002,2004,2006-2016 Glenn Randers-Pehrson
|
* Copyright (c) 1998-2002,2004,2006-2016 Glenn Randers-Pehrson
|
||||||
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
|
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
|
||||||
@ -12,7 +12,7 @@
|
|||||||
* Authors and maintainers:
|
* Authors and maintainers:
|
||||||
* libpng versions 0.71, May 1995, through 0.88, January 1996: Guy Schalnat
|
* libpng versions 0.71, May 1995, through 0.88, January 1996: Guy Schalnat
|
||||||
* libpng versions 0.89, June 1996, through 0.96, May 1997: Andreas Dilger
|
* libpng versions 0.89, June 1996, through 0.96, May 1997: Andreas Dilger
|
||||||
* libpng versions 0.97, January 1998, through 1.6.24beta05, July 8, 2016:
|
* libpng versions 0.97, January 1998, through 1.6.24beta05, July 13, 2016:
|
||||||
* Glenn Randers-Pehrson.
|
* Glenn Randers-Pehrson.
|
||||||
* See also "Contributing Authors", below.
|
* See also "Contributing Authors", below.
|
||||||
*/
|
*/
|
||||||
@ -29,7 +29,7 @@
|
|||||||
* files that are distributed with libpng have other copyright owners and
|
* files that are distributed with libpng have other copyright owners and
|
||||||
* are released under other open source licenses.
|
* are released under other open source licenses.
|
||||||
*
|
*
|
||||||
* libpng versions 1.0.7, July 1, 2000 through 1.6.24beta05, July 8, 2016 are
|
* libpng versions 1.0.7, July 1, 2000 through 1.6.24beta05, July 13, 2016 are
|
||||||
* Copyright (c) 2000-2002, 2004, 2006-2016 Glenn Randers-Pehrson, are
|
* Copyright (c) 2000-2002, 2004, 2006-2016 Glenn Randers-Pehrson, are
|
||||||
* derived from libpng-1.0.6, and are distributed according to the same
|
* derived from libpng-1.0.6, and are distributed according to the same
|
||||||
* disclaimer and license as libpng-1.0.6 with the following individuals
|
* disclaimer and license as libpng-1.0.6 with the following individuals
|
||||||
@ -245,7 +245,7 @@
|
|||||||
* Y2K compliance in libpng:
|
* Y2K compliance in libpng:
|
||||||
* =========================
|
* =========================
|
||||||
*
|
*
|
||||||
* July 8, 2016
|
* July 13, 2016
|
||||||
*
|
*
|
||||||
* Since the PNG Development group is an ad-hoc body, we can't make
|
* Since the PNG Development group is an ad-hoc body, we can't make
|
||||||
* an official declaration.
|
* an official declaration.
|
||||||
@ -314,8 +314,7 @@
|
|||||||
|
|
||||||
/* Version information for png.h - this should match the version in png.c */
|
/* Version information for png.h - this should match the version in png.c */
|
||||||
#define PNG_LIBPNG_VER_STRING "1.6.24beta05"
|
#define PNG_LIBPNG_VER_STRING "1.6.24beta05"
|
||||||
#define PNG_HEADER_VERSION_STRING \
|
#define PNG_HEADER_VERSION_STRING " libpng version 1.6.24beta05 - July 13, 2016\n"
|
||||||
" libpng version 1.6.24beta05 - July 8, 2016\n"
|
|
||||||
|
|
||||||
#define PNG_LIBPNG_VER_SONUM 16
|
#define PNG_LIBPNG_VER_SONUM 16
|
||||||
#define PNG_LIBPNG_VER_DLLNUM 16
|
#define PNG_LIBPNG_VER_DLLNUM 16
|
||||||
@ -2533,18 +2532,22 @@ PNG_EXPORT(216, png_uint_32, png_get_io_chunk_type,
|
|||||||
/* fg and bg should be in `gamma 1.0' space; alpha is the opacity */
|
/* fg and bg should be in `gamma 1.0' space; alpha is the opacity */
|
||||||
|
|
||||||
# define png_composite(composite, fg, alpha, bg) \
|
# define png_composite(composite, fg, alpha, bg) \
|
||||||
{ png_uint_16 temp = (png_uint_16)((png_uint_16)(fg) \
|
{ \
|
||||||
|
png_uint_16 temp = (png_uint_16)((png_uint_16)(fg) \
|
||||||
* (png_uint_16)(alpha) \
|
* (png_uint_16)(alpha) \
|
||||||
+ (png_uint_16)(bg)*(png_uint_16)(255 \
|
+ (png_uint_16)(bg)*(png_uint_16)(255 \
|
||||||
- (png_uint_16)(alpha)) + 128); \
|
- (png_uint_16)(alpha)) + 128); \
|
||||||
(composite) = (png_byte)(((temp + (temp >> 8)) >> 8) & 0xff); }
|
(composite) = (png_byte)(((temp + (temp >> 8)) >> 8) & 0xff); \
|
||||||
|
}
|
||||||
|
|
||||||
# define png_composite_16(composite, fg, alpha, bg) \
|
# define png_composite_16(composite, fg, alpha, bg) \
|
||||||
{ png_uint_32 temp = (png_uint_32)((png_uint_32)(fg) \
|
{ \
|
||||||
|
png_uint_32 temp = (png_uint_32)((png_uint_32)(fg) \
|
||||||
* (png_uint_32)(alpha) \
|
* (png_uint_32)(alpha) \
|
||||||
+ (png_uint_32)(bg)*(65535 \
|
+ (png_uint_32)(bg)*(65535 \
|
||||||
- (png_uint_32)(alpha)) + 32768); \
|
- (png_uint_32)(alpha)) + 32768); \
|
||||||
(composite) = (png_uint_16)(0xffff & ((temp + (temp >> 16)) >> 16)); }
|
(composite) = (png_uint_16)(0xffff & ((temp + (temp >> 16)) >> 16)); \
|
||||||
|
}
|
||||||
|
|
||||||
#else /* Standard method using integer division */
|
#else /* Standard method using integer division */
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
|
|
||||||
/* pngconf.h - machine configurable file for libpng
|
/* pngconf.h - machine configurable file for libpng
|
||||||
*
|
*
|
||||||
* libpng version 1.6.24beta05, July 8, 2016
|
* libpng version 1.6.24beta05, July 13, 2016
|
||||||
*
|
*
|
||||||
* Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
|
* Copyright (c) 1998-2002,2004,2006-2015 Glenn Randers-Pehrson
|
||||||
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
|
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
|
||||||
|
Loading…
Reference in New Issue
Block a user