Hi ppl!
Could you tell me how to convert an RGB value to and HSL value?
Thanks in advance!
Printable View
Hi ppl!
Could you tell me how to convert an RGB value to and HSL value?
Thanks in advance!
L = R+G+B/3
S = 1 - (1/L)*Min(R,G,B)
H = cos^-1( (.5*(R-G) + (R-B) ) / (((R-G)^2 + (R-G)(G-B))^.5) )
(I stole it off of some1 else's site0
I'm sorry but thats far from correct!
Fisrt of all theree must be a more accurate function for the L, cause in most cases it misses big time, S and H are incorrect cause theres something missing!
Hope to hear from any of you guys who can help me out!