Rotate a selected object in an image around a predefined point on Image
2 次查看(过去 30 天)
显示 更早的评论
I have defined my object with the below function.
imshow(I);
h = impoly;
M = ~h.createMask();
I(M) = 0;
As an example I have attached an image with rotated object inside. I would be grateful if you could help me with that. The rotation angle, center point and distance from the center point is defined previously.

0 个评论
采纳的回答
Image Analyst
2018-6-16
You have to crop the image, use imcrop(). Then rotate using imrotate(). After that it's just geometry and pasting. See attached copy and paste demo.
更多回答(0 个)
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!