mirror of
https://github.com/OpenMW/openmw.git
synced 2025-03-03 07:39:41 +00:00
fix regression where LEQUAL was used instead of LESS for depth function
This commit is contained in:
parent
b6572fbe42
commit
2c52695361
2 changed files with 2 additions and 2 deletions
|
@ -816,7 +816,7 @@ namespace MWRender
|
|||
osg::StateSet* queryStateSet = new osg::StateSet;
|
||||
if (queryVisible)
|
||||
{
|
||||
osg::ref_ptr<osg::Depth> depth = new SceneUtil::AutoDepth;
|
||||
osg::ref_ptr<osg::Depth> depth = new SceneUtil::AutoDepth(osg::Depth::LEQUAL);
|
||||
// This is a trick to make fragments written by the query always use the maximum depth value,
|
||||
// without having to retrieve the current far clipping distance.
|
||||
// We want the sun glare to be "infinitely" far away.
|
||||
|
|
|
@ -106,7 +106,7 @@ namespace
|
|||
osg::ref_ptr<osg::Depth> mValue;
|
||||
|
||||
LequalDepth()
|
||||
: mValue(new SceneUtil::AutoDepth)
|
||||
: mValue(new SceneUtil::AutoDepth(osg::Depth::LEQUAL))
|
||||
{
|
||||
}
|
||||
};
|
||||
|
|
Loading…
Reference in a new issue