How to know the original coordinates of cropped images
조회 수: 2 (최근 30일)
이전 댓글 표시
a=imread ('a.jpg');
imshow(a)
[acrop,rect]=imcrop(a);
The question is why rect should be in decimal (rect=[98.5 88.5 87 70] in my case) if it is the coordinate vector?
댓글 수: 0
채택된 답변
Walter Roberson
2011년 11월 22일
The coordinate system for image() (which is called by imshow()) is for the center of the pixels, so when you crop at a pixel boundary, the coordinate for that is going to be between two integers.
댓글 수: 0
추가 답변 (0개)
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!