Made the cursor state protected.

This commit is contained in:
Robert Osfield 2012-01-24 17:57:01 +00:00
parent 7fc23467f1
commit 737da5f23a

View File

@ -221,8 +221,8 @@ osg::Node* createCursorSubgraph(const std::string& filename, float size)
if (image) if (image)
{ {
osg::StateSet* stateset = geom->getOrCreateStateSet(); osg::StateSet* stateset = geom->getOrCreateStateSet();
stateset->setTextureAttributeAndModes(0, new osg::Texture2D(image),osg::StateAttribute::ON); stateset->setTextureAttributeAndModes(0, new osg::Texture2D(image),osg::StateAttribute::ON|osg::StateAttribute::PROTECTED);
stateset->setMode(GL_BLEND,osg::StateAttribute::ON); stateset->setMode(GL_BLEND,osg::StateAttribute::ON|osg::StateAttribute::PROTECTED);
// stateset->setMode(GL_DEPTH_TEST,osg::StateAttribute::OFF); // stateset->setMode(GL_DEPTH_TEST,osg::StateAttribute::OFF);
stateset->setRenderBinDetails(1000, "DepthSortedBin"); stateset->setRenderBinDetails(1000, "DepthSortedBin");
} }