Framebuffer: Difference between revisions

Content deleted Content added
GreenC bot (talk | contribs)
Rescued 1 archive link. Wayback Medic 2.5 per WP:URLREQ#ieee.org
m Color palette: copy edit
Line 35:
 
== Color palette ==
Framebuffers have traditionally supported a wide variety of color modes. Due to the expense of memory, most early framebuffers used 1-bit (2 colors per pixel), 2-bit (4 colors), 4-bit (16 colors) or 8-bit (256 colors) color depths. The problem with such small color depths is that a full range of colors cannot be produced. The solution to this problem was [[indexed color]], which adds a [[lookup table]] to the framebuffer. Each color stored in framebuffer memory acts as a color index. The lookup table serves as a palette with a limited number of different colors meanwhile the rest is used as an index table.
 
Here is a typical indexed 256-color image and its own palette (shown as a
Line 47:
|}
 
In some designs it was also possible to write data to the lookup table (or switch between existing palettes) on the runfly, allowing dividing the picture into horizontal bars with their own palette and thus render an image that had a far wider palette. For example, viewing an outdoor shot photograph, the picture could be divided into four bars, the top one with emphasis on sky tones, the next with foliage tones, the next with skin and clothing tones, and the bottom one with ground colors. This required each palette to have overlapping colors, but carefully done, allowed great flexibility.
 
== Memory access ==