Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
Planar (computer graphics)
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Examples == On a [[Packed pixel|chunky]] display with 4-[[bits-per-pixel]] and a [[List of monochrome and RGB color formats#4-bit RGBI|RGBI]] palette, each byte represents two pixels, with 16 different colors available for each pixel. Four consecutive pixels are stored in two consecutive bytes as follows: {|class="wikitable" ! Byte index || colspan=2 | 0 || colspan=2| 1 |- | Byte value (decimal) || colspan=2 | 1 || colspan=2 | 35 |- | Byte value (hexadecimal) || colspan=2 | 0x01 || colspan=2 | 0x23 |- | Nibble value (binary) || 0000 || 0001 || 0010 || 0011 |- | Nibble value (decimal) || 0 || 1 || 2 || 3 |- | Resulting pixel |style="background-color: #000000; color: white;"| Black |style="background-color: #0000AA; color: white;"| Blue |style="background-color: #00AA00; color: white;"| Green |style="background-color: #00AAAA; color: white;"| Cyan |} Whereas a planar scheme could use 2 bitplanes, providing for a 4 color display. Eight pixels would be stored as 2 bytes non-contiguously in memory: {|class="wikitable" ! Byte index ||colspan=8| 0 ||colspan=2| Byte value |- ! Bit index || 0 || 1 || 2 || 3 || 4 || 5 || 6 || 7 || hexadecimal || decimal |- | Plane 0 || 0 || 1 || 0 || 1 || 0 || 0 || 0 || 0 || style="text-align: center;" | 0x50 || style="text-align: center;" | 80 |- | Plane 1 || 0 || 0 || 1 || 1 || 0 || 0 || 0 || 0 || style="text-align: center;" | 0x30 || style="text-align: center;" | 48 |- | Resulting pixel |style="background-color: #000000; color: white;"| 0 |style="background-color: #0000AA; color: white;"| 1 |style="background-color: #00AA00; color: white;"| 2 |style="background-color: #00AAAA; color: white;"| 3 |style="background-color: #000000; color: white;"| 0 |style="background-color: #000000; color: white;"| 0 |style="background-color: #000000; color: white;"| 0 |style="background-color: #000000; color: white;"| 0 |} In the planar example, 2 bytes represent 8 pixels with 4 available colors, where the packed pixel example uses 2 bytes to represent fewer pixels but with more colors. Adding planes will increase the number of colors available at the cost of requiring more memory. For example, using 4 planes makes 2<sup>4</sup>=16 colors available, but it would then take 4 bytes to represent 8 pixels (making it equivalent in terms of memory usage and available colors to the packed arrangement example).
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
Planar (computer graphics)
(section)
Add topic