Fix: Material storage asserts on shutdown if it has pending updates.

This commit is contained in:
Ben Rog-Wilhelm 2024-09-24 14:06:57 -05:00
parent c3e16cda00
commit 922e7e5134
2 changed files with 4 additions and 0 deletions

View File

@ -1506,6 +1506,8 @@ MaterialStorage::~MaterialStorage() {
memdelete_arr(global_shader_uniforms.buffer_dirty_regions); memdelete_arr(global_shader_uniforms.buffer_dirty_regions);
glDeleteBuffers(1, &global_shader_uniforms.buffer); glDeleteBuffers(1, &global_shader_uniforms.buffer);
material_update_list.clear();
singleton = nullptr; singleton = nullptr;
} }

View File

@ -1180,6 +1180,8 @@ MaterialStorage::~MaterialStorage() {
//def samplers //def samplers
samplers_rd_free(default_samplers); samplers_rd_free(default_samplers);
material_update_list.clear();
singleton = nullptr; singleton = nullptr;
} }