Stereo vision algorithms generally reckon inaccurate results in regions wherever there’s a abrupt amendment within the depth between objects within the scene. they’re outlined as regions wherever neighboring disparities dissent by quite a definite gap, expanded by a window of a given breadth.

Based on paper,

D. Scharstein and R. Szeliski, “A taxonomy and evaluation of dense 2 frame stereo correspondence algorithms,” International Journal of computer Vision, vol. 47(1/2/3), pp. 7-42, Apr. 2002.

Example

Flowerpots Left ImageFlowerpots-Left Image Flowerpots Right ImageFlowerpots-Right Image
Flowerpots, Ground Truth Left-to-RightFlowerpots-Ground TruthDisparity Map=Left-to-Right Image Flowerpots, Ground Truth Right-to-LeftFlowerpots-Ground TruthDisparity Map-Right-to-Left Image
Flowerpots-Depth-DiscontinuousFlowerpots-Depth-Discontinuous Regions(Pixels marked as white are depth-discontinuous)

MATLAB Code: