= Stereo rectification
<Stereo rectification> transforms a pair of images so that corresponding <epipolar lines> become aligned scan lines. In a horizontal stereo arrangement, a scene point visible in both rectified views should have the same vertical image coordinate. This turns a two-dimensional matching search into a one-dimensional search along a row.<Camera Calibration and 3D Reconstruction by OpenCV>[stereoRectify(), horizontal stereo case, R1/R2 and P1/P2]{ref}
For example, a feature initially at left row 100 and right row 104 can be mapped to the same row in virtual aligned views. <Camera calibration> supplies geometry for the transforms, and <image resampling> evaluates the transformed images on a new <pixel> grid. The new images need not retain every border region. <Stereo rectification> aligns the geometric search; it does not identify the correct partner among repeated patterns or restore a feature hidden in one view. The rectified <focal length> and coordinate offsets must also be used when converting <stereo disparity> to depth.
Back to article page