This limits the number of tilemaps per LOD that can be fed to avoid the easy to hit "Too many shadow updates" (#119757). This allows for a max 64 tilemaps to be updated at once at their lowest requested LOD (so ~10.6667 point lights if every faces of the punctual shadow map is needed, but likely more in practice). Unfortunately this is still quite low and will surely be hit quite soon with directional shadow added to it. One idea to workaround this would be to time slice the update of some lights, but this opens a whole can of worms that I'm not ready to open for now so I created #119890 for future reference. Some notes, most lights seems to request around 3 LODs. It might help to allow requesting at least 2 LODs if we are rendering since volumes might want lower LOD available for volumes. I added a very simplistic heuristic that also lowers the max tilemaps when transforming, animation playback or navigating the 3D view to improve the responsiveness of the engine. Note that this doesn't only lowers the resolution to the minimum requested one. So it should be good enough in most cases. Pull Request: https://projects.blender.org/blender/blender/pulls/119889 |
||
---|---|---|
.. | ||
mtl_shader_common.msl | ||
mtl_shader_defines.msl |