@brief Compute a camera matrix given an image width and height in pixels, "sensor width" in mm, and "focal length" in mm
| 62 | /// @brief Compute a camera matrix given an image width and height in |
| 63 | /// pixels, "sensor width" in mm, and "focal length" in mm |
| 64 | inline CameraMatrix getBlenderCameraMatrix(double width, double height, |
| 65 | double mmSensorWidth, |
| 66 | double mmFocalLength) { |
| 67 | auto focalLength = mmFocalLength * (width / mmSensorWidth); |
| 68 | return getCameraMatrix(Eigen::Vector2d(width / 2.0, height / 2.0), |
| 69 | focalLength); |
| 70 | } |
| 71 | |
| 72 | } // namespace vbtracker |
| 73 | } // namespace osvr |
nothing calls this directly
no test coverage detected