summaryrefslogtreecommitdiffstats
path: root/src/opengl
diff options
context:
space:
mode:
Diffstat (limited to 'src/opengl')
-rw-r--r--src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp3
-rw-r--r--src/opengl/qwindowsurface_gl.cpp4
2 files changed, 7 insertions, 0 deletions
diff --git a/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp b/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp
index dbf18b1..89ed1f7 100644
--- a/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp
+++ b/src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp
@@ -1062,6 +1062,9 @@ bool QGL2PaintEngineEx::begin(QPaintDevice *pdev)
bool QGL2PaintEngineEx::end()
{
Q_D(QGL2PaintEngineEx);
+ QGLContext *ctx = d->ctx;
+ glUseProgram(0);
+ d->transferMode(DefaultMode);
d->drawable.swapBuffers();
d->drawable.doneCurrent();
return false;
diff --git a/src/opengl/qwindowsurface_gl.cpp b/src/opengl/qwindowsurface_gl.cpp
index 08c2aab..5cd4366 100644
--- a/src/opengl/qwindowsurface_gl.cpp
+++ b/src/opengl/qwindowsurface_gl.cpp
@@ -439,6 +439,9 @@ void QGLWindowSurface::flush(QWidget *widget, const QRegion &rgn, const QPoint &
if (d_ptr->fbo)
d_ptr->fbo->release();
+ glDisable(GL_DEPTH_TEST);
+ glDisable(GL_SCISSOR_TEST);
+
glMatrixMode(GL_MODELVIEW);
glLoadIdentity();
@@ -539,6 +542,7 @@ void QGLWindowSurface::updateGeometry()
d_ptr->fbo->bind();
if (d_ptr->fbo->isValid()) {
+ qDebug() << "Created Window Surface FBO" << rect.size();
return;
} else {
qDebug() << "QGLWindowSurface: Failed to create valid FBO, falling back";