diff --git a/plugins/GSdx/GSDeviceOGL.cpp b/plugins/GSdx/GSDeviceOGL.cpp index 390ce2ac1..829edc354 100644 --- a/plugins/GSdx/GSDeviceOGL.cpp +++ b/plugins/GSdx/GSDeviceOGL.cpp @@ -391,15 +391,7 @@ void GSDeviceOGL::Flip() void GSDeviceOGL::BeforeDraw() { - GL_PUSH("Before Draw Validation & Setup"); - m_shader->UseProgram(); - -#ifdef _DEBUG - ASSERT(gl_CheckFramebufferStatus(GL_DRAW_FRAMEBUFFER) == GL_FRAMEBUFFER_COMPLETE); -#endif - - GL_POP(); } void GSDeviceOGL::AfterDraw() diff --git a/plugins/GSdx/GSShaderOGL.cpp b/plugins/GSdx/GSShaderOGL.cpp index 0e37bc86d..61f0f437c 100644 --- a/plugins/GSdx/GSShaderOGL.cpp +++ b/plugins/GSdx/GSShaderOGL.cpp @@ -239,6 +239,8 @@ GLuint GSShaderOGL::LinkNewProgram() void GSShaderOGL::UseProgram() { + GL_PUSH("Use Program And Uniform"); + if (GLState::dirty_prog) { if (!GLLoader::found_GL_ARB_separate_shader_objects) { GLState::dirty_subroutine_vs = true; @@ -278,6 +280,8 @@ void GSShaderOGL::UseProgram() SetupSubroutineUniform(); GLState::dirty_prog = false; + + GL_POP(); } std::string GSShaderOGL::GenGlslHeader(const std::string& entry, GLenum type, const std::string& macro)