diff options
author | Laszlo Agocs <laszlo.agocs@qt.io> | 2018-07-30 11:02:05 +0200 |
---|---|---|
committer | Laszlo Agocs <laszlo.agocs@qt.io> | 2018-07-30 11:10:25 +0000 |
commit | ce974eb0112fe23b127e937470a5d2689dccb528 (patch) | |
tree | 54febaecc767741869e29b8865a88118a0814278 /tests | |
parent | 5497f2371ac9abc5ceda9410967f4371192901b1 (diff) |
Make Q3DSCamera default to 0 0 -600 from C++ too
Remnove the discrepancy between cameras created from uip and code.
Change-Id: I8b04199b931b00f3686caf84fbe7e1d0f39c7357
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/manual/qt3dsexplorer/manualpresentationtest.cpp | 5 | ||||
-rw-r--r-- | tests/scripts/newlayer.drgscr | 4 | ||||
-rw-r--r-- | tests/scripts/newlayer_direct.drgscr | 1 |
3 files changed, 3 insertions, 7 deletions
diff --git a/tests/manual/qt3dsexplorer/manualpresentationtest.cpp b/tests/manual/qt3dsexplorer/manualpresentationtest.cpp index 33f7fe1..6aa09ce 100644 --- a/tests/manual/qt3dsexplorer/manualpresentationtest.cpp +++ b/tests/manual/qt3dsexplorer/manualpresentationtest.cpp @@ -56,9 +56,8 @@ QVector<Q3DSUipPresentation *> ManualPresentationTest::build() // each layer uses the first active camera encountered while walking depth-first Q3DSCameraNode *camera1 = mainPres->newObject<Q3DSCameraNode>("camera1"); - // Defaults to a perspective camera with fov 60, near/far 10/5000. This is - // good as it is in many cases. - camera1->setPosition(QVector3D(0, 0, -600)); + // Defaults to a perspective camera with position (0, 0, -600), fov 60, + // near/far 10/5000. This is good as it is in many cases. layer1->appendChildNode(camera1); // let's have a light diff --git a/tests/scripts/newlayer.drgscr b/tests/scripts/newlayer.drgscr index 54d1471..c05647e 100644 --- a/tests/scripts/newlayer.drgscr +++ b/tests/scripts/newlayer.drgscr @@ -2,9 +2,7 @@ object(newlayer, newlayer, Layer, null, Slide1) // default layer background is Transparent, this is good object(newlayer_cam, newlayer_cam, Camera, newlayer, Slide1) -// the default position does not work since the property is shared with nodes and those use 0 0 0 as the default, -// unlike the expected 0 0 -600 for cameras. so must specify it explicitly. -set(newlayer_cam, position, 0 0 -600) +// defaults to position 0 0 -600 // must have a light to see something object(newlayer_light, newlayer_light, Light, newlayer, Slide1) diff --git a/tests/scripts/newlayer_direct.drgscr b/tests/scripts/newlayer_direct.drgscr index 5dbe01d..942d882 100644 --- a/tests/scripts/newlayer_direct.drgscr +++ b/tests/scripts/newlayer_direct.drgscr @@ -4,7 +4,6 @@ object(newlayer, newlayer, Layer, Scene, Slide1) object(newlayer_cam, newlayer_cam, Camera, newlayer, Slide1) -set(newlayer_cam, position, 0 0 -600) object(newlayer_light, newlayer_light, Light, newlayer, Slide1) |