I am trying to get a 3x4 camera matrix for triangulation process but calibrateCamera()
returns only 3x3 and 4x1 matrices.
How can i get the 3x4 out of those matrices?
Thanks in advance!!
In computer vision a camera matrix or (camera) projection matrix is a. matrix which describes the mapping of a pinhole camera from 3D points in the world to 2D points in an image.
Camera Calibration is nothing but estimating the parameters of a camera, parameters about the camera are required to determine an accurate relationship between a 3D point in the real world and its corresponding 2D projection (pixel) in the image captured by that calibrated camera.
Geometric camera calibration, also referred to as camera resectioning, estimates the parameters of a lens and image sensor of an image or video camera. You can use these parameters to correct for lens distortion, measure the size of an object in world units, or determine the location of the camera in the scene.
calibrateCamera() returns you
a 3x3 matrix as cameraMatrix,
a 4x1 matrix as distCoeffs,
and rvecs and tvecs that are vectors of 3x1 rotation(R) and 3x1 transformation(t) matrices.
What you want is ProjectionMatrix, which is multiply [cameraMatrix] by [R|t].
Therefore, it returs you a 3x4 ProjectionMatrix.
You can read OpenCV documentation for more info.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With