RGB Component
In which we convert picture in 3 Chanel (Green , Blue , Red).
subplot(2,2,1); %# Subplot is a function in which (2,2,1) first 2 show row second 2 show column and 1 is show that place picture on 1 row and 1 column
imshow(a); %# imshow mean show image
R=(a);
G=(a);
B=(a);
G(:,:,1:2:3)=0; %# In this function : mean all row column and color channel 1,2,3 is equal to 0 so then that will show just Green Channel of the image
subplot(2,2,4); %# In which picture will place on 2 row and 2 column
imshow(B)
R(:,:,2:3)=0; %# it is use for Red Channel of the image
subplot(2,2,2); %# In which picture will place on 1 row and 2 column
imshow(R)
B(:,:,1:2)=0; %# it is use for Blue Channel of the image
subplot(2,2,3); %# In which picture will place on 2 row and 1 column
imshow(B)

No comments:
Post a Comment