PANDORE Version 6 | GREYC-IMAGE |
phistogramequalization performs a gray-levels transformation
by forcing the gray-levels to spread over the entire intensity range between
min and max.
As a consequence, histogram equalization expands gray-levels where information
is important and compresses gray-levels where the information is low.
This transform is not likely to work well on input
images that have dark gray-levels distribution.
The new output bounds of the output gray-levels are given by the parameter min and max.
The equalization has the form:
im_out[p] = HC[im_in[p]]*(max-min);
For color and multispectral images, the transform uses the marginal approach: it is applied on each band individually.
min and max specify the bounds of the output
pixel value. They are related to the type of the input image.
Note: if min > max then min and max are set with
the minimum and maximum values of the input image type; for example,
0 and 255 for Uchar images.
Returns SUCCESS or FAILURE in case of invalid parameter values.
Equalizes histogram with the new bounds [0,255]:
phistogramequalization 20 200 tangram.pan a.pan
Equalizes histogram with the same bounds than the input image:
phistogramequalization 0 -1 tangram.pan a.pan
Rehaussement de contraste par égalisation d'histogramme.
Author: Régis Clouard