Published
on
August 22, 2008
| 0 followers
members are following updates on this item.
| Last 30 Days | All-Time | |
|---|---|---|
| Total Views | ||
| Unique Visitors |
*Unique visitors count logged-in members only and excludes anonymous views. Total view count is real-time.
Unable to load view analytics. Please try again later.
1 Comment
Comment by Ian Ring:
PNG is a really nice format to use while roughing in the designand CSS of a site. First, chop up your layout into 64-bit losslessPNG images, and build your CSS and HTML so everything lookspixel-perfect. The page size will be huge, but that's not animmediate concern. When all the design work is done, you'lloptimize all those sliced up PNGs - some will be converted to JPG,others may become a smaller 32-bit or 16-bit PNG, or GIF -depending on its palette, transparency needs, etc. Some may even bediscarded entirely, visually replaced by CSS techniques.
There are techniques using PNG that, if used intelligently, willsave bandwidth - potentially lots of it! For instance, you canreuse PNG opaque-to-transparent gradients layering them over solidcolors, to produce color gradients. If your design uses a lot ofgradients as backgrounds with complex foregrounds, using PNGlayering will prevent the use of images with large blocks ofgradated colors (which are normally can not be compressed verywell) behind foreground elements (which can be placed over thegradient as a separate layer, potentially with a much smallerpalette size and antialiased transparency).
Images that are going to be shown over different backgroundcolors are a perfect fit for PNG. If you employ antialiasing in thealpha channel, your icon will never have that "jagged whitehalo"
The only true advantage of PNG is its alpha channel. I'm all forusing PNG where it's appropriate, but alas designers who use PNGcompulsively can get lazy about optimization (speaking frompersonal experience) and end up with huge 64-bit images consumingbandwidth where 64-bit images aren't needed. Using PNG is likecooking with salt. Use it sparingly where it's needed to enhance aflavour, but don't put it on everything. Some people put salt oneverything. Yuck!
GIF has transparency too - selected pixels can be colored"see-through". In contrast, PNG can do has partial opacity - anypixel can be colored and semi-transparent. Adding an alpha(opacity) channel theoretically increases the file size by 1/3(increasing from 3 channels to 4 is an increase of 33%). Chooseyour compression format conservatively - do you need opacity, or doyou only need transparency?