diff options
author | clayjohn <claynjohn@gmail.com> | 2023-01-30 10:36:29 -0800 |
---|---|---|
committer | clayjohn <claynjohn@gmail.com> | 2023-01-30 12:16:33 -0800 |
commit | bc64a734d3a308aea1c1d6bd1634fa507de49cf1 (patch) | |
tree | d1429dcb36643323920ac481a08fdc3b9067d30a /servers/rendering/renderer_rd/storage_rd | |
parent | e9de988020f3d46c3e7b4fd5a8a80724996035e0 (diff) |
Fix various crashes relating to low roughness_layers
Diffstat (limited to 'servers/rendering/renderer_rd/storage_rd')
-rw-r--r-- | servers/rendering/renderer_rd/storage_rd/light_storage.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/servers/rendering/renderer_rd/storage_rd/light_storage.cpp b/servers/rendering/renderer_rd/storage_rd/light_storage.cpp index cdecb3828b..aae6d3f647 100644 --- a/servers/rendering/renderer_rd/storage_rd/light_storage.cpp +++ b/servers/rendering/renderer_rd/storage_rd/light_storage.cpp @@ -1552,6 +1552,11 @@ bool LightStorage::reflection_probe_instance_postprocess_step(RID p_instance) { if (rpi->processing_side == 6) { rpi->processing_side = 0; rpi->processing_layer++; + if (rpi->processing_layer == atlas->reflections[rpi->atlas_index].data.layers[0].mipmaps.size()) { + rpi->rendering = false; + rpi->processing_layer = 1; + return true; + } } return false; |