Used to transforms parts of skinned meshes. 更多...
头: | #include <QJoint> |
CMake: |
find_package(Qt6 COMPONENTS 3dcore REQUIRED)
target_link_libraries(mytarget PRIVATE Qt6::3dcore) |
qmake: | QT += 3dcore |
Since: | Qt 5.10 |
实例化: | Joint |
继承: | Qt3DCore::QNode |
|
|
QJoint (Qt3DCore::QNode * parent = nullptr) | |
void | addChildJoint (Qt3DCore::QJoint * joint ) |
QList<Qt3DCore::QJoint *> | childJoints () const |
QMatrix4x4 | inverseBindMatrix () const |
QString | name () const |
void | removeChildJoint (Qt3DCore::QJoint * joint ) |
QQuaternion | rotation () const |
float | rotationX () const |
float | rotationY () const |
float | rotationZ () const |
QVector3D | scale () const |
QVector3D | translation () const |
void | setInverseBindMatrix (const QMatrix4x4 & inverseBindMatrix ) |
void | setName (const QString & name ) |
void | setRotation (const QQuaternion & rotation ) |
void | setRotationX (float rotationX ) |
void | setRotationY (float rotationY ) |
void | setRotationZ (float rotationZ ) |
void | setScale (const QVector3D & scale ) |
void | setToIdentity () |
void | setTranslation (const QVector3D & translation ) |
void | inverseBindMatrixChanged (const QMatrix4x4 & inverseBindMatrix ) |
void | nameChanged (const QString & name ) |
void | rotationChanged (const QQuaternion & rotation ) |
void | rotationXChanged (float rotationX ) |
void | rotationYChanged (float rotationY ) |
void | rotationZChanged (float rotationZ ) |
void | scaleChanged (const QVector3D & scale ) |
void | translationChanged (const QVector3D & translation ) |
The QJoint node is used to build skeletons as part of the skinned mesh support in Qt 3D. A joint can be transformed by way of its scale, rotation and translation properties. Any mesh vertices that are bound to the joint will have their transformations updated accordingly.
Holds the inverse bind matrix of the joint. This is used to transform vertices from model space into the space of this joint so they can subsequently be multiplied by the joint's global transform to perform the skinning operation.
访问函数:
QMatrix4x4 | inverseBindMatrix () const |
void | setInverseBindMatrix (const QMatrix4x4 & inverseBindMatrix ) |
通知程序信号:
void | inverseBindMatrixChanged (const QMatrix4x4 & inverseBindMatrix ) |
Holds the rotation of the joint as QQuaternion .
访问函数:
QQuaternion | rotation () const |
void | setRotation (const QQuaternion & rotation ) |
通知程序信号:
void | rotationChanged (const QQuaternion & rotation ) |
Holds the x rotation of the joint as an Euler angle.
访问函数:
float | rotationX () const |
void | setRotationX (float rotationX ) |
通知程序信号:
void | rotationXChanged (float rotationX ) |
Holds the y rotation of the joint as an Euler angle.
访问函数:
float | rotationY () const |
void | setRotationY (float rotationY ) |
通知程序信号:
void | rotationYChanged (float rotationY ) |
Holds the z rotation of the joint as an Euler angle.
访问函数:
float | rotationZ () const |
void | setRotationZ (float rotationZ ) |
通知程序信号:
void | rotationZChanged (float rotationZ ) |
Holds the scale of the joint.
访问函数:
QVector3D | scale () const |
void | setScale (const QVector3D & scale ) |
通知程序信号:
void | scaleChanged (const QVector3D & scale ) |
Holds the translation of the joint as QVector3D .
访问函数:
QVector3D | translation () const |
void | setTranslation (const QVector3D & translation ) |
通知程序信号:
void | translationChanged (const QVector3D & translation ) |
Constructs a new QJoint with parent .
[slot]
void
QJoint::
setToIdentity
()
Sets the transform matrix for this joint to the identity matrix.
添加 joint as a child of this joint. If joint has no parent, then this joint takes ownership of it. Child joints are in the coordinate system of their parent joint.
The vector of joints this joint has as children.
Returns the name of the joint.
注意: Getter function for property name.
另请参阅 setName ().
移除 joint from this joint's list of children. The child joint is not destroyed.