Patent ID: 8488870

Claim:
A method comprising: for a pixel under evaluation in a first image, identifying a plurality of support regions, wherein each of the support regions identifies one or more pixels around the pixel under evaluation in the first image; for each of the support regions, determining a disparity value that provides a lowest aggregated matching cost, wherein the aggregated matching cost is a difference between pixel values of pixels in the first image and corresponding pixels in a second image, and wherein the first image and the second image form a stereo image pair; in response to a number of support regions having a same disparity value being greater than a threshold number, setting a disparity value indicator for the pixel under evaluation to the same disparity value; in response to the pixel under evaluation being identified as unreliable, determining a first reliable right disparity value and a first reliable left disparity value; in response to the first reliable left disparity value not being the same as the first reliable right disparity value, determining a mean of pixel values for a hole comprising the pixel under evaluation, a mean of pixel values for a left neighboring region with the first reliable left disparity value, and a mean of pixel values for a right neighboring region with the first reliable right disparity value; setting a disparity value indicator for a first pixel in the hole to the first reliable left disparity value in response to a first pixel value for the first pixel being closer to the mean of pixel values for the left neighboring region than the mean of pixel values for the right neighboring region; and setting a disparity value indicator for a second pixel in the hole to the first reliable right disparity value in response to a second pixel value for the second pixel being closer to the mean of pixel values for the right neighboring region than the mean of pixel values for the left neighboring region.