Reduce saturation in backlight (#651)

Former-commit-id: c2c4fd6f957c3623e03c37393cf3c03a7a27dc1e
This commit is contained in:
Funatiq 2016-05-24 22:15:39 +02:00 committed by brindosch
parent 06afe06774
commit 45dff6d1d3
1 changed files with 3 additions and 0 deletions

View File

@ -66,7 +66,10 @@ void HslTransform::transform(uint8_t & red, uint8_t & green, uint8_t & blue) con
float l = luminance * _luminanceGain;
if (l < _luminanceMinimum)
{
saturation *= l/_luminanceMinimum;
l = _luminanceMinimum;
}
if (l > 1.0f)
luminance = 1.0f;
else