summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
Diffstat (limited to 'examples')
-rw-r--r--examples/examples.pro2
-rw-r--r--examples/qt3d/README14
-rw-r--r--examples/qt3d/basket/README (renamed from examples/basket/README)0
-rw-r--r--examples/qt3d/basket/basket.jpg (renamed from examples/basket/basket.jpg)bin454145 -> 454145 bytes
-rw-r--r--examples/qt3d/basket/basket.pro (renamed from examples/basket/basket.pro)0
-rw-r--r--examples/qt3d/basket/basket.qrc (renamed from examples/basket/basket.qrc)0
-rw-r--r--examples/qt3d/basket/basket_data.h (renamed from examples/basket/basket_data.h)0
-rw-r--r--examples/qt3d/basket/basket_data.txt (renamed from examples/basket/basket_data.txt)0
-rw-r--r--examples/qt3d/basket/basketview.cpp (renamed from examples/basket/basketview.cpp)0
-rw-r--r--examples/qt3d/basket/basketview.h (renamed from examples/basket/basketview.h)0
-rw-r--r--examples/qt3d/basket/main.cpp (renamed from examples/basket/main.cpp)0
-rw-r--r--examples/qt3d/builder/builder.cpp (renamed from examples/builder/builder.cpp)0
-rw-r--r--examples/qt3d/builder/builder.h (renamed from examples/builder/builder.h)0
-rw-r--r--examples/qt3d/builder/builder.pro (renamed from examples/builder/builder.pro)0
-rw-r--r--examples/qt3d/builder/builder.qrc (renamed from examples/builder/builder.qrc)0
-rw-r--r--examples/qt3d/builder/main.cpp (renamed from examples/builder/main.cpp)0
-rw-r--r--examples/qt3d/builder/qt-soup.png (renamed from examples/builder/qt-soup.png)bin91448 -> 91448 bytes
-rw-r--r--examples/qt3d/cube/cube.pro (renamed from examples/cube/cube.pro)0
-rw-r--r--examples/qt3d/cube/cube.qrc (renamed from examples/cube/cube.qrc)0
-rw-r--r--examples/qt3d/cube/cubeview.cpp (renamed from examples/cube/cubeview.cpp)0
-rw-r--r--examples/qt3d/cube/cubeview.h (renamed from examples/cube/cubeview.h)0
-rw-r--r--examples/qt3d/cube/main.cpp (renamed from examples/cube/main.cpp)0
-rw-r--r--examples/qt3d/cube/qtlogo.png (renamed from examples/cube/qtlogo.png)bin13923 -> 13923 bytes
-rw-r--r--examples/qt3d/cylinder/cubeview.cpp (renamed from examples/cylinder/cubeview.cpp)0
-rw-r--r--examples/qt3d/cylinder/cubeview.h (renamed from examples/cylinder/cubeview.h)0
-rw-r--r--examples/qt3d/cylinder/cupTexture.png (renamed from examples/cylinder/cupTexture.png)bin82843 -> 82843 bytes
-rw-r--r--examples/qt3d/cylinder/cylinder.pro (renamed from examples/cylinder/cylinder.pro)0
-rw-r--r--examples/qt3d/cylinder/cylinder.qrc (renamed from examples/cylinder/cylinder.qrc)0
-rw-r--r--examples/qt3d/cylinder/cylinderview.cpp (renamed from examples/cylinder/cylinderview.cpp)0
-rw-r--r--examples/qt3d/cylinder/cylinderview.h (renamed from examples/cylinder/cylinderview.h)0
-rw-r--r--examples/qt3d/cylinder/latte.png (renamed from examples/cylinder/latte.png)bin294671 -> 294671 bytes
-rw-r--r--examples/qt3d/cylinder/main.cpp (renamed from examples/cylinder/main.cpp)0
-rw-r--r--examples/qt3d/geometry/EarthFlat_512x512.jpg (renamed from examples/geometry/EarthFlat_512x512.jpg)bin183612 -> 183612 bytes
-rw-r--r--examples/qt3d/geometry/bullseye.png (renamed from examples/geometry/bullseye.png)bin2737 -> 2737 bytes
-rw-r--r--examples/qt3d/geometry/geometry.cpp (renamed from examples/geometry/geometry.cpp)0
-rw-r--r--examples/qt3d/geometry/geometry.h (renamed from examples/geometry/geometry.h)0
-rw-r--r--examples/qt3d/geometry/geometry.pro (renamed from examples/geometry/geometry.pro)0
-rw-r--r--examples/qt3d/geometry/geometry.qrc (renamed from examples/geometry/geometry.qrc)0
-rw-r--r--examples/qt3d/geometry/geometryview.cpp (renamed from examples/geometry/geometryview.cpp)0
-rw-r--r--examples/qt3d/geometry/geometryview.h (renamed from examples/geometry/geometryview.h)0
-rw-r--r--examples/qt3d/geometry/main.cpp (renamed from examples/geometry/main.cpp)0
-rw-r--r--examples/qt3d/geometry/quadplane.cpp (renamed from examples/geometry/quadplane.cpp)0
-rw-r--r--examples/qt3d/geometry/quadplane.h (renamed from examples/geometry/quadplane.h)0
-rw-r--r--examples/qt3d/graphicsview/cubeicon.png (renamed from examples/graphicsview/cubeicon.png)bin703 -> 703 bytes
-rw-r--r--examples/qt3d/graphicsview/cubeitem.cpp (renamed from examples/graphicsview/cubeitem.cpp)0
-rw-r--r--examples/qt3d/graphicsview/cubeitem.h (renamed from examples/graphicsview/cubeitem.h)0
-rw-r--r--examples/qt3d/graphicsview/edge.cpp (renamed from examples/graphicsview/edge.cpp)0
-rw-r--r--examples/qt3d/graphicsview/edge.h (renamed from examples/graphicsview/edge.h)0
-rw-r--r--examples/qt3d/graphicsview/graph.cpp (renamed from examples/graphicsview/graph.cpp)0
-rw-r--r--examples/qt3d/graphicsview/graph.h (renamed from examples/graphicsview/graph.h)0
-rw-r--r--examples/qt3d/graphicsview/graphicsview.pro (renamed from examples/graphicsview/graphicsview.pro)0
-rw-r--r--examples/qt3d/graphicsview/graphicsview.qrc (renamed from examples/graphicsview/graphicsview.qrc)0
-rw-r--r--examples/qt3d/graphicsview/main.cpp (renamed from examples/graphicsview/main.cpp)0
-rw-r--r--examples/qt3d/graphicsview/modelitem.cpp (renamed from examples/graphicsview/modelitem.cpp)0
-rw-r--r--examples/qt3d/graphicsview/modelitem.h (renamed from examples/graphicsview/modelitem.h)0
-rw-r--r--examples/qt3d/graphicsview/node.cpp (renamed from examples/graphicsview/node.cpp)0
-rw-r--r--examples/qt3d/graphicsview/node.h (renamed from examples/graphicsview/node.h)0
-rw-r--r--examples/qt3d/graphicsview/scene.cpp (renamed from examples/graphicsview/scene.cpp)0
-rw-r--r--examples/qt3d/graphicsview/scene.h (renamed from examples/graphicsview/scene.h)0
-rw-r--r--examples/qt3d/graphicsview/teapoticon.png (renamed from examples/graphicsview/teapoticon.png)bin4969 -> 4969 bytes
-rw-r--r--examples/qt3d/graphicsview/teapotitem.cpp (renamed from examples/graphicsview/teapotitem.cpp)0
-rw-r--r--examples/qt3d/graphicsview/teapotitem.h (renamed from examples/graphicsview/teapotitem.h)0
-rw-r--r--examples/qt3d/graphicsview/view.cpp (renamed from examples/graphicsview/view.cpp)0
-rw-r--r--examples/qt3d/graphicsview/view.h (renamed from examples/graphicsview/view.h)0
-rw-r--r--examples/qt3d/nesting/cubeview.cpp (renamed from examples/nesting/cubeview.cpp)0
-rw-r--r--examples/qt3d/nesting/cubeview.h (renamed from examples/nesting/cubeview.h)0
-rw-r--r--examples/qt3d/nesting/main.cpp (renamed from examples/nesting/main.cpp)0
-rw-r--r--examples/qt3d/nesting/nesting.pro (renamed from examples/nesting/nesting.pro)0
-rw-r--r--examples/qt3d/nesting/nesting.qrc (renamed from examples/nesting/nesting.qrc)0
-rw-r--r--examples/qt3d/nesting/qtlogo.png (renamed from examples/nesting/qtlogo.png)bin13923 -> 13923 bytes
-rw-r--r--examples/qt3d/qt3d.pro2
-rw-r--r--examples/qt3d/tank/main.cpp (renamed from examples/tank/main.cpp)0
-rw-r--r--examples/qt3d/tank/quadplane.cpp (renamed from examples/tank/quadplane.cpp)0
-rw-r--r--examples/qt3d/tank/quadplane.h (renamed from examples/tank/quadplane.h)0
-rw-r--r--examples/qt3d/tank/tank.cpp (renamed from examples/tank/tank.cpp)0
-rw-r--r--examples/qt3d/tank/tank.h (renamed from examples/tank/tank.h)0
-rw-r--r--examples/qt3d/tank/tank.pro (renamed from examples/tank/tank.pro)0
-rw-r--r--examples/qt3d/tank/tankview.cpp (renamed from examples/tank/tankview.cpp)0
-rw-r--r--examples/qt3d/tank/tankview.h (renamed from examples/tank/tankview.h)0
-rw-r--r--examples/qt3d/teapot/main.cpp (renamed from examples/teapot/main.cpp)0
-rw-r--r--examples/qt3d/teapot/teapot.pro (renamed from examples/teapot/teapot.pro)0
-rw-r--r--examples/qt3d/teapot/teapotview.cpp (renamed from examples/teapot/teapotview.cpp)0
-rw-r--r--examples/qt3d/teapot/teapotview.h (renamed from examples/teapot/teapotview.h)0
-rw-r--r--examples/qt3d/tutorials/converting-rawgl/converting-rawgl.pro (renamed from examples/tutorials/converting-rawgl/converting-rawgl.pro)0
-rw-r--r--examples/qt3d/tutorials/converting/converting-rawgl.cpp (renamed from examples/tutorials/converting/converting-rawgl.cpp)0
-rw-r--r--examples/qt3d/tutorials/converting/converting.cpp (renamed from examples/tutorials/converting/converting.cpp)0
-rw-r--r--examples/qt3d/tutorials/converting/converting.pro (renamed from examples/tutorials/converting/converting.pro)0
-rw-r--r--examples/qt3d/tutorials/cube1/cube1.pro (renamed from examples/tutorials/cube1/cube1.pro)0
-rw-r--r--examples/qt3d/tutorials/cube1/cubeview.cpp (renamed from examples/tutorials/cube1/cubeview.cpp)0
-rw-r--r--examples/qt3d/tutorials/cube1/cubeview.h (renamed from examples/tutorials/cube1/cubeview.h)0
-rw-r--r--examples/qt3d/tutorials/cube1/main.cpp (renamed from examples/tutorials/cube1/main.cpp)0
-rw-r--r--examples/qt3d/tutorials/cube2/cube2.pro (renamed from examples/tutorials/cube2/cube2.pro)0
-rw-r--r--examples/qt3d/tutorials/cube2/cubeview.cpp (renamed from examples/tutorials/cube2/cubeview.cpp)0
-rw-r--r--examples/qt3d/tutorials/cube2/cubeview.h (renamed from examples/tutorials/cube2/cubeview.h)0
-rw-r--r--examples/qt3d/tutorials/cube2/main.cpp (renamed from examples/tutorials/cube2/main.cpp)0
-rw-r--r--examples/qt3d/tutorials/cube3/cube3.pro (renamed from examples/tutorials/cube3/cube3.pro)0
-rw-r--r--examples/qt3d/tutorials/cube3/cubeview.cpp (renamed from examples/tutorials/cube3/cubeview.cpp)0
-rw-r--r--examples/qt3d/tutorials/cube3/cubeview.h (renamed from examples/tutorials/cube3/cubeview.h)0
-rw-r--r--examples/qt3d/tutorials/cube3/main.cpp (renamed from examples/tutorials/cube3/main.cpp)0
-rw-r--r--examples/qt3d/tutorials/cube4/cube.qml (renamed from examples/tutorials/cube4/cube.qml)0
-rw-r--r--examples/qt3d/tutorials/cube4/cube.qrc (renamed from examples/tutorials/cube4/cube.qrc)0
-rw-r--r--examples/qt3d/tutorials/cube4/cube4.pro (renamed from examples/tutorials/cube4/cube4.pro)0
-rw-r--r--examples/qt3d/tutorials/cube4/cubeview.cpp (renamed from examples/tutorials/cube4/cubeview.cpp)0
-rw-r--r--examples/qt3d/tutorials/cube4/cubeview.h (renamed from examples/tutorials/cube4/cubeview.h)0
-rw-r--r--examples/qt3d/tutorials/cube4/main.cpp (renamed from examples/tutorials/cube4/main.cpp)0
-rw-r--r--examples/qt3d/tutorials/cube4/qtlogo.png (renamed from examples/tutorials/cube4/qtlogo.png)bin13923 -> 13923 bytes
-rw-r--r--examples/qt3d/tutorials/penguin/main.cpp (renamed from examples/tutorials/penguin/main.cpp)0
-rw-r--r--examples/qt3d/tutorials/penguin/model.qrc (renamed from examples/tutorials/penguin/model.qrc)0
-rw-r--r--examples/qt3d/tutorials/penguin/modelview.cpp (renamed from examples/tutorials/penguin/modelview.cpp)0
-rw-r--r--examples/qt3d/tutorials/penguin/modelview.h (renamed from examples/tutorials/penguin/modelview.h)0
-rw-r--r--examples/qt3d/tutorials/penguin/penguin.3ds (renamed from examples/tutorials/penguin/penguin.3ds)bin36301 -> 36301 bytes
-rw-r--r--examples/qt3d/tutorials/penguin/penguin.pro (renamed from examples/tutorials/penguin/penguin.pro)0
-rw-r--r--examples/qt3d/tutorials/penguin_advanced/main.cpp (renamed from examples/tutorials/penguin_advanced/main.cpp)0
-rw-r--r--examples/qt3d/tutorials/penguin_advanced/model_advanced.qrc (renamed from examples/tutorials/penguin_advanced/model_advanced.qrc)0
-rw-r--r--examples/qt3d/tutorials/penguin_advanced/modelview.cpp (renamed from examples/tutorials/penguin_advanced/modelview.cpp)0
-rw-r--r--examples/qt3d/tutorials/penguin_advanced/modelview.h (renamed from examples/tutorials/penguin_advanced/modelview.h)0
-rw-r--r--examples/qt3d/tutorials/penguin_advanced/penguin.3ds (renamed from examples/tutorials/penguin_advanced/penguin.3ds)bin36301 -> 36301 bytes
-rw-r--r--examples/qt3d/tutorials/penguin_advanced/penguin_advanced.pro (renamed from examples/tutorials/penguin_advanced/penguin_advanced.pro)0
-rw-r--r--examples/qt3d/tutorials/shaders/TutorialTeapot.qml (renamed from examples/tutorials/shaders/TutorialTeapot.qml)0
l---------examples/qt3d/tutorials/shaders/meshes (renamed from examples/tutorials/shaders/meshes)0
-rw-r--r--examples/qt3d/tutorials/shaders/shader-tutorial-1-textures.qml (renamed from examples/tutorials/shaders/shader-tutorial-1-textures.qml)0
-rw-r--r--examples/qt3d/tutorials/shaders/shader-tutorial-2-vertex-shader.qml (renamed from examples/tutorials/shaders/shader-tutorial-2-vertex-shader.qml)0
-rw-r--r--examples/qt3d/tutorials/shaders/shader-tutorial-3-transformed-coordinates.qml (renamed from examples/tutorials/shaders/shader-tutorial-3-transformed-coordinates.qml)0
-rw-r--r--examples/qt3d/tutorials/shaders/shader-tutorial-lighting.qml (renamed from examples/tutorials/shaders/shader-tutorial-lighting.qml)0
-rw-r--r--examples/qt3d/tutorials/shaders/shader-tutorial-varying.qml (renamed from examples/tutorials/shaders/shader-tutorial-varying.qml)0
-rw-r--r--examples/qt3d/tutorials/shaders/shader-tutorial.qml (renamed from examples/tutorials/shaders/shader-tutorial.qml)0
-rw-r--r--examples/qt3d/tutorials/shaders/shaders.pro (renamed from examples/tutorials/shaders/shaders.pro)0
-rw-r--r--examples/qt3d/tutorials/shaders/shaders.qmlproject (renamed from examples/tutorials/shaders/shaders.qmlproject)0
l---------examples/qt3d/tutorials/shaders/textures/basket.jpg (renamed from examples/tutorials/shaders/textures/basket.jpg)0
l---------examples/qt3d/tutorials/shaders/textures/qtlogo.png (renamed from examples/tutorials/shaders/textures/qtlogo.png)0
-rw-r--r--examples/qt3d/tutorials/teapot-qml/teapot-bounce.qml (renamed from examples/tutorials/teapot-qml/teapot-bounce.qml)0
-rw-r--r--examples/qt3d/tutorials/teapot-qml/teapot-qml.qmlproject (renamed from examples/tutorials/teapot-qml/teapot-qml.qmlproject)0
-rw-r--r--examples/qt3d/tutorials/teapot-qml/teapot.bez (renamed from examples/tutorials/teapot-qml/teapot.bez)0
-rw-r--r--examples/qt3d/tutorials/teapot-qml/teapot.qml (renamed from examples/tutorials/teapot-qml/teapot.qml)0
-rw-r--r--examples/qt3d/tutorials/tutorials.pro (renamed from examples/tutorials/tutorials.pro)0
-rw-r--r--examples/quick3d/basket/basket.pro4
-rw-r--r--examples/quick3d/basket/main.cpp60
-rw-r--r--examples/quick3d/basket/qml/basket.qml74
-rw-r--r--examples/quick3d/bounce/bounce.pro4
-rw-r--r--examples/quick3d/bounce/main.cpp60
-rw-r--r--examples/quick3d/bounce/qml/bounce.qml69
-rw-r--r--examples/quick3d/cube/cube.pro4
-rw-r--r--examples/quick3d/cube/main.cpp60
-rw-r--r--examples/quick3d/cube/qml/cube.qml62
-rw-r--r--examples/quick3d/forest/forest.pro4
-rw-r--r--examples/quick3d/forest/main.cpp60
-rw-r--r--examples/quick3d/forest/qml/Tree.qml60
-rw-r--r--examples/quick3d/forest/qml/forest.qml81
-rw-r--r--examples/quick3d/forest/qml/ground.obj11
-rw-r--r--examples/quick3d/forest/qml/tree.obj11
-rw-r--r--examples/quick3d/forest/qml/tree.pngbin0 -> 5631 bytes
-rw-r--r--examples/quick3d/lander/lander.pro4
-rw-r--r--examples/quick3d/lander/main.cpp60
-rw-r--r--examples/quick3d/lander/qml/flame.pngbin0 -> 8974 bytes
-rw-r--r--examples/quick3d/lander/qml/flame.xcfbin0 -> 43771 bytes
-rw-r--r--examples/quick3d/lander/qml/flame2.pngbin0 -> 9282 bytes
-rw-r--r--examples/quick3d/lander/qml/flame2.xcfbin0 -> 44378 bytes
-rw-r--r--examples/quick3d/lander/qml/lander.qml90
-rw-r--r--examples/quick3d/lander/qml/lunar-lander.3dsbin0 -> 17180 bytes
-rw-r--r--examples/quick3d/lander/qml/rusty.pngbin0 -> 3885 bytes
-rw-r--r--examples/quick3d/matrix_animation/main.cpp60
-rw-r--r--examples/quick3d/matrix_animation/matrix_animation.pro4
-rw-r--r--examples/quick3d/matrix_animation/qml/matrix-animation.qml145
-rw-r--r--examples/quick3d/monkeygod/main.cpp60
-rw-r--r--examples/quick3d/monkeygod/monkeygod.pro4
-rw-r--r--examples/quick3d/monkeygod/qml/Penguin.qml78
-rw-r--r--examples/quick3d/monkeygod/qml/meshes/monkey.3dsbin0 -> 13886 bytes
-rw-r--r--examples/quick3d/monkeygod/qml/meshes/penguin.3dsbin0 -> 36301 bytes
-rw-r--r--examples/quick3d/monkeygod/qml/monkeygod.qml115
-rw-r--r--examples/quick3d/monkeygod/qml/monkeygod_no_platform.qml110
-rw-r--r--examples/quick3d/moon/main.cpp60
-rw-r--r--examples/quick3d/moon/moon.pro4
-rw-r--r--examples/quick3d/moon/qml/moon-texture.jpgbin0 -> 111322 bytes
-rw-r--r--examples/quick3d/moon/qml/moon.qml65
-rw-r--r--examples/quick3d/photopane/main.cpp60
-rw-r--r--examples/quick3d/photopane/photopane.pro4
-rw-r--r--examples/quick3d/photopane/qml/photopane.qml127
-rw-r--r--examples/quick3d/photoroom/main.cpp60
-rw-r--r--examples/quick3d/photoroom/photoroom.pro4
-rw-r--r--examples/quick3d/photoroom/qml/photoroom.qml162
-rw-r--r--examples/quick3d/quick3d.pro16
-rw-r--r--examples/quick3d/shaders/main.cpp60
-rw-r--r--examples/quick3d/shaders/qml/Animation.qml124
-rw-r--r--examples/quick3d/shaders/qml/Collapsing.qml125
-rw-r--r--examples/quick3d/shaders/qml/Images.qml144
-rw-r--r--examples/quick3d/shaders/qml/Interpolate.qml126
-rw-r--r--examples/quick3d/shaders/qml/images/basket.jpgbin0 -> 454145 bytes
-rw-r--r--examples/quick3d/shaders/qml/images/qtlogo.pngbin0 -> 13923 bytes
-rw-r--r--examples/quick3d/shaders/qml/images/teapot-logo.pngbin0 -> 3644 bytes
-rw-r--r--examples/quick3d/shaders/qml/meshes/teapot.bez340
-rw-r--r--examples/quick3d/shaders/qml/shaders.qml93
-rw-r--r--examples/quick3d/shaders/shaders.pro4
-rw-r--r--examples/quick3d/sphere/main.cpp60
-rw-r--r--examples/quick3d/sphere/qml/sphere.qml171
-rw-r--r--examples/quick3d/sphere/sphere.pro4
-rw-r--r--examples/quick3d/teapot/main.cpp60
-rw-r--r--examples/quick3d/teapot/qml/teapot.qml50
-rw-r--r--examples/quick3d/teapot/teapot.pro4
-rw-r--r--examples/quick3d/textures/basket.jpgbin0 -> 454145 bytes
-rw-r--r--examples/quick3d/textures/button/face-name.pngbin0 -> 362231 bytes
-rw-r--r--examples/quick3d/textures/button/face-name.xcfbin0 -> 818498 bytes
-rw-r--r--examples/quick3d/textures/button/face.pngbin0 -> 318905 bytes
-rw-r--r--examples/quick3d/textures/button/full-address.pngbin0 -> 48485 bytes
-rw-r--r--examples/quick3d/textures/button/full-address.xcfbin0 -> 57519 bytes
-rw-r--r--examples/quick3d/textures/button/woman-photo-credit.txt5
-rw-r--r--examples/quick3d/textures/button/woman.jpgbin0 -> 83973 bytes
-rw-r--r--examples/quick3d/textures/main.cpp60
-rw-r--r--examples/quick3d/textures/photos/background.jpgbin0 -> 159108 bytes
-rw-r--r--examples/quick3d/textures/photos/niagara_falls.jpgbin0 -> 139646 bytes
-rw-r--r--examples/quick3d/textures/photos/place.jpgbin0 -> 62438 bytes
-rw-r--r--examples/quick3d/textures/qtlogo.pngbin0 -> 13923 bytes
-rw-r--r--examples/quick3d/textures/textures.pro4
212 files changed, 3367 insertions, 1 deletions
diff --git a/examples/examples.pro b/examples/examples.pro
index a25bb6e91..b008b37d8 100644
--- a/examples/examples.pro
+++ b/examples/examples.pro
@@ -1,2 +1,2 @@
TEMPLATE = subdirs
-SUBDIRS += basket builder cube cylinder geometry graphicsview nesting tank teapot tutorials
+SUBDIRS += quick3d qt3d
diff --git a/examples/qt3d/README b/examples/qt3d/README
new file mode 100644
index 000000000..2a45154d9
--- /dev/null
+++ b/examples/qt3d/README
@@ -0,0 +1,14 @@
+This directory contains examples for the Qt3D C++ API.
+
+Qt3D can be used to extend Qt Quick3D with custom 3D items. Qt3D is also
+a general 3D toolkit, featuring a scenegraph API, support for OpenGL VBO's
+and other utilities for general 3D programming.
+
+Research work on Qt3D also continues in the labs repository:
+
+ http://qt.gitorious.org/qt-labs/qt3d
+
+...and is from time to time ported into Qt Quick3D.
+
+Check the labs version of Qt3D for additional cutting edge features such as
+support for stereoscopic hardware.
diff --git a/examples/basket/README b/examples/qt3d/basket/README
index 560fd74c5..560fd74c5 100644
--- a/examples/basket/README
+++ b/examples/qt3d/basket/README
diff --git a/examples/basket/basket.jpg b/examples/qt3d/basket/basket.jpg
index 438e7a0c2..438e7a0c2 100644
--- a/examples/basket/basket.jpg
+++ b/examples/qt3d/basket/basket.jpg
Binary files differ
diff --git a/examples/basket/basket.pro b/examples/qt3d/basket/basket.pro
index 8c24581b0..8c24581b0 100644
--- a/examples/basket/basket.pro
+++ b/examples/qt3d/basket/basket.pro
diff --git a/examples/basket/basket.qrc b/examples/qt3d/basket/basket.qrc
index 590b65c7a..590b65c7a 100644
--- a/examples/basket/basket.qrc
+++ b/examples/qt3d/basket/basket.qrc
diff --git a/examples/basket/basket_data.h b/examples/qt3d/basket/basket_data.h
index d456a6924..d456a6924 100644
--- a/examples/basket/basket_data.h
+++ b/examples/qt3d/basket/basket_data.h
diff --git a/examples/basket/basket_data.txt b/examples/qt3d/basket/basket_data.txt
index 6b693b5a7..6b693b5a7 100644
--- a/examples/basket/basket_data.txt
+++ b/examples/qt3d/basket/basket_data.txt
diff --git a/examples/basket/basketview.cpp b/examples/qt3d/basket/basketview.cpp
index 41b20dfbb..41b20dfbb 100644
--- a/examples/basket/basketview.cpp
+++ b/examples/qt3d/basket/basketview.cpp
diff --git a/examples/basket/basketview.h b/examples/qt3d/basket/basketview.h
index 03a8d61fd..03a8d61fd 100644
--- a/examples/basket/basketview.h
+++ b/examples/qt3d/basket/basketview.h
diff --git a/examples/basket/main.cpp b/examples/qt3d/basket/main.cpp
index c8d28193d..c8d28193d 100644
--- a/examples/basket/main.cpp
+++ b/examples/qt3d/basket/main.cpp
diff --git a/examples/builder/builder.cpp b/examples/qt3d/builder/builder.cpp
index 3628b4d43..3628b4d43 100644
--- a/examples/builder/builder.cpp
+++ b/examples/qt3d/builder/builder.cpp
diff --git a/examples/builder/builder.h b/examples/qt3d/builder/builder.h
index a54dea6bf..a54dea6bf 100644
--- a/examples/builder/builder.h
+++ b/examples/qt3d/builder/builder.h
diff --git a/examples/builder/builder.pro b/examples/qt3d/builder/builder.pro
index 2fac6f330..2fac6f330 100644
--- a/examples/builder/builder.pro
+++ b/examples/qt3d/builder/builder.pro
diff --git a/examples/builder/builder.qrc b/examples/qt3d/builder/builder.qrc
index 8eefbaf1d..8eefbaf1d 100644
--- a/examples/builder/builder.qrc
+++ b/examples/qt3d/builder/builder.qrc
diff --git a/examples/builder/main.cpp b/examples/qt3d/builder/main.cpp
index ade7d1008..ade7d1008 100644
--- a/examples/builder/main.cpp
+++ b/examples/qt3d/builder/main.cpp
diff --git a/examples/builder/qt-soup.png b/examples/qt3d/builder/qt-soup.png
index 5b264fffa..5b264fffa 100644
--- a/examples/builder/qt-soup.png
+++ b/examples/qt3d/builder/qt-soup.png
Binary files differ
diff --git a/examples/cube/cube.pro b/examples/qt3d/cube/cube.pro
index ec2bc6967..ec2bc6967 100644
--- a/examples/cube/cube.pro
+++ b/examples/qt3d/cube/cube.pro
diff --git a/examples/cube/cube.qrc b/examples/qt3d/cube/cube.qrc
index 70f5024d9..70f5024d9 100644
--- a/examples/cube/cube.qrc
+++ b/examples/qt3d/cube/cube.qrc
diff --git a/examples/cube/cubeview.cpp b/examples/qt3d/cube/cubeview.cpp
index e8de75168..e8de75168 100644
--- a/examples/cube/cubeview.cpp
+++ b/examples/qt3d/cube/cubeview.cpp
diff --git a/examples/cube/cubeview.h b/examples/qt3d/cube/cubeview.h
index 8996fd342..8996fd342 100644
--- a/examples/cube/cubeview.h
+++ b/examples/qt3d/cube/cubeview.h
diff --git a/examples/cube/main.cpp b/examples/qt3d/cube/main.cpp
index 1def235d5..1def235d5 100644
--- a/examples/cube/main.cpp
+++ b/examples/qt3d/cube/main.cpp
diff --git a/examples/cube/qtlogo.png b/examples/qt3d/cube/qtlogo.png
index 7d3e97eb3..7d3e97eb3 100644
--- a/examples/cube/qtlogo.png
+++ b/examples/qt3d/cube/qtlogo.png
Binary files differ
diff --git a/examples/cylinder/cubeview.cpp b/examples/qt3d/cylinder/cubeview.cpp
index 4569caeb0..4569caeb0 100644
--- a/examples/cylinder/cubeview.cpp
+++ b/examples/qt3d/cylinder/cubeview.cpp
diff --git a/examples/cylinder/cubeview.h b/examples/qt3d/cylinder/cubeview.h
index 8996fd342..8996fd342 100644
--- a/examples/cylinder/cubeview.h
+++ b/examples/qt3d/cylinder/cubeview.h
diff --git a/examples/cylinder/cupTexture.png b/examples/qt3d/cylinder/cupTexture.png
index e099dea22..e099dea22 100644
--- a/examples/cylinder/cupTexture.png
+++ b/examples/qt3d/cylinder/cupTexture.png
Binary files differ
diff --git a/examples/cylinder/cylinder.pro b/examples/qt3d/cylinder/cylinder.pro
index ee018cb9d..ee018cb9d 100644
--- a/examples/cylinder/cylinder.pro
+++ b/examples/qt3d/cylinder/cylinder.pro
diff --git a/examples/cylinder/cylinder.qrc b/examples/qt3d/cylinder/cylinder.qrc
index 20fa400f7..20fa400f7 100644
--- a/examples/cylinder/cylinder.qrc
+++ b/examples/qt3d/cylinder/cylinder.qrc
diff --git a/examples/cylinder/cylinderview.cpp b/examples/qt3d/cylinder/cylinderview.cpp
index 2b347ab68..2b347ab68 100644
--- a/examples/cylinder/cylinderview.cpp
+++ b/examples/qt3d/cylinder/cylinderview.cpp
diff --git a/examples/cylinder/cylinderview.h b/examples/qt3d/cylinder/cylinderview.h
index c2f4824b9..c2f4824b9 100644
--- a/examples/cylinder/cylinderview.h
+++ b/examples/qt3d/cylinder/cylinderview.h
diff --git a/examples/cylinder/latte.png b/examples/qt3d/cylinder/latte.png
index 6902b96c6..6902b96c6 100644
--- a/examples/cylinder/latte.png
+++ b/examples/qt3d/cylinder/latte.png
Binary files differ
diff --git a/examples/cylinder/main.cpp b/examples/qt3d/cylinder/main.cpp
index 5ea06b74e..5ea06b74e 100644
--- a/examples/cylinder/main.cpp
+++ b/examples/qt3d/cylinder/main.cpp
diff --git a/examples/geometry/EarthFlat_512x512.jpg b/examples/qt3d/geometry/EarthFlat_512x512.jpg
index 28864977b..28864977b 100644
--- a/examples/geometry/EarthFlat_512x512.jpg
+++ b/examples/qt3d/geometry/EarthFlat_512x512.jpg
Binary files differ
diff --git a/examples/geometry/bullseye.png b/examples/qt3d/geometry/bullseye.png
index e67cf7038..e67cf7038 100644
--- a/examples/geometry/bullseye.png
+++ b/examples/qt3d/geometry/bullseye.png
Binary files differ
diff --git a/examples/geometry/geometry.cpp b/examples/qt3d/geometry/geometry.cpp
index c8f262c14..c8f262c14 100644
--- a/examples/geometry/geometry.cpp
+++ b/examples/qt3d/geometry/geometry.cpp
diff --git a/examples/geometry/geometry.h b/examples/qt3d/geometry/geometry.h
index f9a356fc8..f9a356fc8 100644
--- a/examples/geometry/geometry.h
+++ b/examples/qt3d/geometry/geometry.h
diff --git a/examples/geometry/geometry.pro b/examples/qt3d/geometry/geometry.pro
index 66025be88..66025be88 100644
--- a/examples/geometry/geometry.pro
+++ b/examples/qt3d/geometry/geometry.pro
diff --git a/examples/geometry/geometry.qrc b/examples/qt3d/geometry/geometry.qrc
index 4599a46ad..4599a46ad 100644
--- a/examples/geometry/geometry.qrc
+++ b/examples/qt3d/geometry/geometry.qrc
diff --git a/examples/geometry/geometryview.cpp b/examples/qt3d/geometry/geometryview.cpp
index 762e56fcd..762e56fcd 100644
--- a/examples/geometry/geometryview.cpp
+++ b/examples/qt3d/geometry/geometryview.cpp
diff --git a/examples/geometry/geometryview.h b/examples/qt3d/geometry/geometryview.h
index 822a7a409..822a7a409 100644
--- a/examples/geometry/geometryview.h
+++ b/examples/qt3d/geometry/geometryview.h
diff --git a/examples/geometry/main.cpp b/examples/qt3d/geometry/main.cpp
index 9ec88be7b..9ec88be7b 100644
--- a/examples/geometry/main.cpp
+++ b/examples/qt3d/geometry/main.cpp
diff --git a/examples/geometry/quadplane.cpp b/examples/qt3d/geometry/quadplane.cpp
index 3387002bc..3387002bc 100644
--- a/examples/geometry/quadplane.cpp
+++ b/examples/qt3d/geometry/quadplane.cpp
diff --git a/examples/geometry/quadplane.h b/examples/qt3d/geometry/quadplane.h
index e95d1907f..e95d1907f 100644
--- a/examples/geometry/quadplane.h
+++ b/examples/qt3d/geometry/quadplane.h
diff --git a/examples/graphicsview/cubeicon.png b/examples/qt3d/graphicsview/cubeicon.png
index 9979fb582..9979fb582 100644
--- a/examples/graphicsview/cubeicon.png
+++ b/examples/qt3d/graphicsview/cubeicon.png
Binary files differ
diff --git a/examples/graphicsview/cubeitem.cpp b/examples/qt3d/graphicsview/cubeitem.cpp
index 10c7609f8..10c7609f8 100644
--- a/examples/graphicsview/cubeitem.cpp
+++ b/examples/qt3d/graphicsview/cubeitem.cpp
diff --git a/examples/graphicsview/cubeitem.h b/examples/qt3d/graphicsview/cubeitem.h
index 67b4aa257..67b4aa257 100644
--- a/examples/graphicsview/cubeitem.h
+++ b/examples/qt3d/graphicsview/cubeitem.h
diff --git a/examples/graphicsview/edge.cpp b/examples/qt3d/graphicsview/edge.cpp
index bf480ec4b..bf480ec4b 100644
--- a/examples/graphicsview/edge.cpp
+++ b/examples/qt3d/graphicsview/edge.cpp
diff --git a/examples/graphicsview/edge.h b/examples/qt3d/graphicsview/edge.h
index d50c403a9..d50c403a9 100644
--- a/examples/graphicsview/edge.h
+++ b/examples/qt3d/graphicsview/edge.h
diff --git a/examples/graphicsview/graph.cpp b/examples/qt3d/graphicsview/graph.cpp
index 2aa28b107..2aa28b107 100644
--- a/examples/graphicsview/graph.cpp
+++ b/examples/qt3d/graphicsview/graph.cpp
diff --git a/examples/graphicsview/graph.h b/examples/qt3d/graphicsview/graph.h
index 0fa897ce8..0fa897ce8 100644
--- a/examples/graphicsview/graph.h
+++ b/examples/qt3d/graphicsview/graph.h
diff --git a/examples/graphicsview/graphicsview.pro b/examples/qt3d/graphicsview/graphicsview.pro
index 98aba411d..98aba411d 100644
--- a/examples/graphicsview/graphicsview.pro
+++ b/examples/qt3d/graphicsview/graphicsview.pro
diff --git a/examples/graphicsview/graphicsview.qrc b/examples/qt3d/graphicsview/graphicsview.qrc
index 37a99a114..37a99a114 100644
--- a/examples/graphicsview/graphicsview.qrc
+++ b/examples/qt3d/graphicsview/graphicsview.qrc
diff --git a/examples/graphicsview/main.cpp b/examples/qt3d/graphicsview/main.cpp
index 39a3d7a08..39a3d7a08 100644
--- a/examples/graphicsview/main.cpp
+++ b/examples/qt3d/graphicsview/main.cpp
diff --git a/examples/graphicsview/modelitem.cpp b/examples/qt3d/graphicsview/modelitem.cpp
index 41ba13833..41ba13833 100644
--- a/examples/graphicsview/modelitem.cpp
+++ b/examples/qt3d/graphicsview/modelitem.cpp
diff --git a/examples/graphicsview/modelitem.h b/examples/qt3d/graphicsview/modelitem.h
index 063cbb2b2..063cbb2b2 100644
--- a/examples/graphicsview/modelitem.h
+++ b/examples/qt3d/graphicsview/modelitem.h
diff --git a/examples/graphicsview/node.cpp b/examples/qt3d/graphicsview/node.cpp
index 4723b0ab4..4723b0ab4 100644
--- a/examples/graphicsview/node.cpp
+++ b/examples/qt3d/graphicsview/node.cpp
diff --git a/examples/graphicsview/node.h b/examples/qt3d/graphicsview/node.h
index 45208610a..45208610a 100644
--- a/examples/graphicsview/node.h
+++ b/examples/qt3d/graphicsview/node.h
diff --git a/examples/graphicsview/scene.cpp b/examples/qt3d/graphicsview/scene.cpp
index 5fe551058..5fe551058 100644
--- a/examples/graphicsview/scene.cpp
+++ b/examples/qt3d/graphicsview/scene.cpp
diff --git a/examples/graphicsview/scene.h b/examples/qt3d/graphicsview/scene.h
index 73be795a8..73be795a8 100644
--- a/examples/graphicsview/scene.h
+++ b/examples/qt3d/graphicsview/scene.h
diff --git a/examples/graphicsview/teapoticon.png b/examples/qt3d/graphicsview/teapoticon.png
index 17392361d..17392361d 100644
--- a/examples/graphicsview/teapoticon.png
+++ b/examples/qt3d/graphicsview/teapoticon.png
Binary files differ
diff --git a/examples/graphicsview/teapotitem.cpp b/examples/qt3d/graphicsview/teapotitem.cpp
index 72161a5a2..72161a5a2 100644
--- a/examples/graphicsview/teapotitem.cpp
+++ b/examples/qt3d/graphicsview/teapotitem.cpp
diff --git a/examples/graphicsview/teapotitem.h b/examples/qt3d/graphicsview/teapotitem.h
index f2706eeb1..f2706eeb1 100644
--- a/examples/graphicsview/teapotitem.h
+++ b/examples/qt3d/graphicsview/teapotitem.h
diff --git a/examples/graphicsview/view.cpp b/examples/qt3d/graphicsview/view.cpp
index 73f4bb6c9..73f4bb6c9 100644
--- a/examples/graphicsview/view.cpp
+++ b/examples/qt3d/graphicsview/view.cpp
diff --git a/examples/graphicsview/view.h b/examples/qt3d/graphicsview/view.h
index f47a7249b..f47a7249b 100644
--- a/examples/graphicsview/view.h
+++ b/examples/qt3d/graphicsview/view.h
diff --git a/examples/nesting/cubeview.cpp b/examples/qt3d/nesting/cubeview.cpp
index d14b5048e..d14b5048e 100644
--- a/examples/nesting/cubeview.cpp
+++ b/examples/qt3d/nesting/cubeview.cpp
diff --git a/examples/nesting/cubeview.h b/examples/qt3d/nesting/cubeview.h
index 1fae5de4d..1fae5de4d 100644
--- a/examples/nesting/cubeview.h
+++ b/examples/qt3d/nesting/cubeview.h
diff --git a/examples/nesting/main.cpp b/examples/qt3d/nesting/main.cpp
index f3d5764d0..f3d5764d0 100644
--- a/examples/nesting/main.cpp
+++ b/examples/qt3d/nesting/main.cpp
diff --git a/examples/nesting/nesting.pro b/examples/qt3d/nesting/nesting.pro
index 0ea63d333..0ea63d333 100644
--- a/examples/nesting/nesting.pro
+++ b/examples/qt3d/nesting/nesting.pro
diff --git a/examples/nesting/nesting.qrc b/examples/qt3d/nesting/nesting.qrc
index 70f5024d9..70f5024d9 100644
--- a/examples/nesting/nesting.qrc
+++ b/examples/qt3d/nesting/nesting.qrc
diff --git a/examples/nesting/qtlogo.png b/examples/qt3d/nesting/qtlogo.png
index 7d3e97eb3..7d3e97eb3 100644
--- a/examples/nesting/qtlogo.png
+++ b/examples/qt3d/nesting/qtlogo.png
Binary files differ
diff --git a/examples/qt3d/qt3d.pro b/examples/qt3d/qt3d.pro
new file mode 100644
index 000000000..a25bb6e91
--- /dev/null
+++ b/examples/qt3d/qt3d.pro
@@ -0,0 +1,2 @@
+TEMPLATE = subdirs
+SUBDIRS += basket builder cube cylinder geometry graphicsview nesting tank teapot tutorials
diff --git a/examples/tank/main.cpp b/examples/qt3d/tank/main.cpp
index ee9c1429b..ee9c1429b 100644
--- a/examples/tank/main.cpp
+++ b/examples/qt3d/tank/main.cpp
diff --git a/examples/tank/quadplane.cpp b/examples/qt3d/tank/quadplane.cpp
index fb3cf16b7..fb3cf16b7 100644
--- a/examples/tank/quadplane.cpp
+++ b/examples/qt3d/tank/quadplane.cpp
diff --git a/examples/tank/quadplane.h b/examples/qt3d/tank/quadplane.h
index 2ffc1963a..2ffc1963a 100644
--- a/examples/tank/quadplane.h
+++ b/examples/qt3d/tank/quadplane.h
diff --git a/examples/tank/tank.cpp b/examples/qt3d/tank/tank.cpp
index fe4fa8e8b..fe4fa8e8b 100644
--- a/examples/tank/tank.cpp
+++ b/examples/qt3d/tank/tank.cpp
diff --git a/examples/tank/tank.h b/examples/qt3d/tank/tank.h
index 894496404..894496404 100644
--- a/examples/tank/tank.h
+++ b/examples/qt3d/tank/tank.h
diff --git a/examples/tank/tank.pro b/examples/qt3d/tank/tank.pro
index 50b916ff6..50b916ff6 100644
--- a/examples/tank/tank.pro
+++ b/examples/qt3d/tank/tank.pro
diff --git a/examples/tank/tankview.cpp b/examples/qt3d/tank/tankview.cpp
index 9d4d7afbc..9d4d7afbc 100644
--- a/examples/tank/tankview.cpp
+++ b/examples/qt3d/tank/tankview.cpp
diff --git a/examples/tank/tankview.h b/examples/qt3d/tank/tankview.h
index 38b966158..38b966158 100644
--- a/examples/tank/tankview.h
+++ b/examples/qt3d/tank/tankview.h
diff --git a/examples/teapot/main.cpp b/examples/qt3d/teapot/main.cpp
index e14a10306..e14a10306 100644
--- a/examples/teapot/main.cpp
+++ b/examples/qt3d/teapot/main.cpp
diff --git a/examples/teapot/teapot.pro b/examples/qt3d/teapot/teapot.pro
index 1024f6a72..1024f6a72 100644
--- a/examples/teapot/teapot.pro
+++ b/examples/qt3d/teapot/teapot.pro
diff --git a/examples/teapot/teapotview.cpp b/examples/qt3d/teapot/teapotview.cpp
index 2ffe53a34..2ffe53a34 100644
--- a/examples/teapot/teapotview.cpp
+++ b/examples/qt3d/teapot/teapotview.cpp
diff --git a/examples/teapot/teapotview.h b/examples/qt3d/teapot/teapotview.h
index d251f990a..d251f990a 100644
--- a/examples/teapot/teapotview.h
+++ b/examples/qt3d/teapot/teapotview.h
diff --git a/examples/tutorials/converting-rawgl/converting-rawgl.pro b/examples/qt3d/tutorials/converting-rawgl/converting-rawgl.pro
index 8263b9a7d..8263b9a7d 100644
--- a/examples/tutorials/converting-rawgl/converting-rawgl.pro
+++ b/examples/qt3d/tutorials/converting-rawgl/converting-rawgl.pro
diff --git a/examples/tutorials/converting/converting-rawgl.cpp b/examples/qt3d/tutorials/converting/converting-rawgl.cpp
index e65abd3a9..e65abd3a9 100644
--- a/examples/tutorials/converting/converting-rawgl.cpp
+++ b/examples/qt3d/tutorials/converting/converting-rawgl.cpp
diff --git a/examples/tutorials/converting/converting.cpp b/examples/qt3d/tutorials/converting/converting.cpp
index 51c47ffa8..51c47ffa8 100644
--- a/examples/tutorials/converting/converting.cpp
+++ b/examples/qt3d/tutorials/converting/converting.cpp
diff --git a/examples/tutorials/converting/converting.pro b/examples/qt3d/tutorials/converting/converting.pro
index b4febdaa5..b4febdaa5 100644
--- a/examples/tutorials/converting/converting.pro
+++ b/examples/qt3d/tutorials/converting/converting.pro
diff --git a/examples/tutorials/cube1/cube1.pro b/examples/qt3d/tutorials/cube1/cube1.pro
index 51df0efe0..51df0efe0 100644
--- a/examples/tutorials/cube1/cube1.pro
+++ b/examples/qt3d/tutorials/cube1/cube1.pro
diff --git a/examples/tutorials/cube1/cubeview.cpp b/examples/qt3d/tutorials/cube1/cubeview.cpp
index 51e074f62..51e074f62 100644
--- a/examples/tutorials/cube1/cubeview.cpp
+++ b/examples/qt3d/tutorials/cube1/cubeview.cpp
diff --git a/examples/tutorials/cube1/cubeview.h b/examples/qt3d/tutorials/cube1/cubeview.h
index 04238f58d..04238f58d 100644
--- a/examples/tutorials/cube1/cubeview.h
+++ b/examples/qt3d/tutorials/cube1/cubeview.h
diff --git a/examples/tutorials/cube1/main.cpp b/examples/qt3d/tutorials/cube1/main.cpp
index 28fc9bb15..28fc9bb15 100644
--- a/examples/tutorials/cube1/main.cpp
+++ b/examples/qt3d/tutorials/cube1/main.cpp
diff --git a/examples/tutorials/cube2/cube2.pro b/examples/qt3d/tutorials/cube2/cube2.pro
index 3bf258831..3bf258831 100644
--- a/examples/tutorials/cube2/cube2.pro
+++ b/examples/qt3d/tutorials/cube2/cube2.pro
diff --git a/examples/tutorials/cube2/cubeview.cpp b/examples/qt3d/tutorials/cube2/cubeview.cpp
index 1dca459a8..1dca459a8 100644
--- a/examples/tutorials/cube2/cubeview.cpp
+++ b/examples/qt3d/tutorials/cube2/cubeview.cpp
diff --git a/examples/tutorials/cube2/cubeview.h b/examples/qt3d/tutorials/cube2/cubeview.h
index 04238f58d..04238f58d 100644
--- a/examples/tutorials/cube2/cubeview.h
+++ b/examples/qt3d/tutorials/cube2/cubeview.h
diff --git a/examples/tutorials/cube2/main.cpp b/examples/qt3d/tutorials/cube2/main.cpp
index 28fc9bb15..28fc9bb15 100644
--- a/examples/tutorials/cube2/main.cpp
+++ b/examples/qt3d/tutorials/cube2/main.cpp
diff --git a/examples/tutorials/cube3/cube3.pro b/examples/qt3d/tutorials/cube3/cube3.pro
index 70b049fe2..70b049fe2 100644
--- a/examples/tutorials/cube3/cube3.pro
+++ b/examples/qt3d/tutorials/cube3/cube3.pro
diff --git a/examples/tutorials/cube3/cubeview.cpp b/examples/qt3d/tutorials/cube3/cubeview.cpp
index 80c3e0f1a..80c3e0f1a 100644
--- a/examples/tutorials/cube3/cubeview.cpp
+++ b/examples/qt3d/tutorials/cube3/cubeview.cpp
diff --git a/examples/tutorials/cube3/cubeview.h b/examples/qt3d/tutorials/cube3/cubeview.h
index 04238f58d..04238f58d 100644
--- a/examples/tutorials/cube3/cubeview.h
+++ b/examples/qt3d/tutorials/cube3/cubeview.h
diff --git a/examples/tutorials/cube3/main.cpp b/examples/qt3d/tutorials/cube3/main.cpp
index 28fc9bb15..28fc9bb15 100644
--- a/examples/tutorials/cube3/main.cpp
+++ b/examples/qt3d/tutorials/cube3/main.cpp
diff --git a/examples/tutorials/cube4/cube.qml b/examples/qt3d/tutorials/cube4/cube.qml
index d4ba6d995..d4ba6d995 100644
--- a/examples/tutorials/cube4/cube.qml
+++ b/examples/qt3d/tutorials/cube4/cube.qml
diff --git a/examples/tutorials/cube4/cube.qrc b/examples/qt3d/tutorials/cube4/cube.qrc
index 70f5024d9..70f5024d9 100644
--- a/examples/tutorials/cube4/cube.qrc
+++ b/examples/qt3d/tutorials/cube4/cube.qrc
diff --git a/examples/tutorials/cube4/cube4.pro b/examples/qt3d/tutorials/cube4/cube4.pro
index a2f4ba79c..a2f4ba79c 100644
--- a/examples/tutorials/cube4/cube4.pro
+++ b/examples/qt3d/tutorials/cube4/cube4.pro
diff --git a/examples/tutorials/cube4/cubeview.cpp b/examples/qt3d/tutorials/cube4/cubeview.cpp
index e3045292b..e3045292b 100644
--- a/examples/tutorials/cube4/cubeview.cpp
+++ b/examples/qt3d/tutorials/cube4/cubeview.cpp
diff --git a/examples/tutorials/cube4/cubeview.h b/examples/qt3d/tutorials/cube4/cubeview.h
index 4f00216ca..4f00216ca 100644
--- a/examples/tutorials/cube4/cubeview.h
+++ b/examples/qt3d/tutorials/cube4/cubeview.h
diff --git a/examples/tutorials/cube4/main.cpp b/examples/qt3d/tutorials/cube4/main.cpp
index 28fc9bb15..28fc9bb15 100644
--- a/examples/tutorials/cube4/main.cpp
+++ b/examples/qt3d/tutorials/cube4/main.cpp
diff --git a/examples/tutorials/cube4/qtlogo.png b/examples/qt3d/tutorials/cube4/qtlogo.png
index 7d3e97eb3..7d3e97eb3 100644
--- a/examples/tutorials/cube4/qtlogo.png
+++ b/examples/qt3d/tutorials/cube4/qtlogo.png
Binary files differ
diff --git a/examples/tutorials/penguin/main.cpp b/examples/qt3d/tutorials/penguin/main.cpp
index e5c995db3..e5c995db3 100644
--- a/examples/tutorials/penguin/main.cpp
+++ b/examples/qt3d/tutorials/penguin/main.cpp
diff --git a/examples/tutorials/penguin/model.qrc b/examples/qt3d/tutorials/penguin/model.qrc
index 2c330de09..2c330de09 100644
--- a/examples/tutorials/penguin/model.qrc
+++ b/examples/qt3d/tutorials/penguin/model.qrc
diff --git a/examples/tutorials/penguin/modelview.cpp b/examples/qt3d/tutorials/penguin/modelview.cpp
index 3ba6b7355..3ba6b7355 100644
--- a/examples/tutorials/penguin/modelview.cpp
+++ b/examples/qt3d/tutorials/penguin/modelview.cpp
diff --git a/examples/tutorials/penguin/modelview.h b/examples/qt3d/tutorials/penguin/modelview.h
index 978b185f8..978b185f8 100644
--- a/examples/tutorials/penguin/modelview.h
+++ b/examples/qt3d/tutorials/penguin/modelview.h
diff --git a/examples/tutorials/penguin/penguin.3ds b/examples/qt3d/tutorials/penguin/penguin.3ds
index 26c09ac07..26c09ac07 100644
--- a/examples/tutorials/penguin/penguin.3ds
+++ b/examples/qt3d/tutorials/penguin/penguin.3ds
Binary files differ
diff --git a/examples/tutorials/penguin/penguin.pro b/examples/qt3d/tutorials/penguin/penguin.pro
index f35c1cd4e..f35c1cd4e 100644
--- a/examples/tutorials/penguin/penguin.pro
+++ b/examples/qt3d/tutorials/penguin/penguin.pro
diff --git a/examples/tutorials/penguin_advanced/main.cpp b/examples/qt3d/tutorials/penguin_advanced/main.cpp
index e5c995db3..e5c995db3 100644
--- a/examples/tutorials/penguin_advanced/main.cpp
+++ b/examples/qt3d/tutorials/penguin_advanced/main.cpp
diff --git a/examples/tutorials/penguin_advanced/model_advanced.qrc b/examples/qt3d/tutorials/penguin_advanced/model_advanced.qrc
index 2c330de09..2c330de09 100644
--- a/examples/tutorials/penguin_advanced/model_advanced.qrc
+++ b/examples/qt3d/tutorials/penguin_advanced/model_advanced.qrc
diff --git a/examples/tutorials/penguin_advanced/modelview.cpp b/examples/qt3d/tutorials/penguin_advanced/modelview.cpp
index a72495331..a72495331 100644
--- a/examples/tutorials/penguin_advanced/modelview.cpp
+++ b/examples/qt3d/tutorials/penguin_advanced/modelview.cpp
diff --git a/examples/tutorials/penguin_advanced/modelview.h b/examples/qt3d/tutorials/penguin_advanced/modelview.h
index 38b4340cc..38b4340cc 100644
--- a/examples/tutorials/penguin_advanced/modelview.h
+++ b/examples/qt3d/tutorials/penguin_advanced/modelview.h
diff --git a/examples/tutorials/penguin_advanced/penguin.3ds b/examples/qt3d/tutorials/penguin_advanced/penguin.3ds
index 26c09ac07..26c09ac07 100644
--- a/examples/tutorials/penguin_advanced/penguin.3ds
+++ b/examples/qt3d/tutorials/penguin_advanced/penguin.3ds
Binary files differ
diff --git a/examples/tutorials/penguin_advanced/penguin_advanced.pro b/examples/qt3d/tutorials/penguin_advanced/penguin_advanced.pro
index 079c5f5b0..079c5f5b0 100644
--- a/examples/tutorials/penguin_advanced/penguin_advanced.pro
+++ b/examples/qt3d/tutorials/penguin_advanced/penguin_advanced.pro
diff --git a/examples/tutorials/shaders/TutorialTeapot.qml b/examples/qt3d/tutorials/shaders/TutorialTeapot.qml
index 5f2c29e08..5f2c29e08 100644
--- a/examples/tutorials/shaders/TutorialTeapot.qml
+++ b/examples/qt3d/tutorials/shaders/TutorialTeapot.qml
diff --git a/examples/tutorials/shaders/meshes b/examples/qt3d/tutorials/shaders/meshes
index 3bc225c36..3bc225c36 120000
--- a/examples/tutorials/shaders/meshes
+++ b/examples/qt3d/tutorials/shaders/meshes
diff --git a/examples/tutorials/shaders/shader-tutorial-1-textures.qml b/examples/qt3d/tutorials/shaders/shader-tutorial-1-textures.qml
index 081a94c0f..081a94c0f 100644
--- a/examples/tutorials/shaders/shader-tutorial-1-textures.qml
+++ b/examples/qt3d/tutorials/shaders/shader-tutorial-1-textures.qml
diff --git a/examples/tutorials/shaders/shader-tutorial-2-vertex-shader.qml b/examples/qt3d/tutorials/shaders/shader-tutorial-2-vertex-shader.qml
index 37f9ddfde..37f9ddfde 100644
--- a/examples/tutorials/shaders/shader-tutorial-2-vertex-shader.qml
+++ b/examples/qt3d/tutorials/shaders/shader-tutorial-2-vertex-shader.qml
diff --git a/examples/tutorials/shaders/shader-tutorial-3-transformed-coordinates.qml b/examples/qt3d/tutorials/shaders/shader-tutorial-3-transformed-coordinates.qml
index 6b3595c5d..6b3595c5d 100644
--- a/examples/tutorials/shaders/shader-tutorial-3-transformed-coordinates.qml
+++ b/examples/qt3d/tutorials/shaders/shader-tutorial-3-transformed-coordinates.qml
diff --git a/examples/tutorials/shaders/shader-tutorial-lighting.qml b/examples/qt3d/tutorials/shaders/shader-tutorial-lighting.qml
index 94bcee74d..94bcee74d 100644
--- a/examples/tutorials/shaders/shader-tutorial-lighting.qml
+++ b/examples/qt3d/tutorials/shaders/shader-tutorial-lighting.qml
diff --git a/examples/tutorials/shaders/shader-tutorial-varying.qml b/examples/qt3d/tutorials/shaders/shader-tutorial-varying.qml
index 3341bb7b5..3341bb7b5 100644
--- a/examples/tutorials/shaders/shader-tutorial-varying.qml
+++ b/examples/qt3d/tutorials/shaders/shader-tutorial-varying.qml
diff --git a/examples/tutorials/shaders/shader-tutorial.qml b/examples/qt3d/tutorials/shaders/shader-tutorial.qml
index 37d379bb8..37d379bb8 100644
--- a/examples/tutorials/shaders/shader-tutorial.qml
+++ b/examples/qt3d/tutorials/shaders/shader-tutorial.qml
diff --git a/examples/tutorials/shaders/shaders.pro b/examples/qt3d/tutorials/shaders/shaders.pro
index 05755ad8a..05755ad8a 100644
--- a/examples/tutorials/shaders/shaders.pro
+++ b/examples/qt3d/tutorials/shaders/shaders.pro
diff --git a/examples/tutorials/shaders/shaders.qmlproject b/examples/qt3d/tutorials/shaders/shaders.qmlproject
index d4909f868..d4909f868 100644
--- a/examples/tutorials/shaders/shaders.qmlproject
+++ b/examples/qt3d/tutorials/shaders/shaders.qmlproject
diff --git a/examples/tutorials/shaders/textures/basket.jpg b/examples/qt3d/tutorials/shaders/textures/basket.jpg
index b23d4eec4..b23d4eec4 120000
--- a/examples/tutorials/shaders/textures/basket.jpg
+++ b/examples/qt3d/tutorials/shaders/textures/basket.jpg
diff --git a/examples/tutorials/shaders/textures/qtlogo.png b/examples/qt3d/tutorials/shaders/textures/qtlogo.png
index b8b931c8b..b8b931c8b 120000
--- a/examples/tutorials/shaders/textures/qtlogo.png
+++ b/examples/qt3d/tutorials/shaders/textures/qtlogo.png
diff --git a/examples/tutorials/teapot-qml/teapot-bounce.qml b/examples/qt3d/tutorials/teapot-qml/teapot-bounce.qml
index 7a9e61e69..7a9e61e69 100644
--- a/examples/tutorials/teapot-qml/teapot-bounce.qml
+++ b/examples/qt3d/tutorials/teapot-qml/teapot-bounce.qml
diff --git a/examples/tutorials/teapot-qml/teapot-qml.qmlproject b/examples/qt3d/tutorials/teapot-qml/teapot-qml.qmlproject
index d4909f868..d4909f868 100644
--- a/examples/tutorials/teapot-qml/teapot-qml.qmlproject
+++ b/examples/qt3d/tutorials/teapot-qml/teapot-qml.qmlproject
diff --git a/examples/tutorials/teapot-qml/teapot.bez b/examples/qt3d/tutorials/teapot-qml/teapot.bez
index 02b2ac447..02b2ac447 100644
--- a/examples/tutorials/teapot-qml/teapot.bez
+++ b/examples/qt3d/tutorials/teapot-qml/teapot.bez
diff --git a/examples/tutorials/teapot-qml/teapot.qml b/examples/qt3d/tutorials/teapot-qml/teapot.qml
index 97e0bdf56..97e0bdf56 100644
--- a/examples/tutorials/teapot-qml/teapot.qml
+++ b/examples/qt3d/tutorials/teapot-qml/teapot.qml
diff --git a/examples/tutorials/tutorials.pro b/examples/qt3d/tutorials/tutorials.pro
index 8c3fdf364..8c3fdf364 100644
--- a/examples/tutorials/tutorials.pro
+++ b/examples/qt3d/tutorials/tutorials.pro
diff --git a/examples/quick3d/basket/basket.pro b/examples/quick3d/basket/basket.pro
new file mode 100644
index 000000000..da107aa20
--- /dev/null
+++ b/examples/quick3d/basket/basket.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+QML_IMPORT_PATH = $$[QT_INSTALL_IMPORTS]/Qt3D
+SOURCES += main.cpp
diff --git a/examples/quick3d/basket/main.cpp b/examples/quick3d/basket/main.cpp
new file mode 100644
index 000000000..33093a986
--- /dev/null
+++ b/examples/quick3d/basket/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/basket.qml")));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/basket/qml/basket.qml b/examples/quick3d/basket/qml/basket.qml
new file mode 100644
index 000000000..910cc146b
--- /dev/null
+++ b/examples/quick3d/basket/qml/basket.qml
@@ -0,0 +1,74 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+//! [1]
+import Qt 4.7
+import Qt3D 1.0
+
+Viewport {
+ width: 640; height: 480
+
+ camera: Camera {
+ eye: Qt.vector3d(0, 4, 10)
+ }
+//! [1]
+
+//! [2]
+ Item3D {
+ mesh: Mesh { source: "meshes/basket.bez" }
+ effect: Effect { texture: "textures/basket.jpg" }
+//! [2]
+//! [3]
+ transform: [
+ Scale3D { scale: 1.5 },
+ Rotation3D {
+ axis: Qt.vector3d(0, 1, 0)
+ NumberAnimation on angle {
+ running: true
+ loops: Animation.Infinite
+ from: 0
+ to: 360
+ duration: 2000
+ }
+ }
+ ]
+ }
+}
+//! [3]
diff --git a/examples/quick3d/bounce/bounce.pro b/examples/quick3d/bounce/bounce.pro
new file mode 100644
index 000000000..dbae98a47
--- /dev/null
+++ b/examples/quick3d/bounce/bounce.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+
+SOURCES += main.cpp
diff --git a/examples/quick3d/bounce/main.cpp b/examples/quick3d/bounce/main.cpp
new file mode 100644
index 000000000..c9fd2f1b9
--- /dev/null
+++ b/examples/quick3d/bounce/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/bounce.qml")));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/bounce/qml/bounce.qml b/examples/quick3d/bounce/qml/bounce.qml
new file mode 100644
index 000000000..7abfe76d8
--- /dev/null
+++ b/examples/quick3d/bounce/qml/bounce.qml
@@ -0,0 +1,69 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+
+Viewport {
+ width: 640; height: 480
+
+ Item3D {
+ id: teapot
+ mesh: Mesh { source: "meshes/teapot.bez" }
+ effect: Effect {
+ material: china
+ }
+
+ SequentialAnimation on y{
+ running: true
+ loops: Animation.Infinite
+ PauseAnimation { duration: 500 }
+ NumberAnimation { to : 1.0; duration: 300; easing.type:"OutQuad" }
+ NumberAnimation { to : 0.0; duration: 300; easing.type:"OutBounce" }
+ }
+
+ Material {
+ id: china
+ ambientColor: "#c09680"
+ specularColor: "#3c3c3c"
+ shininess: 128
+ }
+ }
+}
diff --git a/examples/quick3d/cube/cube.pro b/examples/quick3d/cube/cube.pro
new file mode 100644
index 000000000..dbae98a47
--- /dev/null
+++ b/examples/quick3d/cube/cube.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+
+SOURCES += main.cpp
diff --git a/examples/quick3d/cube/main.cpp b/examples/quick3d/cube/main.cpp
new file mode 100644
index 000000000..c9e7fb7d5
--- /dev/null
+++ b/examples/quick3d/cube/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/cube.qml")));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/cube/qml/cube.qml b/examples/quick3d/cube/qml/cube.qml
new file mode 100644
index 000000000..11579dd28
--- /dev/null
+++ b/examples/quick3d/cube/qml/cube.qml
@@ -0,0 +1,62 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+import Qt3D.Shapes 1.0
+
+Viewport {
+ width: 640; height: 480
+
+ Cube {
+ scale: 1.5
+
+ transform: Rotation3D {
+ angle: 45
+ axis: Qt.vector3d(1, 1, 1)
+ }
+
+ effect: Effect {
+ color: "#aaca00"
+ texture: "textures/qtlogo.png"
+ decal: true
+ }
+ }
+}
diff --git a/examples/quick3d/forest/forest.pro b/examples/quick3d/forest/forest.pro
new file mode 100644
index 000000000..dbae98a47
--- /dev/null
+++ b/examples/quick3d/forest/forest.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+
+SOURCES += main.cpp
diff --git a/examples/quick3d/forest/main.cpp b/examples/quick3d/forest/main.cpp
new file mode 100644
index 000000000..146ea06c8
--- /dev/null
+++ b/examples/quick3d/forest/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/forest.qml")));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/forest/qml/Tree.qml b/examples/quick3d/forest/qml/Tree.qml
new file mode 100644
index 000000000..0657d51ad
--- /dev/null
+++ b/examples/quick3d/forest/qml/Tree.qml
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+//![1]
+import Qt 4.7
+import Qt3D 1.0
+
+Item3D {
+ id: tree
+ mesh: Mesh { source: "tree.obj" }
+ effect: Effect {
+ blending: true
+ texture: "tree.png"
+ }
+//![1]
+//![2]
+ transform: BillboardTransform {
+ preserveUpVector: true
+ }
+//![2]
+//![3]
+}
+//![3]
diff --git a/examples/quick3d/forest/qml/forest.qml b/examples/quick3d/forest/qml/forest.qml
new file mode 100644
index 000000000..8b0fd545a
--- /dev/null
+++ b/examples/quick3d/forest/qml/forest.qml
@@ -0,0 +1,81 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+//![1]
+import Qt 4.7
+import Qt3D 1.0
+
+Viewport {
+ id: viewport
+ width: 640; height: 480
+ picking: false
+
+ camera: Camera {
+ eye: Qt.vector3d(0, 4, 12)
+ }
+
+ Item3D {
+ id: ground
+ mesh: Mesh { source: "ground.obj" }
+ effect: Effect {
+ color: "#604000"
+ useLighting: false
+ }
+ }
+
+ Item3D {
+ sortChildren: Item3D.BackToFront
+
+ Tree { position: Qt.vector3d(-1.5, 0, -1) }
+ Tree { position: Qt.vector3d(-0.5, 0, -1) }
+ Tree { position: Qt.vector3d(0.5, 0, -1) }
+ Tree { position: Qt.vector3d(1.5, 0, -1) }
+
+ Tree { position: Qt.vector3d(0, 0, 0) }
+ Tree { position: Qt.vector3d(-1, 0, 0) }
+ Tree { position: Qt.vector3d(1, 0, 0) }
+
+ Tree { position: Qt.vector3d(-1.5, 0, 1) }
+ Tree { position: Qt.vector3d(-0.5, 0, 1) }
+ Tree { position: Qt.vector3d(0.5, 0, 1) }
+ Tree { position: Qt.vector3d(1.5, 0, 1) }
+ }
+}
+//![1]
diff --git a/examples/quick3d/forest/qml/ground.obj b/examples/quick3d/forest/qml/ground.obj
new file mode 100644
index 000000000..d13a931a2
--- /dev/null
+++ b/examples/quick3d/forest/qml/ground.obj
@@ -0,0 +1,11 @@
+s 0
+v -3.0 0.0 3.0
+v 3.0 0.0 3.0
+v 3.0 0.0 -3.0
+v -3.0 0.0 -3.0
+vt 0.0 0.0
+vt 1.0 0.0
+vt 1.0 1.0
+vt 0.0 1.0
+vn 0.0 1.0 0.0
+f 1/1/1 2/2/1 3/3/1 4/4/1
diff --git a/examples/quick3d/forest/qml/tree.obj b/examples/quick3d/forest/qml/tree.obj
new file mode 100644
index 000000000..6dd72d7b9
--- /dev/null
+++ b/examples/quick3d/forest/qml/tree.obj
@@ -0,0 +1,11 @@
+s 0
+v -0.5 0.0 0.0
+v 0.5 0.0 0.0
+v 0.5 1.0 0.0
+v -0.5 1.0 0.0
+vt 0.0 0.0
+vt 1.0 0.0
+vt 1.0 1.0
+vt 0.0 1.0
+vn 0.0 0.0 1.0
+f 1/1/1 2/2/1 3/3/1 4/4/1
diff --git a/examples/quick3d/forest/qml/tree.png b/examples/quick3d/forest/qml/tree.png
new file mode 100644
index 000000000..c6a27748f
--- /dev/null
+++ b/examples/quick3d/forest/qml/tree.png
Binary files differ
diff --git a/examples/quick3d/lander/lander.pro b/examples/quick3d/lander/lander.pro
new file mode 100644
index 000000000..dbae98a47
--- /dev/null
+++ b/examples/quick3d/lander/lander.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+
+SOURCES += main.cpp
diff --git a/examples/quick3d/lander/main.cpp b/examples/quick3d/lander/main.cpp
new file mode 100644
index 000000000..9439b25fe
--- /dev/null
+++ b/examples/quick3d/lander/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/lander.qml")));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/lander/qml/flame.png b/examples/quick3d/lander/qml/flame.png
new file mode 100644
index 000000000..503c310b1
--- /dev/null
+++ b/examples/quick3d/lander/qml/flame.png
Binary files differ
diff --git a/examples/quick3d/lander/qml/flame.xcf b/examples/quick3d/lander/qml/flame.xcf
new file mode 100644
index 000000000..bc6a423ad
--- /dev/null
+++ b/examples/quick3d/lander/qml/flame.xcf
Binary files differ
diff --git a/examples/quick3d/lander/qml/flame2.png b/examples/quick3d/lander/qml/flame2.png
new file mode 100644
index 000000000..a3913623c
--- /dev/null
+++ b/examples/quick3d/lander/qml/flame2.png
Binary files differ
diff --git a/examples/quick3d/lander/qml/flame2.xcf b/examples/quick3d/lander/qml/flame2.xcf
new file mode 100644
index 000000000..2cdf4367a
--- /dev/null
+++ b/examples/quick3d/lander/qml/flame2.xcf
Binary files differ
diff --git a/examples/quick3d/lander/qml/lander.qml b/examples/quick3d/lander/qml/lander.qml
new file mode 100644
index 000000000..a7306f671
--- /dev/null
+++ b/examples/quick3d/lander/qml/lander.qml
@@ -0,0 +1,90 @@
+import QtQuick 1.0
+import Qt3D 1.0
+import Qt3D.Shapes 1.0
+
+Viewport {
+ height: 480
+ width: 640
+ //camera: Camera { eye: Qt.vector3d(-3, -20, 2) }
+ Item3D {
+ mesh: Mesh { source: "lunar-lander.3ds"; options: "ForceFaceted" }
+ effect: Effect {
+ color: "#aaca00"
+ texture: "rusty.png"
+ decal: true
+ }
+ }
+ Quad {
+ y: -0.8
+ transform: [
+ Rotation3D { axis: Qt.vector3d(1, 0, 0); angle: 90 },
+ Scale3D { id: scaleFactor; scale: 1.0 }]
+ effect: flame
+ SequentialAnimation {
+ running: true
+ loops: Animation.Infinite
+ NumberAnimation { target: scaleFactor; property: "scale"; from: 1.0; to: 0.8; duration: 100 }
+ PauseAnimation { duration: 100 }
+ NumberAnimation { target: scaleFactor; property: "scale"; from: 0.8; to: 1.0; duration: 100 }
+ }
+ }
+ ShaderProgram {
+ id: flame
+ texture: "flame.png"
+ property variant texture2 : "flame2.png"
+ property real interpolationFactor : 1.0
+
+ SequentialAnimation on interpolationFactor {
+ running: true
+ loops: Animation.Infinite
+ NumberAnimation { to : 1.0; duration: 750; }
+
+
+ PauseAnimation { duration: 550 }
+ NumberAnimation { to : 0.0; duration: 750; }
+ PauseAnimation { duration: 550 }
+ }
+
+ SequentialAnimation on color{
+ running: true
+ loops: Animation.Infinite
+ ColorAnimation {
+ from: "#aaca00"
+ to: "#0033ca"
+ duration: 500
+ }
+ ColorAnimation {
+ from: "#0033ca"
+ to: "#aaca00"
+ duration: 500
+ }
+ }
+
+ vertexShader: "
+ attribute highp vec4 qt_Vertex;
+ attribute highp vec4 qt_MultiTexCoord0;
+ uniform mediump mat4 qt_ModelViewProjectionMatrix;
+ varying highp vec4 texCoord;
+
+ void main(void)
+ {
+ gl_Position = qt_ModelViewProjectionMatrix * qt_Vertex;
+ texCoord = qt_MultiTexCoord0;
+ }
+ "
+ fragmentShader: "
+ varying highp vec4 texCoord;
+ uniform sampler2D qt_Texture0;
+ uniform sampler2D texture2;
+ uniform mediump vec4 qt_Color;
+ uniform mediump float interpolationFactor;
+
+ void main(void)
+ {
+ mediump vec4 col1 = texture2D(qt_Texture0, texCoord.st);
+ mediump vec4 col2 = texture2D(texture2, texCoord.st);
+ gl_FragColor = mix(col1, col2, interpolationFactor);
+ }
+ "
+ }
+}
diff --git a/examples/quick3d/lander/qml/lunar-lander.3ds b/examples/quick3d/lander/qml/lunar-lander.3ds
new file mode 100644
index 000000000..eab75bc53
--- /dev/null
+++ b/examples/quick3d/lander/qml/lunar-lander.3ds
Binary files differ
diff --git a/examples/quick3d/lander/qml/rusty.png b/examples/quick3d/lander/qml/rusty.png
new file mode 100644
index 000000000..b85ad7c9c
--- /dev/null
+++ b/examples/quick3d/lander/qml/rusty.png
Binary files differ
diff --git a/examples/quick3d/matrix_animation/main.cpp b/examples/quick3d/matrix_animation/main.cpp
new file mode 100644
index 000000000..550106230
--- /dev/null
+++ b/examples/quick3d/matrix_animation/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/matrix-animation.qml"));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/matrix_animation/matrix_animation.pro b/examples/quick3d/matrix_animation/matrix_animation.pro
new file mode 100644
index 000000000..dbae98a47
--- /dev/null
+++ b/examples/quick3d/matrix_animation/matrix_animation.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+
+SOURCES += main.cpp
diff --git a/examples/quick3d/matrix_animation/qml/matrix-animation.qml b/examples/quick3d/matrix_animation/qml/matrix-animation.qml
new file mode 100644
index 000000000..78bd71d22
--- /dev/null
+++ b/examples/quick3d/matrix_animation/qml/matrix-animation.qml
@@ -0,0 +1,145 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+
+Viewport {
+ width: 640; height: 480
+ id: viewPort
+
+ MouseArea {
+ anchors.fill: parent
+ onClicked: program.scalex = 2.5 - program.scalex
+ }
+
+ Item3D {
+ mesh: Mesh { source: "meshes/teapot.bez" }
+ effect: program
+
+
+ transform: Rotation3D {
+ NumberAnimation on angle{
+ running: true
+ loops: Animation.Infinite
+ from: 0
+ to: 360
+ duration: 18000
+ }
+ axis: Qt.vector3d(1, -0.3, 0)
+ }
+
+ ShaderProgram {
+ id: program
+ property real qt_Custom : 1.0
+ property int customInt : 1
+ property color customColor : "#3333ff"
+ property real scalex : 1.0
+ property real scaley : 1.0
+ property real scalez : 1.0
+ property real translationX : 0.0
+ property real translationY : 0.0
+ property real translationZ : 0.0
+
+ property variant matrix4x4 :[
+ scalex , 0.0, 0.0, translationX,
+ 0.0, scaley, 0.0, translationY,
+ 0.0, 0.0, scalez, translationZ,
+ 0.0, 0.0, 0.0, 1.0 ]
+
+ SequentialAnimation on translationY {
+ running: true
+ loops: Animation.Infinite
+ PauseAnimation { duration: 2000 }
+ NumberAnimation { from: 1.0; to: 0.001; duration: 1500; easing.type:"OutBounce" }
+ PauseAnimation { duration: 2000 }
+ NumberAnimation { from: 0.001; to: 1.0; duration: 1500; easing.type:"OutBounce" }
+ }
+
+ SequentialAnimation on customInt {
+ running: true
+ loops: Animation.Infinite
+ PauseAnimation { duration: 2500 }
+ NumberAnimation { from: 1.0; to: 0.001; duration: 1500; easing.type:"OutBounce" }
+ PauseAnimation { duration: 2500 }
+ NumberAnimation { from: 0.001; to: 1.0; duration: 1500; easing.type:"OutBounce" }
+ }
+
+ texture: "textures/qtlogo.png"
+
+ vertexShader: "
+ attribute highp vec4 qt_Vertex;
+ attribute highp vec4 qt_MultiTexCoord0;
+ uniform mediump mat4 qt_ModelViewProjectionMatrix;
+ varying highp vec4 texCoord;
+ // uniform highp float qt_Custom;
+ uniform int customInt;
+ uniform vec2 vector;
+
+ uniform mat3 matrix3x3;
+ uniform mat4 matrix4x4;
+
+ void main(void)
+ {
+ gl_Position = qt_ModelViewProjectionMatrix *
+ (matrix4x4 * qt_Vertex);
+ texCoord = -qt_MultiTexCoord0;
+
+ }
+ "
+ fragmentShader: "
+ varying highp vec4 texCoord;
+ uniform sampler2D qt_Texture0;
+ uniform lowp vec4 customColor;
+ uniform bool customBoolean;
+
+ void main(void)
+ {
+ mediump vec4 textureColor =
+ texture2D(qt_Texture0, texCoord.st);
+ gl_FragColor = clamp(vec4(
+ customColor.rgb * (1.0 - textureColor.a) +
+ textureColor.rgb, 1.0), 0.0, 1.0);
+ }
+ "
+ }
+ }
+
+}
diff --git a/examples/quick3d/monkeygod/main.cpp b/examples/quick3d/monkeygod/main.cpp
new file mode 100644
index 000000000..e8ad034ca
--- /dev/null
+++ b/examples/quick3d/monkeygod/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/monkeygod.qml"));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/monkeygod/monkeygod.pro b/examples/quick3d/monkeygod/monkeygod.pro
new file mode 100644
index 000000000..dbae98a47
--- /dev/null
+++ b/examples/quick3d/monkeygod/monkeygod.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+
+SOURCES += main.cpp
diff --git a/examples/quick3d/monkeygod/qml/Penguin.qml b/examples/quick3d/monkeygod/qml/Penguin.qml
new file mode 100644
index 000000000..394110840
--- /dev/null
+++ b/examples/quick3d/monkeygod/qml/Penguin.qml
@@ -0,0 +1,78 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+
+Item3D {
+ id: penguin
+ scale: 0.2
+ effect: Effect{}
+ transform: [
+ Rotation3D {
+ id: penguinTilt
+ angle: -100
+ axis: Qt.vector3d(1,0,0)
+ },
+ Rotation3D {
+ id: penguinFacing
+ angle: 180
+ axis: Qt.vector3d(0,1,0)
+ }
+ ]
+
+ light: Light {}
+
+ mesh: Mesh { source: "meshes/penguin.3ds" }
+
+ SequentialAnimation {
+ running: true
+ loops: 100
+ NumberAnimation {target: penguinTilt; property: "angle"; to: -45; duration: 600; easing.type: "OutQuad"}
+ NumberAnimation {target: penguinTilt; property: "angle"; to: -100; duration: 600; easing.type: "OutQuad"}
+ }
+
+ SequentialAnimation on y {
+ running: true
+ loops: 100
+ NumberAnimation {to: 0.5; duration: 200; easing.type: "OutQuad"}
+ NumberAnimation {to: 0.0; duration: 200; easing.type: "OutQuad"}
+ }
+}
diff --git a/examples/quick3d/monkeygod/qml/meshes/monkey.3ds b/examples/quick3d/monkeygod/qml/meshes/monkey.3ds
new file mode 100644
index 000000000..e9a007b20
--- /dev/null
+++ b/examples/quick3d/monkeygod/qml/meshes/monkey.3ds
Binary files differ
diff --git a/examples/quick3d/monkeygod/qml/meshes/penguin.3ds b/examples/quick3d/monkeygod/qml/meshes/penguin.3ds
new file mode 100644
index 000000000..26c09ac07
--- /dev/null
+++ b/examples/quick3d/monkeygod/qml/meshes/penguin.3ds
Binary files differ
diff --git a/examples/quick3d/monkeygod/qml/monkeygod.qml b/examples/quick3d/monkeygod/qml/monkeygod.qml
new file mode 100644
index 000000000..0782f5e5f
--- /dev/null
+++ b/examples/quick3d/monkeygod/qml/monkeygod.qml
@@ -0,0 +1,115 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+
+ Viewport {
+ width: 1000
+ height: 800
+
+ camera: Camera { eye: Qt.vector3d(21,7,19)}
+
+ Item3D {
+ id: monkey
+ scale: 2
+ position: Qt.vector3d(0, 1.5, -6)
+
+ mesh: Mesh { source: "meshes/monkey.3ds"; options: "ForceSmooth"}
+ effect: Effect { material: gold}
+ transform: LookAt { subject: focalPenguin}
+ }
+
+ Item3D
+ {
+ Penguin {position: Qt.vector3d(-1.5,0,1)}
+ Penguin {position: Qt.vector3d(1.5,0,1)}
+ Penguin {id: focalPenguin; position: Qt.vector3d(-0.5,0,2)}
+ Penguin {position: Qt.vector3d(0.5,0,2)}
+
+ transform: [
+ Rotation3D {id: swivel1; angle: -20; axis: Qt.vector3d(0,1,0)}
+ ]
+
+ SequentialAnimation {
+ running: true
+ loops: 100
+ NumberAnimation {target: swivel1; property: "angle"; to: 20; duration: 1200; easing.type: "OutQuad"}
+ NumberAnimation {target: swivel1; property: "angle"; to: -20; duration: 1200; easing.type: "OutQuad"}
+ }
+ }
+
+ Item3D {
+ scale: 0.012
+ y: -6.5
+ z: -2
+ mesh: Mesh { source: "meshes/lintel.3ds"}
+ transform: [Rotation3D {angle: -90; axis: Qt.vector3d(1,0,0)}]
+ effect: Effect{}
+ }
+
+ Item3D
+ {
+ Penguin {position: Qt.vector3d(-2.5,0,2)}
+ Penguin {position: Qt.vector3d(2.5,0,2)}
+ Penguin {position: Qt.vector3d(-1.5,0,3)}
+ Penguin {position: Qt.vector3d(1.5,0,3)}
+ Penguin {position: Qt.vector3d(-0.5,0,3.5)}
+ Penguin {position: Qt.vector3d(0.5,0,3.5)}
+
+ transform: [
+ Rotation3D {id: swivel2; angle: 20; axis: Qt.vector3d(0,1,0)}
+ ]
+
+ SequentialAnimation {
+ running: true
+ loops: 100
+ NumberAnimation {target: swivel2; property: "angle"; to: -20; duration: 1200; easing.type: "OutQuad"}
+ NumberAnimation {target: swivel2; property: "angle"; to: 20; duration: 1200; easing.type: "OutQuad"}
+ }
+ }
+
+ Material {
+ id: gold
+ ambientColor: "#EEDD00"
+ specularColor: "#FFFFFF"
+ shininess: 200
+ }
+ }
diff --git a/examples/quick3d/monkeygod/qml/monkeygod_no_platform.qml b/examples/quick3d/monkeygod/qml/monkeygod_no_platform.qml
new file mode 100644
index 000000000..eb2ee3fa4
--- /dev/null
+++ b/examples/quick3d/monkeygod/qml/monkeygod_no_platform.qml
@@ -0,0 +1,110 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+
+Rectangle {
+ color: "#AAAA22"
+ width: 1000
+ height: 800
+
+ Viewport {
+ anchors.fill: parent
+
+ camera: Camera { eye: Qt.vector3d(21,7,19)}
+
+ Item3D {
+ id: monkey
+ scale: 2
+ position: Qt.vector3d(0, 1.5, -6)
+
+ mesh: Mesh { source: "meshes/monkey.3ds"; options: "ForceSmooth"}
+ effect: Effect { material: gold}
+ }
+
+ Item3D
+ {
+ Penguin {position: Qt.vector3d(-1.5,0,1)}
+ Penguin {position: Qt.vector3d(1.5,0,1)}
+ Penguin {position: Qt.vector3d(-0.5,0,2)}
+ Penguin {position: Qt.vector3d(0.5,0,2)}
+
+ transform: [
+ Rotation3D {id: swivel1; angle: -20; axis: Qt.vector3d(0,1,0)}
+ ]
+
+ SequentialAnimation {
+ running: true
+ loops: 100
+ NumberAnimation {target: swivel1; property: "angle"; to: 20; duration: 1200; easing.type: "OutQuad"}
+ NumberAnimation {target: swivel1; property: "angle"; to: -20; duration: 1200; easing.type: "OutQuad"}
+ }
+ }
+
+ Item3D
+ {
+ Penguin {position: Qt.vector3d(-2.5,0,2)}
+ Penguin {position: Qt.vector3d(2.5,0,2)}
+ Penguin {position: Qt.vector3d(-1.5,0,3)}
+ Penguin {position: Qt.vector3d(1.5,0,3)}
+ Penguin {position: Qt.vector3d(-0.5,0,3.5)}
+ Penguin {position: Qt.vector3d(0.5,0,3.5)}
+
+ transform: [
+ Rotation3D {id: swivel2; angle: 20; axis: Qt.vector3d(0,1,0)}
+ ]
+
+ SequentialAnimation {
+ running: true
+ loops: 100
+ NumberAnimation {target: swivel2; property: "angle"; to: -20; duration: 1200; easing.type: "OutQuad"}
+ NumberAnimation {target: swivel2; property: "angle"; to: 20; duration: 1200; easing.type: "OutQuad"}
+ }
+ }
+
+ Material {
+ id: gold
+ ambientColor: "#EEDD00"
+ specularColor: "#FFFFFF"
+ shininess: 200
+ }
+ }
+}
diff --git a/examples/quick3d/moon/main.cpp b/examples/quick3d/moon/main.cpp
new file mode 100644
index 000000000..922cdf24d
--- /dev/null
+++ b/examples/quick3d/moon/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/moon.qml"));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/moon/moon.pro b/examples/quick3d/moon/moon.pro
new file mode 100644
index 000000000..dbae98a47
--- /dev/null
+++ b/examples/quick3d/moon/moon.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+
+SOURCES += main.cpp
diff --git a/examples/quick3d/moon/qml/moon-texture.jpg b/examples/quick3d/moon/qml/moon-texture.jpg
new file mode 100644
index 000000000..b6955e389
--- /dev/null
+++ b/examples/quick3d/moon/qml/moon-texture.jpg
Binary files differ
diff --git a/examples/quick3d/moon/qml/moon.qml b/examples/quick3d/moon/qml/moon.qml
new file mode 100644
index 000000000..e8d265e45
--- /dev/null
+++ b/examples/quick3d/moon/qml/moon.qml
@@ -0,0 +1,65 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+import Qt3D.Shapes 1.0
+
+Viewport {
+ width: 640; height: 480
+
+ light: Light {
+ direction: Qt.vector3d(1, 0, 2)
+ }
+
+ Sphere {
+ scale: 1.5
+ levelOfDetail: 6
+ axis: Qt.YAxis
+
+ effect: Effect {
+ // Moon texture sourced from:
+ // http://www.lns.cornell.edu/~seb/celestia/moon-4k-18.jpg
+ // The source texture was scaled down to a more reasonable size,
+ // and the brightness and contrast were increased.
+ texture: "moon-texture.jpg"
+ }
+ }
+}
diff --git a/examples/quick3d/photopane/main.cpp b/examples/quick3d/photopane/main.cpp
new file mode 100644
index 000000000..e729842b9
--- /dev/null
+++ b/examples/quick3d/photopane/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/photopane.qml"));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/photopane/photopane.pro b/examples/quick3d/photopane/photopane.pro
new file mode 100644
index 000000000..dbae98a47
--- /dev/null
+++ b/examples/quick3d/photopane/photopane.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+
+SOURCES += main.cpp
diff --git a/examples/quick3d/photopane/qml/photopane.qml b/examples/quick3d/photopane/qml/photopane.qml
new file mode 100644
index 000000000..1b22c8f07
--- /dev/null
+++ b/examples/quick3d/photopane/qml/photopane.qml
@@ -0,0 +1,127 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+
+Item3D {
+ id: photo
+
+ property real offset
+ property real layer
+ property variant image
+ property bool bounce: false
+
+ mesh: Mesh { source: "meshes/photopane.obj" }
+
+ position: Qt.vector3d(offset, 0, -layer)
+ effect: Effect { decal: true; texture: image }
+
+ onClicked: {
+ if (photo.state == "pulled_out")
+ photo.state = "returned";
+ else
+ photo.state = "pulled_out";
+ }
+
+ onHoverEnter: { photo.state = "pop_up" }
+ onHoverLeave: { photo.state = "returned" }
+
+ states: [
+ State {
+ name: "pop_up"
+ PropertyChanges {
+ target: photo
+ y: 1.0
+ }
+ },
+ State {
+ name: "pulled_out"
+ PropertyChanges {
+ target: photo
+ x: 0
+ }
+ PropertyChanges {
+ target: photo
+ scale: 1.75
+ }
+ PropertyChanges {
+ target: photo
+ z: 2
+ }
+ PropertyChanges {
+ target: viewport
+ state: "show_photo"
+ }
+ },
+ State {
+ name: "returned"
+ PropertyChanges {
+ target: photo
+ x: offset
+ }
+ PropertyChanges {
+ target: photo
+ scale: 1
+ }
+ PropertyChanges {
+ target: photo
+ z: -layer
+ }
+ PropertyChanges {
+ target: viewport
+ state: "show_group"
+ }
+ }
+ ]
+
+ transitions: [
+ Transition {
+ from: "*"
+ to: "*"
+ NumberAnimation {
+ targets: photo
+ properties: "x,scale,z,y"
+ easing.type: "OutBounce"
+ duration: 700
+ }
+ }
+ ]
+}
diff --git a/examples/quick3d/photoroom/main.cpp b/examples/quick3d/photoroom/main.cpp
new file mode 100644
index 000000000..1bb9eb978
--- /dev/null
+++ b/examples/quick3d/photoroom/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/photoroom.qml"));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/photoroom/photoroom.pro b/examples/quick3d/photoroom/photoroom.pro
new file mode 100644
index 000000000..dbae98a47
--- /dev/null
+++ b/examples/quick3d/photoroom/photoroom.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+
+SOURCES += main.cpp
diff --git a/examples/quick3d/photoroom/qml/photoroom.qml b/examples/quick3d/photoroom/qml/photoroom.qml
new file mode 100644
index 000000000..120ad0a29
--- /dev/null
+++ b/examples/quick3d/photoroom/qml/photoroom.qml
@@ -0,0 +1,162 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+
+Viewport {
+ id: viewport
+ width: 800; height: 480
+ picking: true
+ //navigation: false
+ //showPicking: true
+
+ camera: Camera {
+ id: main_camera
+ eye: Qt.vector3d(0, 4, 12)
+ center: Qt.vector3d(0, 0, -2.5)
+ }
+
+ PhotoPane {
+ offset: -2.1
+ layer: 0
+ image: "textures/button/woman.jpg"
+ }
+ PhotoPane {
+ offset: -2.1
+ layer: 1
+ image: "textures/photos/niagara_falls.jpg"
+ }
+ PhotoPane {
+ offset: -2.1
+ layer: 2
+ image: "textures/photos/place.jpg"
+ }
+ PhotoPane {
+ offset: -2.1
+ layer: 3
+ image: "textures/photos/background.jpg"
+ }
+ PhotoPane {
+ offset: -2.1
+ layer: 4
+ image: "textures/basket.jpg"
+ }
+ PhotoPane {
+ offset: -2.1
+ layer: 5
+ image: "textures/qtlogo.png"
+ effect.color: "#006090"
+ }
+
+ PhotoPane {
+ offset: 2.1
+ layer: 0
+ image: "textures/photos/niagara_falls.jpg"
+ }
+ PhotoPane {
+ offset: 2.1
+ layer: 1
+ image: "textures/photos/place.jpg"
+ }
+ PhotoPane {
+ offset: 2.1
+ layer: 2
+ image: "textures/photos/background.jpg"
+ }
+ PhotoPane {
+ offset: 2.1
+ layer: 3
+ image: "textures/basket.jpg"
+ }
+ PhotoPane {
+ offset: 2.1
+ layer: 4
+ image: "textures/qtlogo.png"
+ effect.color: "#006090"
+ }
+ PhotoPane {
+ offset: 2.1
+ layer: 5
+ image: "textures/button/woman.jpg"
+ }
+
+ states: [
+ State {
+ name: "show_photo"
+ PropertyChanges {
+ target: main_camera
+ eye.y: 0
+ }
+ PropertyChanges {
+ target: main_camera
+ eye.x: 0
+ }
+ PropertyChanges {
+ target: main_camera
+ eye.z: 12
+ }
+ PropertyChanges {
+ target: main_camera
+ upVector: Qt.vector3d(0, 1, 0)
+ }
+ },
+ State {
+ name: "show_group"
+ PropertyChanges {
+ target: main_camera
+ eye.y: 4
+ }
+ }
+ ]
+
+ transitions: [
+ Transition {
+ from: "*"
+ to: "*"
+ NumberAnimation {
+ targets: main_camera
+ properties: "eye.y"
+ easing.type: "OutBounce"
+ duration: 700
+ }
+ }
+ ]
+}
diff --git a/examples/quick3d/quick3d.pro b/examples/quick3d/quick3d.pro
new file mode 100644
index 000000000..7e70381af
--- /dev/null
+++ b/examples/quick3d/quick3d.pro
@@ -0,0 +1,16 @@
+TEMPLATE = subdirs
+SUBDIRS += \
+ basket \
+ bounce \
+ cube \
+ forest \
+ lander \
+ matrix_animation \
+ monkeygod \
+ moon \
+ photopane \
+ photoroom \
+ shaders \
+ sphere \
+ teapot
+
diff --git a/examples/quick3d/shaders/main.cpp b/examples/quick3d/shaders/main.cpp
new file mode 100644
index 000000000..53d6ce64c
--- /dev/null
+++ b/examples/quick3d/shaders/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/shaders.qml"));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/shaders/qml/Animation.qml b/examples/quick3d/shaders/qml/Animation.qml
new file mode 100644
index 000000000..4bfa01b8e
--- /dev/null
+++ b/examples/quick3d/shaders/qml/Animation.qml
@@ -0,0 +1,124 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+
+Viewport {
+ width: 640; height: 480
+
+ property string name: "Animation Shader"
+ property string icon: "images/teapot-logo.png"
+ property bool run: false
+
+ Item3D {
+ mesh: Mesh { source: "meshes/teapot.bez" }
+ effect: program
+
+ transform: Rotation3D {
+ NumberAnimation on angle{
+ running: run
+ loops: Animation.Infinite
+ from: 0
+ to: 360
+ duration: 18000
+ }
+ axis: Qt.vector3d(1, -0.3, 0)
+ }
+
+ ShaderProgram {
+ id: program
+ property real qt_Custom : 1.0
+ SequentialAnimation on qt_Custom {
+ running: run
+ loops: Animation.Infinite
+ PauseAnimation { duration: 700 }
+ NumberAnimation { from: 1.0; to: 0.001; duration: 1500; easing.type:"OutBounce" }
+ PauseAnimation { duration: 700 }
+ NumberAnimation { from: 0.001; to: 1.0; duration: 1500; easing.type:"OutBounce" }
+ }
+
+ texture: "images/qtlogo.png"
+
+ SequentialAnimation on color {
+ running: run
+ loops: Animation.Infinite
+ ColorAnimation {
+ from: "#00008a"
+ to: "#003333"
+ duration: 5000
+ }
+ ColorAnimation {
+ from: "#003333"
+ to: "#00008a"
+ duration: 5000
+ }
+ }
+
+ vertexShader: "
+ attribute highp vec4 qt_Vertex;
+ attribute highp vec4 qt_MultiTexCoord0;
+ uniform mediump mat4 qt_ModelViewProjectionMatrix;
+ varying highp vec4 texCoord;
+ uniform highp float qt_Custom;
+
+ void main(void)
+ {
+ gl_Position = qt_ModelViewProjectionMatrix * (qt_Vertex *
+ vec4(1.0, qt_Custom, 1.0, 1.0));
+ texCoord = -qt_MultiTexCoord0 + vec4(qt_Custom, 0.0, 0.0, 0.0);
+
+ }
+ "
+ fragmentShader: "
+ varying highp vec4 texCoord;
+ uniform sampler2D qt_Texture0;
+ uniform mediump vec4 qt_Color;
+
+ void main(void)
+ {
+ mediump vec4 col = texture2D(qt_Texture0, texCoord.st);
+ gl_FragColor = vec4(clamp(qt_Color.rgb * (1.0 - col.a) +
+ col.rgb, 0.0, 1.0), 1.0);
+ }
+ "
+ }
+ }
+}
diff --git a/examples/quick3d/shaders/qml/Collapsing.qml b/examples/quick3d/shaders/qml/Collapsing.qml
new file mode 100644
index 000000000..42cdf41e5
--- /dev/null
+++ b/examples/quick3d/shaders/qml/Collapsing.qml
@@ -0,0 +1,125 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+
+Viewport {
+ property string name: "Collapsing Shader"
+ property string icon: "images/teapot-logo.png"
+
+ width: 640; height: 480
+
+ Item3D {
+ mesh: Mesh { source: "meshes/teapot.bez" }
+ effect: program
+
+ transform: Rotation3D {
+ NumberAnimation on angle{
+ running: true
+ loops: Animation.Infinite
+ from: 0
+ to: 360
+ duration: 8000
+ }
+ axis: Qt.vector3d(1, -0.3, 0)
+ }
+
+ ShaderProgram {
+ id: program
+ property real collapseFactor : 0.0
+
+ SequentialAnimation on collapseFactor {
+ running: true
+ loops: Animation.Infinite
+ PauseAnimation { duration: 700 }
+ NumberAnimation { from: 0.0; to: 1.0; duration: 1500; easing.type:"OutBounce" }
+ PauseAnimation { duration: 700 }
+ NumberAnimation { from: 1.0; to: 0.0; duration: 1500; easing.type:"OutBounce" }
+ }
+ texture: "images/qtlogo.png"
+
+ SequentialAnimation on color{
+ running: true
+ loops: Animation.Infinite
+ ColorAnimation {
+ from: "#00008a"
+ to: "#003333"
+ duration: 5000
+ }
+ ColorAnimation {
+ from: "#003333"
+ to: "#00008a"
+ duration: 5000
+ }
+ }
+
+ vertexShader: "
+ attribute highp vec4 qt_Vertex;
+ attribute highp vec4 qt_MultiTexCoord0;
+ uniform mediump mat4 qt_ModelViewProjectionMatrix;
+ varying highp vec4 texCoord;
+ uniform highp float collapseFactor;
+
+ void main(void)
+ {
+ // Interpolate between the actual position of the input vertex
+ // and treating the tex-coordinates as vertex positions to
+ // create a neat collapsing effect.
+ vec4 workingPosition = mix( qt_Vertex, vec4(-qt_MultiTexCoord0.xyz, 1.0) , collapseFactor);
+ gl_Position = qt_ModelViewProjectionMatrix * workingPosition;
+ texCoord = -qt_MultiTexCoord0;
+ }
+ "
+ fragmentShader: "
+ varying highp vec4 texCoord;
+ uniform sampler2D qt_Texture0;
+ uniform mediump vec4 qt_Color;
+
+ void main(void)
+ {
+ mediump vec4 col = texture2D(qt_Texture0, texCoord.st);
+ gl_FragColor = vec4(clamp(qt_Color.rgb * (1.0 - col.a) +
+ col.rgb, 0.0, 1.0), 1.0);
+ }
+ "
+ }
+ }
+}
diff --git a/examples/quick3d/shaders/qml/Images.qml b/examples/quick3d/shaders/qml/Images.qml
new file mode 100644
index 000000000..0ca21e640
--- /dev/null
+++ b/examples/quick3d/shaders/qml/Images.qml
@@ -0,0 +1,144 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+
+Rectangle {
+ property string name: "Images Shader"
+ property string icon: "images/teapot-logo.png"
+
+ width: 640; height: 480
+ id: top
+ color: "black"
+
+ property bool flag : true
+
+ property string imageUrl: flag ?
+ "images/qtlogo.png" :
+ "images/basket.jpg"
+
+ Image {
+ id: myChangingImage
+ source: imageUrl
+ }
+
+ Viewport {
+ anchors.fill: parent
+
+ MouseArea
+ {
+ anchors.fill: parent
+ onClicked: top.flag = !top.flag
+ }
+
+ Item3D {
+ mesh: Mesh { source: "meshes/teapot.bez" }
+ effect: shaderEffect
+
+ transform: Rotation3D {
+ NumberAnimation on angle{
+ running: true
+ loops: Animation.Infinite
+ from: 0
+ to: 360
+ duration: 18000
+ }
+ axis: Qt.vector3d(1, -0.3, 0)
+ }
+ }
+
+ ShaderProgram {
+ id: shaderEffect
+ property alias myBoolean : top.flag
+ property variant textureOffset : Qt.size(textureOffsetX * 5, 0.0)
+ property real textureOffsetX : 0.0
+
+
+ // Default texture that the shaderprogram will get until something else
+ // is bound:
+ texture: "images/qtlogo.png"
+
+ // This property is automatically hooked up to the image uniform
+ // in the shader program below.
+ property string image : imageUrl
+
+ SequentialAnimation on textureOffsetX {
+ running: true
+ loops: Animation.Infinite
+ PauseAnimation { duration: 2500 }
+ NumberAnimation { from: 0.0; to: 1.0; duration: 1500; easing.type:"OutBounce" }
+ PauseAnimation { duration: 2500 }
+ NumberAnimation { from: 1.0; to: 0.0; duration: 1500; easing.type:"OutBounce" }
+ }
+
+ vertexShader: "
+ attribute highp vec4 qt_Vertex;
+ attribute highp vec4 qt_MultiTexCoord0;
+ uniform mediump mat4 qt_ModelViewProjectionMatrix;
+ varying highp vec4 texCoord;
+
+ uniform mediump vec2 textureOffset;
+
+ void main(void)
+ {
+ gl_Position = qt_ModelViewProjectionMatrix * qt_Vertex;
+ texCoord = -qt_MultiTexCoord0 + vec4(textureOffset.x, textureOffset.y, 0.0, 0.0);
+ }
+ "
+
+ fragmentShader: "
+ varying highp vec4 texCoord;
+ uniform sampler2D qt_Texture0;
+ uniform bool myBoolean;
+
+ // This image uniform is automatically associated with the image
+ // property of the shader program.
+ uniform sampler2D image;
+
+ void main(void)
+ {
+ mediump vec4 imageColor = texture2D(image, texCoord.st);
+ gl_FragColor = imageColor;
+ }
+ "
+ }
+ }
+}
diff --git a/examples/quick3d/shaders/qml/Interpolate.qml b/examples/quick3d/shaders/qml/Interpolate.qml
new file mode 100644
index 000000000..e45caba51
--- /dev/null
+++ b/examples/quick3d/shaders/qml/Interpolate.qml
@@ -0,0 +1,126 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+
+Viewport {
+ property string name: "Interpolate Shader"
+ property string icon: "images/teapot-logo.png"
+
+ width: 640; height: 480
+
+ Item3D {
+ mesh: Mesh { source: "meshes/teapot.bez" }
+ effect: program
+
+ transform: Rotation3D {
+ NumberAnimation on angle{
+ running: true
+ loops: Animation.Infinite
+ from: 0
+ to: 360
+ duration: 5000
+ }
+ axis: Qt.vector3d(1, -0.3, 0)
+ }
+
+ ShaderProgram {
+ id: program
+ texture: "images/basket.jpg"
+ property variant texture2 : "images/qtlogo.png"
+ property real interpolationFactor : 1.0
+
+ SequentialAnimation on interpolationFactor {
+ running: true
+ loops: Animation.Infinite
+ NumberAnimation { to : 1.0; duration: 750; }
+
+
+ PauseAnimation { duration: 550 }
+ NumberAnimation { to : 0.0; duration: 750; }
+ PauseAnimation { duration: 550 }
+ }
+
+ SequentialAnimation on color{
+ running: true
+ loops: Animation.Infinite
+ ColorAnimation {
+ from: "#aaca00"
+ to: "#0033ca"
+ duration: 500
+ }
+ ColorAnimation {
+ from: "#0033ca"
+ to: "#aaca00"
+ duration: 500
+ }
+ }
+
+ vertexShader: "
+ attribute highp vec4 qt_Vertex;
+ attribute highp vec4 qt_MultiTexCoord0;
+ uniform mediump mat4 qt_ModelViewProjectionMatrix;
+ varying highp vec4 texCoord;
+
+ void main(void)
+ {
+ gl_Position = qt_ModelViewProjectionMatrix * qt_Vertex;
+ texCoord = qt_MultiTexCoord0;
+ }
+ "
+
+ fragmentShader: "
+ varying highp vec4 texCoord;
+ uniform sampler2D qt_Texture0;
+ uniform sampler2D texture2;
+ uniform mediump vec4 qt_Color;
+ uniform mediump float interpolationFactor;
+
+ void main(void)
+ {
+ mediump vec4 col1 = texture2D(qt_Texture0, texCoord.st);
+ mediump vec4 col2 = texture2D(texture2, texCoord.st);
+ gl_FragColor = mix(col1, col2, interpolationFactor);
+ }
+ "
+ }
+ }
+}
diff --git a/examples/quick3d/shaders/qml/images/basket.jpg b/examples/quick3d/shaders/qml/images/basket.jpg
new file mode 100644
index 000000000..438e7a0c2
--- /dev/null
+++ b/examples/quick3d/shaders/qml/images/basket.jpg
Binary files differ
diff --git a/examples/quick3d/shaders/qml/images/qtlogo.png b/examples/quick3d/shaders/qml/images/qtlogo.png
new file mode 100644
index 000000000..7d3e97eb3
--- /dev/null
+++ b/examples/quick3d/shaders/qml/images/qtlogo.png
Binary files differ
diff --git a/examples/quick3d/shaders/qml/images/teapot-logo.png b/examples/quick3d/shaders/qml/images/teapot-logo.png
new file mode 100644
index 000000000..39f02e51d
--- /dev/null
+++ b/examples/quick3d/shaders/qml/images/teapot-logo.png
Binary files differ
diff --git a/examples/quick3d/shaders/qml/meshes/teapot.bez b/examples/quick3d/shaders/qml/meshes/teapot.bez
new file mode 100644
index 000000000..02b2ac447
--- /dev/null
+++ b/examples/quick3d/shaders/qml/meshes/teapot.bez
@@ -0,0 +1,340 @@
+32
+1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16
+4,17,18,19,8,20,21,22,12,23,24,25,16,26,27,28
+19,29,30,31,22,32,33,34,25,35,36,37,28,38,39,40
+31,41,42,1,34,43,44,5,37,45,46,9,40,47,48,13
+13,14,15,16,49,50,51,52,53,54,55,56,57,58,59,60
+16,26,27,28,52,61,62,63,56,64,65,66,60,67,68,69
+28,38,39,40,63,70,71,72,66,73,74,75,69,76,77,78
+40,47,48,13,72,79,80,49,75,81,82,53,78,83,84,57
+57,58,59,60,85,86,87,88,89,90,91,92,93,94,95,96
+60,67,68,69,88,97,98,99,92,100,101,102,96,103,104,105
+69,76,77,78,99,106,107,108,102,109,110,111,105,112,113,114
+78,83,84,57,108,115,116,85,111,117,118,89,114,119,120,93
+121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136
+124,137,138,121,128,139,140,125,132,141,142,129,136,143,144,133
+133,134,135,136,145,146,147,148,149,150,151,152,69,153,154,155
+136,143,144,133,148,156,157,145,152,158,159,149,155,160,161,69
+162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177
+165,178,179,162,169,180,181,166,173,182,183,170,177,184,185,174
+174,175,176,177,186,187,188,189,190,191,192,193,194,195,196,197
+177,184,185,174,189,198,199,186,193,200,201,190,197,202,203,194
+204,204,204,204,207,208,209,210,211,211,211,211,212,213,214,215,4
+204,204,204,204,210,217,218,219,211,211,211,211,215,220,221,222,4
+204,204,204,204,219,224,225,226,211,211,211,211,222,227,228,229,4
+204,204,204,204,226,230,231,207,211,211,211,211,229,232,233,212,4
+212,213,214,215,234,235,236,237,238,239,240,241,242,243,244,245
+215,220,221,222,237,246,247,248,241,249,250,251,245,252,253,254
+222,227,228,229,248,255,256,257,251,258,259,260,254,261,262,263
+229,232,233,212,257,264,265,234,260,266,267,238,263,268,269,242
+270,270,270,270,279,280,281,282,275,276,277,278,271,272,273,274,4
+270,270,270,270,282,289,290,291,278,286,287,288,274,283,284,285,4
+270,270,270,270,291,298,299,300,288,295,296,297,285,292,293,294,4
+270,270,270,270,300,305,306,279,297,303,304,275,294,301,302,271,4
+306
+0.700000,0.450000,-0.000000
+0.700000,0.450000,0.392000
+0.392000,0.450000,0.700000
+0.000000,0.450000,0.700000
+0.668750,0.515625,-0.000000
+0.668750,0.515625,0.374500
+0.374500,0.515625,0.668750
+0.000000,0.515625,0.668750
+0.718750,0.515625,-0.000000
+0.718750,0.515625,0.402500
+0.402500,0.515625,0.718750
+0.000000,0.515625,0.718750
+0.750000,0.450000,-0.000000
+0.750000,0.450000,0.420000
+0.420000,0.450000,0.750000
+0.000000,0.450000,0.750000
+-0.392000,0.450000,0.700000
+-0.700000,0.450000,0.392000
+-0.700000,0.450000,-0.000000
+-0.374500,0.515625,0.668750
+-0.668750,0.515625,0.374500
+-0.668750,0.515625,-0.000000
+-0.402500,0.515625,0.718750
+-0.718750,0.515625,0.402500
+-0.718750,0.515625,-0.000000
+-0.420000,0.450000,0.750000
+-0.750000,0.450000,0.420000
+-0.750000,0.450000,-0.000000
+-0.700000,0.450000,-0.392000
+-0.392000,0.450000,-0.700000
+0.000000,0.450000,-0.700000
+-0.668750,0.515625,-0.374500
+-0.374500,0.515625,-0.668750
+0.000000,0.515625,-0.668750
+-0.718750,0.515625,-0.402500
+-0.402500,0.515625,-0.718750
+0.000000,0.515625,-0.718750
+-0.750000,0.450000,-0.420000
+-0.420000,0.450000,-0.750000
+0.000000,0.450000,-0.750000
+0.392000,0.450000,-0.700000
+0.700000,0.450000,-0.392000
+0.374500,0.515625,-0.668750
+0.668750,0.515625,-0.374500
+0.402500,0.515625,-0.718750
+0.718750,0.515625,-0.402500
+0.420000,0.450000,-0.750000
+0.750000,0.450000,-0.420000
+0.875000,0.187500,-0.000000
+0.875000,0.187500,0.490000
+0.490000,0.187500,0.875000
+0.000000,0.187500,0.875000
+1.000000,-0.075000,-0.000000
+1.000000,-0.075000,0.560000
+0.560000,-0.075000,1.000000
+0.000000,-0.075000,1.000000
+1.000000,-0.300000,-0.000000
+1.000000,-0.300000,0.560000
+0.560000,-0.300000,1.000000
+0.000000,-0.300000,1.000000
+-0.490000,0.187500,0.875000
+-0.875000,0.187500,0.490000
+-0.875000,0.187500,-0.000000
+-0.560000,-0.075000,1.000000
+-1.000000,-0.075000,0.560000
+-1.000000,-0.075000,-0.000000
+-0.560000,-0.300000,1.000000
+-1.000000,-0.300000,0.560000
+-1.000000,-0.300000,-0.000000
+-0.875000,0.187500,-0.490000
+-0.490000,0.187500,-0.875000
+0.000000,0.187500,-0.875000
+-1.000000,-0.075000,-0.560000
+-0.560000,-0.075000,-1.000000
+0.000000,-0.075000,-1.000000
+-1.000000,-0.300000,-0.560000
+-0.560000,-0.300000,-1.000000
+0.000000,-0.300000,-1.000000
+0.490000,0.187500,-0.875000
+0.875000,0.187500,-0.490000
+0.560000,-0.075000,-1.000000
+1.000000,-0.075000,-0.560000
+0.560000,-0.300000,-1.000000
+1.000000,-0.300000,-0.560000
+1.000000,-0.525000,-0.000000
+1.000000,-0.525000,0.560000
+0.560000,-0.525000,1.000000
+0.000000,-0.525000,1.000000
+0.750000,-0.637500,-0.000000
+0.750000,-0.637500,0.420000
+0.420000,-0.637500,0.750000
+0.000000,-0.637500,0.750000
+0.750000,-0.675000,-0.000000
+0.750000,-0.675000,0.420000
+0.420000,-0.675000,0.750000
+0.000000,-0.675000,0.750000
+-0.560000,-0.525000,1.000000
+-1.000000,-0.525000,0.560000
+-1.000000,-0.525000,-0.000000
+-0.420000,-0.637500,0.750000
+-0.750000,-0.637500,0.420000
+-0.750000,-0.637500,-0.000000
+-0.420000,-0.675000,0.750000
+-0.750000,-0.675000,0.420000
+-0.750000,-0.675000,-0.000000
+-1.000000,-0.525000,-0.560000
+-0.560000,-0.525000,-1.000000
+0.000000,-0.525000,-1.000000
+-0.750000,-0.637500,-0.420000
+-0.420000,-0.637500,-0.750000
+0.000000,-0.637500,-0.750000
+-0.750000,-0.675000,-0.420000
+-0.420000,-0.675000,-0.750000
+0.000000,-0.675000,-0.750000
+0.560000,-0.525000,-1.000000
+1.000000,-0.525000,-0.560000
+0.420000,-0.637500,-0.750000
+0.750000,-0.637500,-0.420000
+0.420000,-0.675000,-0.750000
+0.750000,-0.675000,-0.420000
+-0.800000,0.262500,-0.000000
+-0.800000,0.262500,0.150000
+-0.750000,0.375000,0.150000
+-0.750000,0.375000,-0.000000
+-1.150000,0.262500,-0.000000
+-1.150000,0.262500,0.150000
+-1.250000,0.375000,0.150000
+-1.250000,0.375000,-0.000000
+-1.350000,0.262500,-0.000000
+-1.350000,0.262500,0.150000
+-1.500000,0.375000,0.150000
+-1.500000,0.375000,-0.000000
+-1.350000,0.150000,-0.000000
+-1.350000,0.150000,0.150000
+-1.500000,0.150000,0.150000
+-1.500000,0.150000,-0.000000
+-0.750000,0.375000,-0.150000
+-0.800000,0.262500,-0.150000
+-1.250000,0.375000,-0.150000
+-1.150000,0.262500,-0.150000
+-1.500000,0.375000,-0.150000
+-1.350000,0.262500,-0.150000
+-1.500000,0.150000,-0.150000
+-1.350000,0.150000,-0.150000
+-1.350000,0.037500,-0.000000
+-1.350000,0.037500,0.150000
+-1.500000,-0.075000,0.150000
+-1.500000,-0.075000,-0.000000
+-1.250000,-0.187500,-0.000000
+-1.250000,-0.187500,0.150000
+-1.325000,-0.281250,0.150000
+-1.325000,-0.281250,-0.000000
+-1.000000,-0.300000,0.150000
+-0.950000,-0.450000,0.150000
+-0.950000,-0.450000,-0.000000
+-1.500000,-0.075000,-0.150000
+-1.350000,0.037500,-0.150000
+-1.325000,-0.281250,-0.150000
+-1.250000,-0.187500,-0.150000
+-0.950000,-0.450000,-0.150000
+-1.000000,-0.300000,-0.150000
+0.850000,-0.037500,-0.000000
+0.850000,-0.037500,0.330000
+0.850000,-0.450000,0.330000
+0.850000,-0.450000,-0.000000
+1.300000,-0.037500,-0.000000
+1.300000,-0.037500,0.330000
+1.550000,-0.337500,0.330000
+1.550000,-0.337500,-0.000000
+1.150000,0.300000,-0.000000
+1.150000,0.300000,0.125000
+1.200000,0.262500,0.125000
+1.200000,0.262500,-0.000000
+1.350000,0.450000,-0.000000
+1.350000,0.450000,0.125000
+1.650000,0.450000,0.125000
+1.650000,0.450000,-0.000000
+0.850000,-0.450000,-0.330000
+0.850000,-0.037500,-0.330000
+1.550000,-0.337500,-0.330000
+1.300000,-0.037500,-0.330000
+1.200000,0.262500,-0.125000
+1.150000,0.300000,-0.125000
+1.650000,0.450000,-0.125000
+1.350000,0.450000,-0.125000
+1.400000,0.487500,-0.000000
+1.400000,0.487500,0.125000
+1.762500,0.496875,0.125000
+1.762500,0.496875,-0.000000
+1.450000,0.487500,-0.000000
+1.450000,0.487500,0.075000
+1.725000,0.506250,0.075000
+1.725000,0.506250,-0.000000
+1.400000,0.450000,-0.000000
+1.400000,0.450000,0.075000
+1.600000,0.450000,0.075000
+1.600000,0.450000,-0.000000
+1.762500,0.496875,-0.125000
+1.400000,0.487500,-0.125000
+1.725000,0.506250,-0.075000
+1.450000,0.487500,-0.075000
+1.600000,0.450000,-0.075000
+1.400000,0.450000,-0.075000
+0.000000,0.825000,-0.000000
+0.000000,0.825000,0.001000
+0.001000,0.825000,-0.000000
+0.400000,0.825000,-0.000000
+0.400000,0.825000,0.225000
+0.225000,0.825000,0.400000
+0.000000,0.825000,0.400000
+0.000000,0.675000,-0.000000
+0.100000,0.600000,-0.000000
+0.100000,0.600000,0.056000
+0.056000,0.600000,0.100000
+0.000000,0.600000,0.100000
+-0.001000,0.825000,-0.000000
+-0.225000,0.825000,0.400000
+-0.400000,0.825000,0.225000
+-0.400000,0.825000,-0.000000
+-0.056000,0.600000,0.100000
+-0.100000,0.600000,0.056000
+-0.100000,0.600000,-0.000000
+0.000000,0.825000,-0.001000
+-0.400000,0.825000,-0.225000
+-0.225000,0.825000,-0.400000
+0.000000,0.825000,-0.400000
+-0.100000,0.600000,-0.056000
+-0.056000,0.600000,-0.100000
+0.000000,0.600000,-0.100000
+0.225000,0.825000,-0.400000
+0.400000,0.825000,-0.225000
+0.056000,0.600000,-0.100000
+0.100000,0.600000,-0.056000
+0.200000,0.525000,-0.000000
+0.200000,0.525000,0.112000
+0.112000,0.525000,0.200000
+0.000000,0.525000,0.200000
+0.650000,0.525000,-0.000000
+0.650000,0.525000,0.364000
+0.364000,0.525000,0.650000
+0.000000,0.525000,0.650000
+0.650000,0.450000,-0.000000
+0.650000,0.450000,0.364000
+0.364000,0.450000,0.650000
+0.000000,0.450000,0.650000
+-0.112000,0.525000,0.200000
+-0.200000,0.525000,0.112000
+-0.200000,0.525000,-0.000000
+-0.364000,0.525000,0.650000
+-0.650000,0.525000,0.364000
+-0.650000,0.525000,-0.000000
+-0.364000,0.450000,0.650000
+-0.650000,0.450000,0.364000
+-0.650000,0.450000,-0.000000
+-0.200000,0.525000,-0.112000
+-0.112000,0.525000,-0.200000
+0.000000,0.525000,-0.200000
+-0.650000,0.525000,-0.364000
+-0.364000,0.525000,-0.650000
+0.000000,0.525000,-0.650000
+-0.650000,0.450000,-0.364000
+-0.364000,0.450000,-0.650000
+0.000000,0.450000,-0.650000
+0.112000,0.525000,-0.200000
+0.200000,0.525000,-0.112000
+0.364000,0.525000,-0.650000
+0.650000,0.525000,-0.364000
+0.364000,0.450000,-0.650000
+0.650000,0.450000,-0.364000
+0.000000,-0.750000,-0.000000
+0.750000,-0.675000,-0.000000
+0.750000,-0.675000,-0.420000
+0.420000,-0.675000,-0.750000
+0.000000,-0.675000,-0.750000
+0.750000,-0.712500,-0.000000
+0.750000,-0.712500,-0.420000
+0.420000,-0.712500,-0.750000
+0.000000,-0.712500,-0.750000
+0.712500,-0.750000,-0.000000
+0.712500,-0.750000,-0.399000
+0.399000,-0.750000,-0.712500
+0.000000,-0.750000,-0.712500
+-0.420000,-0.675000,-0.750000
+-0.750000,-0.675000,-0.420000
+-0.750000,-0.675000,-0.000000
+-0.420000,-0.712500,-0.750000
+-0.750000,-0.712500,-0.420000
+-0.750000,-0.712500,-0.000000
+-0.399000,-0.750000,-0.712500
+-0.712500,-0.750000,-0.399000
+-0.712500,-0.750000,-0.000000
+-0.750000,-0.675000,0.420000
+-0.420000,-0.675000,0.750000
+0.000000,-0.675000,0.750000
+-0.750000,-0.712500,0.420000
+-0.420000,-0.712500,0.750000
+0.000000,-0.712500,0.750000
+-0.712500,-0.750000,0.399000
+-0.399000,-0.750000,0.712500
+0.000000,-0.750000,0.712500
+0.420000,-0.675000,0.750000
+0.750000,-0.675000,0.420000
+0.420000,-0.712500,0.750000
+0.750000,-0.712500,0.420000
+0.399000,-0.750000,0.712500
+0.712500,-0.750000,0.399000
diff --git a/examples/quick3d/shaders/qml/shaders.qml b/examples/quick3d/shaders/qml/shaders.qml
new file mode 100644
index 000000000..4b6237797
--- /dev/null
+++ b/examples/quick3d/shaders/qml/shaders.qml
@@ -0,0 +1,93 @@
+import Qt 4.7
+
+Rectangle {
+ property int current : 0
+
+ Rectangle {
+ id: tabContentArea
+ width: parent.width
+
+ anchors.top: parent.top
+ anchors.bottom: tabBar.top
+ Repeater {
+ model: tabsModel
+ }
+ }
+
+ VisualItemModel {
+ id: tabsModel
+ Animation { }
+ Collapsing { }
+ Images { }
+ Interpolate { }
+ }
+
+ Rectangle {
+ id: tabButtonArea
+ height: 64
+ width: parent.width
+
+ anchors.left: parent.left
+ anchors.right: parent.right
+ anchors.bottom: parent.bottom
+
+ gradient: Gradient {
+ GradientStop {position: 0.0; color: "#CCCCCC"}
+ GradientStop {position: 1.0; color: "#000000"}
+ }
+
+ Component {
+ id: tabButton
+ onStatusChanged:
+
+ function tabClicked(index)
+ {
+ tabs.children[current].color = "transparent";
+ tabsModel.children[current].visible = false;
+ current = index;
+ tabs.children[current].color = "#30ffffff";
+ tabsModel.children[current].visible = true;
+ }
+
+ Rectangle {
+ height: tabButtonArea.height
+ width: tabs.width / tabsModel.count
+
+ color: "transparent"
+
+ Image {
+ source: tabsModel.children[index].icon
+ anchors.horizontalCenter: parent.horizontalCenter
+ anchors.top: parent.top
+ anchors.topMargin: 4
+ }
+
+ Text {
+ anchors.horizontalCenter: parent.horizontalCenter
+ anchors.bottom: parent.bottom
+ anchors.bottomMargin: 4
+ color: "white"
+ text: tabsModel.children[index].name
+ }
+
+ MouseArea {
+ anchors.fill: parent
+ onClicked: {
+ tabClicked(index);
+ }
+ }
+ }
+ }
+
+ Row {
+ id: tabs
+ anchors.fill: parent
+ Repeater {
+ model: tabsModel.count
+ delegate: tabButton
+ }
+ }
+ }
+
+ Component.onCompleted:
+}
diff --git a/examples/quick3d/shaders/shaders.pro b/examples/quick3d/shaders/shaders.pro
new file mode 100644
index 000000000..dbae98a47
--- /dev/null
+++ b/examples/quick3d/shaders/shaders.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+
+SOURCES += main.cpp
diff --git a/examples/quick3d/sphere/main.cpp b/examples/quick3d/sphere/main.cpp
new file mode 100644
index 000000000..1bb9eb978
--- /dev/null
+++ b/examples/quick3d/sphere/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/photoroom.qml"));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/sphere/qml/sphere.qml b/examples/quick3d/sphere/qml/sphere.qml
new file mode 100644
index 000000000..b6adacb30
--- /dev/null
+++ b/examples/quick3d/sphere/qml/sphere.qml
@@ -0,0 +1,171 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+import Qt3D.Shapes 1.0
+
+Viewport {
+ width: 800; height: 480
+
+ Item3D {
+ effect: Effect { color: "#aaca00" }
+
+ Sphere {
+ radius: 0.5
+ x: -2.5
+ y: 0.6
+ levelOfDetail: 1
+
+ transform: Rotation3D {
+ angle: 45
+ axis: Qt.vector3d(1, -1, 1)
+ }
+ }
+
+ Sphere {
+ radius: 0.5
+ x: -1.25
+ y: 0.6
+ levelOfDetail: 2
+
+ transform: Rotation3D {
+ angle: 45
+ axis: Qt.vector3d(1, -1, 1)
+ }
+ }
+
+ Sphere {
+ radius: 0.5
+ x: 0
+ y: 0.6
+ levelOfDetail: 3
+
+ transform: Rotation3D {
+ angle: 45
+ axis: Qt.vector3d(1, -1, 1)
+ }
+ }
+
+ Sphere {
+ radius: 0.5
+ x: 1.25
+ y: 0.6
+ levelOfDetail: 4
+
+ transform: Rotation3D {
+ angle: 45
+ axis: Qt.vector3d(1, -1, 1)
+ }
+ }
+
+ Sphere {
+ radius: 0.5
+ x: 2.5
+ y: 0.6
+ levelOfDetail: 5
+
+ transform: Rotation3D {
+ angle: 45
+ axis: Qt.vector3d(1, -1, 1)
+ }
+ }
+
+ Sphere {
+ radius: 0.5
+ x: -2.5
+ y: -0.6
+ levelOfDetail: 6
+
+ transform: Rotation3D {
+ angle: 45
+ axis: Qt.vector3d(1, -1, 1)
+ }
+ }
+
+ Sphere {
+ radius: 0.5
+ x: -1.25
+ y: -0.6
+ levelOfDetail: 7
+
+ transform: Rotation3D {
+ angle: 45
+ axis: Qt.vector3d(1, -1, 1)
+ }
+ }
+
+ Sphere {
+ radius: 0.5
+ x: 0
+ y: -0.6
+ levelOfDetail: 8
+
+ transform: Rotation3D {
+ angle: 45
+ axis: Qt.vector3d(1, -1, 1)
+ }
+ }
+
+ Sphere {
+ radius: 0.5
+ x: 1.25
+ y: -0.6
+ levelOfDetail: 9
+
+ transform: Rotation3D {
+ angle: 45
+ axis: Qt.vector3d(1, -1, 1)
+ }
+ }
+
+ Sphere {
+ radius: 0.5
+ x: 2.5
+ y: -0.6
+ levelOfDetail: 10
+
+ transform: Rotation3D {
+ angle: 45
+ axis: Qt.vector3d(1, -1, 1)
+ }
+ }
+ }
+}
diff --git a/examples/quick3d/sphere/sphere.pro b/examples/quick3d/sphere/sphere.pro
new file mode 100644
index 000000000..dbae98a47
--- /dev/null
+++ b/examples/quick3d/sphere/sphere.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+
+SOURCES += main.cpp
diff --git a/examples/quick3d/teapot/main.cpp b/examples/quick3d/teapot/main.cpp
new file mode 100644
index 000000000..731d04d0e
--- /dev/null
+++ b/examples/quick3d/teapot/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/teapot.qml"));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/teapot/qml/teapot.qml b/examples/quick3d/teapot/qml/teapot.qml
new file mode 100644
index 000000000..ebb126c01
--- /dev/null
+++ b/examples/quick3d/teapot/qml/teapot.qml
@@ -0,0 +1,50 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D examples of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:BSD$
+** You may use this file under the terms of the BSD license as follows:
+**
+** "Redistribution and use in source and binary forms, with or without
+** modification, are permitted provided that the following conditions are
+** met:
+** * Redistributions of source code must retain the above copyright
+** notice, this list of conditions and the following disclaimer.
+** * Redistributions in binary form must reproduce the above copyright
+** notice, this list of conditions and the following disclaimer in
+** the documentation and/or other materials provided with the
+** distribution.
+** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+** the names of its contributors may be used to endorse or promote
+** products derived from this software without specific prior written
+** permission.
+**
+** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+import Qt 4.7
+import Qt3D 1.0
+
+Viewport {
+ width: 640; height: 480
+ Item3D {
+ mesh: Mesh { source: "meshes/teapot.bez" }
+ effect: Effect {}
+ }
+}
diff --git a/examples/quick3d/teapot/teapot.pro b/examples/quick3d/teapot/teapot.pro
new file mode 100644
index 000000000..dbae98a47
--- /dev/null
+++ b/examples/quick3d/teapot/teapot.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+
+SOURCES += main.cpp
diff --git a/examples/quick3d/textures/basket.jpg b/examples/quick3d/textures/basket.jpg
new file mode 100644
index 000000000..438e7a0c2
--- /dev/null
+++ b/examples/quick3d/textures/basket.jpg
Binary files differ
diff --git a/examples/quick3d/textures/button/face-name.png b/examples/quick3d/textures/button/face-name.png
new file mode 100644
index 000000000..280aa62f7
--- /dev/null
+++ b/examples/quick3d/textures/button/face-name.png
Binary files differ
diff --git a/examples/quick3d/textures/button/face-name.xcf b/examples/quick3d/textures/button/face-name.xcf
new file mode 100644
index 000000000..ea733fce5
--- /dev/null
+++ b/examples/quick3d/textures/button/face-name.xcf
Binary files differ
diff --git a/examples/quick3d/textures/button/face.png b/examples/quick3d/textures/button/face.png
new file mode 100644
index 000000000..327c88423
--- /dev/null
+++ b/examples/quick3d/textures/button/face.png
Binary files differ
diff --git a/examples/quick3d/textures/button/full-address.png b/examples/quick3d/textures/button/full-address.png
new file mode 100644
index 000000000..8c83ac062
--- /dev/null
+++ b/examples/quick3d/textures/button/full-address.png
Binary files differ
diff --git a/examples/quick3d/textures/button/full-address.xcf b/examples/quick3d/textures/button/full-address.xcf
new file mode 100644
index 000000000..1b1815382
--- /dev/null
+++ b/examples/quick3d/textures/button/full-address.xcf
Binary files differ
diff --git a/examples/quick3d/textures/button/woman-photo-credit.txt b/examples/quick3d/textures/button/woman-photo-credit.txt
new file mode 100644
index 000000000..c7f04c1c9
--- /dev/null
+++ b/examples/quick3d/textures/button/woman-photo-credit.txt
@@ -0,0 +1,5 @@
+http://www.flickr.com/photos/fromthefrontend/
+
+Attribution:
+
+<div xmlns:cc="http://creativecommons.org/ns#" about="http://www.flickr.com/photos/fromthefrontend/4527587863/"><a rel="cc:attributionURL" href="http://www.flickr.com/photos/fromthefrontend/">http://www.flickr.com/photos/fromthefrontend/</a> / <a rel="license" href="http://creativecommons.org/licenses/by/2.0/">CC BY 2.0</a></div>
diff --git a/examples/quick3d/textures/button/woman.jpg b/examples/quick3d/textures/button/woman.jpg
new file mode 100644
index 000000000..f3a6abc28
--- /dev/null
+++ b/examples/quick3d/textures/button/woman.jpg
Binary files differ
diff --git a/examples/quick3d/textures/main.cpp b/examples/quick3d/textures/main.cpp
new file mode 100644
index 000000000..cdad31ad5
--- /dev/null
+++ b/examples/quick3d/textures/main.cpp
@@ -0,0 +1,60 @@
+/****************************************************************************
+**
+** Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+** All rights reserved.
+** Contact: Nokia Corporation (qt-info@nokia.com)
+**
+** This file is part of the QtQuick3D module of the Qt Toolkit.
+**
+** $QT_BEGIN_LICENSE:LGPL$
+** No Commercial Usage
+** This file contains pre-release code and may not be distributed.
+** You may use this file in accordance with the terms and conditions
+** contained in the Technology Preview License Agreement accompanying
+** this package.
+**
+** GNU Lesser General Public License Usage
+** Alternatively, this file may be used under the terms of the GNU Lesser
+** General Public License version 2.1 as published by the Free Software
+** Foundation and appearing in the file LICENSE.LGPL included in the
+** packaging of this file. Please review the following information to
+** ensure the GNU Lesser General Public License version 2.1 requirements
+** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html.
+**
+** In addition, as a special exception, Nokia gives you certain additional
+** rights. These rights are described in the Nokia Qt LGPL Exception
+** version 1.1, included in the file LGPL_EXCEPTION.txt in this package.
+**
+** If you have questions regarding the use of this file, please contact
+** Nokia at qt-info@nokia.com.
+**
+**
+**
+**
+**
+**
+**
+**
+** $QT_END_LICENSE$
+**
+****************************************************************************/
+
+#include <QtGui/QApplication>
+#include <QtDeclarative/qdeclarativeview.h>
+
+int main(int argc, char *argv[])
+{
+ QApplication app(argc, argv);
+
+ QDeclarativeView view;
+ view.setSource(QUrl::fromLocalFile(QLatin1String("qml/model_viewer.qml"));
+
+ if (QApplication::arguments().contains(QLatin1String("-maximize")))
+ view.showMaximized();
+ else if (QApplication::arguments().contains(QLatin1String("-fullscreen")))
+ view.showFullScreen();
+ else
+ view.show();
+
+ return app.exec();
+}
diff --git a/examples/quick3d/textures/photos/background.jpg b/examples/quick3d/textures/photos/background.jpg
new file mode 100644
index 000000000..9884233a2
--- /dev/null
+++ b/examples/quick3d/textures/photos/background.jpg
Binary files differ
diff --git a/examples/quick3d/textures/photos/niagara_falls.jpg b/examples/quick3d/textures/photos/niagara_falls.jpg
new file mode 100644
index 000000000..7a912d3b9
--- /dev/null
+++ b/examples/quick3d/textures/photos/niagara_falls.jpg
Binary files differ
diff --git a/examples/quick3d/textures/photos/place.jpg b/examples/quick3d/textures/photos/place.jpg
new file mode 100644
index 000000000..03e534433
--- /dev/null
+++ b/examples/quick3d/textures/photos/place.jpg
Binary files differ
diff --git a/examples/quick3d/textures/qtlogo.png b/examples/quick3d/textures/qtlogo.png
new file mode 100644
index 000000000..7d3e97eb3
--- /dev/null
+++ b/examples/quick3d/textures/qtlogo.png
Binary files differ
diff --git a/examples/quick3d/textures/textures.pro b/examples/quick3d/textures/textures.pro
new file mode 100644
index 000000000..dbae98a47
--- /dev/null
+++ b/examples/quick3d/textures/textures.pro
@@ -0,0 +1,4 @@
+qmlFiles.sources = qml
+DEPLOYMENT += qmlFiles
+
+SOURCES += main.cpp