summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorSamuel Rødal <sroedal@trolltech.com>2009-09-18 11:41:07 (GMT)
committerSamuel Rødal <sroedal@trolltech.com>2009-09-18 11:47:10 (GMT)
commit9076fba7ad1f8c4bde69169d3a91d7fa77a34d21 (patch)
tree8b5c24d3ca4f0a897416d8966bbc8d338d2c8844 /src
parent82108cb53ae39283d97e80c92f8632f3ebab673f (diff)
downloadQt-9076fba7ad1f8c4bde69169d3a91d7fa77a34d21.zip
Qt-9076fba7ad1f8c4bde69169d3a91d7fa77a34d21.tar.gz
Qt-9076fba7ad1f8c4bde69169d3a91d7fa77a34d21.tar.bz2
Fixed bug in GL pixmap backend (causing missing rendering in lance).
Since copyBackFromRenderFbo() manually changes the framebuffer object binding, we also need to update the context's current_fbo member. Reviewed-by: Kim
Diffstat (limited to 'src')
-rw-r--r--src/opengl/qpixmapdata_gl.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/opengl/qpixmapdata_gl.cpp b/src/opengl/qpixmapdata_gl.cpp
index 3bc0d4f..8cb6c8d 100644
--- a/src/opengl/qpixmapdata_gl.cpp
+++ b/src/opengl/qpixmapdata_gl.cpp
@@ -486,8 +486,12 @@ void QGLPixmapData::copyBackFromRenderFbo(bool keepCurrentFboBound) const
GL_COLOR_BUFFER_BIT,
GL_NEAREST);
- if (keepCurrentFboBound)
+ if (keepCurrentFboBound) {
glBindFramebuffer(GL_FRAMEBUFFER_EXT, ctx->d_ptr->current_fbo);
+ } else {
+ glBindFramebuffer(GL_DRAW_FRAMEBUFFER_EXT, m_renderFbo->handle());
+ ctx->d_ptr->current_fbo = m_renderFbo->handle();
+ }
}
bool QGLPixmapData::useFramebufferObjects()