Qt3DExtras::QTextureMaterial Class
class Qt3DExtras::QTextureMaterialLe matériau QTextureMaterial fournit une implémentation par défaut d'un matériau de texture simple non éclairé. Plus d'informations...
| En-tête : | #include <QTextureMaterial> |
| CMake : | find_package(Qt6 REQUIRED COMPONENTS 3dextras)target_link_libraries(mytarget PRIVATE Qt6::3dextras) |
| qmake : | QT += 3dextras |
| Hérite : | Qt3DRender::QMaterial |
| Statut : | Déclassé |
Propriétés
- alphaBlending : bool
- texture : Qt3DRender::QAbstractTexture*
- textureOffset : QVector2D
- textureTransform : QMatrix3x3
Fonctions publiques
| QTextureMaterial(Qt3DCore::QNode *parent = nullptr) | |
| virtual | ~QTextureMaterial() |
| bool | isAlphaBlendingEnabled() const |
| Qt3DRender::QAbstractTexture * | texture() const |
| QVector2D | textureOffset() const |
| QMatrix3x3 | textureTransform() const |
Emplacements publics
| void | setAlphaBlendingEnabled(bool enabled) |
| void | setTexture(Qt3DRender::QAbstractTexture *texture) |
| void | setTextureOffset(QVector2D textureOffset) |
| void | setTextureTransform(const QMatrix3x3 &matrix) |
Signaux
| void | alphaBlendingEnabledChanged(bool enabled) |
| void | textureChanged(Qt3DRender::QAbstractTexture *texture) |
| void | textureOffsetChanged(QVector2D textureOffset) |
| void | textureTransformChanged(const QMatrix3x3 &textureTransform) |
Description détaillée
Ce matériel utilise un effet avec une approche de rendu unique. Les techniques sont fournies pour OpenGL 2, OpenGL 3 ou supérieur ainsi que pour OpenGL ES 2.
Documentation sur les propriétés
alphaBlending : bool
Indique si les informations alpha provenant de la propriété diffuse seront prises en compte lors du rendu. La valeur par défaut est false.
Fonctions d'accès :
| bool | isAlphaBlendingEnabled() const |
| void | setAlphaBlendingEnabled(bool enabled) |
Signal du notificateur :
| void | alphaBlendingEnabledChanged(bool enabled) |
texture : Qt3DRender::QAbstractTexture*
Détient la texture actuelle utilisée par le matériau.
Fonctions d'accès :
| Qt3DRender::QAbstractTexture * | texture() const |
| void | setTexture(Qt3DRender::QAbstractTexture *texture) |
Signal de notification :
| void | textureChanged(Qt3DRender::QAbstractTexture *texture) |
textureOffset : QVector2D
Il s'agit d'une propriété utilitaire. Elle définit la composante de translation de la matrice de transformation générale de la texture.
Fonctions d'accès :
| QVector2D | textureOffset() const |
| void | setTextureOffset(QVector2D textureOffset) |
Signal de notification :
| void | textureOffsetChanged(QVector2D textureOffset) |
textureTransform : QMatrix3x3
Contient la transformation de texture actuelle. Elle est appliquée aux coordonnées de la texture au moment du rendu. La valeur par défaut est la matrice d'identité.
Fonctions d'accès :
| QMatrix3x3 | textureTransform() const |
| void | setTextureTransform(const QMatrix3x3 &matrix) |
Signal de notification :
| void | textureTransformChanged(const QMatrix3x3 &textureTransform) |
Fonction membre Documentation
[explicit] QTextureMaterial::QTextureMaterial(Qt3DCore::QNode *parent = nullptr)
Construit une nouvelle instance de QTextureMaterial avec l'objet parent parent.
[virtual noexcept] QTextureMaterial::~QTextureMaterial()
Détruit l'instance QTextureMaterial.
© 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.