fixed png reader bug :

fill alpha channel with 0xff on expansion
This commit is contained in:
Artem Pavlenko 2006-12-01 15:23:19 +00:00
parent f4786fe76a
commit bbab2d90bf

View file

@ -189,8 +189,8 @@ namespace mapnik
png_set_gray_to_rgb(png_ptr);
// quick hack -- only work in >=libpng 1.2.7
png_set_add_alpha(png_ptr,1,1);
png_set_add_alpha(png_ptr,0xff,PNG_FILLER_AFTER); //rgba
double gamma;
if (png_get_gAMA(png_ptr, info_ptr, &gamma))
png_set_gamma(png_ptr, 2.2, gamma);