A technique for improving the dynamic range of an image by changing the brightness of the individual pixels in such a way as to increase the image contrast. This works best when the range of pixel brightness in the original image is limited to a small part of the full range of brightness available in the image format. The darkest pixel in the image is mapped to a fully black pixel in the adjusted image, while the brightest is mapped to maximum whiteness. The other pixels’ brightness values are then stretched to fit within these extremes, using a suitable continuous nonlinear function. The technique gets its name from the fact that the parameters of the stretching function are determined by first plotting a histogram that determines how many original image pixels are present for each brightness level. Analysis of the histogram is then used to determine the optimal function parameters. See also gamma correction.