Patent ID: 8681880

Claim:
A non-transitory program storage device comprising instructions stored thereon to cause a processor to: obtain a first image; select a pixel in the first image, the pixel having an original value; filter the first image at a plurality of distances from the selected pixel; calculate an average value for the selected pixel at each of the plurality of distances; for each of the plurality of distances— determine a difference between the average value, at the distance, and the original value, set a weight value of the average value at the distance to a value proportional to the difference only when the difference is less than a threshold, and set the weight value of the average value, at the distance and all greater distances, to zero only when the difference is greater than or equal to the threshold; determine an overall weight value for the selected pixel; and change the selected pixel's original value to a new value based, at least in part, on the overall weight value.