Table of Contents

Class StereoMatcher

Namespace
OpenCvSharp
Assembly
OpenCvSharp.dll

The base class for stereo correspondence algorithms.

public class StereoMatcher : Algorithm, IDisposable, ICvPtrHolder
Inheritance
StereoMatcher
Implements
Derived
Inherited Members

Constructors

StereoMatcher(nint)

constructor

protected StereoMatcher(nint ptr)

Parameters

ptr nint

Properties

BlockSize

public int BlockSize { get; set; }

Property Value

int

Disp12MaxDiff

public int Disp12MaxDiff { get; set; }

Property Value

int

MinDisparity

public int MinDisparity { get; set; }

Property Value

int

NumDisparities

public int NumDisparities { get; set; }

Property Value

int

SpeckleRange

public int SpeckleRange { get; set; }

Property Value

int

SpeckleWindowSize

public int SpeckleWindowSize { get; set; }

Property Value

int

Methods

Compute(InputArray, InputArray, OutputArray)

Computes disparity map for the specified stereo pair

public virtual void Compute(InputArray left, InputArray right, OutputArray disparity)

Parameters

left InputArray

Left 8-bit single-channel image.

right InputArray

Right image of the same size and the same type as the left one.

disparity OutputArray

Output disparity map. It has the same size as the input images. Some algorithms, like StereoBM or StereoSGBM compute 16-bit fixed-point disparity map(where each disparity value has 4 fractional bits), whereas other algorithms output 32 - bit floating - point disparity map.