Section 7-1: About Pictures
Home
Chapter 7
Next
Section 7-2: Using Paint

With the invention of the GUI, graphics have bcome increasingly important through the years. A virtual folder of picture files can be managed easier than reams and reams of paper photographs.

Getting Pictures on Your Computer

While a document can be retyped into the computer, the same is not true for a picture. So how you turn a photo into a nice picture file? Here's how.

Scanner

Using a scanner, you can convert an image on a piece of paper to a picture on your computer. A scanner visually looks like a small, streamlined copy machine.

To use a scanner, simply place your picture face-down in the scanner. Then, use your computer to instruct the scanner to scan. (Most scanner manufacturers include a program for controlling the scanner on a disc along with the scanner drivers.) Many control programs will let you crop (trim) and scale the picture before it is saved to the disc. In most cases you can also send the image directly to the printer, thereby making the scanner be a copier. (In fact, there are even combination scanner/printers designed for this.) However, in most cases one will simply scan the image and save it to a file on their computer, to be stored or edited in an image-editing program such as The GIMP or Photoshop.

If you do not have a scanner, many places operate a scanning kiosk that will allow you to scan your images and burn them to a CD for a small fee. Many copy shops will also scan documents.

Digital Camera

An increasingly popular route to take is to take the photographs with a digital camera. A digital camera differs from a regular one in that it doesn't use film to record its pictures. Instead it uses tiny flash media cards (even smaller than JumpDrives) that can be transferred between cameras and even inserted into some computers. (Files can usually be transferred directly to the computer through a USB cable as well.)

Digital cameras produce pictures that are of higher quality than paper photos that have been scanned. They are also usually larger (in both picture and file size) so fine details can easily be seen.

CDs From Photo Developers

Some photo developers (Wal-Mart Photo Center is one) also offer the option to purchase a CD containing digital images of your photos. The quality is about equal to if you had scanned the image with a scanner.

Bitmaps vs. Vector Images

There are two different types of pictures: bitmaps and vector images. They differ in how they store picture data and how it is edited.

Bitmaps

Bitmaps are the traditional kind of image. They consist of a grid of squares called pixels. Each pixel corresponds to a pixel on the monitor (see Section 2-2 for more on pixels). The pixels are each one color. Together, they create an image.

There are some drawbacks to bitmaps. When they are scaled down, there are less pixels, so the image loses detail. Also, lines that are not perfectly vertical or horizontal appear jagged because they do not perfectly fit in to the grid of pixels. (Anti-aliasing, the technique of blurring a line into its surroundings, can minimize this effect.)

Vector Images

Vector Images or vector drawings are images composed of design elements defined by math formulas. They solve the drawbacks of bitmaps because they do not use the grid of pixels used by bitmaps. Unfortunately, they have drawbacks of their own: vector images cannot store extremely detailed objects, such as photographs. Also, they are generally not supported as well as bitmap images are.

Picture Formats

Unlike with Microsoft Office, there are a multitude of formats availiable to store pictures with. It can sometimes get confusing to decide which one to use. However, whichever one you pick depends on what you intend to use the image for. This book will only explore the most popular picture formats.

Windows Bitmap

The *.bmp format is the default format saved by Microsoft Paint. It loses absolutely no quality - it is lossless. Unfortunately, this means the file size can quickly balloon past acceptable levels.

Windows bitmaps are useful for transferring images between editors because of their losslessness and the fact that just about every image editor supports them. (You can save as a *.bmp in one editor and then load the file into the other editor.) Bitmaps are unsuitable for transferring between computers because of their large size. On the Internet, they can be a pain, especially to those with slow connections.

Bitmaps are a good format for storing very small images.

JPEG Format

The Joint Photographic Experts Group developed this format that bears their name. JPEGs are very small, and so they are popular on the Internet. However, they are lossy. They typically have a *.jpg extension, though sometimes they have an *.jpeg extension.

Color mixingColor mixing
Figure 7.1: JPEG is a lossy format that is good for compressing image sizes. The first picture is the original *.bmp file created in Microsoft Paint (88 KB), and the second image is the JPEG saved from Paint (5 KB).

JPEGs are typically fairly low quality. Digital cameras take very large images, and save them as JPEG. Even so, they are usually almost 1MB in size even when compressed. While JPEGs are great in some instances, don't use them for pictures where fine detail is important!

GIF

The GIF format is also favored on the Internet. File sizes range a little bit larger than that of JPEG. GIF has two interesting features that other formats lack. One of these is that one color in the image may be specified as the "transparent color". Most often, bright green or purple is used as this color does not normally occur in pictures. The boundaries of this color will also be used for things such as wrap points in Microsoft Word.

GIF images can also support small animations (usually used for cartoons). These are found in abundance on the Web. They cannot store extremely long or complex animations.

There is one disadvantage to the GIF format. It cannot handle more than 256 different colors per image. Because of this, pictures which have more than 256 colors (photographs, for instance) may end up looking bad.

PNG

This fairly new format is intended to replace the GIF format described above. Because of this, it has a lot of features that GIF does. However, PNG does not support animations. PNG also supports more than 256 colors

Another difference between the PNG and GIF formats is the way they implement transparency. Rather than designating one color to be displayed as transparent, PNG images include a second, hidden image called an alpha channel. The alpha channel is a grayscale silhouette of the image. White parts will be displayed as transparent, black parts will be opaque, and shades of gray indicate translucency (semi-transparency).

Original imageAlpha Channel
Figure 7.2: An image and its alpha channel. The first image is the original image while the second image is the alpha channel

The alpha channel technique is more flexible because of the added ability to allow a pixel to be semitransparent. This allows antialiasing on edges separating transparent parts of the image from opaque parts. (Because antialiasing blurs the lines - creating many intermediate shades - GIF images will not render the pixels filled by antialiasing as transparent, as they need to be to pull off the trick.)

For more information about the PNG format you might want to visit the <libpng> website.

Opening Pictures

On most computers, opening an image is as easy as double-clicking its icon in Windows Explorer. This will open an appropriate program for that image format. For instance, *.bmp images will bring up Microsoft Paint, while *.gif and *.jpg images will display in Internet Explorer.

A new feature in Windows XP is the Windows Picture and Fax Viewer. It will display images when you open them. You can also scroll through the images in the folder by clicking the blue left and right buttons in the lower-left hand corner of the page.

Windows Picture and Fax Viewer
Figure 7.3: The Windows Picture and Fax Viewer in action

Now that you know how to store and access pictures on your computer, continue on to Section 7-2, where you learn how to create basic images with the Microsoft Paint program included with Windows.

Home
Chapter 7
Next
Section 7-2: Using Paint
Valid XHTML 1.0 Strict