Qt3DCore::QAbstractAspect Class
class Qt3DCore::QAbstractAspectQAbstractAspect è la classe base per gli aspetti che forniscono una sezione verticale del comportamento. Per saperne di più...
| Intestazione: | #include <Qt3DCore/QAbstractAspect> |
| CMake: | find_package(Qt6 REQUIRED COMPONENTS 3DCore) target_link_libraries(mytarget PRIVATE Qt6::3DCore) |
| qmake: | QT += 3dcore |
| Eredita da: | QObject |
| Ereditato da: | Qt3DAnimation::QAnimationAspect, Qt3DInput::QInputAspect, Qt3DLogic::QLogicAspect e Qt3DRender::QRenderAspect |
| Stato: | Obsoleta |
Questa classe è deprecata. Si sconsiglia vivamente di utilizzarla nel nuovo codice.
Funzioni pubbliche
| QAbstractAspect(QObject *parent = nullptr) |
Funzioni protette
| void | registerBackendType(const Qt3DCore::QBackendNodeMapperPtr &functor) |
| void | registerBackendType(const QMetaObject &obj, const Qt3DCore::QBackendNodeMapperPtr &functor) |
| Qt3DCore::QNodeId | rootEntityId() const |
Elementi non membri correlati
Macro
| QT3D_REGISTER_ASPECT(name, AspectType) |
Documentazione sulle funzioni membro
[explicit] QAbstractAspect::QAbstractAspect(QObject *parent = nullptr)
Crea un nuovo oggetto QAbstractAspect con parent
[protected] template <typename Frontend> void QAbstractAspect::registerBackendType(const Qt3DCore::QBackendNodeMapperPtr &functor)
Registra il backend su functor.
[protected] void QAbstractAspect::registerBackendType(const QMetaObject &obj, const Qt3DCore::QBackendNodeMapperPtr &functor)
Registra il backend su obj e functor.
[noexcept protected] Qt3DCore::QNodeId QAbstractAspect::rootEntityId() const
Restituisce l'ID del nodo dell'entità radice.
Elementi correlati non membri
QAspectJobPtr
Un puntatore condiviso per QAspectJob.
QBackendNodeMapperPtr
Un puntatore condiviso per QBackendNodeMapper.
Documentazione sulle macro
QT3D_REGISTER_ASPECT(name, AspectType)
Macro di comodità per registrare AspectType affinché venga istanziato dall'oggetto Qt3DCore::QAspectFactory attualmente impostato. Ciò consente di creare un'istanza di AspectType nel thread degli aspetti passando successivamente name a Qt3DCore::QAspectEngine::registerAspect(const QString &name).
Nota: è anche possibile registrare un nuovo aspetto senza utilizzare questa macro, ricorrendo invece a ` Qt3DCore::QAspectEngine::registerAspect` (`QAbstractAspect *aspect`), che si occuperà di spostare un'istanza di aspetto creata in precedenza nel contesto del thread degli aspetti.
KDAB ha pubblicato sul proprio blog alcuni articoli sulla scrittura di aspetti Qt3D personalizzati. Questi rappresentano un ottimo punto di partenza se desiderate approfondire l’argomento.
© 2026 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.