Patent ID: 8400534

Claim:
A method of processing a digital image with an image processor, wherein the digital image comprises a plurality of pixels, the method comprising: with the image processor, defining a first window of pixels surrounding a first subject pixel representing a first color, the first window comprising a plurality of first pixels representing the first color; with the image processor, calculating a replacement pixel value of the first color by computing a weighted average of the pixel values of the first color associated with the first subject pixel and the first pixels in the first window; with the image processor, replacing the pixel value of the first color associated with the first subject pixel with the replacement pixel value of the first color; with the image processor, defining a second window of pixels surrounding a second subject pixel representing a second color different from the first color, the second window comprising a plurality of second pixels representing the second color; with the image processor, estimating a respective interpolated pixel value of the first color for the second subject pixel and each of the second pixels in the second window; with the image processor, calculating a replacement pixel value of the second color for the second subject pixel by computing a weighted average of a plurality of difference and sum values, each difference value and sum value calculated for a respective pixel of the second subject pixel and the plurality of second pixels based on the estimated interpolated pixel value of the first color and the pixel value of the second color associated with the respective pixel; and with the image processor, replacing the pixel value of the second color associated with the second subject pixel with the replacement pixel value of the second color.