Patent ID: 8606005

Claim:
An image processing apparatus comprising: a processor; and a memory that stores computer readable instructions that, when executed by the processor, cause the image processing apparatus to implement processes comprising: calculating, based on image data indicative of an image, a first coordinate value that indicates a white balance of the image in a color space, the color space being configured to represent colors in coordinate values, the first coordinate value being calculated by averaging color values of particular pixels in the image, each of the particular pixels having a brightness greater than or equal to a particular threshold value; determining a first distance between the first coordinate value and a reference coordinate value, the reference coordinate value indicating an achromatic color in the color space; determining, for each pixel in the image, a third distance between the first coordinate value and a third coordinate value corresponding to a color of each pixel; setting an adjustment amount for each pixel based on the third distance and a first reference adjustment amount when the first distance is less than or equal to the particular threshold distance, the first reference adjustment amount corresponding to the first distance; setting the adjustment amount for each pixel based on the third distance and a second reference adjustment amount when the first distance is greater than the particular threshold distance, the second reference adjustment amount corresponding to a second distance which is smaller than the first distance; and executing a white balance adjustment for each pixel in the image using the adjustment amount set for each pixel.