diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2020-03-01 09:26:17 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-03-01 09:26:17 +0100 |
commit | f05bbe6932113b73efc57115a65b63ee8f626b8c (patch) | |
tree | 5835b32c109921706741691163e5b08e2dc2bc5b | |
parent | 1ab695bf3732e5918e471231556ce6b5aa3dacdd (diff) | |
parent | a422b8c497b126d6cd01c75f04f7d544c09f6e3c (diff) |
Merge pull request #36698 from clayjohn/VULKAN-free-ref-probes
Properly free reflection probe atlas
-rw-r--r-- | servers/visual/rasterizer_rd/rasterizer_scene_rd.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/servers/visual/rasterizer_rd/rasterizer_scene_rd.cpp b/servers/visual/rasterizer_rd/rasterizer_scene_rd.cpp index bfe98857d9..4a78fa89ba 100644 --- a/servers/visual/rasterizer_rd/rasterizer_scene_rd.cpp +++ b/servers/visual/rasterizer_rd/rasterizer_scene_rd.cpp @@ -653,8 +653,11 @@ void RasterizerSceneRD::reflection_atlas_set_size(RID p_ref_atlas, int p_reflect //clear and invalidate everything RD::get_singleton()->free(ra->reflection); ra->reflection = RID(); + RD::get_singleton()->free(ra->depth_buffer); + ra->depth_buffer = RID(); for (int i = 0; i < ra->reflections.size(); i++) { + _clear_reflection_data(ra->reflections.write[i].data); if (ra->reflections[i].owner.is_null()) { continue; } |