修正COLOR.hsv函数s小于0时漏返回透明度 close #445

This commit is contained in:
MrZ626
2021-11-10 14:35:22 +08:00
parent cd6a50d5a0
commit 16497833df

View File

@@ -1,6 +1,6 @@
local abs=math.abs
local function hsv(h,s,v,a)
if s<=0 then return v,v,v end
if s<=0 then return v,v,v,a end
h=h*6
local c=v*s
local x=abs((h-1)%2-1)*c