1
0
Fork 0

Fix new splash screen with Rembrandt enabled

Stray depth-test state was causing the splash quad to be discarded.
This commit is contained in:
James Turner 2017-05-11 23:02:29 +01:00
parent faf872e7f7
commit 327f59a105

View file

@ -218,13 +218,13 @@ void SplashScreen::createNodes()
_splashQuadCamera->setAllowEventFocus(false); _splashQuadCamera->setAllowEventFocus(false);
_splashQuadCamera->setCullingActive(false); _splashQuadCamera->setCullingActive(false);
_splashQuadCamera->setRenderOrder(osg::Camera::POST_RENDER, 20000); _splashQuadCamera->setRenderOrder(osg::Camera::POST_RENDER, 20000);
stateSet = _splashQuadCamera->getOrCreateStateSet(); stateSet = _splashQuadCamera->getOrCreateStateSet();
stateSet->setMode(GL_BLEND, osg::StateAttribute::ON); stateSet->setMode(GL_BLEND, osg::StateAttribute::ON);
stateSet->setAttribute(new osg::BlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA), osg::StateAttribute::ON); stateSet->setAttribute(new osg::BlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA), osg::StateAttribute::ON);
stateSet->setMode(GL_LIGHTING, osg::StateAttribute::OFF); stateSet->setMode(GL_LIGHTING, osg::StateAttribute::OFF);
stateSet->setRenderBinDetails(1, "RenderBin"); stateSet->setRenderBinDetails(1, "RenderBin");
stateSet->setMode(GL_DEPTH_TEST, osg::StateAttribute::OFF);
geometry = new osg::Geometry; geometry = new osg::Geometry;
geometry->setSupportsDisplayList(false); geometry->setSupportsDisplayList(false);