bertjiazheng / Structured3D

[ECCV'20] Structured3D: A Large Photo-realistic Dataset for Structured 3D Modeling
https://structured3d-dataset.org
MIT License
541 stars 62 forks source link

What is the focal length and sensor width of the perspective Camera(s)? #14

Closed micaeltchapmi closed 4 years ago

micaeltchapmi commented 4 years ago

Hi,

I want to reproduce the perspective images in Blender and I want to know what is the focal length and sensor width of the cameras you used to render these images. Can you please provide me with this information?

Thanks,

Micael

bertjiazheng commented 4 years ago

Hi Micael,

The camera information is provided in _camerapose.txt, please refer to data_organization.md for more details. You can get the intrinsic information via parse_camera_info.

Best, Jia

micaeltchapmi commented 4 years ago

Hi Jia,

Thanks for your quick response. I used the information from parse_camera_info to set the camera extrinsics and I would like to calculate the focal length of the camera using this formula: focal_length =(0.5*SensorWidth)/TAN((0.5*HorzFieldOfView)/57.296) I got the horizontal field of view from parse_camera_info but I don't have information about the camera sensor width. Can you provide that information?

Thanks,

Micael

bertjiazheng commented 4 years ago

The resolution of the perspective image is 720x1280.

micaeltchapmi commented 4 years ago

Thanks for your reply Jia. I was looking for how to get the sensor width and focal length from the intrinsics and I found it here https://blender.stackexchange.com/a/40835/99643 . The equations of interest were:

sensor_width_in_mm = 𝐾[1,1]∗𝐾[0,2]/(𝐾[0,0]∗𝐾[1,2]) 𝑠𝑢 = resolution_𝑥_in_px / sensor_width_in_mm focal_length_in_mm = 𝐾[0,0] / 𝑠𝑢

Putting it here in case someone needs this.