For cameras perfectly aligned with the axes and having identical intrinsic parameters (the same focal length and the same principal point), the equations for three-dimensional reconstruction simplify considerably.
Under these conditions, the perspective projection equations reduce to
Let us now consider only the stereo case: for simplicity, camera 1 will denote the left camera and camera 2 the right camera.
The alignment constraints impose ,
,
, and
, having placed the right camera at the origin of the reference frame without loss of generality.
Quantity
is defined as the baseline.
The difference between the horizontal coordinates of the projections of the same point viewed in the two images of the stereo pair is called the disparity.
This value is obtained by substituting the alignment constraints into equation (10.17), yielding
By inverting this simple relationship and substituting it into equation (10.17), it is possible to obtain the world-coordinate point corresponding to a point
in the right camera with disparity
:
As can be seen, each component is determined by the multiplicative factor of the baseline, which is the actual scale factor of the reconstruction, and by the inverse of the disparity
.
The coordinates thus obtained are sensor coordinates, referred to a particular stereo configuration in which the orientation and position are aligned with and coincident with the system axes.
To move from sensor coordinates to the general case of world coordinates, with arbitrarily oriented cameras, a transformation from sensor to world coordinates must be applied, namely the rotation matrix
and the translation
of the pin-hole, so that
By combining equation (10.19) with equation (10.20), it is possible to define a matrix such that the conversion between the image-disparity point
and the world coordinate
can be written in a very compact form as
| (10.21) |
Paolo medici