The contrast of a digital image is enhanced by forming a histogram of the luma values of an active area of the image, computing "initial" bin indices that partition the histogram into bins of substantially equal population, mapping the "initial" bin indices into "final" bin indices that are more uniformly spaced than the "initial" bin indices, and adjusting the luma values of all the pixels in accordance with the "final" bin indices.
Disclosed is a method for generating transfer curves for adaptive contrast enhancement. Transfer curves are generated so as to enhance the bright pixels in mostly dark images and the dark pixels in mostly bright images. For a dark image, a transfer curve is generated which increases luminance in high-luminance regions of the image without substantially changing the luminance in the mid- and low-luminance regions of the image. For a bright image, a transfer curve is generated which decreases the luminance in the dark areas of the image without substantially changing the luminance in the mid- and high-luminance regions of the image. For a medium-bright image, a transfer curve is generated with increases the luminance in the high-luminance range and decreases the luminance in the low-luminance range of the histogram without substantially changing the luminance in the medium-luminance range of the image.
In a set of non-reference gamma characteristics corresponding to a density adjustment value, a first region has first characteristics for converting input values to the maximum output value. A second region has second characteristics for converting input values to the minimum output value. A third region defined between the first and second regions has third characteristics for converting input values to intermediate output values. The third characteristics defines a monotonous curve that changes monotonously with respect to change in the amount of the input value. The amount of at least one of the first region and the second region is different from the amount of the corresponding at least one of the first reference region and the second reference region of the reference gamma characteristics by a degree dependent on each density adjustment value.