Algorithm Search⌘K

Definitionintro

Camera extrinsic parameters

Also called exterior orientation, camera pose parameters.

The rotation and translation that take world coordinates to camera coordinates, six degrees of freedom in all.

The extrinsic parameters of a camera are a rotation RR and a translation tt that take the coordinates XwX_w of a point in a fixed world frame to its coordinates Xc=RXw+tX_c = R X_w + t in the frame of the camera. They say where the camera is and which way it points, with 6 degrees of freedom: 3 for the rotation and 3 for the translation. They are the outer half of the camera projection matrix P=K[R∣t]P = K [R \mid t]; the inner half, the camera intrinsic matrix KK, maps the camera frame to pixels. Photogrammetry calls them the exterior orientation. The translation tt is not the position of the camera: the position is the center C=−RTtC = -R^{\mathsf T} t.

Definition

Frames. The world frame is any fixed right-handed frame, for example one tied to a calibration pattern. The camera frame has its origin at the center of projection, XX to the right, YY down and ZZ forward along the optical axis.

Parameters. The extrinsic parameters are a rotation R∈SO(3)R \in SO(3), so RTR=IR^{\mathsf T} R = I and det⁡R=+1\det R = +1 (see special orthogonal group), and a vector t∈R3t \in \mathbb{R}^3, such that for every point

Xc=RXw+t.X_c = R X_w + t.

As a 4×44 \times 4 matrix acting on homogeneous coordinates, this is the rigid body transformation

Tcw=(Rt0T1)∈SE(3),T_{cw} = \begin{pmatrix} R & t \\ 0^{\mathsf T} & 1 \end{pmatrix} \in SE(3),

which maps world points to camera points (see homogeneous transformation matrix and special Euclidean group).

What the entries mean.

  • The camera center CC is the world point with Xc=0X_c = 0, so RC+t=0R C + t = 0 and C=−RTtC = -R^{\mathsf T} t. Then Xc=R(Xw−C)X_c = R (X_w - C), and P=KR[I∣−C]P = K R [I \mid -C] (HZ section 6.1).
  • The rows r1,r2,r3r_1, r_2, r_3 of RR are the camera axes written in world coordinates: r1r_1 points right, r2r_2 down, and r3r_3 along the optical axis. So the depth of a world point is Z=r3T(Xw−C)Z = r_3^{\mathsf T} (X_w - C), and a point is in front of the camera if this is positive.
  • The inverse map, from the camera to the world, is Xw=RTXc+CX_w = R^{\mathsf T} X_c + C. Its matrix Twc=Tcw−1T_{wc} = T_{cw}^{-1} holds RTR^{\mathsf T} and CC. This is the pose of the camera in the world, the form that robotics and graphics code usually store.

Counting. RR has 3 degrees of freedom and tt has 3, so there are 6 in all. The 9 entries of RR are not free; code that estimates RR uses a minimal form, such as the rotation vector θa\theta a of the axis-angle representation with RR from the Rodrigues formula, or a unit quaternion.

Two cameras. For two cameras with extrinsics (R1,t1)(R_1, t_1) and (R2,t2)(R_2, t_2) in the same world frame, the motion from the frame of camera 1 to the frame of camera 2 is X2=RX1+tX_2 = R X_1 + t with R=R2R1TR = R_2 R_1^{\mathsf T} and t=t2−Rt1t = t_2 - R t_1. This is the relative pose that stereo camera calibration estimates.

Examples and non-examples

A camera on the X axis. Put the center at C=(2,0,0)C = (2, 0, 0) and let the camera look at the world origin, with its YY axis along the world YY axis. The forward axis is r3=(−1,0,0)r_3 = (-1, 0, 0), the down axis is r2=(0,1,0)r_2 = (0, 1, 0), and the right axis is r1=r2×r3=(0,0,1)r_1 = r_2 \times r_3 = (0, 0, 1). So

R=(001010−100),t=−RC=(0,0,2).R = \begin{pmatrix} 0 & 0 & 1 \\ 0 & 1 & 0 \\ -1 & 0 & 0 \end{pmatrix}, \qquad t = -R C = (0, 0, 2).

RR is the rotation by 9090 degrees about the YY axis, with rotation vector (0,π/2,0)(0, \pi/2, 0), and det⁡R=+1\det R = +1. Check: the origin goes to Xc=t=(0,0,2)X_c = t = (0, 0, 2), straight ahead at depth 2. The world point (0,0,1)(0, 0, 1) goes to (1,0,2)(1, 0, 2), to the right of the axis. With KK of focal length 800 and principal point (320,240)(320, 240), these two points have the pixels (320,240)(320, 240) and (720,240)(720, 240).

The translation is not the position. In the example, t=(0,0,2)t = (0, 0, 2) but C=(2,0,0)C = (2, 0, 0). The relation t=−Ct = -C holds only when R=IR = I.

Two cameras. With R1=R2=IR_1 = R_2 = I, t1=(0,0,5)t_1 = (0, 0, 5) and t2=(−0.1,0,5)t_2 = (-0.1, 0, 5), the relative pose is R=IR = I and t=(−0.1,0,0)t = (-0.1, 0, 0): camera 2 sits 0.10.1 to the right of camera 1, at C2=(0.1,0,−5)C_2 = (0.1, 0, -5) against C1=(0,0,−5)C_1 = (0, 0, -5).

Non-examples.

  • A pair (Q,t)(Q, t) with QQ orthogonal but det⁡Q=−1\det Q = -1. QQ is a reflection, and the frame it gives is left-handed. Such a matrix appears when a linear method fits RR without a sign rule; the camera matrix decomposition page shows the fix.
  • The camera pose (RT,C)(R^{\mathsf T}, C) given where (R,t)(R, t) is expected. Both describe the same camera, but they are inverse maps. Mixing them is the most common bug with extrinsics, and it often gives images that look nearly right for cameras close to the world origin.
  • A 3×43 \times 4 matrix [M∣m][M \mid m] with MM not a rotation, for example a scaled or sheared one. It can be a camera matrix with K≠IK \ne I, but its left block is KRK R and it must be decomposed before RR can be read.
  • The full PP. The extrinsics say nothing about pixels; two cameras at the same place with different lenses have the same (R,t)(R, t).

References

  1. Richard Hartley and Andrew Zisserman, Multiple View Geometry in Computer Vision, second edition, Cambridge University Press, 2004, Section 6.1, Finite cameras (camera rotation and translation, the camera center and the form P = K R [I | -C])
  2. Richard Szeliski, Computer Vision, Algorithms and Applications, second edition, Springer, 2022, Chapter 2, Image formation (3D rotations and the camera extrinsics)

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.

LadderLevelWhat the next level needs
Human proofH0 no proof
  • add a proof in proofs/ (06.5)
LeanL0 no Lean part
  • name a Lean module in the lean field (07)
VisualV0 none
  • add viz/scene.ts or a figure (10)
WritingW4 complete
  • a review of the text: no review record reviews/X5VYZG/text.yaml