summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorqarmin <mikrutrafal54@gmail.com>2020-05-11 21:04:39 +0200
committerqarmin <mikrutrafal54@gmail.com>2020-05-11 21:04:39 +0200
commit84867275bb2d5c1642820473a6069ee0137e3be7 (patch)
tree0064b12c02abdbeada8b996b49f9284f930c1ded
parent6d46d2fe27e8728d0788fe119e8105780035d15d (diff)
Fix memory leak with light maps
-rw-r--r--servers/rendering/rasterizer_rd/rasterizer_scene_high_end_rd.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/servers/rendering/rasterizer_rd/rasterizer_scene_high_end_rd.cpp b/servers/rendering/rasterizer_rd/rasterizer_scene_high_end_rd.cpp
index 3f0062b2ae..0436556ce6 100644
--- a/servers/rendering/rasterizer_rd/rasterizer_scene_high_end_rd.cpp
+++ b/servers/rendering/rasterizer_rd/rasterizer_scene_high_end_rd.cpp
@@ -3410,6 +3410,8 @@ RasterizerSceneHighEndRD::~RasterizerSceneHighEndRD() {
memdelete_arr(scene_state.gi_probes);
memdelete_arr(scene_state.directional_lights);
memdelete_arr(scene_state.lights);
+ memdelete_arr(scene_state.lightmaps);
+ memdelete_arr(scene_state.lightmap_captures);
memdelete_arr(scene_state.reflections);
memdelete_arr(scene_state.decals);
}