Definitioncore
Camera projection matrix
Also called 3x4 camera matrix, finite projective camera.
The 3 by 4 matrix P = K[R | t] that maps a world point in homogeneous coordinates to its image point, with 11 degrees of freedom.
The camera projection matrix is the matrix that maps a point of 3D space, written in homogeneous coordinates as , to its image point . For a pinhole camera , the product of the camera intrinsic matrix and the camera extrinsic parameters . is known only up to scale, so it has degrees of freedom, which are exactly the 5 intrinsic and the 6 extrinsic ones. This page defines and lists what can be read from it. Getting from point matches is DLT resectioning, and getting , and back from is camera matrix decomposition. The graphics page pinhole camera model uses the same map with the view direction ; this area looks along .
Definition
The pinhole camera. Let be an intrinsic matrix, a rotation and a vector, with the conventions of this area: , the camera frame has right, down and forward, and the center of pixel is the point . The camera matrix is
and the pixel of the world point is found by
For a point in front of the camera, is its depth in the camera frame, so the division needs .
General and finite cameras. A general projective camera is any real matrix of rank 3, up to a nonzero scale (HZ section 6.2). Write with the left block. If is nonsingular, is a finite camera, and then it factors as with upper triangular with a positive diagonal and , a rotation and ; with these sign rules the factors are unique. If is singular, the center lies on the plane at infinity; the affine camera, whose last row is , is the main case.
Degrees of freedom. has 12 entries and one scale, so 11 degrees of freedom. A finite camera has the same count: 5 in , 3 in and 3 in . Each 2D to 3D match gives two equations, so 6 matches in general position fix (5.5 in the minimum).
What the matrix holds (HZ section 6.2). Let be the third row of and the rows of .
- Camera center. is the right null vector: . For a finite camera, . Every point on a ray through has the same image, and itself has none.
- Columns. The first three columns are the images of the points at infinity in the directions of the world , and axes, that is, their vanishing points. The last column is the image of the world origin.
- Rows. Each row is a plane of space. The third row is the principal plane: the plane through parallel to the image, whose points have and map to infinity. The rows and are the planes through that map to the image lines and .
- Principal axis and point. The vector points along the optical axis, to the front of the camera, and the principal point is up to scale.
- Depth. For and , the depth of the point is . It is positive for a point in front of the camera, whatever the scale of .
- Back-projection. The pixel is the image of all points ; the front half of this line is the ray that the pixel sees.
- A plane. For the world plane , the map from to the image is the matrix , a homography. Zhang's method is built on this fact.
Examples and non-examples
A camera five units back. Let have , and principal point , and let and . Then
- The world point gives , so its pixel is , and its depth is 5.
- The null vector is : . So .
- The third column is the principal point: the world axis is the optical axis, and its vanishing point is where the axis meets the image. The first column is a point at infinity of the image, because the world axis is parallel to the image plane.
- and give the same pixels. With , for the same point, but also changes sign, so the depth formula still gives .
Not every matrix is a camera.
- A matrix of rank 2, for example one with a zero third row, is not a camera: it maps all of space into a line or to points at infinity, and its null space is a line, not a point.
- A finite camera needs . The matrix has rank 3, so it is a projective camera, but is singular: it is the orthographic projection , an affine camera with its center at infinity.
- A homography is not a camera matrix. It maps one plane to the image, and it is what becomes on that plane.
- The projection matrix of a graphics API is not . It keeps a fourth row for the depth buffer and maps to clip coordinates, before the viewport transform.
Related definitions
- Camera intrinsic matrix and camera extrinsic parameters: the two factors of .
- Camera matrix decomposition: the algorithm that splits a finite into , , and .
- DLT resectioning: the linear algorithm that finds from six or more 2D to 3D matches.
- Affine camera model: the cameras with last row , a limit of finite cameras far from the scene.
- Point triangulation and perspective-n-point: the problems of finding a point from known cameras, and a pose from known points and .
References
- Richard Hartley and Andrew Zisserman, Multiple View Geometry in Computer Vision, second edition, Cambridge University Press, 2004, Section 6.1, Finite cameras, and Section 6.2, The projective camera (the camera center as null vector, the column and row vectors, the principal plane, axis and point, the depth of points, back-projection)
- Richard Szeliski, Computer Vision, Algorithms and Applications, second edition, Springer, 2022, Chapter 2, Image formation (the 3 by 4 camera matrix)
- Peter Sturm, Srikumar Ramalingam, Jean-Philippe Tardif, Simone Gasparini and Joao Barreto, Camera models and fundamental concepts used in geometric computer vision, Foundations and Trends in Computer Graphics and Vision 6(1-2), 2011, 1-183, the part on the perspective camera and its projection matrix
Where this leads
About this page
The build computes these levels from the evidence in the repository. Each row says what the next level needs. Read what the levels mean.
| Ladder | Level | What the next level needs |
|---|---|---|
| Human proof | H0 no proof |
|
| Lean | L0 no Lean part |
|
| Visual | V0 none |
|
| Writing | W4 complete |
|
Tag N0TBTV Edit this page History Report an error Markdown