diff options
author | Andy Nichols <andy.nichols@qt.io> | 2016-05-06 15:12:19 +0200 |
---|---|---|
committer | Andy Nichols <andy.nichols@qt.io> | 2016-05-06 19:17:34 +0000 |
commit | 6b8a0c932eb60a7839f9d8ae7112c79166e1f49b (patch) | |
tree | c3112150ae29c30a0462e734d7bbc274157b7e8a /src/quick/items/context2d/qquickcanvasitem.cpp | |
parent | 928915cabe4b8efacf9766962b60f895f51b6b98 (diff) |
QQuickCanvasItem: Don't set QSGGeomety in updatepaintnodes
Just rely on the QSGImageNode to modify the geometry.
Change-Id: I91967ba987ac08a1950cc3fd8aa1c1af25537316
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
Diffstat (limited to 'src/quick/items/context2d/qquickcanvasitem.cpp')
-rw-r--r-- | src/quick/items/context2d/qquickcanvasitem.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/quick/items/context2d/qquickcanvasitem.cpp b/src/quick/items/context2d/qquickcanvasitem.cpp index 2fda25b49a..9ca986501c 100644 --- a/src/quick/items/context2d/qquickcanvasitem.cpp +++ b/src/quick/items/context2d/qquickcanvasitem.cpp @@ -772,11 +772,9 @@ QSGNode *QQuickCanvasItem::updatePaintNode(QSGNode *oldNode, UpdatePaintNodeData d->nodeTexture = texture; node->setTexture(texture); - const QSize ts = texture->textureSize(); - const QRectF srcRect(0, 0, ts.width(), ts.height()); - QSGGeometry::updateTexturedRectGeometry(node->geometry(), - QRectF(QPoint(0, 0), d->canvasWindow.size()), - texture->convertToNormalizedSourceRect(srcRect)); + node->setTargetRect(QRectF(QPoint(0, 0), d->canvasWindow.size())); + node->setInnerTargetRect(QRectF(QPoint(0, 0), d->canvasWindow.size())); + node->update(); if (d->textureProvider) { d->textureProvider->tex = d->nodeTexture; |