Seperating in Digital Image Processing
Show older comments
I coded this question but it don't work. I have a error. If someone help me, i will be very happy. Thans.

My tried code block:
img=imread('peppers.png');
img=(im2double(img));
R(img)=img(:,:,1); %we chosed channal 1
G=img(:,:,2);
B=img(:,:,3);
x=16; y=16;
m=2048; n=1024;
sub_image=R(img)(x:x+m,y:y+n);
sub_image=R(img)(16:2048, 16:1024);
imshow(sub_image);
imwrite(sub_image,'sub_region.jpg');
Answers (0)
Categories
Find more on Image Segmentation 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!