|While the term "palette" can refer to a set of colors in the art world, there is a more specific use of the word in digital art. In this case, a palette is an ordered set of colors used by a piece of raster graphic data. Most sprites and other pixel-based game graphics are actually maps (bitmaps and pixmaps) and each pixel has a palette index color assigned to it. Example: if the pixel at column 4, row 2 (X:4, Y:2) is color 3, the system will draw it using the color in the third palette slot. One of these color slots, usually color 0, can be the "transparent color" that isn't drawn on the screen.|
For most 2-D games, the palettes also have an extra color for the transparent areas that aren't drawn onto the screen. With most fan-made sprites or sprite edits, that transparency color is something odd that would never appear in the sprite like a neon pink or neon green. The number of colors in a sprite is determined by the power of a system. While the classic Commodore 64 has sprites with 4 colors, most Super NES and CPS-2 games feature 16 color palettes. In some games, sprites with different colors are layered on top of each other or near each other to cheat that color limit. Wolverine's claws in Capcom's X-Men: Children of the Atom are an example of layering.
Remember that, in most cases, the program is drawing by the palette index number and not just the color. Two palette indices can have the same colors in them, but the system will still treat them differently even if it copies the "transparent" color.
The program or game can assign alternate palettes that replace the colors in the image's original palette color slots and this ability is used for a variety of tricks. Sprites sets can be recolored (or palette-swapped) to create new variations and even backgrounds can be recolored to depict different time and weather changes. The palette of an object can be changed as the game is playing (color cycling) to imitate glowing effects, moving water and lighting changes.
|Related Terms: palette swap|
Return to top of the top of the page