Hi all, just sent it to Christèle and thought the rest of the 3000
are entitled for a peak too.
here is the extracted HSV to RGB formula:
---- <snip> -------
on HSV2RGB hue,sat,val -- tint degrees / saturation / value (0-360,0-1,0-1)
mymod=1.0000*((10000*hue) mod (10000*60))/10000 -- special thanx to
Roy Crisman for the feedback...
posval=integer(1.0000*(mymod)/60*255)
negval=integer(1.0000*(60-(mymod))/60*255)
if hue<60 then col=rgb(255,posval,0)
if hue>=60 then col=rgb(negval,255,0)
if hue>=120 then col=rgb(0,255,posval)
if hue>=180 then col=rgb(0,negval,255)
if hue>=240 then col=rgb(posval,0,255)
if hue>=300 then col=rgb(255,0,negval)
wcol=rgb((255*(1-sat)+col.red*sat), (255*(1-sat)+col.green*sat),
(255*(1-sat)+col.blue*sat))
return
rgb((0*(1-val)+wcol.red*val),(0*(1-val)+wcol.green*val),(0*(1-val)+wcol.blue*val))
end
---- <snap> --------
Currently working on the same formula, only the other way around.
this will allow sending color objects back to the ColorWheel and have
it set itself to these colors.
Ciao,
Yariv
-- <snoop> --
>Hi Christèle,
>
>> > If TSL is the same as HSV then you might ask Yariv.
>It is
>
>> >
>> What is his E-mail?
>
>try : Yariv Alter Fin <[EMAIL PROTECTED]>
>
>
>HTH,
>Séb
>
>
>[To remove yourself from this list, or to change to digest mode, go to
>http://www.penworks.com/LUJ/lingo-l.cgi To post messages to the list,
>email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED])
>Lingo-L is for learning and helping with programming Lingo. Thanks!]
[To remove yourself from this list, or to change to digest mode, go to
http://www.penworks.com/LUJ/lingo-l.cgi To post messages to the list,
email [EMAIL PROTECTED] (Problems, email [EMAIL PROTECTED])
Lingo-L is for learning and helping with programming Lingo. Thanks!]