QAbstractAnimation Class▲
-
Header: QAbstractAnimation
-
Since: Qt 5.9
-
CMake:
find_package(Qt6 REQUIRED COMPONENTS 3danimation)
target_link_libraries(mytarget PRIVATE Qt6::3danimation)
-
qmake: QT += 3danimation
-
Inherited By: Qt3DAnimation::QKeyframeAnimation, Qt3DAnimation::QMorphingAnimation, and Qt3DAnimation::QVertexBlendAnimation
-
Instantiated By: qml-qt3d-animation-abstractanimation.xml
-
Inherits: QObject
-
Inherited By: Qt3DAnimation::QKeyframeAnimation, Qt3DAnimation::QMorphingAnimation, and Qt3DAnimation::QVertexBlendAnimation
Detailed Description▲
Qt3DAnimation::QAbstractAnimation is an abstract base class for all animations. Qt3DAnimation::QAbstractAnimation can not be directly instantiated, but rather through its subclasses. QAbstractAnimation specifies common properties for all Qt3D animations, such as animation name and type, current position and animation duration, while leaving the actual animating for the subclasses.
Member Type Documentation▲
enum QAbstractAnimation::AnimationType▲
This enumeration specifies the type of the animation
Constant |
Value |
Description |
---|---|---|
Qt3DAnimation::QAbstractAnimation::KeyframeAnimation |
1 |
Simple keyframe animation implementation for QTransform |
Qt3DAnimation::QAbstractAnimation::MorphingAnimation |
2 |
Blend-shape morphing animation |
Qt3DAnimation::QAbstractAnimation::VertexBlendAnimation |
3 |
Vertex-blend animation |
Property Documentation▲
animationName : QString▲
Holds the name of the animation.
Access functions:
-
animationName() const
-
void setAnimationName(const &name)
Notifier signal:
-
void animationNameChanged(const &name)
[read-only] animationType : const AnimationType▲
Holds the type of the animation.
Access functions:
-
animationType() const
[read-only] duration : const float▲
Holds the duration of the animation.
Access functions:
-
float duration() const
Notifier signal:
-
void durationChanged(float duration)
position : float▲
Holds the current position of the animation.
Access functions:
-
float position() const
-
void setPosition(float position)
Notifier signal:
-
void positionChanged(float position)