What Is an OpenGL® Bitmap?

Article Details
  • Written By: Eugene P.
  • Edited By: Angela B.
  • Last Modified Date: 20 October 2019
  • Copyright Protected:
    Conjecture Corporation
  • Print this Article
Free Widgets for your Site/Blog
Octopuses and other cephalopods sometimes change color while sleeping; this could indicate that they are dreaming.  more...

November 21 ,  1969 :  The first Advanced Research Projects Agency Network (ARPNET) link was permanently established for the first time.  more...

An OpenGL® bitmap can be one of two things, depending on the context in which the term is used. The original meaning of a bitmap is an image in which each pixel location is stored in a bit, giving it a value of transparent or solid. After the introduction of certain image file formats, the term "bitmap" also came to mean full-color images stored in a certain format and, eventually, digital images in general. At the source-code level, an OpenGL® bitmap takes the original meaning, and the simplified image is most often used to create a transparency mask, display text or icons, or to act as a texture or simple overlay. When the term is used to refer to any digital image, then these are most often used as two-dimensional (2D) textures to be mapped onto polygons.

A true, two-color OpenGL® bitmap takes up very little storage space on a disk and also can occupy very little memory while a program is running, depending on the implementation. The bitmap is comprised of just true and false values, so it can be used to make very precise characters, although no intrinsic color information can be included in the file. This precision and simplicity has made the bitmap one of the most widely used methods for creating, storing and representing symbols, icons and nearly any graphical detail that only requires information on whether a single pixel is used or not.


A common use for an OpenGL® bitmap is to display text within a scene. This is because there are a wide variety of bitmap fonts available. In the simplest implementation, a quadrilateral is formed inside the scene and the bitmap font characters are composited onto the shape to form words and sentences. The areas of the bitmap image that are false are transparent, meaning the background will show through. An additional benefit is that the text will rotate with the scene, if desired, or can be constantly translated to face the camera, providing a kind of heads-up, persistent display.

Another use for an OpenGL® bitmap is to create a transparency mask. This is the same concept as a font, except the bitmap is used to make areas of a three-dimensional (3D) shape transparent, effectively granting the ability to carve shapes from primitive types that could be difficult or impossible to do with a 3D model. This technique is sometimes used to represent trees in a scene, where the detail of the branches and leaves could otherwise be difficult. A normal, full-color texture is usually mapped on top of the transparency mask to complete the illusion.


You might also Like


Discuss this Article

Post your comments

Post Anonymously


forgot password?