lunedì 20 novembre 2017

Day 206: Point light culling in tiled deferred rendering

Today has been an amazingly productive day. I planned to implement the full culling logic for point lights in the tiled deferred rendered, and I managed to do it. Also, I imposed myself to not look online for implementations, as I wanted to do all the math on my own, and I'm really happy I managed to pull it through fairly easily.
The shader might have room for optimization, as its performance is not very good in all situations. Here are some data on 1000 point lights

Normal deferred : ~55 fps
Tiled deferred with 16x16 grid: ~35 fps
Tiled deferred with 32x32 grid: ~62 fps

As you can see, the technique is an improvement when using the 32x32 cell size, which basically tests a single culling for each pixel. On 16x16 though, apparently the 4 tests required are killing performance, which is fairly surprising, as the most complext part of the shader, the fragment rendering, doesn't seem to give any problems. Tomorrow I'll debug and improve what I have.

In the picture is shown the rendering with a white overlay representing the number of point lights influencing that specific quad.



Nessun commento:

Posta un commento