mirror of
https://github.com/lovell/sharp.git
synced 2026-02-05 22:26:20 +01:00
Add contrast limiting adaptive histogram equalization (CLAHE) operator (#2726)
This commit is contained in:
@@ -92,6 +92,13 @@ namespace sharp {
|
||||
return image;
|
||||
}
|
||||
|
||||
/*
|
||||
* Contrast limiting adapative histogram equalization (CLAHE)
|
||||
*/
|
||||
VImage Clahe(VImage image, int const width, int const height, int const maxSlope) {
|
||||
return image.hist_local(width, height, VImage::option()->set("max_slope", maxSlope));
|
||||
}
|
||||
|
||||
/*
|
||||
* Gamma encoding/decoding
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user