If I want to make a 3D game, and I want all my textures to be 8 bit, to save RAM, that is 256 indexed colors, including "transparent", how do I choose the colors?

Is there any recommended pre-defined palette? (Link?)

The end-rendering would use full colors, based on lighting, ...

  • 2
    \$\begingroup\$ There can't be a "best" palette for a game, as it depends entirely on the game and the style/mood you want to create. A dark/muddy palette won't suit a mario-type game (with bright and vivid colors) etc. So your question is unanswerable. \$\endgroup\$ – bummzack Dec 13 '11 at 11:32
  • 1
    \$\begingroup\$ I read his question so that he wants to use 8bit textures to save RAM, but will use true color for rendering, and he wants to know how to pick the palette for the 8bit textures. \$\endgroup\$ – Jari Komppa Dec 13 '11 at 17:28
  • \$\begingroup\$ @bummzack I asked (in the title) for how to find it. I did NOT imply that there was one universally best 8 bit palette. There might be many good "examples", and asking for some just would help me find the best one for me faster. \$\endgroup\$ – Sebastien Diot Dec 14 '11 at 19:10
  • \$\begingroup\$ @Jari Komppa You are totally right. +1 \$\endgroup\$ – Sebastien Diot Dec 14 '11 at 19:10

If I interpret your question correctly, you want to know which 256 colors to pick to a palette to make things look good.

This is called the black magic art of color reduction. There's plenty of ways to perform it, some work better than others, and all of them are wrong, as what you're doing is removing information.

One common way is to place all desired colors into an octree and then reading out the 256 biggest cells; another is to do median-cut of the color space until you have 256 segments.

Easiest solution would probably be to drop all the desired colors into photoshop (or something similar), and convert to 8-bit paletted picture. Photoshop, at least, contains variety of methods to do the conversion.

  • \$\begingroup\$ As others have pointed out, it's probably a bad idea, but since you actually told me how to solve my problem, I will select your answer. \$\endgroup\$ – Sebastien Diot Dec 14 '11 at 19:22

This is more useful for website design but the theory of how colours work together should be applicable anywhere:


If you’re set on 8-bit colour, just remember that you won’t have enough to do lots of intricate shading; your models can end up looking quite flat or cartoony (but that may be the look you’re going for). Wikipedia has a list of some of the palettes other people have used:


  • \$\begingroup\$ The Wikipedia article doesn't seem that relevant, it's about 8 bit systems, but most of those systems use only 4 bit colours. \$\endgroup\$ – aaaaaaaaaaaa Dec 13 '11 at 18:18
  • \$\begingroup\$ I don't aim for realistic, so cartoony is OK. But I am rendering in full colors, so I will get descent shading. It's only the texture that are 8 bit, not the rendered game itself. \$\endgroup\$ – Sebastien Diot Dec 14 '11 at 19:14

A few points:
Modern video cards and drivers has a texture compression feature that pretty much defeat the purpose of this question. You get good looking textures at low memory and memory bandwidth consumption. You can't compress paletted images in the same fashion.

It is correct that you are not even close to having made a game yet? Then why are you asking such a tech question? Stop stalling on possible future issues and get to work.

A kind of answer:
As for making a global 8 bit palette, I think you'd get the best results from something like a table with all the possible combinations of colours with 4 different blue values, 7 red values and 9 green values.

In modern computing colour palettes are used mostly for storing images, png images will often grow a lot smaller when converted to 8 bit, and for a lot of their typical use cases the difference is unnoticeable. But this is almost always done with a pallette generated specifically for that image as that can provide way better results than a standard palette.

  • \$\begingroup\$ I agree. DXT1 being equivalent to 4 bits per pixel will halve the size of the textures compared to palletized ones as well as almost certainly looking better. \$\endgroup\$ – Adam Dec 13 '11 at 20:37
  • \$\begingroup\$ "Stop stalling on possible future issues and get to work." Unfortunately, you are right on that one. Also, good tip about why the question is probably not meaningful. +1 \$\endgroup\$ – Sebastien Diot Dec 14 '11 at 19:20

I would say it depend on what kind of feeling you would like to achieve. If you would like to have some creepy game you will have differente palette (gray/dark colors), then for game some casual "happy" game.

I think the link Sullivan provided is good, if you need Gameboy like palette.

I can't give you exact colors, nobody can. BUT if you are looking for an inspiration I would recommend http://kuler.adobe.com/

Be aware, colors presented at kuler.adobe.com are usually for web designers. But they might give you some idea.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.