The BMP file format

BMP is a meanwhile outdated image file format for computers running the Windows operating system. The format was developed by Microsoft for storing bitmap files in a device-independent bitmap (DIB) format that would allow Windows to display the bitmap on any type of display device. The term ‘device-independent’ means that the bitmap specifies pixel color in a form independent of the method used by a display to represent color.

General information

Since BMP is a fairly simple file format, its structure is pretty straightforward. Each bitmap file contains:

  • a bitmap-file header: this contains information about the type, size, and layout of a device-independent bitmap file.
  • a bitmap-information header that specifies the dimensions, compression type, and color format for the bitmap.
  • a color table, defined as an array of RGBQUAD structures, contains as many elements as there are colors in the bitmap. The color table is not present for bitmaps with 24 color bits because each pixel is represented by 24-bit red-green-blue (RGB) values in the actual bitmap data area.
  • an array of bytes that defines the bitmap bits. These are the actual image data, represented by consecutive rows or ‘scan lines’ of the bitmap. Each scan line consists of consecutive bytes representing the pixels in the scan line, in left-to-right order.

BMP files always contain RGB data. The file can be:

  • 1-bit: 2 colors (monochrome)
  • 4-bit: 16 colors
  • 8-bit: 256 colors.
  • 24-bit: 16777216 colors, mixes 256 tints of Red with 256 tints of Green and Blue

Windows versions 3.0 and later support run-length encoded (RLE) formats for compressing bitmaps that use 4 bits per pixel and 8 bits per pixel.

The default filename extension of a Windows DIB file is .BMP.

Use in a prepress environment

Everything that can be done with BMP, can also be done with TIFF files (or EPS or PNG). Because TIFF is an established and more versatile file format for prepress applications, it is better to avoid BMP-files for prepress production. BMP is also limited to RGB-images only while CMYK data are often preferred in prepress.

Specsheet

Name: BMP
Developer: Microsoft
Release date: 1986?
Type of data: bitmap
Number of colours:
2,16,256, 16777216
Color spaces: RGB
Compression algorithms: RLE
Ideal use: background of your display 😉
Extension on PC-platform: .BMP
Macintosh file type: ?
Special features:
Remarks:

5 thoughts on “The BMP file format

  1. having trouble printing a .bmp file attachment. all i get is a 4 pointed arrow and unable to point with one arrow to print. any help would be appreciated.
    thank you

Leave a Reply

Your email address will not be published. Required fields are marked *