Documentation

This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

Stereo Vision

Stereo rectification, disparity, and dense 3-D reconstruction

Stereo vision is the process of recovering depth from camera images by comparing two or more views of the same scene. The output of this computation is a 3-D point cloud, where each 3-D point corresponds to a pixel in one of the images.

Stereo image rectification projects images onto a common image plane in such a way that the corresponding points have the same row coordinates. This process is useful for stereo vision, because the 2-D stereo correspondence problem reduces to a 1-D problem. As an example, stereo image rectification is often used as a pre-processing step for computing disparity or creating anaglyph images.

Apps

Camera Calibrator Estimate geometric parameters of a single camera
Stereo Camera Calibrator Estimate geometric parameters of a stereo camera

Functions

triangulate 3-D locations of undistorted matching points in stereo images
undistortImage Correct image for lens distortion
undistortPoints Correct point coordinates for lens distortion
cameraMatrix Camera projection matrix
disparity Disparity map between stereo images
estimateUncalibratedRectification Uncalibrated stereo rectification
rectifyStereoImages Rectify a pair of stereo images
reconstructScene Reconstruct 3-D scene from disparity map
stereoParameters Object for storing stereo camera system parameters
stereoAnaglyph Create red-cyan anaglyph from stereo pair of images
pcshow Plot 3-D point cloud
plotCamera Plot a camera in 3-D coordinates
rotationMatrixToVector Convert 3-D rotation matrix to rotation vector
rotationVectorToMatrix Convert 3-D rotation vector to rotation matrix

Topics

Coordinate Systems

Specify pixel Indices, spatial coordinates, and 3-D coordinate systems

Stereo Calibration App

Calibrate a stereo camera, which you can then use to recover depth from images.

Depth Estimation From Stereo Video

This example shows how to detect people in video taken with a calibrated stereo camera and determine their distances from the camera.

Code Generation for Depth Estimation From Stereo Video

This example shows how to use the MATLAB® Coder™ to generate C code for a MATLAB function, which uses the stereoParameters object produced by Stereo Camera Calibrator app or the estimateCameraParameters function.

Was this topic helpful?