I confused you!

Graphics files re-explained

Computer Life column for February 7, 1998 by
Richard Gordon


Last Saturday, my dad called from Arizona to tell me he had no idea what I was talking about in last week's column. I heard the same thing from at least four other readers.

Two students at UD assailed me on Tuesday, complaining that I had over-simplified the distinctions between two file types I'd mentioned.

OK, class, let's review before we move on to the next topic.

What is a graphics file?

Just as a newspaper photo is composed of many tiny dots, usually 1,200 or more per inch, a computer image is composed of tiny dots of color-each dot is called a "pixel." Most computer monitors display 72 pixels per inch; many home computer printers can print images with 300 or 600 pixels per inch.

In short, all graphics files contain information interpreted by a computer program so that all these little dots can make a coherent image.

We don't all speak the same language, neither do our computers. If someone uses X to convert a photo of his grandson into a computer file and sends you a file in X's special language, you usually can't see the image unless you also have program X.

As a result, myriad competing "standards" for storing images sprang up, different attempts to make more portable files that could be created with one program, yet viewed in others.

Most common formats: GIF and JPEG

There are many common formats (TIFF, PICT, BMP), none of which require you to use the exact program that created the image. However, two types of graphics files are most common on the Net: GIF and JPEG. Almost every commercial or shareware graphics package and all graphics-capable Web browsers understand both of these formats.

GIF files can only have 8 bits (or tiny chunks) of information about each pixel, meaning that they can only display 256 different colors. They are usually restricted to 72 dots per inch. You can also combine several GIF files into an animation that appears to move.

The JPEG format allows you to adjust the number of bits you want stored about each pixel so that your image could use thousands, even millions, of colors. You can also adjust the resolution, the number of dots per inch. Sorry, can't make them dance.

Further, JPEG files are compressed; that is, they are made smaller before you store them on your disk, in a process much like you'd fold your bedsheets before putting them away on a narrow shelf. But before JPEG files can be viewed, they have to be uncompressed, or unfolded, in your computer's memory (RAM).

Greg and Tyler, the students who accosted me, usually store all their graphics as JPEG files, increasing the "folding" and decreasing the amount of information stored when they need to save space; increasing the amount of information stored when they want to improve the quality. That approach works as well as the one I mentioned last week: storing smaller GIF files and larger JPEG files depending on what you need the image for.

As a test, we turned a 900K Photoshop image into a GIF (99K), a low-quality, highly compressed JPEG (90K), and a high-quality JPEG (215K).

Why does this matter?

If you have one of those nifty Hewlett Packard computers with a photo scanner in the case-next to the CD-ROM drive-or a 16-bit (64,000+ colors) digital camera or 24-bit (16 million+ colors) scanner, you may be driving your friends and family nuts by sending them family snapshots in e-mail or begging them to visit the "Holiday Scrapbook" on your Web page.

If you want to be sure they see your pictures, you'll have to teach yourself how to save your images in GIF and JPEG formats.

Further, you need to be sensitive to the size of the files you send in e-mail. Large files attached to e-mail can cause havoc for some of your recipients with restrictions on the size of their inbox or a slow modem.

As one of my music pals puts it: "Friends don't send friends large, unsolicited e-mail messages!"


Copyright © 1998, The News Journal Company

Computer Life Index

Richard Gordon helps support faculty, staff and student computing at the University of Delaware. E-mail questions, comments or suggestions to richard@inet.net, or write him at The News Journal, Box 15505, Wilmington, DE 19850. Although each note cannot be answered individually, reader comments and questions will often be incorporated in future columns.