Cut a .JPG image
1 回表示 (過去 30 日間)
古いコメントを表示
Hi everybody,
i would like to cut a .JPG image. To do this i used that script but it does not run:
X=imread('C:\Users\Utente\Desktop\DSC_0183.JPG');
[columns,rows,colors]=size(X);
X2 = imcrop(X,[400, 1, rows-400, columns]);
imshow(X2)
With X=my image and X2=new image
and 400, 1=coordinates of the upper left corner of the specified rectangle
and rows-400, columns= coordinates of the bottom right corner of the specified rectangle.
In particular the image (X2) is correctly cut to the left but not to the right. How can i resolve it?
Thank you!!
0 件のコメント
回答 (1 件)
KSSV
2019 年 2 月 19 日
Select your region manually.
X=imread('C:\Users\Utente\Desktop\DSC_0183.JPG');
[columns,rows,colors]=size(X);
X2 = imcrop(X);
imshow(X2)
参考
カテゴリ
Help Center および File Exchange で Image Processing Toolbox についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!