Code does not work!
1 次查看(过去 30 天)
显示 更早的评论
This code used to work, I tried it now.. it does not work.. i do not know what happened! Can anyone try to help me with that? Manual selection to the photo does not work also !
采纳的回答
Walter Roberson
2017-6-23
To expand on Stephen's response: change your code to
function [loc] = get_image_point (I)
fig = figure('name','Doubleclick to set location');
imshow(I);
title('Double click on the center of the ring')
[c r] = getpts(fig);
loc = int32([c r]);
if size(loc)>1
loc = [loc(1,1) loc(1,2)];
end
close(fig);
end
更多回答(0 个)
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!