diff options
author | Volker Krause <volker.krause@kdab.com> | 2016-03-12 18:32:09 +0100 |
---|---|---|
committer | Volker Krause <volker.krause@kdab.com> | 2016-03-12 18:12:34 +0000 |
commit | adac8310291828ff40b24f2ee8431fd418743749 (patch) | |
tree | 94d1721d5e0e027bf98339a609819f2463f31c27 | |
parent | de14d026e89465d03c8bdbdf8457ad168eb66c69 (diff) |
Sync with scene3d/AnimatedEntity.qml.
This makes at least the first scene in the example show up again.
Change-Id: Ife23dc180cabd223ad824aa377f6631d58651890
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
-rw-r--r-- | examples/qt3d/scene3d-loader/AnimatedEntity.qml | 25 |
1 files changed, 9 insertions, 16 deletions
diff --git a/examples/qt3d/scene3d-loader/AnimatedEntity.qml b/examples/qt3d/scene3d-loader/AnimatedEntity.qml index faf459157..f95466cc5 100644 --- a/examples/qt3d/scene3d-loader/AnimatedEntity.qml +++ b/examples/qt3d/scene3d-loader/AnimatedEntity.qml @@ -61,10 +61,9 @@ Entity { id: camera projectionType: CameraLens.PerspectiveProjection fieldOfView: 45 - aspectRatio: 16/9 nearPlane : 0.1 farPlane : 1000.0 - position: Qt.vector3d( 0.0, 0.0, -40.0 ) + position: Qt.vector3d( 0.0, 0.0, 40.0 ) upVector: Qt.vector3d( 0.0, 1.0, 0.0 ) viewCenter: Qt.vector3d( 0.0, 0.0, 0.0 ) } @@ -73,19 +72,9 @@ Entity { components: [ RenderSettings { - activeFrameGraph: Viewport { - id: viewport - normalizedRect: Qt.rect(0.0, 0.0, 1.0, 1.0) // From Top Left + activeFrameGraph: ForwardRenderer { + camera: camera clearColor: "transparent" - - CameraSelector { - id : cameraSelector - camera: camera - - ClearBuffer { - buffers : ClearBuffer.ColorDepthBuffer - } - } } } ] @@ -121,8 +110,12 @@ Entity { Transform { id: sphereTransform property real userAngle: 0.0 - translation: Qt.vector3d(20, 0, 0) - rotation: fromAxisAndAngle(Qt.vector3d(0, 1, 0), userAngle) + matrix: { + var m = Qt.matrix4x4(); + m.rotate(userAngle, Qt.vector3d(0, 1, 0)) + m.translate(Qt.vector3d(20, 0, 0)); + return m; + } } QQ2.NumberAnimation { |