Skip to content

Instantly share code, notes, and snippets.

@beugnen
Created May 20, 2012 01:14
Show Gist options
  • Save beugnen/2733074 to your computer and use it in GitHub Desktop.
Save beugnen/2733074 to your computer and use it in GitHub Desktop.
Draw Secondary FBO
void MyDualFramebufferView::DrawToBackbuffer(IDrawable& drawable)
{
// use off screen FBO
glBindFramebuffer(GL_FRAMEBUFFER, _frameBufferID);
glViewport(0,0, cxFBO, cyFBO);
glClearColor(0, 0, 0, 1.0f);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
.
.
.
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment