language-icon Old Web
English
Sign In

Bit blit

Bit blit (also written BITBLT, BIT BLT, BitBLT, Bit BLT, Bit Blt etc., which stands for bit block transfer) is a data operation commonly used in computer graphics in which several bitmaps are combined into one using a boolean function. Bit blit (also written BITBLT, BIT BLT, BitBLT, Bit BLT, Bit Blt etc., which stands for bit block transfer) is a data operation commonly used in computer graphics in which several bitmaps are combined into one using a boolean function. The operation involves at least two bitmaps, one source and destination, possibly a third that is often called the 'mask' and sometimes a fourth used to create a stencil. The pixels of each are combined bitwise according to the specified raster operation (ROP) and the result is then written to the destination. The ROP is essentially a boolean formula. The most obvious ROP overwrites the destination with the source. Other ROPs may involve AND, OR, XOR, and NOT operations. The Commodore Amiga's graphics chipset (and others) could combine three source bitmaps using any of the 256 possible boolean functions with three inputs. Modern graphics software has almost completely replaced bitwise operations with more general mathematical operations used for effects such as alpha compositing. This is because bitwise operations on color displays do not usually produce results that resemble the physical combination of lights or inks. Some software still uses XOR to draw interactive highlight rectangles or region borders; when this is done to color images, the unusual resulting colors are easily seen. The name derives from the BitBLT routine for the Xerox Alto computer, standing for bit-boundary block transfer. Dan Ingalls, Larry Tesler, Bob Sproull, and Diana Merry programmed this operation at Xerox PARC in November 1975 for the Smalltalk-72 system. Dan Ingalls later implemented a redesigned version in microcode. The development of fast methods for various bit blit operations gave impetus to the evolution of computer displays from using character graphics to using bitmap graphics for everything. Machines that rely heavily on the performance of 2D graphics (such as video game consoles) often have special-purpose circuitry called a blitter. A classic use for blitting is to render transparent sprites onto a background. In this example a background image, a sprite, and a 1-bit mask are used. As the mask is 1-bit, there is no possibility for partial transparency via alpha blending. A loop that examines each bit in the mask and copies the pixel from the sprite only if the mask is set will be much slower than hardware that can apply exactly the same operation to every pixel. Instead a masked blit can be implemented with two regular BitBlit operations using the AND and OR raster operations.

[ "Bitmap", "Graphics", "block transfer", "Image (mathematics)" ]
Parent Topic
Child Topic
    No Parent Topic