Given a pair of rectified images from a stereo camera, the Stereo Disparity algorithm uses high-quality dense stereo matching to produce an output image of the same resolution as the input with left-right disparity information. This allows for inferring the depth of the scene captured by the left and right images.
Left image
Right image
Disparity map
Confidence map
Implementation
The stereo disparity estimator uses semi-global matching algorithm to compute the disparity. We deviate from the original algorithm by using as cost function the hamming distance of the census transforms of the stereo pair.
C API functions
For list of limitations, constraints and backends that implements the algorithm, consult reference documentation of the following functions:
Runs stereo processing on a pair of images and outputs a disparity map.
Usage
Language:
Import VPI module
import vpi
Estimate the disparity between left and right input VPI images, using 5x5 window and 64 maximum disparity. Optionally, the resulting disparity image is converted to U8, with range [0,255], suited for display.
Include the header that defines the needed functions and structures. ColorImageFormat algorithm will be needed to process the disparity output for display.
Runs stereo processing on a pair of images and outputs a disparity map.
Optionally, the resulting disparity image can be converted to U8 format and the disparity values are rescaled to fit in [0,255] range, suited for display.
Hirschmüller, Heiko (2005). "Accurate and efficient stereo processing by semi-global matching and mutual information".
IEEE Conference on Computer Vision and Pattern Recognition. pp. 807–814.
Zabih, Ramin; Woodfill, John (1994). "Non-parametric local transforms for computing visual correspondence".
European conference on computer vision. pp. 151–158.