Graphics/ForwardFramePipeline: Fix light frustum culling

This commit is contained in:
SirLynix 2023-06-28 17:44:34 +02:00
parent c2caec3954
commit b66c50a5da
1 changed files with 1 additions and 1 deletions

View File

@ -376,7 +376,7 @@ namespace Nz
const BoundingVolumef& boundingVolume = lightData.light->GetBoundingVolume();
// TODO: Use more precise tests for point lights (frustum/sphere is cheap)
if (renderMask & lightData.renderMask && frustum.Contains(boundingVolume))
if (renderMask & lightData.renderMask && frustum.Intersect(boundingVolume) != IntersectionSide::Outside)
{
m_visibleLights.push_back(lightIndex);