Invalidate the bounding rects when the roots change.
authorGunnar Sletta <gunnar.sletta@digia.com>
Wed, 2 Oct 2013 10:58:42 +0000 (12:58 +0200)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Thu, 3 Oct 2013 14:18:44 +0000 (16:18 +0200)
When roots change, matrices are updated in the nodes, so
we need to also invalidate the bounding rects for geometry
nodes.

Change-Id: I61f60ad069c3b1d018ce31c57310a1e5c4807684
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
src/quick/scenegraph/coreapi/qsgbatchrenderer.cpp

index 18f09fe..d52f9db 100644 (file)
@@ -848,8 +848,10 @@ void Renderer::nodeChangedBatchRoot(Node *node, Node *root)
     } else if (node->type() == QSGNode::GeometryNodeType) {
         // Only need to change the root as nodeChanged anyway flags a full update.
         Element *e = node->element();
-        if (e)
+        if (e) {
             e->root = root;
+            e->boundsComputed = false;
+        }
     }
 
     SHADOWNODE_TRAVERSE(node)