Difference between revisions of "Palette"
From Sega Retro
Scarred Sun (talk | contribs) m (According to the Oxford English Dictionary, "palette" didn't appear until the 19th century. "Pallet" is the original, correct spelling.) |
Scarred Sun (talk | contribs) (added your note to the bottom - very interesting, I didn't even know it) |
||
Line 23: | Line 23: | ||
*11 = 255 | *11 = 255 | ||
As such, the highest palette value is '''00111111''', which is '''3F''' when converted to a byte. | As such, the highest palette value is '''00111111''', which is '''3F''' when converted to a byte. | ||
+ | |||
+ | According to the Oxford English Dictionary, "palette" didn't appear until the 19th century. "Pallet" is the original, correct spelling. However, both are correct today, and "palette" is more commonly used. |
Revision as of 18:15, 29 September 2004
A selection of colours which is used in an image. Rather than defining a colour for each individual pixel (such as in 24-bit colour images), palettes are used to link pixels to colour data by way of an index reference. Graphics in Megadrive, Master System, Game Gear and GameBoy Advance games all use palettes.
Megadrive Palette
Consists of 16 colours, each represented by two bytes (four nybbles) in the format 0B GR, where B = blue; G = green; and R = red. The B, G and R can be any of the following values:
- 0 = 0
- 2 = 32
- 4 = 64
- 6 = 96
- 8 = 128
- A = 160
- C = 192
- E = 224
- (and in rare cases, F = 224)
Pixels reference these 16 colours using a single nybble. 0 refers to the 1st palettte entry (which is normally transparent), 1 refers to the second entry, and so on.
Master System Palette
Consists of 16 colours, each represented by eight bits (a single byte) in the format 00BBGGRR, where BB = blue; GG = green; and RR = red. The BB, GG and RR can be any of the following values:
- 00 = 0
- 01 = 85
- 10 = 170
- 11 = 255
As such, the highest palette value is 00111111, which is 3F when converted to a byte.
According to the Oxford English Dictionary, "palette" didn't appear until the 19th century. "Pallet" is the original, correct spelling. However, both are correct today, and "palette" is more commonly used.