Q:

Put a JPEG file into your Current Folder. Type in the following script, using your own JPEG file name

0

I1 = imread('xxx.jpg');

[r c h] = size(I1);

Inew(:,:,:) = I1(:,c:-1:1,:);

figure(1)

subplot(2,1,1)

image(I1);

subplot(2,1,2)

image(Inew);

Determine what the script does. Put comments into the script to 

explain it step-by-step

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

Ch13Ex12.m

%Load image and get size

I1 = imread('photo1.jpg');

[r, c, h] = size(I1);

%Put columns in reverse order

Inew(:,:,:) = I1(:,c:-1:1,:);

%Plot original image and flipped image in a subplot

figure(1)

subplot(1,2,1)

image(I1);

subplot(1,2,2)

image(Inew);

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

Similar questions


need a help?


find thousands of online teachers now