Contents - Index - Previous - Next

Image Format Basics

Image Format Basics 

James P. Terry

For the beginner, selecting a picture format, resolution, dimensions and compression options when scanning or editing pictures can be confusing. Just plain "not knowing" often results in huge graphics files that take up vast amounts of disk space, use up system memory (RAM), take a very long time to load or just can't be viewed or printed by Legacy at all.
The initial release of Legacy supports some 25 picture formats: BMP, CALS, DCX, EPS, GEM IMG, GIF, HALO CUT, ICO, IFF, IOCA, JPEG, LASERVIEW, MACPAINT, MSP, PCX, PNG, PSG, PCD, PICT, XPM-X, RAST, TARGA, TIFF, WMF, WPG and XBM-X. The following discussion is limited to BMP, GIF, JPEG, PNG and TIFF, which are generally considered the essential graphics formats.
Image Formats
The first factor to consider when scanning or editing a picture or document is the file format. File format is the specific way image information is produced and stored digitally. The format you select should be matched to the picture's intended use if optimal quality with minimum file size is to be achieved. For example, Web browsers will only support JPEG (.jpg), Graphic Interchange Format (.gif.), and Portable Network Graphic (.png) images. This means you should not scan a picture and save it as a TIFF (.tif) or Bitmap (.bmp) if you really intend for people to see it on the Internet.  (Yes, Legacy will convert TIFFs and Bitmaps to JPEGs when creating web pages, but then you end up with the same picture in two formats.) Here are some essential formats and their uses:
BMP (Bitmap)
BMP is the standard Windows bitmapped graphic file format. BMP can represent a monochrome line-art image, continuous gray scale, or True Color image. The BMP format should not be used for Web pages and only full color mode should be used for archiving images. BMP files are normally very large. RLE compression is available for Windows BMP images. The TIFF format is preferred over BMP for archiving images. Legacy recognizes all "flavors" of BMPs.

GIF (Graphics Interchange Format)
GIF is a common graphic format on the Internet for artwork having large blocks of solid color, or having a transparent background, or which is animated. GIFs contain information compressed into a relatively small file format. This is because GIF images are limited to 256 colors (8-bit). However B&W photos and those color photos with fewer than 256 palette colors can successfully be saved in the GIF format. The tintype at the right is a good example of a B&W picture with 239 shades of gray saved as a GIF image. (JPEGs are preferred over GIFs as a format for images with more than 256 colors (full or true color). The regular release of Legacy does not support the GIF format because of licensing issues. LZW compression is available for GIF images. 

TIFF (Tagged Image File Format)
TIFF is a bitmapped graphics that can contain a high level of information about each bit or pixel. TIFF images come in several "flavors": monochrome, 8-bit, or 24-bit images. In addition, the TIFF format supports transparency. The format was developed for Macintosh and PC/Windows publishing applications, such as Adobe PageMaker and QuarkExpress. Save your images as TIFFs if you plan to reproduce them in printed form. TIFFs are also preferred as an archival file format, however; they can make for very large files. 

The TIFF format supports several compression methods, including the JPEG and LZW, but the lossy JPEG compression method should be avoided if archiving.  Legacy recognizes all TIFFs, except those employing LZW compression, which should be avoided.

PNG (Portable Network Graphic)
PNG is a good choice for archiving images because it utilizes a lossless (non-lossy) compression method and supports up to 48-bit True Color. In 24-bit True Color images, PNG supports transparency and is intended to eventually replace the proprietary GIF format owned by Compuserve. One important advantage of PNGs is their images contain gamma correction information, which helps the images maintain the same brightness on various computer monitors and printers. If your pictures look OK on the screen, but print out too dark, try using the PNG format.

PNG is quickly growing in popularity on the Web and the format is compatible with the most recent versions of Internet Explorer and Netscape browsers. Because PNG files are lossless, there is no image deterioration when the image is compressed. PNG images make for larger file sizes than their JPEG or GIF counterparts. Legacy recognizes the PNG format.

JPEG (Joint Photographic Experts Group)
JPEG is a graphic file format that compresses up to 16 million colors (True Color) in an image into a relatively small file. Although JPEGs can achieve much greater compression than other methods, the images can suffer noticeable loss of quality if re-edited. JPEGs are the preferred format for color photos on the Internet.
Image Resolution
The second factor to consider when scanning or editing is image resolution. The following table shows typical files sizes based on a 24-bit True Color photograph scanned at 100 percent for three common resolutions. (Your actual file sizes may vary.)
Purpose & Resolution (dots per inch) Photo Size: 4X5 Photo Size: 5X7 Photo Size: 8X10 
Screen Viewing: 72 dpi .300 MB .530 MB  1.39 MB 
Printing: 300 dpi 5.15 MB 9.01 MB 24.10 MB 
Archiving/Editing: 600 dpi 20.60 MB 36.10 MB 96.30 MB 
As you can see from the above table, the higher the resolution, the larger the file size will be. The various resolutions depend on the application of the image. Image applications can generally be classified in three broad categories: screen viewing (including Web pictures and e-mail attachments), printing, and archiving/editing.
A picture scanned at 100 percent at 72 or 75 dpi will appear on a monitor very close to the picture's original size because monitors typically display at 72 dpi. A picture scanned at 100 percent at 300 dpi will print at the picture's original size because most printers print at 300 dpi. The exception is  when you are scanning small images or images that you will edit. In these instances scan at 600 dpi or higher. Most graphics programs will allow you to crop and enhance an image in various ways; as well as let you change the resolution and resize, plus save the edited image in a format of your choice. By working with an image at 600 dpi or higher, little or no detail will be lost in the final product.
Please refer to the following table, which summarizes common file applications matched to suggested formats:
Application Recommended Formats  
Printing .tif, .bmp, .png  
Screen Viewing  .tif, .bmp, .png, .jpg, .gif  
Web Pages .jpg, .gif, .png  
E-mail Attachments .jpg, .gif  
OCR and FAX .tif  
Pre-Press .tif, .bmp, .png  
Editing, Enlarging and Reducing .tif, .bmp, .png  
Archiving .tif, .bmp, .png  
Image Dimension
The third factor to consider is the dimensions of the image in dots per inch or dpi. (For sake of discussion, consider dpi the same as pixels .) For example, when including pictures in Web pages, Legacy offers picture size options of Small, Medium and Large. Large pictures display 200 pixels wide. Unless there are overriding factors, you may wish to reduce any pictures to 200 pixels wide to match. Why load a picture 600 pixels wide when a smaller image would load faster, and fill up less precious disk space?  On the other hand, a picture that is too small, can look like a mosaic (pixelated) when "stretched" to a larger size. When scanning large pictures, for example an 8x10 photograph, try setting the scaling factor at 50 percent or less. In addition, when planning pictures for the Web, consider how your images would appear on a monitor set at the lowest resolution available, which is 640 X 480 pixels, and keep your image dimensions well within those limits.
Image Compression
The fourth factor to consider is image file compression. Compression is a way of "squeezing" an image in order to reduce file size.  There are two general approaches to compressing digital images. The first approach is called "non-lossy" or lossless compression because it saves the image as close as technically possible to the picture's original appearance. The second approach called is "lossy" compression and uses complex mathematical formulas to reduce file size. The result is a dramatically smaller file, at the expense of some discarded image information. Compression methods include:

JPEG Compression
JPEG is a lossy compression method that eliminates repetitive image data or visual information the human eye cannot perceive. It was developed by a group of photographic experts to achieve much greater compression than other methods. Scanned pictures once saved as JPEG images should not be re-edited or visible degradation can occur. In addition, compression ratios can be varied by the user; however, compression greater than 20 percent is not advised because of the noticeable image deterioration that can occur.

LZW (Lempel-Zif-Welch)
LZW compression does not discard data during compression, and thus provides an accurate reproduction of the original image. It is best at preserving all the image data and achieving non-lossy compression, but it doesn't achieve the high compression ratios that JPEG does. LZW is available for monochrome, grayscale, palette, and True Color images, however; the amount of compression cannot be varied.

RLE (Run Length Encoding)
Associates a count with a pixel value. For example, the number 250, followed by the numerical value for blue, encodes a line of 250 blue pixels. RLE gives good compression ratios for images that have large blocks of consistent color.
With increased understanding of  picture formats, resolution, dimensions and compression options, you should be better equipped to scan and edit pictures in order to achieve optimal picture quality with a minimal file size. Such images will help you conserve disk space, avoid images that use up system memory, and decrease loading time for pictures put on the Web or sent as e-mail attachments. Good luck!