]> git.sesse.net Git - nageru/commitdiff
Remove some redundant glUseProgram() calls.
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Fri, 3 Aug 2018 16:07:07 +0000 (18:07 +0200)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Fri, 3 Aug 2018 16:07:07 +0000 (18:07 +0200)
flow.cpp

index 512bdaf12e3ff283b07af22ffd40645ae0cebd5b..726e74fad73c1e844f96ee0d24c62571d782dee9 100644 (file)
--- a/flow.cpp
+++ b/flow.cpp
@@ -379,7 +379,6 @@ void GrayscaleConversion::exec(GLint tex, GLint gray_tex, int width, int height)
        glViewport(0, 0, width, height);
        fbos.render_to(gray_tex);
        glBindVertexArray(gray_vao);
-       glUseProgram(gray_program);
        glDisable(GL_BLEND);
        glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
 }
@@ -422,7 +421,6 @@ void Sobel::exec(GLint tex0_view, GLint grad0_tex, int level_width, int level_he
 
        glViewport(0, 0, level_width, level_height);
        fbos.render_to(grad0_tex);
-       glUseProgram(sobel_program);
        glDisable(GL_BLEND);
        glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
 }
@@ -472,7 +470,6 @@ void MotionSearch::exec(GLuint tex0_view, GLuint tex1_view, GLuint grad0_tex, GL
 
        glViewport(0, 0, width_patches, height_patches);
        fbos.render_to(flow_out_tex);
-       glUseProgram(motion_search_program);
        glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
 }
 
@@ -1448,7 +1445,6 @@ void Blend::exec(GLuint tex0, GLuint tex1, GLuint flow_tex, GLuint output_tex, i
 
        glViewport(0, 0, level_width, level_height);
        fbos.render_to(output_tex);
-       glUseProgram(blend_program);
        glDisable(GL_BLEND);  // A bit ironic, perhaps.
        glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
 }