Hacker News new | ask | show | jobs
by midnightclubbed 606 days ago
One caveat is doing screen space means anything offscreen doesn’t contribute to lighting. For a fixed perspective dungeon or 2d game it works great, but a light source behind a column or in another room will cast no light on the scene
2 comments

There are multiple ways to solve this issue. The most naive would be rendering to a larger texture and cropping, but with radiance cascades you can do better- you could only render what's necessary based on per-cascade interval lengths. Depending on needed accuracy, you could calculate it similar to ambient light, only calculating it for the largest cascade- wouldn't be perfect, but could feel pretty natural.

Definitely an area that could use more research!

Not entirely true, you can do the column with a 2nd depthmap rendered from the twincamera at maxdepth with lightsources.