Planar (computer graphics)

From Wikipedia, the free encyclopedia

In computer graphics, planar is the method of representing pixel colours with several bitplanes of RAM. Each bit in a bitplane is related to one pixel on the screen. Unlike Chunky, Highcolour or Truecolour graphics, the whole data for an individual pixel isn't in one specific location in RAM, but spread across the bitplanes that make up the display.

For example, on a chunky display, each byte represents one pixel. Three pixels in a row would be stored as follows, where up to 256 different colours are available:

Byte 0: 00000000 = Black pixel
Byte 1: 00000001 = Blue pixel
Byte 2: 00000010 = Green pixel

Whereas a planar data store could use 2 bitplanes, providing for a 4 colour display:

A row of 8 black pixels:
Plane 0, Byte 0: 00000000
Plane 1, Byte 0: 00000000

A row of 1 blue pixel, 2 black pixels, 1 green pixel, 4 black pixels:
Plane 0, Byte 0: 10000000
Plane 1, Byte 0: 00010000

Adding a third plane would make 23=8 colours available. Where fewer than 256 colours are needed, planar graphics are economical in RAM compared with chunky graphics. Example: to display 8 colours using 3 bitplanes, so each pixel has 3 bits assigned to it instead of 8, reduces memory and bandwidth requirements by 62.5%. This saving was most significant in the 80s and early 90s when fast RAM was expensive and most computer graphics displayed fewer than 256 colours.

A disadvantage of planar graphics is that more RAM address cycles are needed for scrolling and animations, although these operations can be made faster by dedicated hardware.

Languages