








by Janette B.
Bradley
axsWave Software, Inc.
The number of colors your computer can display is dependent on the number of bits (bit-depth) your graphics card is capable of displaying.
The more bits, the better the graphic looks on your computer.
However, the more bits, the larger the file size and the slower the load time for your Web page.
Bits
Color
24-bit
16.7+ million colors
16-bit
65.5 thousand colors
15-bit
32.8 thousand colors
8-bit
256 colors
7-bit
128 colors
6-bit
64 colors
5-bit
32 colors
4-bit
16 colors
3-bit
8 colors
2-bit
4 colors
1-bit
2 colors
Computers deal with graphics that have more colors in it than the graphics board can handle by dithering.
Dithering requires the computer to choose 2 or more colors from its built-in colors to approximate the colors it does not have built in.
This process results in a speckled appearance on some graphics, almost as if the graphic had measles.
Dithering is generally unavoidable on continuous-tone graphics such as gradients or photographs, since these types of graphics have thousands, if not millions of colors in them.
The only people who will be able to view these graphics without dithering are people with graphics boards that can display millions of colors.
Right now most people on the Web have a 256 color display or less.
The key is to design your graphics to either minimize "measles" or design them in such a way that the "measles" effect is not objectionable.
GIF stands for Graphic Interchange Format. It is the most common graphic format on the Web.
GIFs can only contain a maximum of 256 colors.
You generally want to reduce the number of colors even further, since fewer colors means smaller file size and thus faster loading.
Converting a file to GIF from formats such as TIFF, PICT, BMP to GIF compresses the file.
The GIF compression scheme is a "loss less" scheme so no information in the graphic is "lost" during the compression process.
However, if you have a 24-bit graphic (16.7 million colors) the change to 8-bit (256 colors) can cause a serious impact on the quality of the graphic.
There are 2 types of GIFs: 87a and 89a.
GIF 87a format does not offer the option of transparency (discussed later). In Photoshop 87a is referred to as CompuServe GIF.
GIF89a does offer the option of transparency.
Both types can be saved as interlaced. Interlaced GIFs appear on a web page in low-resolution chunks and "rez-up" over several seconds.
The interlaced scheme allows the users to begin reading information on the Web page while the graphic continues to load. The graphic also begins to appear sooner than if it had to load in one piece.
Interlaced GIF files are usually larger than non-interlaced. So if you have a small graphic, less than 2k, use non-interlaced.
JPEG format was created by the Joint Photographic Experts Group.
It was designed to compress photographic-type images and works best with those types of continuous-tone or "organic" images.
If you use it on flat-graphic types of images which contain swaths of the same color, you will often introduce strange artifacts (groups of off-color dots).
JPEG is a "lossy" compression scheme where information about the graphic is lost during compression.
Nevertheless if your graphics card is capable of displaying more that 256 colors, JPEG-compressed photos will be far more attractive than GIF-compressed photos.
One thing to be aware of: JPEG files tend to load slower than GIFs, so even though the file size is smaller it may not be faster loading.
Many new graphics programs offer Progressive JPEG, which is similar to interlaced-GIFs.
Not all JPEG conversion algorithms are created equal. Many of the free ones on the Web are not as effective as some of the ones available commercially.
When you save a JPEG you will be given a choice on the level of quality. Test your graphic at low qualities first. The lower the quality the smaller the file size.
Feel free to contact me with questions or to talk about how axsWave Software team can help you with your Web site:
Janette B. Bradley (janette@metronet.com)








