RGB to lαβ
Show older comments
Hello,
Can anyone advise on how to convert a colour space of an image from RGB to lαβ ? what is the syntax for this particular conversion?
Thanks, v
3 Comments
V
on 4 Dec 2011
Dev Ba
on 6 Feb 2023
I tried running the script, I'm getting a rather different type of error.
>> C = makecform('srgb2lab')
C =
struct with fields:
c_func: @applycformsequence
ColorSpace_in: 'rgb'
ColorSpace_out: 'lab'
encoding: 'double'
cdata: [1×1 struct]
>> C(HCC1)
Array indices must be positive integers or logical values.
HCC1 is a tiff image loaded from my local PC. To add I'm using the online version of MATLAB.
Image Analyst
on 6 Feb 2023
@Dev Ba just use
labimage = rgb2lab(rgbImage);
Accepted Answer
More Answers (3)
bym
on 4 Dec 2011
0 votes
Walter Roberson
on 4 Dec 2011
0 votes
http://www.mathworks.com/help/toolbox/images/ref/makecform.html is part of the Image Processing Toolkit. Do you have that installed and licensed?
V
on 5 Dec 2011
0 votes
Categories
Find more on L*a*b* Color Space in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!