From d15fb548047413f04c26e18c1b6ba4b8738eaf0f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mario=20H=C3=BCttel?= Date: Tue, 17 Mar 2020 23:27:57 +0100 Subject: [PATCH] Unload opengl shader program on object disposal --- src/openglshader.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/openglshader.cpp b/src/openglshader.cpp index 953db1d..61749c9 100644 --- a/src/openglshader.cpp +++ b/src/openglshader.cpp @@ -8,6 +8,11 @@ OpenGlShaderProgram::OpenGlShaderProgram(std::string vertex_file, std::string ge this->compiled = false; } +OpenGlShaderProgram::~OpenGlShaderProgram() +{ + this->unload(); +} + char *load_shader_program_from_file(std::string file_name) { return NULL;