1. A method of processing an image, the method comprising: determining one or more gain adjustment surfaces for a reference illuminant type that is selected from a plurality of illuminant types; determining an illuminant type for the image to be processed; modifying each of the gain adjustment surfaces using a scene adjustment surface determined based on the illuminant type for the image to be processed; and processing the image using the one or more modified gain adjustment surfaces, wherein each gain adjustment surface is determined for the reference illuminant type for each color channel of a pixel array in an image sensor, wherein the scene adjustment surface is a polynomial curve based on the deviation between two gain adjustment surfaces, wherein the polynomial curve is a function of a center of the image sensor, a scaling parameter, an offset parameter, and at least one surface fitting parameter, and wherein the scaling parameter adjusts the strength of the polynomial curve for low-light scenes.