1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-01-21 06:53:53 +00:00

fix a weird problem with the fading overlay

This commit is contained in:
scrawl 2012-09-21 18:09:07 +02:00
parent b91d74d394
commit 845dddbab8

View file

@ -24,7 +24,8 @@ Fader::Fader(Ogre::SceneManager* sceneMgr)
MaterialPtr material = MaterialManager::getSingleton().create("FadeInOutMaterial", ResourceGroupManager::DEFAULT_RESOURCE_GROUP_NAME );
Pass* pass = material->getTechnique(0)->getPass(0);
pass->setSceneBlending(SBT_TRANSPARENT_ALPHA);
mFadeTextureUnit = pass->createTextureUnitState();
pass->setDepthWriteEnabled (false);
mFadeTextureUnit = pass->createTextureUnitState("black.png");
mFadeTextureUnit->setColourOperationEx(LBX_SOURCE1, LBS_MANUAL, LBS_CURRENT, ColourValue(0.f, 0.f, 0.f)); // always black colour
mRectangle = new Ogre::Rectangle2D(true);