Qt3DAnimation::QMorphTarget Class

class Qt3DAnimation::QMorphTarget

A class providing morph targets to blend-shape animation. 更多...

頭: #include <QMorphTarget>
CMake: find_package(Qt6 REQUIRED COMPONENTS 3danimation)
target_link_libraries(mytarget PRIVATE Qt6::3danimation)
qmake: QT += 3danimation
在 QML: MorphTarget
繼承: QObject
狀態: 棄用

特性

公共函數

QMorphTarget (QObject * parent = nullptr)
void addAttribute (Qt3DCore::QAttribute * attribute )
QList<Qt3DCore::QAttribute *> attributeList () const
QStringList attributeNames () const
void removeAttribute (Qt3DCore::QAttribute * attribute )
void setAttributes (const QList<Qt3DCore::QAttribute *> & 屬性 )

信號

void attributeNamesChanged (const QStringList & attributeNames )

靜態公共成員

Qt3DAnimation::QMorphTarget * fromGeometry (Qt3DCore::QGeometry * geometry , const QStringList & 屬性 )

詳細描述

A Qt3DAnimation::QMorphTarget class is a convenience class, which provides a list of QAttributes , which the QMorphingAnimation uses to animate geometry. A QMorphTarget can also be created based on existing Qt3DCore::QGeometry .

特性文檔編製

[read-only] attributeNames : const QStringList

Holds a list of attribute names contained in the morph target.

訪問函數:

QStringList attributeNames () const

通知程序信號:

void attributeNamesChanged (const QStringList & attributeNames )

成員函數文檔編製

[explicit] QMorphTarget:: QMorphTarget ( QObject * parent = nullptr)

Constructs a QMorphTarget with given parent .

void QMorphTarget:: addAttribute ( Qt3DCore::QAttribute * attribute )

添加 attribute the morph target. An attribute with the same name must not have been added previously to the morph target.

QList < Qt3DCore::QAttribute *> QMorphTarget:: attributeList () const

Returns a list of attributes contained in the morph target.

[static invokable] Qt3DAnimation::QMorphTarget *QMorphTarget:: fromGeometry ( Qt3DCore::QGeometry * geometry , const QStringList & 屬性 )

Returns a morph target based on the attributes 以給定 geometry .

注意: 此函數可以被援引,通過元對象係統和從 QML。見 Q_INVOKABLE .

void QMorphTarget:: removeAttribute ( Qt3DCore::QAttribute * attribute )

Removes an attribute from the morph target.

void QMorphTarget:: setAttributes (const QList < Qt3DCore::QAttribute *> & 屬性 )

設置 attributes to the morph target. Old attributes are cleared.