Hi,

I try to load a 8bits image and create an osg::Texture2D with it. I search all 
the day but without sucess. 

It seems that the image load by osgDB::readImageFile(...) is transform in a 32 
bits image. Is it possible to load it as 8bits image with an associated look up 
table ? (I didn't find attribut in osg::Image that could correspond to a lut, 
is there one ?)

However if I can load my image as a 8 bits image, I don't know how I can 
associate the color table to the texture, is there a way to do that ?

In fact and to clarify what I mean, here is the code in OpenGL I would like to 
translate in OpenSceneGraph :

glColorTableEXT(GL_TEXTURE_2D, GL_RGBA8, 256, GL_RGBA, GL_UNSIGNED_BYTE, 
colorTable);
glTexImage2D(GL_TEXTURE_2D, 0, GL_COLOR_INDEX8_EXT, width, height, 0, 
GL_COLOR_INDEX, GL_UNSIGNED_BYTE, texture);

I hope I was enough clear. Sorry if I wasn't.

Thank you very much for your help.

Cheers,
Adrien

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=29500#29500





_______________________________________________
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

Reply via email to