how to measure distance between points in X using interactive mouse

12 次查看(过去 30 天)
Hello
I have used edge function to detect the edge of a shape in matlab, now I want to create a GUI where as someone moves their mouse over the image it draws a horizontal line between the points and measures the distance in X between the points, then when the mouse is clicked saves the distance.
Is this possible?
James

回答(2 个)

Thomas
Thomas 2012-9-24
  5 个评论

请先登录,再进行评论。


Image Analyst
Image Analyst 2012-9-24
Try imfreehand() if you want to trace an arbitrary path. It doesn't "snap" to the next point though, like Photoshop's magnetic lasoo.

类别

Help CenterFile Exchange 中查找有关 Migrate GUIDE Apps 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by