HTML and CSS Reference
The GIF format also supports animation through a basic page-flipping architec-
ture. With GIF animation, a series of images are rapidly displayed to give the
appearance of movement. GIF animations are frequently used for simple banner
ads on the Web.
A photographic image is best represented in the JPEG format. The acronym is derived from the for-
mat's creator body, the Joint Photographic Experts Group. A JPEG image can be comprised of thou-
sands of colors, necessary for showing color ranges like those that appear in nature or in skin tones.
Unlike GIFs, JPEGs cannot display any transparent areas. To make a JPEG image smaller in file size,
reduce the quality setting. Because a lossy compression algorithm is used, when the quality is reduced
too much of the image visibly becomes less recognizable. For example, Figure 10-2 shows the same
image with three different quality settings. Although there is little visual difference between the first
two, the file size reduction is significant. The third image, however, goes too far; although the file size
is the smallest of the three, the image quality has deteriorated too far for the image to be used.
In some ways the best of both worlds, the PNG (Portable Network Graphics) format offers a wide
color range like JPEG, and transparency like, but superior to, GIF. PNG provides several output for-
mats like 8-bit, 16-bit, and 24-bit color so you can optimize your images appropriately. Of the three
formats, PNG images are found the least on the Web because across-the-board browser support has