diff --git a/src/wayland/externalbrightness_v1.cpp b/src/wayland/externalbrightness_v1.cpp index 0cf78f38bf..9c6dfa0478 100644 --- a/src/wayland/externalbrightness_v1.cpp +++ b/src/wayland/externalbrightness_v1.cpp @@ -60,7 +60,8 @@ ExternalBrightnessDeviceV1::~ExternalBrightnessDeviceV1() void ExternalBrightnessDeviceV1::setBrightness(double brightness) { - const uint32_t val = std::clamp(std::round(brightness * m_maxBrightness), 0, m_maxBrightness); + const uint32_t minBrightness = m_internal ? 1 : 0; // some laptop screens turn off at brightness 0 + const uint32_t val = std::round(std::lerp(minBrightness, m_maxBrightness, std::clamp(brightness, 0.0, 1.0))); send_requested_brightness(val); }