What is a Bitmap?
A bitmap represents an image as a rectangular grid of pixels, each storing a color or intensity value. Depending on context, the term may mean one bit per pixel or more broadly any raster image.
How Bitmaps work
A bitmap lays samples out over a fixed two-dimensional pixel grid, making spatial resolution intrinsic to the representation. The word can narrowly mean a one-bit map or broadly mean any raster buffer, while BMP names a specific file family and should not be treated as a synonym in API design. Encoded formats are decoded into bitmap memory for compositing and filters. That working buffer is sized by dimensions, channels, depth, row stride, and sometimes multiple planes.
Key facts
- 1A compressed PNG or JPEG may occupy little storage yet expand into a much larger bitmap in memory, so decoders should budget against pixel dimensions rather than file bytes alone.
- 2Row stride can include alignment padding beyond visible pixels, and rows may be stored top-down or bottom-up; copying width times bytes-per-pixel can corrupt such buffers.
- 3Raster enlargement must synthesize new pixels and cannot recover missing detail, unlike vector rendering, which evaluates geometric primitives at the requested output size.
When Bitmaps matter
Applications decode images into bitmaps for canvas drawing, filtering, pixel analysis, or raster export. Memory use grows with dimensions and bit depth even when the encoded source file is highly compressed.
Common use cases for image
These examples cover image broadly, not specifically Bitmaps.
- Generating responsive website images, thumbnails, avatars, social cards, and product imagery.
- Standardizing user uploads to safe dimensions, formats, and metadata policies.
- Applying crops, overlays, watermarks, background operations, or visual analysis at scale.
Working with image
This guidance covers image broadly, not just Bitmaps.
Image software decodes the source into pixels, applies spatial or color operations, and encodes the result. Resize filters, crop coordinates, operation order, and output settings determine both appearance and file size.
Image operations interact with resolution, aspect ratio, alpha, color profiles, orientation, and compression. Test the complete sequence because changing the order of resize, crop, sharpen, and encode operations can change the result.
What you gain
- One source can produce consistent variants for different layouts and devices.
- Automated optimization reduces bytes without requiring editors to prepare every derivative.
- Explicit transformation rules make crops, dimensions, and formats reproducible.
What it costs
- Smaller dimensions and stronger compression reduce transfer size but can remove useful detail.
- Automatic crops scale well but can cut off important subjects when detection or focal information is wrong.
- Wide-gamut, HDR, and transparent assets need an end-to-end path that preserves those properties.
Before production
- 1Test representative dimensions, transparency, color profiles, orientation, and animated inputs.
- 2Compare visual quality at the actual display size, not only at 100% zoom.
- 3Set explicit crop, fit, and upscaling rules so edge cases remain predictable.