mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2023-10-10 13:36:59 +02:00
Fix bug in hsv2rgb transform
This commit is contained in:
parent
94a8dfad2f
commit
02fa8f5679
@ -103,7 +103,7 @@ void HsvTransform::hsv2rgb(uint16_t hue, uint8_t saturation, uint8_t value, uint
|
|||||||
}
|
}
|
||||||
|
|
||||||
region = hue / 60;
|
region = hue / 60;
|
||||||
remainder = (hue - (region * 60)) * 6;
|
remainder = (hue - (region * 60)) * 256 / 60;
|
||||||
|
|
||||||
p = (value * (255 - saturation)) >> 8;
|
p = (value * (255 - saturation)) >> 8;
|
||||||
q = (value * (255 - ((saturation * remainder) >> 8))) >> 8;
|
q = (value * (255 - ((saturation * remainder) >> 8))) >> 8;
|
||||||
|
Loading…
Reference in New Issue
Block a user