1 | initial version |
Not sure of the relationship between the parameters you have and the field of view. However if you can get this I think an approximate calculation of distance would be easier.
Angle of arc = (field of view) * (object pixel width)/(screen pixel width).
Then tan(arc/2) = (true width/2)/(true distance).
So (true distance) = width/2.tan(arc/2). (very approximate.)
May contain mistakes, lots of simple assumptions made, low tech answer.
(PS lots of info in the exif data from a still from the camera. Something may be useful. I think its an augmented reality trick to get your app to take a sample picture and read this info to get approximate camera geometry.)