I have read an RGB Image, and extracted all its components R,G,B seperately by,
R = inputImage (:,:,1);
G = inputImage (:,:,2);
B = inputImage (:,:,3);
Again I performed some operations to get the values changed. they are Re,Ge,Be.
Now again I want to display the Image integrating all these Re,Ge,Be. How?

 채택된 답변

추가 답변 (1개)

Image Analyst
Image Analyst 2012년 9월 14일

5 개 추천

Concatenate separate image channels into one RGB image using cat():
newRGBImage = cat(3, Re, Ge, Be);
But now, how you display it depends on what class your processed image channels were: integer or floating point. If, after processing, your new image is uint8, you can simply display it.
imshow(newRGBImage);
If, after processing, your new image channels are floating point, instead of uint8, and are in the range 0-255, you'll need to cast to uint8 before you display the new image.
imshow(uint8(newRGBImage));
If you have floating point values outside this range, you can do:
imshow(im2double(newRGBImage));

카테고리

도움말 센터 및 File Exchange에서 Geometric Transformation and Image Registration에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by