QSkeletonLoader Class

( Qt3DCore::QSkeletonLoader )

Used to load a skeleton of joints from file. 更多...

頭: #include <QSkeletonLoader>
qmake: QT += 3dcore
Since: Qt 5.10
實例化: SkeletonLoader
繼承: Qt3DCore::QAbstractSkeleton

公共類型

enum Status { NotReady, Ready, Error }

特性

公共函數

QSkeletonLoader (Qt3DCore::QNode * parent = nullptr)
QSkeletonLoader (const QUrl & source , Qt3DCore::QNode * parent = nullptr)
bool isCreateJointsEnabled () const
Qt3DCore::QJoint * rootJoint () const
QUrl source () const
Qt3DCore::QSkeletonLoader::Status status () const

公共槽

void setCreateJointsEnabled (bool enabled )
void setSource (const QUrl & source )

信號

void createJointsEnabledChanged (bool createJointsEnabled )
void rootJointChanged (Qt3DCore::QJoint * rootJoint )
void sourceChanged (const QUrl & source )
void statusChanged (Qt3DCore::QSkeletonLoader::Status status )

靜態公共成員

const QMetaObject staticMetaObject

額外繼承成員

詳細描述

Used to load a skeleton of joints from file.

使用 SkeletonLoader if you wish to load a whole skeleton from file rather than creating the joints yourself using Skeleton and Joints. Creating a skeleton and binding the vertices of a mesh to the skeleton is most easily performed in a 3D digital content creation tool such as Blender. The resulting skeleton and mesh can then be exported in a suitable format such as glTF 2 for consumption by Qt 3D.

成員類型文檔編製

enum QSkeletonLoader:: Status

This enum identifies the status of skeleton.

常量 描述
Qt3DCore::QSkeletonLoader::NotReady 0 The skeleton has not been loaded yet
Qt3DCore::QSkeletonLoader::Ready 1 The skeleton was successfully loaded
Qt3DCore::QSkeletonLoader::Error 2 An error occurred while loading the skeleton

特性文檔編製

createJointsEnabled : bool

This property holds a boolean to indicate whether createJoints is enabled or not.

訪問函數:

bool isCreateJointsEnabled () const
void setCreateJointsEnabled (bool enabled )

通知程序信號:

void createJointsEnabledChanged (bool createJointsEnabled )

rootJoint : Qt3DCore::QJoint * const

訪問函數:

Qt3DCore::QJoint * rootJoint () const

通知程序信號:

void rootJointChanged (Qt3DCore::QJoint * rootJoint )

source : QUrl

Holds the source url from which to load the skeleton.

訪問函數:

QUrl source () const
void setSource (const QUrl & source )

通知程序信號:

void sourceChanged (const QUrl & source )

status : const Status

Holds the current status of skeleton loading.

訪問函數:

Qt3DCore::QSkeletonLoader::Status status () const

通知程序信號:

void statusChanged (Qt3DCore::QSkeletonLoader::Status status )

成員函數文檔編製

QSkeletonLoader:: QSkeletonLoader ( Qt3DCore::QNode * parent = nullptr)

構造新的 QSkeletonLoader with parent .

QSkeletonLoader:: QSkeletonLoader (const QUrl & source , Qt3DCore::QNode * parent = nullptr)

構造新的 QSkeletonLoader with parent 和設置 source .

bool QSkeletonLoader:: isCreateJointsEnabled () const

Returns a boolean indicating whether CreateJoints is enabled or not. The default value is false .

注意: getter 函數對於特性 createJointsEnabled .

Qt3DCore::QJoint *QSkeletonLoader:: rootJoint () const

Returns the root joint of the hierarchy of joints forming the skeleton.

注意: getter 函數對於特性 rootJoint .