Advertisement

8-bit Colour in OpenGL – Is it Possible?

Started by February 14, 2001 06:34 PM
0 comments, last by Pho 23 years, 9 months ago
Is it possible to use 8-bit colour mode in OpenGL under Windows system? I am referring to the PFD_TYPE_RGBA format in the PIXELFORMATDESCRIPTOR structure. I ask this because I am experimenting with different colour modes under simple OpenGL “coloured triangle” application (each of the 3 vertices has a different colour). Everything works fine in 16 and 32 bit modes, however, when I switch to 8-bit desktop and use desktop colour as a colour depth, this coloured triangle becomes... Something undefined. I’ve changed coloured triangle to a completely white triangle and then it is displayed correctly. Therefore, the problem is in colours. Perhaps this is an issue with my specific system ( C333, RivaTNT, Windows95 ), so I am asking all of you fellows: Has anyone of you managed to utilise 8 bit RGBA (not Colour Index) colour mode in your OpenGL applications? I would be really grateful if some of you would try to give me some feedback. Just take your everyday OpenGL app, and then initialise PIXELFORMATDESCRIPTOR to PFD_TYPE_RGBA and 8 bit as Colour Depth. And that’s it. Please note that you may need to switch your Desktop to 256-colour mode prior to experimenting with your OpenGL apps. It appears that if the system is in 16 / 32-bit mode, OpenGL will always use that setting for colour depth, no matter what value is used for colour depth in the PIXELFORMATDESCRIPTOR structure. Thanks for replying Pho
>>Is it possible to use 8-bit colour mode in OpenGL under Windows system?<<

only with a palette and theres prolly no hardware support for your card (theres defintly none for the tnt so its gonna run in software)

http://members.xoom.com/myBollux

This topic is closed to new replies.

Advertisement