1 --- src/kernel/qpngio.cpp.orig 2010-01-16 22:02:41.000000000 +0100
2 +++ src/kernel/qpngio.cpp 2010-01-16 22:03:56.000000000 +0100
4 image.setColor( i, qRgba(c,c,c,0xff) );
6 if ( png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS) ) {
7 - const int g = info_ptr->trans_values.gray;
8 + const int g = info_ptr->trans_color.gray;
10 image.setAlphaBuffer(TRUE);
11 image.setColor(g, image.color(g) & RGB_MASK);
13 info_ptr->palette[i].red,
14 info_ptr->palette[i].green,
15 info_ptr->palette[i].blue,
17 + info_ptr->trans_alpha[i]
22 png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS)
23 if (image.depth()==32 && png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS)) {
24 QRgb trans = 0xFF000000 | qRgb(
25 - (info_ptr->trans_values.red << 8 >> bit_depth)&0xff,
26 - (info_ptr->trans_values.green << 8 >> bit_depth)&0xff,
27 - (info_ptr->trans_values.blue << 8 >> bit_depth)&0xff);
28 + (info_ptr->trans_color.red << 8 >> bit_depth)&0xff,
29 + (info_ptr->trans_color.green << 8 >> bit_depth)&0xff,
30 + (info_ptr->trans_color.blue << 8 >> bit_depth)&0xff);
31 for (uint y=0; y<height; y++) {
32 for (uint x=0; x<info_ptr->width; x++) {
33 if (((uint**)jt)[y][x] == trans) {