Measuring distance between two points in an image
4 views (last 30 days)
Show older comments
Hello, I'm working on a MATLAB project at uni and i've been trying to find out how to measure sizes of objects in a given image. For example - Measuring the size of a foot through image proccessing. If you have any knowledge about these kind of analasys, I would be more than happy if you could share it.
1 Comment
Adam
on 13 Jun 2017
What are you actually asking here? What is in the question title or the much wider question in the body which seems to be asking how to do image processing and identify objects before you get anywhere near measuring them?
Answers (3)
Image Analyst
on 16 Jun 2017
See my attached spatial calibration demo.
2 Comments
AVINASH SURESHRAO DIKKAR 17MMT1022
on 17 Dec 2018
Edited: Image Analyst
on 17 Dec 2018
i refered your spatial calibration demo code. I'm doing a matlab project for the inspection of chain link for that I have to find out the object position and measurement. While going through your code I didnt understand how you created a boundary around the object and created a line into that. Can you please explain to me and can you explain me the formula for distance which you use in your code. Please explain me code it is very helpfull to me and my project.
Image Analyst
on 17 Dec 2018
Edited: Image Analyst
on 17 Dec 2018
You can try imfreehand(). I attach demos.
Or you can use roipoly() or roipolyold().
Here is an explanation for how distance is calculated: Wikipedia on Pythagorean Theorem
See Also
Categories
Find more on Read, Write, and Modify Image in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!