1. A method for refining a value of a similarity measure that is assigned to a pixel or a group of pixels of a disparity map that is assigned to at least two stereo images each having a plurality of pixels, wherein the similarity measure constitutes an estimate for a match quality of the pixel or the group of pixels, the method comprising: determining the similarity measure between a pixel or a group of pixels in a first stereo image and a corresponding pixel or a corresponding group of pixels in a second stereo image, determining a contrast value for the pixel or the group of pixels of the first or the second stereo image, and correcting the value of the similarity measure by a correction value that is a function of the determined contrast value, wherein the value of the similarity measure is maintained if the similarity measure for the pixel or the group of pixels is located in a first predetermined continuous subset of a range for the similarity measure, the first subset comprising a maximum value of the similarity measure.