diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2021-10-31 09:12:10 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-10-31 09:12:10 +0100 |
commit | d6f972fad45d28222b1437a047241dd74f0d5b90 (patch) | |
tree | f464390199e97e5e73d91d3cbb76880a4264a429 /servers/rendering | |
parent | 2074647ab9891e9f94108e72ee7b3a7b70e8cd8c (diff) | |
parent | 346e4979599107420d964e5a573621c413a83422 (diff) |
Merge pull request #54403 from briansemrau/fix-small-fogvolume
FogVolume don't dispatch compute with zero-dimension groups
Diffstat (limited to 'servers/rendering')
-rw-r--r-- | servers/rendering/renderer_rd/renderer_scene_render_rd.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/servers/rendering/renderer_rd/renderer_scene_render_rd.cpp b/servers/rendering/renderer_rd/renderer_scene_render_rd.cpp index 517a9b93c3..0ca2f051fa 100644 --- a/servers/rendering/renderer_rd/renderer_scene_render_rd.cpp +++ b/servers/rendering/renderer_rd/renderer_scene_render_rd.cpp @@ -3954,6 +3954,10 @@ void RendererSceneRenderRD::_update_volumetric_fog(RID p_render_buffers, RID p_e kernel_size = Vector3i(int32_t(rb->volumetric_fog->width), int32_t(rb->volumetric_fog->height), int32_t(rb->volumetric_fog->depth)); } + if (kernel_size.x == 0 || kernel_size.y == 0 || kernel_size.z == 0) { + continue; + } + volumetric_fog.push_constant.position[0] = position.x; volumetric_fog.push_constant.position[1] = position.y; volumetric_fog.push_constant.position[2] = position.z; |