MATLAB 不同顏色空間的影象儲存的資料型別
阿新 • • 發佈:2019-02-15
TEST=imread('test.jpg'); img=im2double(imresize(TEST,0.5)); imgRGB = uint8(255.*img); >> TEST=imread('test.jpg'); img=im2double(imresize(TEST,0.5)); lab_transform = makecform('srgb2lab'); imgLAB = lab2uint8(applycform(img,lab_transform)); >> TEST=imread('test.jpg'); img=im2double(imresize(TEST,0.5)); imgHSV = uint8(255.*rgb2hsv(img)); >> TEST=imread('test.jpg'); img=im2double(imresize(TEST,0.5)); imgGRAY = uint8(255.*rgb2gray(img));
在MATLAB中輸入以上語句,可以檢視不同顏色空間的影象在MATLAB中的儲存方式