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);
}
glViewport(0, 0, level_width, level_height);
fbos.render_to(grad0_tex);
- glUseProgram(sobel_program);
glDisable(GL_BLEND);
glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
}
glViewport(0, 0, width_patches, height_patches);
fbos.render_to(flow_out_tex);
- glUseProgram(motion_search_program);
glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
}
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);
}