Don't crash on GL error in present thread

This commit is contained in:
Bradley Austin Davis 2016-02-01 18:26:32 -08:00
parent c71a20b2f0
commit aecf582593

View file

@ -351,8 +351,12 @@ float OpenGLDisplayPlugin::presentRate() {
}
void OpenGLDisplayPlugin::drawUnitQuad() {
_program->Bind();
_plane->Draw();
try {
_program->Bind();
_plane->Draw();
} catch (const oglplus::Error& error) {
qWarning() << "The present thread encountered an error writing the scene texture to the output: " << error.what();
}
}
void OpenGLDisplayPlugin::enableVsync(bool enable) {