From d27f640a3265fd4a2a2d2b2901cc9b783a718423 Mon Sep 17 00:00:00 2001 From: qarmin Date: Tue, 12 May 2020 10:11:17 +0200 Subject: [PATCH] Fixes memory leak with lightmap part 2 --- .../rendering/rasterizer_rd/rasterizer_scene_high_end_rd.cpp | 2 ++ 1 file changed, 2 insertions(+) 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 0436556ce64..b639b4200a1 100644 --- a/servers/rendering/rasterizer_rd/rasterizer_scene_high_end_rd.cpp +++ b/servers/rendering/rasterizer_rd/rasterizer_scene_high_end_rd.cpp @@ -3404,6 +3404,8 @@ RasterizerSceneHighEndRD::~RasterizerSceneHighEndRD() { RD::get_singleton()->free(scene_state.gi_probe_buffer); RD::get_singleton()->free(scene_state.directional_light_buffer); RD::get_singleton()->free(scene_state.light_buffer); + RD::get_singleton()->free(scene_state.lightmap_buffer); + RD::get_singleton()->free(scene_state.lightmap_capture_buffer); RD::get_singleton()->free(scene_state.reflection_buffer); RD::get_singleton()->free(scene_state.decal_buffer); memdelete_arr(scene_state.instances);