mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-21 12:23:51 +00:00
Make the dummy texture for the character preview shadow-friendly
This commit is contained in:
parent
94e8855c8c
commit
0639f8b7c6
1 changed files with 3 additions and 0 deletions
|
@ -184,6 +184,9 @@ namespace MWRender
|
|||
osg::ref_ptr<osg::Texture2D> dummyTexture = new osg::Texture2D();
|
||||
dummyTexture->setInternalFormat(GL_RED);
|
||||
dummyTexture->setTextureSize(1, 1);
|
||||
// This might clash with a shadow map, so make sure it doesn't cast shadows
|
||||
dummyTexture->setShadowComparison(true);
|
||||
dummyTexture->setShadowCompareFunc(osg::Texture::ShadowCompareFunc::ALWAYS);
|
||||
stateset->setTextureAttributeAndModes(7, dummyTexture, osg::StateAttribute::ON);
|
||||
stateset->setTextureAttribute(7, noBlendAlphaEnv, osg::StateAttribute::ON);
|
||||
stateset->addUniform(new osg::Uniform("noAlpha", true));
|
||||
|
|
Loading…
Reference in a new issue