The GIF file format was developed by Compuserve and is sometimes still referred to as Compuserve Gif. It uses the LZW (Limpel-Ziv and Welch) compression algorithm for 8-bit color images. It is the only image format supported by all graphical web browsers – even the very first ones.
8-bit (28 = 256) color depth refers to the number of colors in an image. Thus, gifs can have upto 8-bit or 256 colors. Decreasing the number of colors in a gif image decreases its file size.
For example, take a look at the two images below. The first image contains 72 colors and the second one only 16 images. Now compare their file sizes – The image with more number of colors is larger in file size.
File size: 1755 bytes
File size: 746 bytes
Though visually the two images might not seem very different, the image with the larger file size uses 72 different color pixels while the other uses only 16 different color pixels.
Decreasing the number of colors in a gif image, especially one that has to be used on the web, is always a good idea because smaller file sizes result in quicker downloads. However, it might also result in dithered and/or ‘blocky’ images. Below are three images – the first one containing only 4 colors, the second with 8 colors while the third contains pixels of 32 different colors. As you have learnt above, Gif images that use more colors are larger in file size and this is proved once again by the images below.
Any way, what I wanted to point out was that as you decrease the number of colors in an image, the image becomes “blocky” and you can see that in the image with 4 color pixels. Note the edges of the green round circle in this image; they appear more jagged than the other two.
There are two kinds of GIF images:
Every third worker in the U.S. is a freelancer. The freelancing workforce is, thus, close to 53 million and earns a total of $715 billion each year. [more...]