Page MenuHome

Clustered Light Culing
Open, Confirmed, LowPublic


Lights evaluation is what takes the most time in eevee. Using Clustered light culling, we could cut down the evaluation time by evaluating only lights present in the view.

This needs further investigation as how to communicate what lights are visible. Light Bits is the most straight forward way but it severly limits the number of lights per froxel.
Also findMSB (glsl bitscan) is GL 4.0 only, so need to review other alternative. (avalanche studio slides link).

We need a way to cull thoses on GPU (pixel shader per froxel?) for efficiency.
Need more investigation about the state of the art techniques.
Issue is that it takes another texture slot. Could we use a UBO instead and use bigger froxel? (Can't write to UBO using shaders)

Estimate : 2 weeks


To Do

Event Timeline

Clément Foucault (fclem) triaged this task as Confirmed, Low priority.

There's an alternative to clustered shading called BVH Accelerated Shading. Downside, you need to maintain a bvh on the cpu side, upside, you don't need any compute shaders and you aren't limted to a fixed count of lights.
Maybe worth looking into it: Simple Alternative to Clustered Shading for Thousands of Lights