clear images  
clearpage2    

Most commonly used graphic formats
The images we see on the WWW nowadays basically are in two types: raster and vector. Not every format is suitable for displaying in the browsers, only some are supported. At this moment there is not yet a real standard vector format for the Web.

lovelymaps
GIF
The logo above is a GIF (Graphics Interchange Format) image. A GIF is one of the two most common file formats for graphic images on the World Wide Web. It has become a standard format. The format is actually owned by Compuserve. Companies that make products that exploit the format (not the normal Web users or businesses that include GIFs in their pages) need to license its use.
Technically the GIF format uses 2D raster data type with a binary encoding and makes use of LZW (Lempel-Ziv-Welch) compression techniques. This technique is "lossless", meaning that after de-compressing the image looks the same as before compressing. The compression basically works in the following way: The GIF image is a raster image, pixels are stored in rows and columns. During compression each row is scanned. Taking the Logo of "LovelyMaps" (see above) as an example.
In the first pixel row of the logo the following colour scheme can be seen:
pixelrow
During the encoding the number of pixels per row with the same value are counted. Let's assume the first colour encountered is given the code A, the next B etc., In that case the description of this line is: 2A3B1A15C1D10E1D8A2B5A25C1F1G1F12C1H5C. Each line will get an index number.
Especially when there are large areas with the same pixelvalue, reduction of file size can be enormous. The compression also recognizes patterns, as soon as a pattern is repeated a reference is made to a previous line just by naming the index number.

Additional
The GIF format has some extra characteristics, above the other commonly used format JPEG. GIF supports transparency, interlacing and has the possibility of generating an animation from a sequence of GIF images.
A browser that supports GIF89a can show transparency, in GIF89a one specific colour (one specific indexed number) can be indicated as transparent, not visible. This transparency is a very important item for web designers. Also non-square shapes can be shown on top of the background.
With interlacing an image shows in a gradual increase of the resolution, the image will show already in the browser during download. The surfer is not facing an empty area, but sees what he/she is waiting for. During interlacing the GIF image is not stored line by line, as it usually is, but in blocks. The image is downloaded block by block, and each block is shown in the browser at the moment that it is downloaded. An interlaced image is slightly bigger than a normal GIF. Only use interlacing for larger images.
A GIF animation is nothing more than a sequence of GIF images played at a pre-set speed (David Siegel refers to it in his book "Creating Killer Web Sites" as a "poor-man's video"). Here a small example of the logo of "LovelyMaps" containing the first five images resulting in the animation as shown:
animation


When to use GIF compression
This compression is best used for images that have solid colours. Most thematic maps are within this category. Also when a simple animation has to be made GIF is a good format to use. For images that have graduated colours another compression technique is advisable, JPEG.

 
clear

 

 

 
clearHome
  previousexerc  
prevpage index nextpage
  nextexerc