From a360d59f7e1e110f88d1341d78ca7dbd1411f706 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= Date: Sun, 3 Jul 2011 20:11:10 +0200 Subject: [PATCH] Remove intersection of region with visible rect No longer needed as the splitting into quads will perform the intersection. --- scene_opengl.cpp | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/scene_opengl.cpp b/scene_opengl.cpp index 61590f3320..3761ec4f9e 100644 --- a/scene_opengl.cpp +++ b/scene_opengl.cpp @@ -469,22 +469,14 @@ void SceneOpenGL::Window::performPaint(int mask, QRegion region, WindowPaintData return; // Only painting translucent and window is opaque }*/ - // Intersect the clip region with the rectangle the window occupies on the screen - if (!(mask & (PAINT_WINDOW_TRANSFORMED | PAINT_SCREEN_TRANSFORMED))) - region &= toplevel->visibleRect(); - if (region.isEmpty()) return; - if (region != infiniteRegion()) { + if (region != infiniteRegion() && !(mask & PAINT_WINDOW_TRANSFORMED)) { WindowQuadList quads; const QRegion filterRegion = region.translated(-x(), -y()); // split all quads in bounding rect with the actual rects in the region foreach (const WindowQuad &quad, data.quads) { - if (quad.isTransformed()) { - quads << quad; - continue; - } foreach (const QRect &r, filterRegion.rects()) { const QRectF rf(r); const QRectF quadRect(QPointF(quad.left(), quad.top()), QPointF(quad.right(), quad.bottom()));