diff options
author | Michael Brasser <michael.brasser@live.com> | 2014-04-22 21:19:50 -0500 |
---|---|---|
committer | Michael Brasser <michael.brasser@live.com> | 2014-08-07 21:36:14 +0200 |
commit | ee616b3905106a3eedef9ee964ab283ef45c7dbc (patch) | |
tree | 8cef0f09a44419e88acf21ad893bbbfadb5c8af1 /src/quick/items/qquickshadereffectmesh.cpp | |
parent | 6b31418a1b5d9be47df5ed61747e8a5fb225acfa (diff) |
Allow simple ShaderEffects to be batched by the renderer.
Identical ShaderEffects that use the standard vertex shader with a
single source texture, and that set supportsAtlasTextures, are now
candidates for batching.
Task-number: QTBUG-37914
Change-Id: Ib0ce58647a8c7c48e88bd84cf2645f1a8f28691f
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
Diffstat (limited to 'src/quick/items/qquickshadereffectmesh.cpp')
-rw-r--r-- | src/quick/items/qquickshadereffectmesh.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/quick/items/qquickshadereffectmesh.cpp b/src/quick/items/qquickshadereffectmesh.cpp index bc97a424f4..cf2f8faf5e 100644 --- a/src/quick/items/qquickshadereffectmesh.cpp +++ b/src/quick/items/qquickshadereffectmesh.cpp @@ -70,7 +70,7 @@ QQuickGridMesh::QQuickGridMesh(QObject *parent) connect(this, SIGNAL(resolutionChanged()), this, SIGNAL(geometryChanged())); } -QSGGeometry *QQuickGridMesh::updateGeometry(QSGGeometry *geometry, const QVector<QByteArray> &attributes, const QRectF &dstRect) +QSGGeometry *QQuickGridMesh::updateGeometry(QSGGeometry *geometry, const QVector<QByteArray> &attributes, const QRectF &srcRect, const QRectF &dstRect) { int vmesh = m_resolution.height(); int hmesh = m_resolution.width(); @@ -125,7 +125,6 @@ QSGGeometry *QQuickGridMesh::updateGeometry(QSGGeometry *geometry, const QVector QSGGeometry::Point2D *vdata = static_cast<QSGGeometry::Point2D *>(geometry->vertexData()); - QRectF srcRect(0, 0, 1, 1); for (int iy = 0; iy <= vmesh; ++iy) { float fy = iy / float(vmesh); float y = float(dstRect.top()) + fy * float(dstRect.height()); |