1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2026-02-11 02:38:29 +00:00
Regression from 2754d4264c !5047
This commit is contained in:
AnyOldName3 2026-02-07 23:43:56 +00:00
parent a086ff3fb6
commit 9fbe9a02aa

View file

@ -645,6 +645,8 @@ MWShadowTechnique::Frustum::Frustum(osgUtil::CullVisitor* cv, double minZNear, d
{
osg::Matrix::value_type zNear = osg::maximum<osg::Matrix::value_type>(cv->getCalculatedNearPlane(),minZNear);
osg::Matrix::value_type zFar = osg::minimum<osg::Matrix::value_type>(cv->getCalculatedFarPlane(),maxZFar);
if (zFar < 0)
zFar = minZNear;
zNear = std::min(zNear, zFar);
cv->clampProjectionMatrix(projectionMatrix, zNear, zFar);