[Openicc] HSV conversion

Jeff Cunningham jefrey_c at airpost.net
Sun Jul 16 13:51:54 PDT 2006


There simply aren't any transforms to get you from generic RGB or HSV to 
colorimetric values.  That means for a given set of generic RGB or HSV 
values, we don't know what color corresponds to those colors.  For RGB 
spaces, we can usually assume that means sRGB (unless specified 
otherwise).  Now that we're talking about a specific RGB space, we can 
covert the RGB triplets to colorimetric values.  CIE L*a*b* is a common 
colorimetric color space.  L*, a*, b* (LAB) are the rectangular 
coordinates for the space.  L*, C*, h* (LCH) are the cylindrical 
coordinates of the same space.  Same colors, just a different way of 
referencing.  The cylindrical coordinates are a little more intuitive I 
think.

I think you have two options:
1.  Instead of using HSV or HSL, use LCH.  All three are cylindrical.  
Most people won't know what "LCH" means.
2.  Treat the HSV space and the RGB space as one in the same, with the 
only difference being the coordinates.  HSV = cylindrical; RGB = 
rectangular.  This is probably the better option.  You could also 
implement both -- they are not mutually exclusive.

cheers,
jeff



Casper Boemann wrote:
> Hi
>
> I'm looking at creating a profile aware colorselector for krita and want it to 
> use HLS or HSV, but I have this conceptual problem.
>
> (For the rest of the mail I'll  just write HSV but my questions relate to both 
> colorspaces.)
>
> All I can find is conversion from "RGB" to HSV, but nowhere does that take 
> profiles into consideration.
>
> Are HSV inheriting the colorspace of the RGB it's based on? And if so does it 
> make sense to talk about a HSV_sRGB (ie HSV based on sRGB)?
>
> Can someone explain how HSV and RGB relates, in terms of profiles.
>
>   
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 3343 bytes
Desc: S/MIME Cryptographic Signature
Url : http://lists.freedesktop.org/archives/openicc/attachments/20060716/5e911743/smime.bin


More information about the openicc mailing list