finding distance from object
2 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
omer zchut
il 25 Apr 2018
Modificato: Florian Morsch
il 27 Apr 2018
Hi, in my project I need to fly a drone using one Camera to navigate to some point and to avoid obstacles on the way (using only picture not video). I read here that you can use two Camera (whice i dont have) to find distance , or take 2 picture and revalue the distance using trigonometry,the problem is that the drone is unstable and the distance between the images will be approximately random.So, I ask for your opnion on the subject. thank you! (Sorry about the English).
0 Commenti
Risposta accettata
Florian Morsch
il 26 Apr 2018
With only one camera its very hard to do. Right now im writing my thesis about a similar case, i needed two months to get good results and i use a marker-based approach. I can give a pretty accurate distance-information (+/- 2mm)with a single camera, but only on a marker i designed.
Without a certain amount of knowledge on what you are going to see or a reference in the picture you are taking its nearly impossible to get the 3D-informations out of a 2D-image.
You could try and extract 2 matching spots of two following images, but if the drone is unstable/ flies fast this is pretty much impossible.
My best advice would be: Design a reference point (marker) you can then use to find the distance.
2 Commenti
Florian Morsch
il 27 Apr 2018
Modificato: Florian Morsch
il 27 Apr 2018
A pretty simple approach would be to set up a known object ( a black rectange e.g.) from which you know the real measurements ( lets say its 30cm x 30cm).
Now take a picture from exacly 1 m away, so now you have the ammount of pixels from the rectangle from 1 m. If you move your camera to 2 m, the ammount of pixel should get lower by a certain amount. Find a correlation between the distance to the sum of the pixels and you can recreate the distance.
Note that this method will only work if you are looking straight at the reference object ( a angle would change the ammount of pixel you see).
You might want to take a look at this https://zone.biblio.laurentian.ca/bitstream/10219/2458/1/Peyman%2520Alizadeh%2520MSc.%2520Thesis%2520Corrected_2_2.pdf which can give you a idea of different approaches.
Più risposte (0)
Vedere anche
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!