Class AutoLevelProcessor
- Namespace
- SixLabors.ImageSharp.Processing.Processors.Normalization
- Assembly
- SixLabors.ImageSharp.dll
Applies a luminance histogram equilization to the image.
public class AutoLevelProcessor : HistogramEqualizationProcessor, IImageProcessor
- Inheritance
-
AutoLevelProcessor
- Implements
- Inherited Members
Constructors
AutoLevelProcessor(int, bool, int, bool)
Initializes a new instance of the AutoLevelProcessor class. It uses the exact minimum and maximum values found in the luminance channel, as the BlackPoint and WhitePoint to linearly stretch the colors (and histogram) of the image.
public AutoLevelProcessor(int luminanceLevels, bool clipHistogram, int clipLimit, bool syncChannels)
Parameters
luminanceLevels
intThe number of different luminance levels. Typical values are 256 for 8-bit grayscale images or 65536 for 16-bit grayscale images.
clipHistogram
boolIndicating whether to clip the histogram bins at a specific value.
clipLimit
intThe histogram clip limit. Histogram bins which exceed this limit, will be capped at this value.
syncChannels
boolWhether to apply a synchronized luminance value to each color channel.
Properties
SyncChannels
Gets a value indicating whether to apply a synchronized luminance value to each color channel.
public bool SyncChannels { get; }
Property Value
Methods
CreatePixelSpecificProcessor<TPixel>(Configuration, Image<TPixel>, Rectangle)
public override IImageProcessor<TPixel> CreatePixelSpecificProcessor<TPixel>(Configuration configuration, Image<TPixel> source, Rectangle sourceRectangle) where TPixel : unmanaged, IPixel<TPixel>
Parameters
configuration
Configurationsource
Image<TPixel>sourceRectangle
Rectangle
Returns
- IImageProcessor<TPixel>
Type Parameters
TPixel