summaryrefslogtreecommitdiffstats
path: root/examples/qt3d/simple-cpp
diff options
context:
space:
mode:
authorSean Harmer <sean.harmer@kdab.com>2015-10-12 20:45:19 +0100
committerPaul Lemire <paul.lemire@kdab.com>2015-10-13 13:19:50 +0000
commit7c971e0e7791ab38d7d3d8ebc25468c44cbe49c5 (patch)
tree53197a9e5eb7501d6f5b497f70c25dad9c265a6f /examples/qt3d/simple-cpp
parent0bfd20ad3b8eb3edec8d6317af9eb5504f8c0871 (diff)
Move Qt3DCore into Qt3DCore namespace
Update other aspects, tests and examples accordingly. Change-Id: Ib1bcf0bdf4f5aec4422dc0c80bfc32b27fb1a317 Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
Diffstat (limited to 'examples/qt3d/simple-cpp')
-rw-r--r--examples/qt3d/simple-cpp/main.cpp20
1 files changed, 10 insertions, 10 deletions
diff --git a/examples/qt3d/simple-cpp/main.cpp b/examples/qt3d/simple-cpp/main.cpp
index 67d4fcbda..73c29c8f4 100644
--- a/examples/qt3d/simple-cpp/main.cpp
+++ b/examples/qt3d/simple-cpp/main.cpp
@@ -68,10 +68,10 @@ int main(int argc, char* argv[])
view.registerAspect(input);
// Root entity
- Qt3D::QEntity *rootEntity = new Qt3D::QEntity();
+ Qt3DCore::QEntity *rootEntity = new Qt3DCore::QEntity();
// Camera
- Qt3D::QCamera *cameraEntity = view.defaultCamera();
+ Qt3DCore::QCamera *cameraEntity = view.defaultCamera();
cameraEntity->lens()->setPerspectiveProjection(45.0f, 16.0f/9.0f, 0.1f, 1000.0f);
cameraEntity->setPosition(QVector3D(0, 0, -40.0f));
@@ -83,18 +83,18 @@ int main(int argc, char* argv[])
Qt3DRender::QMaterial *material = new Qt3DRender::QPhongMaterial(rootEntity);
// Torus
- Qt3D::QEntity *torusEntity = new Qt3D::QEntity(rootEntity);
+ Qt3DCore::QEntity *torusEntity = new Qt3DCore::QEntity(rootEntity);
Qt3DRender::QTorusMesh *torusMesh = new Qt3DRender::QTorusMesh;
torusMesh->setRadius(5);
torusMesh->setMinorRadius(1);
torusMesh->setRings(100);
torusMesh->setSlices(20);
- Qt3D::QTransform *torusTransform = new Qt3D::QTransform;
- Qt3D::QScaleTransform *torusScaleTransform = new Qt3D::QScaleTransform;
+ Qt3DCore::QTransform *torusTransform = new Qt3DCore::QTransform;
+ Qt3DCore::QScaleTransform *torusScaleTransform = new Qt3DCore::QScaleTransform;
torusScaleTransform->setScale3D(QVector3D(1.5, 1, 0.5));
- Qt3D::QRotateTransform *torusRotateTransform = new Qt3D::QRotateTransform;
+ Qt3DCore::QRotateTransform *torusRotateTransform = new Qt3DCore::QRotateTransform;
torusRotateTransform->setAxis(QVector3D(1, 0, 0));
torusRotateTransform->setAngleDeg(45);
@@ -107,15 +107,15 @@ int main(int argc, char* argv[])
torusEntity->addComponent(material);
// Sphere
- Qt3D::QEntity *sphereEntity = new Qt3D::QEntity(rootEntity);
+ Qt3DCore::QEntity *sphereEntity = new Qt3DCore::QEntity(rootEntity);
Qt3DRender::QSphereMesh *sphereMesh = new Qt3DRender::QSphereMesh;
sphereMesh->setRadius(3);
- Qt3D::QTransform *sphereTransform = new Qt3D::QTransform;
- Qt3D::QTranslateTransform *sphereTranslateTransform = new Qt3D::QTranslateTransform;
+ Qt3DCore::QTransform *sphereTransform = new Qt3DCore::QTransform;
+ Qt3DCore::QTranslateTransform *sphereTranslateTransform = new Qt3DCore::QTranslateTransform;
sphereTranslateTransform->setTranslation(QVector3D(20, 0, 0));
- Qt3D::QRotateTransform *sphereRotateTransform = new Qt3D::QRotateTransform;
+ Qt3DCore::QRotateTransform *sphereRotateTransform = new Qt3DCore::QRotateTransform;
QPropertyAnimation *sphereRotateTransformAnimation = new QPropertyAnimation(sphereRotateTransform);
sphereRotateTransformAnimation->setTargetObject(sphereRotateTransform);
sphereRotateTransformAnimation->setPropertyName("angle");