54 lines
1.5 KiB
C++
54 lines
1.5 KiB
C++
#ifndef LIGHTMUX_H
|
|
#define LIGHTMUX_H
|
|
#include <QDebug>
|
|
|
|
class LightMux
|
|
{
|
|
private:
|
|
|
|
int brightness; // total power of the LED Panels (both colors) in percent
|
|
int temperatur; // muxed color temperature of the LED Panels, from coldest to warmest in Kelvin
|
|
|
|
int coldest_temperature = 6500; // coldest possible temperature in Kelvin --> the cold LEDs
|
|
int warmest_temperature = 2700; // warmest possible temperature in Kelvin --> the warm LEDs
|
|
int steps_temperature = 100; // steps to change the temperature in Kelvin
|
|
|
|
int power_cold; // power of the cold LEDs of Panels in percent
|
|
int power_warm; // power of the warm LEDs of Panels in percent
|
|
int power_combined; //combined power of both LEDs in percent
|
|
|
|
bool adaptive_brightness; // true indecates adaptive brightness is enabled
|
|
|
|
public:
|
|
LightMux();
|
|
|
|
void incBrightness();
|
|
void decBrightness();
|
|
|
|
void setBrightness(int val); // set total power of the LED Panels (both colors) in percent
|
|
|
|
void cold_Temperature();
|
|
void warm_Temperature();
|
|
|
|
void setTemperature(int requested_val); // set muxed color temperature of the LED Panels, from coldest to warmest in Kelvin. Fitted to the nearest value that the steps allow
|
|
|
|
int getBrightness();
|
|
|
|
int getTemperature();
|
|
|
|
int getColdest_temperature();
|
|
int getWarmest_temperature();
|
|
|
|
void mux();
|
|
|
|
int getPowerCold();
|
|
int getPowerWarm();
|
|
|
|
int getPowerCombined();
|
|
|
|
void toogleAdaptiveBrightness();
|
|
|
|
};
|
|
|
|
#endif // LIGHTMUX_H
|