I just know it’s related with something like palette.But I don’t know how to define and implement it.
I’m a newbie in opengl and my correlative knowledge is not rich,so if you would give your reply,please write down it in details.
All advices are welcome.
Thank you very much!
[This message has been edited by Keddy (edited 05-24-2002).]
This certainly isn’t the quickest method, but I’m using it at present (NOTE: I’m using a texture library manager here, but essentially what I’m doing is creating RGB triples by using the DIB pixel value to look up R, G and B in the DIB palette. The final result is basically an array of RGB values that is then bound as a texture. I’m also using my own `CDib’ class here - you should be able to get the idea though
//
// Re-generate a texture from the given dib - only works on 8 or 24 bit source DIB and 32 bit destination texture.
//