DeferredTexturing icon indicating copy to clipboard operation
DeferredTexturing copied to clipboard

Light clustering issue

Open omd24 opened this issue 1 year ago • 0 comments

I noticed a rare issue with clustered spotlights which only appears at certain positions and orientations.

image The issue can be reproduced using following camera position and orientation (replace the following code in BindlessDeferred::InitializeScene() line 1063:

    camera.SetPosition(Float3(3.49f, 1.76f, 0.49f));
    camera.SetXRotation(-0.26f);
    camera.SetYRotation(4.7f);

image

I also noticed, setting the scaleCorrection to 1.0f in BindlessDeferred::UpdateLights() before calculating light bounds, "fixes" the issue (though from your comment on it, this probably causes other issues due to inaccurate bounds ^^)

omd24 avatar Jan 19 '24 16:01 omd24