fix: Only try to delete textures if OpenGL is still available

This commit is contained in:
WerWolv
2025-02-25 21:51:18 +01:00
parent 96cc7e8ba8
commit 5f61fe2c4f

View File

@@ -288,6 +288,9 @@ namespace ImGuiExt {
}
void Texture::reset() {
if (glDeleteTextures == nullptr)
return;
if (m_textureId != 0) {
glDeleteTextures(1, reinterpret_cast<GLuint*>(&m_textureId));
m_textureId = 0;