HOME

TheInfoList



OR:

In
computing Computing is any goal-oriented activity requiring, benefiting from, or creating computer, computing machinery. It includes the study and experimentation of algorithmic processes, and the development of both computer hardware, hardware and softw ...
, a bitmap (also called raster) graphic is an image formed from rows of different colored
pixel In digital imaging, a pixel (abbreviated px), pel, or picture element is the smallest addressable element in a Raster graphics, raster image, or the smallest addressable element in a dot matrix display device. In most digital display devices, p ...
s. A
GIF The Graphics Interchange Format (GIF; or , ) is a Raster graphics, bitmap Image file formats, image format that was developed by a team at the online services provider CompuServe led by American computer scientist Steve Wilhite and released ...
is an example of a graphics image file that uses a bitmap. As a noun, the term "bitmap" is very often used to refer to a particular bitmapping application: the pix-map, which refers to a map of
pixel In digital imaging, a pixel (abbreviated px), pel, or picture element is the smallest addressable element in a Raster graphics, raster image, or the smallest addressable element in a dot matrix display device. In most digital display devices, p ...
s, where each pixel may store more than two colors, thus using more than one bit per pixel. In such a case, the domain in question is the array of pixels which constitute a digital graphic output device (a screen or monitor). In some contexts, the term ''bitmap'' implies one bit per pixel, whereas ''pixmap'' is used for images with multiple bits per pixel. A bitmap is a type of
memory Memory is the faculty of the mind by which data or information is encoded, stored, and retrieved when needed. It is the retention of information over time for the purpose of influencing future action. If past events could not be remembe ...
organization or
image file format An image file format is a file format for a digital image. There are many formats that can be used, such as JPEG, PNG, and GIF. Most formats up until 2022 were for storing 2D images, not 3D ones. The data stored in an image file format may be co ...
used to store
digital image A digital image is an image composed of picture elements, also known as pixels, each with '' finite'', '' discrete quantities'' of numeric representation for its intensity or gray level that is an output from its two-dimensional functions f ...
s. The term ''bitmap'' comes from the
computer programming Computer programming or coding is the composition of sequences of instructions, called computer program, programs, that computers can follow to perform tasks. It involves designing and implementing algorithms, step-by-step specifications of proc ...
terminology, meaning just a ''map of bits'', a spatially mapped array of bits. Now, along with ''pixmap'', it commonly refers to the similar concept of a spatially mapped array of pixels. Raster images in general may be referred to as bitmaps or pixmaps, whether synthetic or photographic, in files or memory. Many
graphical user interface A graphical user interface, or GUI, is a form of user interface that allows user (computing), users to human–computer interaction, interact with electronic devices through Graphics, graphical icon (computing), icons and visual indicators such ...
s use bitmaps in their built-in graphics subsystems. For example, the
Microsoft Windows Windows is a Product lining, product line of Proprietary software, proprietary graphical user interface, graphical operating systems developed and marketed by Microsoft. It is grouped into families and subfamilies that cater to particular sec ...
and
OS/2 OS/2 is a Proprietary software, proprietary computer operating system for x86 and PowerPC based personal computers. It was created and initially developed jointly by IBM and Microsoft, under the leadership of IBM software designer Ed Iacobucci, ...
platforms'
GDI GDI may refer to: Science and technology * Gasoline direct injection, a type of fuel injection * Graphics Device Interface, a component of Microsoft Windows * Guanosine nucleotide dissociation inhibitor, a protein Organisations * Gabriel Dumont I ...
subsystem uses the ''Windows and OS/2 bitmap file format'', usually named with the
file extension File or filing may refer to: Mechanical tools and processes * File (tool), a tool used to remove fine amounts of material from a workpiece. ** Filing (metalworking), a material removal process in manufacturing ** Nail file, a tool used to gen ...
.BMP (or .DIB for ''device-independent bitmap''). Besides BMP, other file formats that store literal bitmaps include InterLeaved Bitmap (ILBM), Portable Bitmap (PBM), X Bitmap (XBM), and Wireless Application Protocol Bitmap (WBMP). Similarly, most other image file formats, such as
JPEG JPEG ( , short for Joint Photographic Experts Group and sometimes retroactively referred to as JPEG 1) is a commonly used method of lossy compression for digital images, particularly for those images produced by digital photography. The degr ...
, TIFF, PNG, and GIF, also store bitmap images (as opposed to
vector graphics Vector graphics are a form of computer graphics in which visual images are created directly from geometric shapes defined on a Cartesian plane, such as points, lines, curves and polygons. The associated mechanisms may include vector displ ...
), but they are not usually referred to as ''bitmaps'', since they use compressed formats internally.


Pixel storage

In typical uncompressed bitmaps, image
pixel In digital imaging, a pixel (abbreviated px), pel, or picture element is the smallest addressable element in a Raster graphics, raster image, or the smallest addressable element in a dot matrix display device. In most digital display devices, p ...
s are generally stored with a variable number of bits per pixel which identify its color (the
color depth Color depth, also known as bit depth, is either the number of bits used to indicate the color of a single pixel, or the number of bits used for each color component of a single pixel. When referring to a pixel, the concept can be defined as bit ...
). Pixels of 8 bits and fewer can represent either
grayscale In digital photography, computer-generated imagery, and colorimetry, a greyscale (more common in Commonwealth English) or grayscale (more common in American English) image is one in which the value of each pixel is a single sample (signal), s ...
or
indexed color In computing, indexed color is a technique to manage digital images' colors in a limited fashion, in order to save computer computer data storage, memory and Hard disk drive, file storage, while speeding up display refresh and file transfers. It ...
. An
alpha channel In computer graphics, alpha compositing or alpha blending is the process of combining one image with a background to create the appearance of partial or full transparency. It is often useful to render picture elements (pixels) in separate pass ...
(for transparency) may be stored in a separate bitmap, where it is similar to a grayscale bitmap, or in a fourth channel that, for example, converts 24-bit images to 32 bits per pixel. The bits representing the bitmap pixels may be packed or unpacked (spaced out to byte or word boundaries), depending on the format or device requirements. Depending on the color depth, a pixel in the picture will occupy at least ''n''/8 bytes, where is the bit depth. For an uncompressed, packed-within-rows bitmap, such as is stored in Microsoft DIB or
BMP file format The BMP file format, or bitmap, is a raster graphics image file format used to store bitmap digital images, independently of the display device (such as a graphics adapter), especially on Microsoft Windows and OS/2 operating systems. The BMP f ...
, or in uncompressed TIFF format, a lower bound on storage size for a ''n''-bit-per-pixel (2n colors) bitmap, in
byte The byte is a unit of digital information that most commonly consists of eight bits. Historically, the byte was the number of bits used to encode a single character of text in a computer and for this reason it is the smallest addressable un ...
s, can be calculated as: :\text = \text \cdot \text \cdot n/8 where width and height are given in pixels. In the formula above, header size and
color palette In color theory, a color scheme is a combination of 2 or more colors used in aesthetic or practical design. Aesthetic color schemes are used to create style and appeal. Colors that create a color harmony, harmonious feeling when viewed togethe ...
size, if any, are not included. Due to effects of row padding to align each row start to a storage unit boundary, such as a
word A word is a basic element of language that carries semantics, meaning, can be used on its own, and is uninterruptible. Despite the fact that language speakers often have an intuitive grasp of what a word is, there is no consensus among linguist ...
, additional bytes may be needed.


Device-independent bitmaps and BMP file format

Microsoft Microsoft Corporation is an American multinational corporation and technology company, technology conglomerate headquartered in Redmond, Washington. Founded in 1975, the company became influential in the History of personal computers#The ear ...
has defined a particular representation of color bitmaps of different
color depth Color depth, also known as bit depth, is either the number of bits used to indicate the color of a single pixel, or the number of bits used for each color component of a single pixel. When referring to a pixel, the concept can be defined as bit ...
s, as an aid to exchanging bitmaps between devices and applications with a variety of internal representations. They called these device-independent bitmaps "DIBs", and the file format for them is called DIB file format or
BMP file format The BMP file format, or bitmap, is a raster graphics image file format used to store bitmap digital images, independently of the display device (such as a graphics adapter), especially on Microsoft Windows and OS/2 operating systems. The BMP f ...
. According to Microsoft support:
A device-independent bitmap (DIB) is a format used to define device-independent bitmaps in various color resolutions. The main purpose of DIBs is to allow bitmaps to be moved from one device to another (hence, the device-independent part of the name). A DIB is an external format, in contrast to a device-dependent bitmap, which appears in the system as a bitmap object (created by an application...). A DIB is normally transported in metafiles (usually using the StretchDIBits() function), BMP files, and the Clipboard (CF_DIB data format).
Here, "device independent" refers to the format, or storage arrangement, and should not be confused with device-independent color.


Other bitmap file formats

The
X Window System The X Window System (X11, or simply X) is a windowing system for bitmap displays, common on Unix-like operating systems. X originated as part of Project Athena at Massachusetts Institute of Technology (MIT) in 1984. The X protocol has been at ...
uses a similar XBM format for
black-and-white Black-and-white (B&W or B/W) images combine black and white to produce a range of achromatic brightnesses of grey. It is also known as greyscale in technical settings. Media The history of various visual media began with black and white, ...
images, and XPM (''pixelmap'') for color images. Numerous other uncompressed bitmap file formats are in use, though most not widely. For most purposes, standardized compressed bitmap files such as
GIF The Graphics Interchange Format (GIF; or , ) is a Raster graphics, bitmap Image file formats, image format that was developed by a team at the online services provider CompuServe led by American computer scientist Steve Wilhite and released ...
, PNG, TIFF, and
JPEG JPEG ( , short for Joint Photographic Experts Group and sometimes retroactively referred to as JPEG 1) is a commonly used method of lossy compression for digital images, particularly for those images produced by digital photography. The degr ...
are used.
Lossless compression Lossless compression is a class of data compression that allows the original data to be perfectly reconstructed from the compressed data with no loss of information. Lossless compression is possible because most real-world data exhibits statisti ...
in particular provides the same information as a bitmap in a smaller file size. TIFF and JPEG have various options. JPEG is usually
lossy compression In information technology, lossy compression or irreversible compression is the class of data compression methods that uses inexact approximations and partial data discarding to represent the content. These techniques are used to reduce data size ...
. TIFF is usually either uncompressed, or lossless
Lempel–Ziv–Welch Lempel–Ziv–Welch (LZW) is a universal lossless data compression algorithm created by Abraham Lempel, Jacob Ziv, and Terry Welch. It was published by Welch in 1984 as an improved implementation of the LZ78 algorithm published by Lem ...
compressed like
GIF The Graphics Interchange Format (GIF; or , ) is a Raster graphics, bitmap Image file formats, image format that was developed by a team at the online services provider CompuServe led by American computer scientist Steve Wilhite and released ...
. PNG uses deflate lossless compression, another Lempel-Ziv variant. There are also a variety of "raw" image files, which store raw bitmaps with no other information. Such raw files are just bitmaps in files, often with no header or size information (they are distinct from photographic
raw image format A camera raw image file contains unprocessed or minimally processed data from the image sensor of either a digital camera, a motion picture film scanner, or other image scanner. Raw files are so named because they are not yet processed, ...
s, which store raw unprocessed sensor data in a structured container such as TIFF format along with extensive image
metadata Metadata (or metainformation) is "data that provides information about other data", but not the content of the data itself, such as the text of a message or the image itself. There are many distinct types of metadata, including: * Descriptive ...
).


See also

*
Free space bitmap Free-space bitmaps are one method used to track allocated sectors by some file systems. While the most simplistic design is highly inefficient, advanced or hybrid implementations of free-space bitmaps are used by some modern file systems. Examp ...
, an array of bits that tracks which disk storage blocks are in-use *
Raster graphics upright=1, The Smiley, smiley face in the top left corner is a raster image. When enlarged, individual pixels appear as squares. Enlarging further, each pixel can be analyzed, with their colors constructed through combination of the values for ...
*
Raster scan A raster scan, or raster scanning, is the rectangular pattern of image capture and reconstruction in television. By analogy, the term is used for raster graphics, the pattern of image storage and transmission used in most computer bitmap image s ...
* Rasterization *
Sprite (computer graphics) In computer graphics, a sprite is a Plane (mathematics), two-dimensional bitmap that is integrated into a larger scene, most often in a 2D video game. Originally, the term ''sprite'' referred to fixed-sized objects composited together, by hardw ...
* Voxels *
Vector graphics Vector graphics are a form of computer graphics in which visual images are created directly from geometric shapes defined on a Cartesian plane, such as points, lines, curves and polygons. The associated mechanisms may include vector displ ...
*
Image tracing In computer graphics, image tracing, raster-to-vector conversion or raster vectorization is the conversion of raster graphics into vector graphics. Background An image does not have any structure: it is just a collection of marks on paper, grai ...


References

{{Authority control
Map A map is a symbolic depiction of interrelationships, commonly spatial, between things within a space. A map may be annotated with text and graphics. Like any graphic, a map may be fixed to paper or other durable media, or may be displayed on ...
Graphics file formats ca:Mapa de bits es:Gráfico rasterizado fr:Bitmap it:Bitmap