views:

646

answers:

4

When using PNG files (made with Paint.NET) as background images on my web site, IE7 is changing the colors and actually displaying a darker version of my images, as seen here. In this image, the dark background and background image should be both #001122, and the medium background and background image #004466. But IE7 changes the images to #000C1A and #003A5B respectively. No problem with FF3.

+1  A: 

I think this has to do with Gamma correction. Take a look at this

http://www.hanselman.com/blog/GammaCorrectionAndColorCorrectionPNGIsStillTooHard.aspx

Lou Franco
+3  A: 

IE has a known bug with PNG gamma info, though I thought they had fixed it in version 7 :-?

I remove the gamma info from PNG files using "PNG Crush". I've created a right-click shortcut in Windows explorer. Further info: using pngcrush in windows

Álvaro G. Vicario
In this particular case, removing only the gamma section out of the PNG file is enough: pngcrush -rem gAMA inputfile.png outputfile.pngThanks!
Martin Plante
PNGGauntlet is a nice Windows GUI for PNGOUT that could also be used for removing the gamma from PNGs. http://brh.numbera.com/software/pnggauntlet/
Sam Hasler
A: 

Additional resource on this issue: http://www.modernblue.com/web-design-blog/tweak-that-gamma/

yoavf
A: 

An alternative to PNGOUT is TweakPNG. Comes with a GUI and no installer, very easy to remove the gAMA (just right click and delete it!)

http://entropymine.com/jason/tweakpng/