From: Steinar H. Gunderson Date: Sun, 1 Nov 2015 01:02:10 +0000 (+0100) Subject: Add some earlier check_error() calls so that we do not get confusing behavior if... X-Git-Tag: 1.3.0~24 X-Git-Url: https://git.sesse.net/?p=movit;a=commitdiff_plain;h=15b0642fb679aabc45e6ef778d99494152f233b2 Add some earlier check_error() calls so that we do not get confusing behavior if there is already error on the entrance to render_to_fbo(). --- diff --git a/effect_chain.cpp b/effect_chain.cpp index b6b5f59..4a333ea 100644 --- a/effect_chain.cpp +++ b/effect_chain.cpp @@ -1648,7 +1648,9 @@ void EffectChain::render_to_fbo(GLuint dest_fbo, unsigned width, unsigned height // This needs to be set anew, in case we are coming from a different context // from when we initialized. + check_error(); glDisable(GL_DITHER); + check_error(); // Save original viewport. GLuint x = 0, y = 0; @@ -1663,6 +1665,7 @@ void EffectChain::render_to_fbo(GLuint dest_fbo, unsigned width, unsigned height } // Basic state. + check_error(); glDisable(GL_BLEND); check_error(); glDisable(GL_DEPTH_TEST);