Module imageproc::contrast [] [src]

Functions for manipulating the contrast of images.

Functions

cumulative_histogram

Returns the cumulative histogram of grayscale values in an 8bpp grayscale image.

equalize_histogram

Equalises the histogram of an 8bpp grayscale image. https://en.wikipedia.org/wiki/Histogram_equalization

equalize_histogram_mut

Equalises the histogram of an 8bpp grayscale image in place. https://en.wikipedia.org/wiki/Histogram_equalization

histogram

Returns the histogram of grayscale values in an 8bpp grayscale image.

match_histogram

Adjusts contrast of an 8bpp grayscale image so that its histogram is as close as possible to that of the target image.

match_histogram_mut

Adjusts contrast of an 8bpp grayscale image in place so that its histogram is as close as possible to that of the target image.

otsu_level

Returns the Otsu threshold level of an 8bpp image. This threshold will optimally binarize an image that contains two classes of pixels which have distributions with equal variances. For details see: Xu, X., et al. Pattern recognition letters 32.7 (2011)

threshold

Returns a binarized image from an input 8bpp grayscale image obtained by applying the given threshold.

threshold_mut

Mutates given image to form a binarized version produced by applying the given threshold.