QQuickQGraphicsTransform3D ClassThe QQuickQGraphicsTransform3D class is an abstract base class for building 3D transformations. More... #include <QQuickQGraphicsTransform3D> Inherits: QObject. Inherited by: QGraphicsBillboardTransform, QGraphicsLookAtTransform, QGraphicsRotation3D, QGraphicsScale3D, and QGraphicsTranslation3D. This class was introduced in Qt 4.8. Public Functions
Signals
Additional Inherited Members
Detailed DescriptionThe QQuickQGraphicsTransform3D class is an abstract base class for building 3D transformations. QQuickQGraphicsTransform3D lets you create and control advanced transformations that can be configured independently using specialized properties. Scene nodes have an associated list of transforms, which are applied in order, one at a time, to the modelview matrix. Transformations are computed in true 3D space using QMatrix4x4. QQuickQGraphicsTransform3D is particularly useful for animations. Whereas QGLPainter::modelViewMatrix() lets you assign any transform directly, there is no direct way to interpolate between two different transformations (e.g., when transitioning between two states, each for which the item has a different arbitrary transform assigned). Using QQuickQGraphicsTransform3D you can interpolate the property values of each independent transformation. The resulting operation is then combined into a single transform which is applied to the modelview matrix during drawing. If you want to create your own configurable transformation, you can create a subclass of QQuickQGraphicsTransform3D (or any or the existing subclasses), and reimplement the pure virtual applyTo() function, which takes a pointer to a QMatrix4x4. Each operation you would like to apply should be exposed as properties (e.g., customTransform->setVerticalShear(2.5)). Inside you reimplementation of applyTo(), you can modify the provided transform respectively. See also QGraphicsScale3D, QGraphicsRotation3D, QGraphicsTranslation3D, and QGraphicsBillboardTransform. Member Function Documentation
|