Focal length
Is there a way to extract the camera's focal length?
https://github.com/Microsoft/AirSim/blob/master/docs/image_apis.md#getting-camera-parameters
Hello,
The link you provided does not include the "getting-camera-parameters" section. I need to know to camera's focal length and in general the calibration parameters of the camera for 3D mapping. Is it possible?
Hello,
The link you provided does not include the "getting-camera-parameters" section. I need to know to camera's focal length and in general the calibration parameters of the camera for 3D mapping. Is it possible?
client.simGetCameraInfo(str(camera_id))
There is a function called get focal length also get film back settings to get sensor info
I tried using the python API to get the focal length. The focal length is got was 11.9 Then, I used that to compute the 3D target object location from the pixel position (using intrinsic matrix). However, it did not match the 3D target location obtained using python API Here, by target I mean another drone. So, I wanted correspondence between the target drone location in the image and the 3D target drone location obtained using python API
I also want to share something else that I noticed through this experiment: I captured a sequence of images of the target drone from the chaser camera. The target (at a distance of 3m from chaser) was given a horizontal straight line trajectory and the chaser was kept steady. Then, I tried several values of focal length. Finally, I got the values which worked (fx=28, fy=29). The 3D target location obtained using the intrinsic matrix matched to that obtained using python API. Then, I changed the distance of the target from the chaser (7m) and conducted the same experiment. This, time those values did not work! After several trials, the values that worked were fx = 118, fy=125
So, I figured that the values of fx, fy change for different values of the distance between the camera and the target object. I am not sure of the reason though