summaryrefslogtreecommitdiffstats
path: root/examples/qt3d/scene2d/doc/src/scene2d.qdoc
diff options
context:
space:
mode:
Diffstat (limited to 'examples/qt3d/scene2d/doc/src/scene2d.qdoc')
-rw-r--r--examples/qt3d/scene2d/doc/src/scene2d.qdoc23
1 files changed, 12 insertions, 11 deletions
diff --git a/examples/qt3d/scene2d/doc/src/scene2d.qdoc b/examples/qt3d/scene2d/doc/src/scene2d.qdoc
index 66cf7dd21..90b767e43 100644
--- a/examples/qt3d/scene2d/doc/src/scene2d.qdoc
+++ b/examples/qt3d/scene2d/doc/src/scene2d.qdoc
@@ -74,25 +74,25 @@
\section1 Rendering Qt Quick into a Texture
We begin by declaring the Entity that will become our control panel. It consists of
- a PlaneMesh onto which we will place the texture containing a rendering of the Qt Quick
- scene. In this case we are using a simple flat plane for the geometry, but we could use
+ a CuboidMesh onto which we will place the texture containing a rendering of the Qt Quick
+ scene. In this case we are using a simple cube for the geometry, but we could use
any valid 3D geometry as long as it has texture coordinates. The texture coordinates
are used for projecting the texture onto the 3D surface, and also for calculating the
coordinates of mouse events to be passed to the originating Qt Quick scene.
\skipto Entity {
- \printto }
- \printto }
-
- Note that we enable the mirrored property on the PlaneMesh to ensure that the texture
- coordinate vertical axis is aligned with the usual Qt window coordinate system.
+ \printto Behavior
+ \skipto Transform {
+ \printuntil }
+ \printuntil }
We also include an ObjectPicker component so that we can interact with the controls
using the mouse:
\skipto ObjectPicker {
- \printto }
- \printto }
+ \printuntil }
+ \printuntil }
+ \printuntil }
For this example we have chosen to use an interaction mechanism whereby you must
explicitly middle-click the controls to enable them.
@@ -100,7 +100,7 @@
To apply the texture to the mesh, we make use of the built in TextureMaterial:
\skipto TextureMaterial
- \printto }
+ \printuntil }
The final remaining piece is how to render the above texture from a Qt Quick scene.
This is done with the Scene2D element:
@@ -122,7 +122,8 @@
as a child to the Scene2D element:
\skipto LogoControls
- \printto }
+ \printuntil }
+ \printuntil }
When the mouseEnabled property is set to true by the ObjectPicker, then the Scene2D
object will process mouse events from any ObjectPickers attached to the listed entities.