Nesta página

QAmbientLightReading Class

A classe QAmbientLightReading representa uma leitura do sensor de luz ambiente. Mais...

Cabeçalho: #include <QAmbientLightReading>
CMake: find_package(Qt6 REQUIRED COMPONENTS Sensors)
target_link_libraries(mytarget PRIVATE Qt6::Sensors)
qmake: QT += sensors
Herdado de: QSensorReading

Tipos públicos

enum LightLevel { Undefined, Dark, Twilight, Light, Bright, Sunny }

Propriedades

Funções públicas

QAmbientLightReading::LightLevel lightLevel() const
void setLightLevel(QAmbientLightReading::LightLevel lightLevel)

Descrição detalhada

Unidades de leitura da luz ambiente

O sensor de luz ambiente retorna a intensidade da luz ambiente utilizando os valores predefinidos encontrados na enumeração ` QAmbientLightReading::LightLevel `.

Documentação do tipo de membro

enum QAmbientLightReading::LightLevel

Esta enumeração representa o nível de luz ambiente.

ConstanteValorDescrição
QAmbientLightReading::Undefined0O nível de luz é desconhecido.
QAmbientLightReading::Dark1Está escuro.
QAmbientLightReading::Twilight2Está moderadamente escuro.
QAmbientLightReading::Light3Está claro (por exemplo, luzes internas).
QAmbientLightReading::Bright4Está claro (por exemplo, sombra).
QAmbientLightReading::Sunny5Está muito claro (por exemplo, luz solar direta).

Documentação do imóvel

[read-only] lightLevel : LightLevel

Essa propriedade armazena o nível de luz ambiente.

O valor representa a luz ambiente e é proveniente de QAmbientLightReading::LightLevel.

Funções de acesso:

QAmbientLightReading::LightLevel lightLevel() const

Veja também QAmbientLightReading Units.

Documentação das funções de membro

void QAmbientLightReading::setLightLevel(QAmbientLightReading::LightLevel lightLevel)

Define o nível de luz ambiente como lightLevel.

Veja também lightLevel().

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