8-bit textures ?
Hi, can anybody tell me how to change the tutorial-code so I can use 8-bit textures, instead of 24-bit ?
That would save a lot of memory, right ?
Thanks a lot !
Wiek
substitute RG_R3_G3_B2 for the first GL_RGB in glTexImage2D(..)
http://members.xoom.com/myBollux
so, will this save memory? or does it convert the 8bit into true color?
------------------General Equation, this is Private Function reporting for duty, sir!a2k
Well theres a few ways to do this.
1. Specify an 8bit internal format when passing the texture with glTexImage2D. If the driver supports the format it should only use 8 bits to store the texture on your card. However the OGL specs. say that this isn''t mandatory. So so driver dependant time again!
2. Use a paletted texture. Make sure your card supports EXT_color_table and use 8 bit textures directly.
My .tga loading code does paletted textures.
Paul.
Paul Groves
pauls opengl page
1. Specify an 8bit internal format when passing the texture with glTexImage2D. If the driver supports the format it should only use 8 bits to store the texture on your card. However the OGL specs. say that this isn''t mandatory. So so driver dependant time again!
2. Use a paletted texture. Make sure your card supports EXT_color_table and use 8 bit textures directly.
My .tga loading code does paletted textures.
Paul.
Paul Groves
pauls opengl page
Paul Grovespauls opengl page
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement