This commit is contained in:
Wojtek Figat
2024-04-11 17:34:21 +02:00
parent 6233718b06
commit 5f860db6a5

View File

@@ -562,7 +562,7 @@ void ShadowsPass::SetupLight(ShadowsCustomBuffer& shadows, RenderContext& render
atlasLight.Bias = light.ShadowsDepthBias;
atlasLight.FadeDistance = Math::Max(light.ShadowsFadeDistance, 0.1f);
atlasLight.Distance = Math::Min(renderContext.View.Far, light.ShadowsDistance);
atlasLight.Bounds.Center = light.Position + renderContext.View.Position;
atlasLight.Bounds.Center = light.Position + renderContext.View.Origin; // Keep bounds in world-space to properly handle DirtyStaticBounds
atlasLight.Bounds.Radius = 0.0f;
}