Feature/globals handling (#1352)

* Cleaner handling of global state
* Prevent Lua memory corruption (closes #982)
* Initialize glfw first thing to prevent weird joystick loading bug during startup
This commit is contained in:
Alexander Bock
2020-10-21 22:30:05 +02:00
committed by GitHub
parent 1525a0490d
commit efffc25ce0
164 changed files with 1484 additions and 1390 deletions
@@ -205,7 +205,7 @@ RenderableConstellationBounds::RenderableConstellationBounds(
}
void RenderableConstellationBounds::initializeGL() {
_program = global::renderEngine.buildRenderProgram(
_program = global::renderEngine->buildRenderProgram(
"ConstellationBounds",
absPath("${MODULE_SPACE}/shaders/constellationbounds_vs.glsl"),
absPath("${MODULE_SPACE}/shaders/constellationbounds_fs.glsl")
@@ -237,7 +237,7 @@ void RenderableConstellationBounds::deinitializeGL() {
_vao = 0;
if (_program) {
global::renderEngine.removeRenderProgram(_program.get());
global::renderEngine->removeRenderProgram(_program.get());
_program = nullptr;
}
}