Patent ID: 7099574

Claim:
A distance measuring apparatus, comprising: an AF data generating device which forms images of light from a distance measurement object on a pair of line sensors comprising a plurality of light-receiving elements and generates a pair of AF data for correlation value calculation according to signals from the plurality of light-receiving elements; an AF data obtaining device which obtains a pair of AF data from a pair of employed sensor ranges for use in distance measurement in the pair of line sensors; a correlation value calculating device which determines a pair of window ranges for obtaining the pair of AF data for use in the correlation value calculation in the pair of employed sensor ranges, and sequentially calculates correlation values while shifting the pair of window ranges to obtain a highest correlation level in the pair of employed sensor ranges; an AF data correcting device which determines a pair of window ranges providing a highest correlation value of the correlation values calculated by the correlation value calculating device, and performs correction of the pair of AF data in the pair of employed sensor ranges so that smallest values of AF data in the pair of window ranges of the determined pair of window ranges providing the highest correlation value are consistent with each other; a correlation value recalculating device which sequentially performs recalculation of correlation values according to the pair of AF data corrected by the AF data correcting device while shifting the pair of window ranges, in the pair of employed sensor ranges; and a distance measurement object distance calculating device which determines a shift amount of the pair of window ranges providing the highest correlation value according to the correlation values recalculated by the correlation value recalculating device, and calculates a distance from the distance measurement object according to the shift amount of the pair of window ranges.