From 141d4d5eeec292d9db0b5c1796f0d0f7570000f5 Mon Sep 17 00:00:00 2001 From: vrld Date: Sat, 12 Mar 2011 14:36:50 +0100 Subject: [PATCH] Turn of auto color clearing in Framebuffer::startGrab(). --HG-- branch : minor --- src/modules/graphics/opengl/Framebuffer.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/modules/graphics/opengl/Framebuffer.cpp b/src/modules/graphics/opengl/Framebuffer.cpp index 93575d70b..7d6326509 100644 --- a/src/modules/graphics/opengl/Framebuffer.cpp +++ b/src/modules/graphics/opengl/Framebuffer.cpp @@ -199,10 +199,9 @@ namespace opengl current->stopGrab(); // bind buffer and clear screen - glPushAttrib(GL_VIEWPORT_BIT | GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT | GL_TRANSFORM_BIT); + glPushAttrib(GL_VIEWPORT_BIT | GL_DEPTH_BUFFER_BIT | GL_TRANSFORM_BIT); strategy->bindFBO(fbo); - glClearColor(.0f, .0f, .0f, .0f); - glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); + glClear(GL_DEPTH_BUFFER_BIT); glViewport(0, 0, width, height); // Reset the projection matrix