Raster graphics

On this page 7

Raster graphics are digital images made of a fixed grid of pixels, each storing a color value. In graphic design, raster images (also called bitmap images) are the natural format for photographs, painted textures and detailed tonal transitions, because each pixel can hold an independent color.

The defining limitation is resolution dependence: a raster image contains a set number of pixels, so enlarging it beyond that detail produces blur or visible pixels. This distinguishes raster graphics from vector graphics, which describe shapes mathematically and scale without loss.

How raster graphics store an image

A raster image is a two-dimensional array of pixels defined by its pixel dimensions, such as 3000 by 2000 pixels. Each pixel stores values for one or more color channels, for example red, green and blue, plus an optional alpha channel for transparency.

The amount of tonal detail depends on bit depth. An 8-bit-per-channel RGB image can represent about 16.7 million colors, which is sufficient for final delivery, while 16-bit-per-channel files preserve smooth gradients during heavy editing and reduce the risk of banding.

PropertyTypical valuesWhat it determines
Pixel dimensionsFrom icons of 16 px to photos over 8000 pxTotal detail available
Bit depth8 or 16 bits per channel, 32-bit float for HDRNumber of tonal steps
Color modeRGB, CMYK, grayscaleIntended output medium
Color profilesRGB, Display P3, Adobe RGB, print profilesHow values map to real colors
Alpha channelPresent or absentTransparency and soft edges
Key properties of a raster image

Resolution, size and output

Pixel dimensions alone determine how much detail an image holds. PPI (pixels per inch) only describes how densely those pixels are placed when the image is output, so changing PPI without resampling does not add or remove detail.

For print, the common guideline is about 300 PPI at final size for close viewing; large posters viewed from a distance can use 150 PPI or less. For screens, the relevant measure is pixel dimensions relative to the display, with 2x assets commonly prepared for high-density displays.

UseResolution targetReason
Magazine or brochure printAbout 300 PPI at print sizeClose viewing distance
Large-format posterAbout 100 to 150 PPIViewed from several meters
Website hero imageAbout 2000 to 2600 px wideCovers wide and high-density screens
App icon or UI asset1x, 2x and 3x sizesSharp on different pixel densities
Typical raster resolution targets by use

Upscaling a raster image must invent new pixels through interpolation or machine-learning-based enlargement. The result can look acceptable, but it cannot recover detail that was never captured.

Raster file formats

Raster formats differ in compression, transparency support and color depth. Choosing the right one balances quality, file size and compatibility.

FormatCompressionBest use
JPEGLossy, no transparencyPhotographs for web and sharing
PNGLossless, alpha transparencyScreenshots, interface assets, flat graphics
WebPLossy or lossless, transparencyWeb images with smaller file sizes
AVIFEfficient lossy or lossless, HDR supportModern web delivery
TIFFUncompressed or lossless, layers possiblePrint production and archiving
GIFLossless, 256 colors, animationSimple animations and legacy uses
Common raster formats compared

Lossy compression discards information each time a file is saved again, so working files should be kept in a lossless format and exported to JPEG, WebP or AVIF only for delivery.

Raster graphics compared with vector graphics

Raster and vector graphics solve different problems, and most graphic design projects combine both. The comparison shows when each is the right choice.

AspectRaster graphicsVector graphics
StructureGrid of pixelsPaths defined by points and curves
ScalingLoses quality when enlargedScales to any size without loss
Best contentPhotos, textures, painted detailLogos, icons, type, diagrams
EditingPixel-level retouching, maskingShape and node editing
File size driverPixel count and compressionNumber and complexity of paths
Typical formatsJPEG, PNG, WebP, TIFFSVG, PDF, EPS, AI
Raster versus vector graphics

A logo should therefore be created and stored as a vector and exported to raster only for specific outputs, whereas a product photograph is inherently raster and is isolated from its background with masking or a clipping path.

Common raster mistakes

  • Enlarging small web images for print produces soft or pixelated results.
  • Repeated JPEG saving accumulates compression artifacts around edges and in gradients.
  • Missing color profiles cause colors to shift between applications and devices.
  • Raster logos and text become blurry at large sizes and should be replaced by vector originals.
  • Oversized images on websites slow page loading; images should be resized and compressed for their display size.

A non-technical view

A raster image is like a mosaic made of tiny colored tiles. From a normal distance, the tiles blend into a smooth picture, such as a photo of a face or a landscape.

The number of tiles is fixed. If the picture is stretched very large, the tiles become visible and the image looks blocky or blurry. That is why photos work well as raster images, while logos are usually made in a different way that can grow without limits.

A concrete example

A graphic designer prepares a trade fair banner that is 2 meters wide. The client supplies a product photo downloaded from its own website, measuring only 1200 by 800 pixels, and a logo saved as a small PNG.

At 2 meters wide, the photo would print at only about 15 PPI, which would look visibly soft even from a distance. The designer requests the original camera file of about 6000 by 4000 pixels, which yields roughly 75 PPI at banner size, adequate for viewing from several meters. The logo is replaced with the original vector file.

The printed banner shows a sharp product image and crisp logo edges, and the client avoids an expensive reprint caused by low-resolution raster artwork.