Digital Images

From Eduwiki

Jump to: navigation, search

What is a digital image? You can think of it as a digital copy of a picture, but its not really the picture. A digital image is a set of instructions for how to draw the image on a screen (or printer). Any digital image will have two parts: the header and the image data.

Image types

Contents

Rastor Images

A rastor image (or bitmap) contains information about the coloring of the pixels in a image. Typically the image is defined within an rectangular area. Color information is stored in the image data by rows. Rastor images differ in their color depth, their pixel resolution and their compression format.

Color Depths

The color depth is a measure of the how many different colors are available to be used. Most images use the RGB color model (some use CMYK). Often you can select levels of gray (grayscale) instead of color.

Binary images (1 bit) have pixels that are one of two colors - typically black or white. Each pixel requires only 1 bit of information (a bit can be either a 1 or 0). Also called monochrome.

Palette images (8 bit) have pixels which can have one of 256 colors. Each pixel requires only 8 bits of information. The data can refer to a color listed on a palette of available colors or identify the red, green and blue (3 for red, 3 for green and 2 for blue).

High color (16 bit) is also known as "thousands of colors" because it uses 5 bits each for red and blue and 5 or 6 for green.

Truecolor (24 bit) is "millions of colors" because it uses 8 bits (256 options) for red, green and blue. 256^3 = 16,777,216.

Larger color depths up to 64 bit are starting to be used.

Pixel Size and Resolution

In the past the size of a picture could simply be described in terms of its pixel dimensions (e.g. 480 x 640 pixels). But modern image editing tools allow you to specify both the size of the image (in inches or centimeters) and the resolution (in pixels per inch/centimeter). The pixel dimensions are determined by multiplying the size and pixels per inch (ppi).

Computer screens have traditionally be between 70-80 ppi, but high definition screens have resolution up to 130 ppi. Many graphics are set to a 73ppi if they are intended to be used on screens only. But these images can look bad if they are zoomed in on. Some printers can print images with resolutions above 4800 ppi.

Compression

Compression of raster images typically uses techniques to reduce the number of pixels that have specific color data. Some compression is lossless (image quality remains the same) while others are lossy (image quality is reduced).

JPEG (Joint Photographic Experts Group) is one of the most popular formats because it produces small image files with limited loss of quality. Most cameras have built in JPEG compression.

TIFF is a generic file type that can be compressed in many different ways (some of which can not be read by many programs). Often TIFF files are used with lossless compression so the files are large.

GIF (Graphics Interchange Format) is a limited color (8-bit) format that supports both transparency and sequences of images to produce simple animations. GIF uses lossless compression that is best used for simple images. GIF format is proprietary (owned by CompuServe) but few have to pay for its use.

PNG (Portable Network Graphic) was developed when Compuserve threatened to enforce their patten on GIF. PNG uses 24 bit color and can support transparency. Compression is lossless so it is a good format to save pictures (and convert to JPEG for distribution). Older browsers and software may not support PNG.

Vector Graphics

Vector graphics are defined by shapes and modifications, instead of pixels. This allows vector graphics to be much smaller in size than rastor graphics and allows them to be scaled to any size without any loss of quality. Ideal for simple generated images, vector graphics are widely used by graphic artists. Many editing program allow both vector graphics and raster graphics to be overlayed in different layers on the same image.

Typical shapes include:

  • polygons
  • ellipses
  • straight lines
  • hand drawn Bezier curves
  • Bezigons - closed shapes created by repeated clicking
  • text

Vector file formats include SVG (Scalable Vector Graphics), AI (Adobe Illustrator) and SWF (Adobe Flash).

Personal tools