-
Notifications
You must be signed in to change notification settings - Fork 0
/
img_read.m
37 lines (30 loc) · 1.09 KB
/
img_read.m
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
%--------------------------------------------------------------
% Welcome to Getscriptall
%--------------------------------------------------------------
% Read an Image
img=imread('lena.png');
% Displaying Lena image
figure;
imshow(img);title('Lena image')
% Decompose the RGB channel(Color image)
R=img(:,:,1);
% Reading R channel and displaying
figure;
imshow(R);title('R-channel');
G=img(:,:,2);
% Reading G channel and displaying
figure;
imshow(G);title('G-channel');
B=img(:,:,3);
% Reading B channel and displaying
figure;
imshow(B);title('B-channel');
%--------------------------------------------------------------------
% imread()-for reading an image
% imshow()- for show an image
% title()- for dispaly the title
% here image is considering as a matrix with size 256*256*3
% decomposing into 3 sub matrix R,G,B and each having the size 256*256
%----------------------------------------------------
%%%%%%%%%%%-------------------$$$$$$$$>>>>> BY Getscriptall <<<<$$$$$$$$$-----------------%%%%%%%%%%%%%%
% @@@ for any query contact: info.getscriptall@gmail.com