Sur cette page

Qt3DRender::QAbstractLight Class

class Qt3DRender::QAbstractLight

Encapsule un objet QAbstractLight dans une scène Qt 3D. Plus...

En-tête : #include <QAbstractLight>
CMake : find_package(Qt6 REQUIRED COMPONENTS 3drender)
target_link_libraries(mytarget PRIVATE Qt6::3drender)
qmake : QT += 3drender
En QML : Light
Hérite : Qt3DCore::QComponent
Héritée par :

Qt3DRender::QDirectionalLight, Qt3DRender::QPointLight, et Qt3DRender::QSpotLight

Statut : Déclassé

Types publics

enum Type { PointLight, DirectionalLight, SpotLight }

Propriétés

Fonctions publiques

QColor color() const
float intensity() const
Qt3DRender::QAbstractLight::Type type() const

Emplacements publics

void setColor(const QColor &color)
void setIntensity(float intensity)

Signaux

void colorChanged(const QColor &color)
void intensityChanged(float intensity)

Description détaillée

Documentation des types de membres

enum QAbstractLight::Type

Identifie le type particulier de lumière.

ConstanteValeur
Qt3DRender::QAbstractLight::PointLight0
Qt3DRender::QAbstractLight::DirectionalLight1
Qt3DRender::QAbstractLight::SpotLight2

Propriété Documentation

color : QColor

Maintient la couleur actuelle de QAbstractLight.

Fonctions d'accès :

QColor color() const
void setColor(const QColor &color)

Signal de notification :

void colorChanged(const QColor &color)

intensity : float

Indique l'intensité actuelle de QAbstractLight.

Fonctions d'accès :

float intensity() const
void setIntensity(float intensity)

Signal de notification :

void intensityChanged(float intensity)

[read-only] type : Type

Le type de lumière.

Fonctions d'accès :

Qt3DRender::QAbstractLight::Type type() const

Documentation des fonctions membres

Qt3DRender::QAbstractLight::Type QAbstractLight::type() const

Indique le type actuel de QAbstractLight.

Note : Fonction d'obtention du type de propriété.

© 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.