Hi
I am rendering a part of my scene with the help of a cameranode into a
texture. Here's the setup of the CameraNode:
_camera = new osg::CameraNode();
_camera->setClearColor(osg::Vec4(0.0f,0.0f,0.0f,1.0f));
_camera->setClearMask(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
_camera->setViewport(0,0,rect[2]-rect[0],rect[3]-rect[1]);
_camera->setRenderTargetImplementation(osg::CameraNode::FRAME_BUFFER_OBJECT);
_camera->setRenderOrder(osg::CameraNode::POST_RENDER);
To disable writes into the alpha-channel of the texture, I set the
ColorMask accordingly:
_camera->setColorMask(new osg::ColorMask(1,1,1,0));
In my visible scene I render a quad textured with the texture from the
CameraNode. Here's the problem: I am experiencing distortions in the
alpha-channel. (see <http://cefix.org/tmp/colormask.jpg>)
If I attach the ColorMask to the children of the CameraNode, the
resulting rendering is fine.
Is this a driver-problem ( i can't test the source on another machine
for now), or a problem with OSG? (I am using a one week old cvs-checkout
on a MacPro, GeForce 7300, OS X 10.4.8)
thanks in advance,
Stephan
_______________________________________________
osg-users mailing list
[email protected]
http://openscenegraph.net/mailman/listinfo/osg-users
http://www.openscenegraph.org/