World Coordinates and Camera Coordinates

Figure 9.2: Image Coordinates (Image coordinates)
Figure 9.3: Camera Coordinates (Camera coordinates)
Figure 9.4: Example of “Vehicle” or “World” coordinates: Front-Left-Up or ISO 8855 (World coordinates)
Image fig_imagecoord

Image fig_cameracoord

Image fig_worldcoord

In practical applications, it is necessary to move from a coordinate system fixed to the camera, in which point $(0,0,0)^{\top}$ coincides with the projection center (pin-hole), to a more general coordinate system better suited to the user's needs, in which the camera is positioned at an arbitrary point in the “world” and oriented arbitrarily with respect to it. This applies to any sensor, including non-imaging sensors, by defining relationships that allow points to be transformed from world coordinates to sensor coordinates and vice versa.

At this point, we need to clarify the terminology used in this book for coordinate systems: the “world” coordinate system is the system considered absolute and fixed in each context, relative to which the sensor is positioned. For example, in Figure 9.4, the origin of the “world” system is associated with a point on the vehicle (for example, its frontmost point). In this case, “vehicle” (body) and “world” are synonymous. This distinction no longer applies, however, when a vehicle moves relative to a “world,” which can again be defined as the fixed coordinate system. In this case, we have sensor coordinates, the vehicle's local or body coordinates, and world coordinates. Usually, however, the axes defining the sensor, vehicle, and world coordinate systems are kept consistent.

In camera coordinates, the special role of coordinate $z$ arises for purely mathematical reasons: using homogeneous coordinates requires dividing the first two components by the third during projection. This restriction does not apply to “sensor” coordinates. Although there is no requirement to do so, this book uses the coordinate system shown in Figure 9.4 (ISO 8855) for “sensor,” “body,” and “world” coordinates, with axis $z$ representing the point's height above the ground.

To derive the final pin-hole camera equation, we start with Equation (9.10) and apply the following considerations:

The transformation from “world” coordinates to “camera” coordinates is a composition of rotations and is therefore itself a rotation, given by $\mathbf{R} = \prescript{c}{}{\mathbf{R}}_{w} = \boldsymbol\Pi \prescript{w}{}{\mathbf{R}}^{-1}_{b}$.

Let $(x_{i},y_{i},z_{i})^{\top}$ be a point in “world” coordinates and $(\tilde{x}_{i},\tilde{y}_{i},\tilde{z}_{i})^{\top}$ the same point in “camera” coordinates. The relationship between these points can be written as

\begin{displaymath}
\begin{bmatrix}
\tilde{x}_{i} \\
\tilde{y}_{i} \\
\tilde{z...
..._{i} \\
y_{i} \\
z_{i}
\end{bmatrix} + \tilde{\mathbf{t}}_0
\end{displaymath} (9.22)

where $\mathbf{R}$ is a $3 \times 3$ matrix that transforms world coordinates to camera coordinates and accounts for rotations and sign changes between the world and camera axes (see Appendix A), while the vector
\begin{displaymath}
\tilde{\mathbf{t}}_{0} = -\mathbf{R} \mathbf{t}_0
\end{displaymath} (9.23)

represents the position of the pin-hole $\mathbf{t}_0$ relative to the origin of the world system, expressed in camera coordinates.

Recall that rotation matrices are orthonormal: their determinant is 1, so they preserve distances and areas, and the inverse of a rotation matrix is its transpose.

The matrix $\mathbf{R}$ and the vector $\mathbf{t}_{0}$ can be combined into a matrix $3\times4$ using homogeneous coordinates. This representation makes it possible to write the projection of a point, expressed in homogeneous world coordinates as $(x_{i},y_{i},z_{i})^{\top}$, onto an image point in homogeneous coordinates as $(u_{i},v_{i})^{\top}$, very compactly:

\begin{displaymath}
\lambda \begin{bmatrix}
u_{i} \\
v_{i} \\
1
\end{bmatri...
...] \begin{bmatrix}
x_{i} \\
y_{i} \\
z_{i} \\
1
\end{bmatrix}\end{displaymath} (9.24)

This equation makes it clear that each image point $(u_{i},v_{i})$ corresponds to infinitely many world points $(x_{i},y_{i},z_{i})^{\top}$ lying on a line as the parameter $\lambda$ varies.

Assuming $\lambda$ and collecting the matrices yields the final pin-hole camera equation (which does not, and should not, account for distortion):

\begin{displaymath}
\begin{bmatrix}
u_{i} \\
v_{i} \\
1
\end{bmatrix} \equiv \...
...} \begin{bmatrix}
x_{i} \\
y_{i} \\
z_{i} \\
1
\end{bmatrix}\end{displaymath} (9.25)

where $\mathbf{P} = \mathbf{K} [ \mathbf{R} \vert \mathbf{\tilde{t}}_0 ]$ is the projective matrix (camera matrix) used later (Str87). The matrix $\mathbf{P}$ is a $3\times4$ matrix and, being rectangular, is not invertible.

It is worth noting that imposing an additional constraint on the points, for example $z_{i}=0$, reduces the matrix $\mathbf{P}$ to an invertible $3 \times 3$ matrix, which is exactly the homography (see Section 9.3.1) of the perspective transformation of points on the ground. The matrix $\mathbf{P}_{z=0}$ is an example of an IPM (Inverse Perspective Mapping) transformation used to obtain a bird's-eye view of the scene (MBLB91).

The inverse of the relationship in Equation (9.24), which transforms image points into world coordinates, can be written as:

\begin{displaymath}
\begin{bmatrix}
x_{i} \\
y_{i} \\
z_{i}
\end{bmatrix}=
\l...
...\mathbf{t}_0 = \lambda \mathbf{v}(u_{i}, v_{i}) + \mathbf{t}_0
\end{displaymath} (9.26)

where it is clear that each image point corresponds to a line in the world (as $\lambda$ varies) that passes through the pin-hole ($\mathbf{t}_0$) and is directed along
\begin{displaymath}
\mathbf{v}(u_i,v_i) = \mathbf{R}^{-1} \mathbf{K}^{-1}
\begin{bmatrix}
u_{i} \\
v_{i} \\
1
\end{bmatrix}\end{displaymath} (9.27)

where $\mathbf{v}: \mathbb{R}^2 \to \mathbb{R}^3$ is the function that maps each image point to the vector joining the pin-hole to the corresponding sensor point.

Using the Camera Matrix $\mathbf{P} = \left[ \mathbf{P}_{3 \times 3} \vert \mathbf{p}_4 \right]$ directly gives a result equivalent to Equation (9.26) in the form

\begin{displaymath}
\begin{bmatrix}
x_{i} \\
y_{i} \\
z_{i}
\end{bmatrix}=
\l...
... \\
1
\end{bmatrix}-
\mathbf{P}_{ 3\times 3}^{-1}\mathbf{p}_4
\end{displaymath} (9.28)

without explicitly using the intrinsic and extrinsic parameter matrices. The two formulations are, of course, equivalent.



Subsections
Paolo medici
2026-10-19