Mobile-SDK-Android icon indicating copy to clipboard operation
Mobile-SDK-Android copied to clipboard

Feature Request: Get FOV of Camera

Open RocketRider opened this issue 7 years ago • 6 comments

I would like to get the Field of View (Horizontal and Vertical) of the Camera to make some image processing. Is it possible to get this from the SDK, I didn't find anything? Currently I am using a Mavic Pro, where the FOV is static but on other system where a zoom is available this would not be static anymore.

RocketRider avatar Apr 16 '18 09:04 RocketRider

From the specs of the mavic pro they say it is a 78.8 deg fov. https://www.dji.com/mavic/info#specs

The 78.8 deg is talking about the Hfov which stands for the horizontal fov.

You will then need to figure out what aspect ratio the camera is taking photos.

I believe the Mavic has two aspect ratios for its photos. 16:9 and 4:3.

If you use the 16:9 ratio your full fov should be 78.8 hfov x 50 vfov If you use the 4:3 ratio your full fov should be 78.8 hfov x 64 vfov

Don't hold me to these numbers because I'm not entirely sure how DJI does their aspect ratios but I should be close on the vfov.

jmoore3274 avatar Apr 20 '18 01:04 jmoore3274

Thank you, I calculated the them as well. But it would be great to have a solution for all drones and with exact numbers. So an function in the API would be great. I think the sensor is something like 16:9, so 4:3 will crop the image.

RocketRider avatar Apr 20 '18 10:04 RocketRider

The sensor should be 4:3 which is larger than 16:9 because 4:3 is almost a 1:1 ratio. The mavic pro at 4:3 kicks out photos with the resolution of 4000x3000 and a 16:9 resolution of 4000x2250.

What type of calculations are you trying to do? I have spreadsheets made up for optics calculations. I do this kind of stuff on a daily basis at my day job.

jmoore3274 avatar Apr 20 '18 20:04 jmoore3274

Thank you, I must have overlooked the picture size 4000x3000. I am trying to calculate the geo location where the drone is looking at. Lets say I see a car in the video stream, I want to know the exact Location of that car. My first approach would be to use the fov to calculate the angles and then match them with elevation data of the surroundings.

RocketRider avatar Apr 21 '18 07:04 RocketRider

@RocketRider I am working for this too, I think that the sensor (1/2.3″)is in the ratio 4:3, and when you use a 16:9 resolution, the original picture will be chopped. So, in the ratio of 16:9, FOV is little than the one in 4:3, is it correct?

crazysong avatar Oct 07 '22 15:10 crazysong

Hi. @crazysong @RocketRider have you found a way to get sensor size or native aspect ratio or at least native resolution from SDK to be able to calculate FoV without hard-coding camera spec?

EMaksymenko avatar Mar 17 '23 21:03 EMaksymenko