Tuesday, January 04, 2005

The PNG Image Format..


I was sitting here looking at my lonely mIRC Status window and decided to say something about my favorite image format, PNG. PNG, pronounced PiNG, has been around since the mid to late 1990's and is a nearly perfect format. It was created to be a direct substitute for "GIF" or Graphics Interchange Format.

The PNG format supports Alpha Transparency and up to 48-bit color. Images created using the GIF format offer only 8-bit color and no Alpha Transparency. You can read a short definition explaining what an Alpha Channel is by clicking here.

On this blog I'll be using mostly PNG images because they look great for computer graphics. For Photo images, JPEG is still the best however. That is unless you can manage to scan a photo and save it as a PNG. GIF on the other hand is now totally obsolete. The only reason it's still so prominent on the Internet is because Internet Explorer doesn't yet fully support the PNG format.

Here is a breakdown of what images can, should and shouldn't be converted to PNG:
  • GIF images can and should be. Any GIF images converted to PNG will have a smaller file size if transferred correctly.
  • JPEG images can but should not be. JPEG images converted to PNG tend to have a higher file size because of the way the JPEG format stores the image's color information.
  • Lossless formats such as TIFF and BMP are perfect candidates for the PNG format. PNG is also lossless and, in the case of BMP, can considerably decrease the file size.
The image that I placed above this post is a PNG image with an Alpha Transparency. Therefore it will not look proper when viewed in Internet Explorer, but will still be visible in a degraded form. Firefox and nearly every other web browser can and do display it as it was intended. The image placed at the end of this post also utilizes PNG's Alpha Transparency, and to a greater extent. Sadly, IE users will only see a big a white square in place of that very nice image.

With every new version of IE, web developers have kept their fingers crossed with the hope that Microsoft had finally implemented the PNG format. Time and again they were disappointed. Eventually Microsoft will fix the PNG issue. They've made it well known to web developers that even they would rather use PNG over GIF. Until they fully implement it however, PNG will remain somewhat of a "Secret" to the mainstream public.

Don't like waiting? You don't have to if you are one of the enlightened people using a Mozilla based browser. Such as Firefox! There is a whole world of beautiful PNG enabled websites waiting out there for you to find them. I'll eventually make a post to list as many as I can.

Learn More About PNG:
http://www.libpng.org/pub/png/


No comments: