Change two remaining "gamma" to "png_gamma" (Brandon Casey)

This commit is contained in:
Glenn Randers-Pehrson 2009-04-20 11:49:24 -05:00
parent 8764c2595d
commit 4db4affbaf

View File

@ -1,7 +1,7 @@
/* pngset.c - storage of image information into info struct /* pngset.c - storage of image information into info struct
* *
* Last changed in libpng 1.4.0 [April 19, 2009] * Last changed in libpng 1.4.0 [April 20, 2009]
* For conditions of distribution and use, see copyright notice in png.h * For conditions of distribution and use, see copyright notice in png.h
* Copyright (c) 1998-2009 Glenn Randers-Pehrson * Copyright (c) 1998-2009 Glenn Randers-Pehrson
* (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger) * (Version 0.96 Copyright (c) 1996, 1997 Andreas Dilger)
@ -123,7 +123,7 @@ png_set_gAMA(png_structp png_ptr, png_infop info_ptr, double file_gamma)
png_gamma = file_gamma; png_gamma = file_gamma;
info_ptr->gamma = (float)png_gamma; info_ptr->gamma = (float)png_gamma;
#ifdef PNG_FIXED_POINT_SUPPORTED #ifdef PNG_FIXED_POINT_SUPPORTED
info_ptr->int_gamma = (int)(gamma*100000.+.5); info_ptr->int_gamma = (int)(png_gamma*100000.+.5);
#endif #endif
info_ptr->valid |= PNG_INFO_gAMA; info_ptr->valid |= PNG_INFO_gAMA;
if (png_gamma == 0.0) if (png_gamma == 0.0)
@ -156,7 +156,7 @@ png_set_gAMA_fixed(png_structp png_ptr, png_infop info_ptr, png_fixed_point
png_gamma = int_gamma; png_gamma = int_gamma;
} }
#ifdef PNG_FLOATING_POINT_SUPPORTED #ifdef PNG_FLOATING_POINT_SUPPORTED
info_ptr->gamma = (float)(gamma/100000.); info_ptr->gamma = (float)(png_gamma/100000.);
#endif #endif
#ifdef PNG_FIXED_POINT_SUPPORTED #ifdef PNG_FIXED_POINT_SUPPORTED
info_ptr->int_gamma = png_gamma; info_ptr->int_gamma = png_gamma;