Why can CIELAB values with L*=0 convert to non-black RGB?
Asked 12/17/2014
3 views
2 answers
0
I’ve read that in CIELAB, L*=0 is black and L*=100 is white. But when I convert values like L*=0, a*=127, b*=0 into RGB, software returns a dark red instead of pure black.
Examples:
- Mathematica:
ColorConvert[LABColor[0, 1.27, 0], "RGB"]→ non-black RGB - Julia Color.jl:
convert(RGB, LAB(0,127,0))→ non-black RGB
If L* represents lightness, why doesn’t L*=0 always produce black? Is this because of how LAB is defined, or because of how software converts out-of-range LAB values into RGB?
Originally by Photography Stack Exchange contributor. Source · Licensed CC BY-SA 4.0
Photography Stack Exchange contributor
11y ago
2 Answers
6
Whatever is the "RGB" color space (sRGB?) that you entered as destination in Mathematica, it has limited range of colors that are described by the R, G and B values, usually similar to what a monitor can produce, printer can print etc and way smaller than Lab. Since there is only limited number of values (256 per color channel in 8-bit), the RGB color spaces try not to waste any values on colors that can't be reproduced to avoid nasty side effects.
The conversion from Lab to RGB ends up with out of gamut colors and the program is then trying to map the Lab color to the closest color that exists in the target RGB color space, usually by trimming any values < 0 or > 1 to 0 and 1.
If you are inclined to play with it, here is a great tool on the web, CIE Color Calculator by Bruce Lindbloom, that can be used for quick interactive conversions
Originally by user27944. Source · Licensed CC BY-SA 4.0
user27944
11y ago
0
Generated from our catalog & community — verify before relying on it.
L*=0 does correspond to black only for valid CIELAB colors. Your example is not a physically valid Lab color.
In Lab, L* is lightness, while a* and b* describe chroma/opponent color axes. If L*=0 means no light, there cannot also be meaningful chroma. So a value like L*=0, a*=127, b*=0 is outside the realizable Lab gamut.
What happens next is a conversion issue: when software converts an invalid or out-of-gamut Lab value into RGB, it must map it into the much smaller RGB gamut. A common approach is clipping or moving to the nearest reproducible RGB value, which can yield a dark colored RGB result instead of black.
So the key points are:
- Valid Lab colors with L*=0 are black.
- Not every numeric combination of L*, a*, and b* represents a real color.
- Converting invalid/out-of-gamut Lab values to RGB can produce non-black approximations because the software is forcing the value into RGB’s limited range.
Recommended products
UniqueBot
AI11y ago
Your Answer
Related Questions
How do I interpret Photoshop histogram mean values for Lab images?
How do RGB values on a QPcard 201 gray patch translate to percent gray?
Is gamma-correct resizing really an issue, and is the article's test valid?
What causes pixel value differences when comparing the same scene from different cameras or telescopes?