diff options
author | Rhys Weatherley <rhys.weatherley@nokia.com> | 2009-12-04 07:17:00 (GMT) |
---|---|---|
committer | Rhys Weatherley <rhys.weatherley@nokia.com> | 2009-12-04 07:17:00 (GMT) |
commit | c0b81480b2909b18ac15bdd124a562ae005c2f41 (patch) | |
tree | 8cb3feb9ed332d5211e78c6bc829c3577d098f8f /src/opengl/qglframebufferobject.cpp | |
parent | 108ab335537d20bc74aa9115d46cf91243223c4e (diff) | |
download | Qt-c0b81480b2909b18ac15bdd124a562ae005c2f41.zip Qt-c0b81480b2909b18ac15bdd124a562ae005c2f41.tar.gz Qt-c0b81480b2909b18ac15bdd124a562ae005c2f41.tar.bz2 |
Rebind window surface fbo after native GL rendering
If the user called QGLFramebufferObject::bind()/release() during a
beginNativePainting() callout, the release() would reset the context's
fbo to zero, not the actual window surface fbo.
Task-number: QTBUG-6204
Reviewed-by: Tom
Diffstat (limited to 'src/opengl/qglframebufferobject.cpp')
-rw-r--r-- | src/opengl/qglframebufferobject.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/opengl/qglframebufferobject.cpp b/src/opengl/qglframebufferobject.cpp index d79283e..d0297c9 100644 --- a/src/opengl/qglframebufferobject.cpp +++ b/src/opengl/qglframebufferobject.cpp @@ -899,8 +899,8 @@ bool QGLFramebufferObject::release() #endif if (current) { - current->d_ptr->current_fbo = 0; - glBindFramebuffer(GL_FRAMEBUFFER_EXT, 0); + current->d_ptr->current_fbo = current->d_ptr->default_fbo; + glBindFramebuffer(GL_FRAMEBUFFER_EXT, current->d_ptr->default_fbo); } return true; |