LIFX / lifx-protocol-docs

LIFX LAN protocol V2 documentation

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

HSBK Interpretation?

autolog opened this issue · comments

commented

Is there documentation available on how to interpret the HSBK values in relation to say the iOS app?

For example, when in colour mode, when I set the wheel to 50% in the iOS app, the B value is coming back as 100% (0xFFFF). Increasing the wheel to 75% leaves the B value at 100% and decreases the saturation value. I was just wondering if there is an algorithm documented as to how the iOS app decides how to interpret the wheel values and what HSBK values to set?

Internally we've been referring to this behaviour as intensity. When adjusting the ball slider on the colour wheel you're adjusting the intensity of the colour which is a combination of brightness and saturation. After 50% intensity we linearly decrease saturation while continuing to increase brightness. On iOS the minimum saturation is 20%. This behaviour only applies to colour and may change in a future release of our apps.

Example:

  • 0% intensity = 100% saturation, 0% brightness
  • 50% intensity = 100% saturation, 100% brightness
  • 100% intensity = 20% saturation, 100% brightness
commented

Thanks - that is very helpful 👍