From cf52d92133a356784e0f784e810b232290d8d3da Mon Sep 17 00:00:00 2001 From: Sean Harmer Date: Wed, 11 Nov 2015 12:18:26 +0000 Subject: Adapt examples to use rotation property and quaternion helper This covers all examples that can use the standard S, R, T order of transformations with a single rotation. Change-Id: Ief6741f9605742c545d8ef2be9bf8ab65164835d Reviewed-by: Paul Lemire --- examples/qt3d/tessellation-modes/TessellatedQuad.qml | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) (limited to 'examples/qt3d/tessellation-modes') diff --git a/examples/qt3d/tessellation-modes/TessellatedQuad.qml b/examples/qt3d/tessellation-modes/TessellatedQuad.qml index b5945ed6c..363b43710 100644 --- a/examples/qt3d/tessellation-modes/TessellatedQuad.qml +++ b/examples/qt3d/tessellation-modes/TessellatedQuad.qml @@ -53,16 +53,9 @@ Entity { Transform { id: transform - matrix: { - var m = Qt.matrix4x4(1, 0, 0, 0, - 0, 1, 0, 0, - 0, 0, 1, 0, - 0, 0, 0, 1); - m.translate(Qt.vector3d(root.x, root.y, root.z)); - m.rotate(root.theta, Qt.vector3d(0, 1, 0)); - m.scale(root.scale) - return m; - } + translation: Qt.vector3d(root.x, root.y, root.z) + rotation: fromAxisAndAngle(Qt.vector3d(0, 1, 0), root.theta) + scale: root.scale } TessellatedQuadMesh { -- cgit v1.2.3