QComponent Class

class Qt3DCore::QComponent

Qt3DCore::QEntity インスタンスをコンポーネントとして集約できるシーンノードの基本クラスです。詳細...

プロパティ

パブリック機能

QComponent(Qt3DCore::QNode *parent = nullptr)
QList<Qt3DCore::QEntity *> entities() const
bool isShareable() const

パブリックスロット

void setShareable(bool isShareable)

シグナル

void addedToEntity(Qt3DCore::QEntity *entity)
void removedFromEntity(Qt3DCore::QEntity *entity)
void shareableChanged(bool isShareable)

詳細説明

Qt3DCore::QComponent は、Qt3DCore::QEntity インスタンスに割り当てることができ、場合によっては全体で共有することもできる、垂直方向の振る舞いのスライスを提供します。

Qt3DCore::QComponent サブクラスは多くの場合、集約エンティティに有用な振る舞いを与えるグループに集約されます。たとえば、Qt3D レンダラのアスペクトによって描画されるエンティティを持つには、 、 、 コンポーネントが集約されます。Qt3DCore::QTransform Qt3DRender::QMesh Qt3DRender::QMaterial

Qt3DCore::QEntityも参照してください

プロパティのドキュメント

isShareable : bool

QComponent の共有可能フラグを保持する。true の場合、QComponent は複数のエンティティで共有できる。

アクセス関数:

bool isShareable() const
void setShareable(bool isShareable)

Notifier シグナル:

void shareableChanged(bool isShareable)

メンバ関数ドキュメント

[explicit] QComponent::QComponent(Qt3DCore::QNode *parent = nullptr)

parent を親として新しい QComponent インスタンスを構築します。

注意: QComponent を直接インスタンス化してはいけません。

[signal] void QComponent::addedToEntity(Qt3DCore::QEntity *entity)

entity に参照が追加されたことを示す。

QList<Qt3DCore::QEntity *> QComponent::entities() const

このコンポーネントを参照しているすべてのエンティティを含むQList を返します。

[signal] void QComponent::removedFromEntity(Qt3DCore::QEntity *entity)

entity から参照が削除されたことを示す。

© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.