フィルターのクリア

How to cut an image manually using pixels values with for loop without imcrop ?

1 回表示 (過去 30 日間)
Hanan Elsayed
Hanan Elsayed 2021 年 9 月 4 日
回答済み: Image Analyst 2021 年 9 月 5 日
How can I apply Matlab code to do what the imcrop function does but manually using for loop?

回答 (2 件)

Sulaymon Eshkabilov
Sulaymon Eshkabilov 2021 年 9 月 4 日
  1 件のコメント
Hanan Elsayed
Hanan Elsayed 2021 年 9 月 5 日
I could not apply it and understand it ,,as it is used while loop

サインインしてコメントする。


Image Analyst
Image Analyst 2021 年 9 月 5 日
Not sure what you mean. How about this
grayImage = imread('moon.tif');
figure(1)
imshow(grayImage)
for k = 1 : 3
uiwait(helpdlg('Drag out a box to crop the image.'));
croppedImage = imcrop(grayImage);
figure(2) % Switch to a figure just for the cropped images only.
subplot(2, 2, k);
imshow(croppedImage); % Display it.
figure(1); % Return to the original image.
end

カテゴリ

Help Center および File ExchangeGeometric Transformation and Image Registration についてさらに検索

製品


リリース

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by