3D-Viewer: fixes a shadow hit bug

This commit is contained in:
Mario Luzeiro 2020-08-18 00:15:27 +01:00 committed by Seth Hillbrand
parent 88d76eaf62
commit 2764a41d96
1 changed files with 1 additions and 1 deletions

View File

@ -459,7 +459,7 @@ bool CLAYERITEM::IntersectP( const RAY &aRay , float aMaxDistance ) const
(boxHitPointEnd - boxHitPointStart) * tOut; (boxHitPointEnd - boxHitPointStart) * tOut;
const float t = glm::length( hitPoint - aRay.m_Origin ); const float t = glm::length( hitPoint - aRay.m_Origin );
if( (t < 1.0f) && ( t > FLT_EPSILON ) ) if( (t < aMaxDistance) && ( t > FLT_EPSILON ) )
return true; return true;
} }
} }