finding distance from object

4 次查看(过去 30 天)
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).

采纳的回答

Florian Morsch
Florian Morsch 2018-4-26
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 个评论
omer zchut
omer zchut 2018-4-27
thank you, I will look into this !
Florian Morsch
Florian Morsch 2018-4-27
编辑:Florian Morsch 2018-4-27
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.

请先登录,再进行评论。

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 MATLAB Support Package for IP Cameras 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by