# Difference between Stereo vision, Structured light and Time of Flight (ToF)

This page compares Stereo vision, Structured light and ToF (Time of Flight) 3D imaging technologies and mentions difference between Stereo vision, Structured light and Time of Flight (ToF) method including advantages and disadvantages these depth sensing technologies.

## Stereo Vision

This method uses two cameras separated by distance as shown in the figure. This resembles to human eyes. In this technique, each of these pin hole cameras will give object positions as "α" and "β". Using these angles, depth "Z" can be calculated using following equation.
➨ Z = { x /( (1/tanα) + (1/tanβ) )};

• The technique requires lower implementation cost due to cheaper off-the-shelf cameras used.
• Due to its human like configuration, it is suitable to capture images for intuitive presentation to human beings.

• Depth resolution error is quadratic function of distance in stereo vision.
• The major challenge with this technique is to solve correspondence problem. Without this, it is difficult to determine disparity and depth accurately. Solution of correspondence problem requires computationally intensive and complex algorithms.
• Stereo vision is less effective in measuring distance from a uniformly colored wall.

## Structured Light

This method works by projecting known patterns on the object and inspects pattern distortion in the reflected signal.

The figure-2 depicts the concept of structured light.

• This technique offers relatively higher spatial resolution with the use of off-the-shelf HD Color cameras and DLP projectors.

• In this technique, reflected pattern is sensitive to optical interference from surrounding environment. Hence this technique is suitable for indoor applications.

## Time of Flight (ToF)

This technique uses camera which illuminates scene using modulated light source and observes reflected light signal. The source can be either CW or pulsed usually sinusoidal or square wave in shape.

There are two types of ToF techniques viz. direct ToF and Indirect ToF. Refer DToF vs IToF >> for difference between Direct ToF sensor and Indirect ToF Sensor.

Figure depicts simple working principle of Time of Flight technique. The depth can be measured by following equation.
➨ Depth, d = c*ΔT/2;
Where c = Speed of light which is 3 x 108 m/s
ΔT = Time interval between light emission and received light by the camera sensor

In automotive domain, TOF sensors are widely used for autonomous driving and surrounding awareness for safety reasons. ToF technology has wide applications which include robotics, digital signage, virtual reality, home automation, sports & fitness, video games, 3D scanning, user interface control, augmented reality and so on.

• Depth resolution error is sensitive to distance in ToF sensor also but this can be overcome by increasing the energy of illuminated signal. This maximizes accuracy of measurement using kalman filter like techniques.
• ToF sensing does not have any limitations to measure the distance from a uniformly colored wall as it does not depend on color or texture of the object or scene.
• ToF is less sensitive to mechanical alignment and environmental lighting conditions.
• It is more compact mechanically.
• It is very cost effective technique.

• The present ToF technology offers low resolution compare to structured light but it is rapidly evolving.

## Difference between Stereo vision, Structured light and ToF

Following table mentions difference between Stereo vision, Structured light and ToF (Time of Flight) technique.

Comparison parameters Stereo Vision Structured Light ToF (Time of Flight)
Software Implementation Complexity High Medium Low
Cost of material Low High Medium
Compactness Low High Low
Response time Medium Slow Fast
Accuracy of depth measurement Low High Medium
Performance in low light environment Weak Good Good
Performance in bright light environment Good Weak Good
Power consumption Low Medium Scalable
Range Limited Scalable Scalable

➨Refer LiDAR vs Time of Flight >> for difference between LiDAR and ToF.