[osg-users] Read color from osgTerrain ImageLayer?
robert.osfield at gmail.com
Mon Nov 30 02:44:25 PST 2009
Is it that the image data is stored in a DXT compressed format? If so
then you'll need to decode the compressed form, something that isn't
presently built into osg::Image or osgTerrain.
On Sun, Nov 29, 2009 at 6:04 PM, Martin Scheffler <osgforum at tevs.eu> wrote:
> a question: How can I get a terrain color from a specific position?
> ImageLayer::getValue(int, int, osg::Vec4) is not implemented.
> When I try to read from the Image with the command imageLayer->getImage()->getColor(i, j);
> I always get (1,1,1,1) as a return value. This seems to happen because the _pixelFormat value (33776) is not caught by the switch statement in Image::_readColor.
> I use a VPB built terrain.
> So how can I get at the color? Thanks!
> Read this topic online here:
> osg-users mailing list
> osg-users at lists.openscenegraph.org
More information about the osg-users