RGB to CIELAB (or simply lab) color conversion 
Author Message
 RGB to CIELAB (or simply lab) color conversion

I am trying to find some code to convert colors from RGB to lab colors.

Wikipedia says here:
http://www.*-*-*.com/ #RGB_and_CMYK_conversions

"There are no simple formulas for conversion between RGB or CMYK values and
L*a*b*, because the RGB and CMYK color models are device dependent. The RGB
or CMYK values first need to be transformed to a specific absolute color
space, such as sRGB or Adobe RGB. This adjustment will be device dependent,
but the resulting data from the transform will be device independent,
allowing data to be transformed to the CIE 1931 color space and then
transformed into L*a*b*."

One question I have is: the RGB colors that we have in Windows (and in VB)
are RGB or sRGB?
If they are sRGB, better, but if they are RGB, can i set an arbitrary
reference and convert them to lab?

I searched the web and didn't find a VB function, here there is some related
C code:
http://www.*-*-*.com/

PS: it is not a "need", but I'm having trouble with colors and I thought
that converting them to lab may help in some way.



Wed, 25 May 2011 05:02:24 GMT  
 RGB to CIELAB (or simply lab) color conversion

Quote:

>I am trying to find some code to convert colors from RGB to lab colors.

> Wikipedia says here:
> http://en.wikipedia.org/wiki/Lab_color_space#RGB_and_CMYK_conversions

> "There are no simple formulas for conversion between RGB or CMYK values
> and L*a*b*, because the RGB and CMYK color models are device dependent.
> The RGB or CMYK values first need to be transformed to a specific absolute
> color space, such as sRGB or Adobe RGB. This adjustment will be device
> dependent, but the resulting data from the transform will be device
> independent, allowing data to be transformed to the CIE 1931 color space
> and then transformed into L*a*b*."

> One question I have is: the RGB colors that we have in Windows (and in VB)
> are RGB or sRGB?
> If they are sRGB, better, but if they are RGB, can i set an arbitrary
> reference and convert them to lab?

> I searched the web and didn't find a VB function, here there is some
> related C code:
> http://inkscape.modevia.com/doxygen/html/classorg_1_1siox_1_1CieLab.php

> PS: it is not a "need", but I'm having trouble with colors and I thought
> that converting them to lab may help in some way.

Eduardo - this link might provide some reference
http://www.planet-source-code.com/vb/scripts/ShowCode.asp?txtCodeId=4...

Included in the download are a number of htm files showing how to
use the FX.dll.  In particular fxCMYK.htm may pertain.

I also did a search for cmyk in MSDN & got a number of hits.



Wed, 25 May 2011 23:21:28 GMT  
 RGB to CIELAB (or simply lab) color conversion


Quote:

> Eduardo - this link might provide some reference
> http://www.planet-source-code.com/vb/scripts/ShowCode.asp?txtCodeId=4...

> Included in the download are a number of htm files showing how to
> use the FX.dll.  In particular fxCMYK.htm may pertain.

> I also did a search for cmyk in MSDN & got a number of hits.

Hi Norm:

I also found that code, but i don't want to conver to CMYK but to CIELAB.
The CMYK color space was just mentioned in the Wikipedia article from which
I copied that text, but what I would like is to be able to convert from RGB
to lab colors.

Thanks you anyway.



Thu, 26 May 2011 09:14:56 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Color Conversions (Hue/Lum/Saturation) to RGB

2. 256 Colors to RGB conversion?

3. Color Conversions (RGB, CMYK, HSB)

4. HSV-to-RGB and RGB-to-HSV conversion

5. VB Colors vs. Web Hex RGB colors

6. Converting RGB-color to HEX color

7. Converting RGB-color to HEX color

8. RGB conversion

9. BackColor to RGB conversion

10. Conversion from long to RGB

11. RGB Color

12. Line Color in RGB?

 

 
Powered by phpBB® Forum Software