ImageTColor, TDepthThresholdAdaptive Method |
http://www.emgu.com
Transforms grayscale image to binary image.
Threshold calculated individually for each pixel.
For the method CV_ADAPTIVE_THRESH_MEAN_C it is a mean of blockSize x blockSize pixel
neighborhood, subtracted by param1.
For the method CV_ADAPTIVE_THRESH_GAUSSIAN_C it is a weighted sum (gaussian) of blockSize x blockSize pixel neighborhood, subtracted by param1.
Namespace:
Emgu.CV
Assembly:
Emgu.CV.World (in Emgu.CV.World.dll) Version: 4.1.1.3497 (4.1.1.3497)
Syntaxpublic Image<TColor, TDepth> ThresholdAdaptive(
TColor maxValue,
AdaptiveThresholdType adaptiveType,
ThresholdType thresholdType,
int blockSize,
TColor param1
)
Public Function ThresholdAdaptive (
maxValue As TColor,
adaptiveType As AdaptiveThresholdType,
thresholdType As ThresholdType,
blockSize As Integer,
param1 As TColor
) As Image(Of TColor, TDepth)
public:
Image<TColor, TDepth>^ ThresholdAdaptive(
TColor maxValue,
AdaptiveThresholdType adaptiveType,
ThresholdType thresholdType,
int blockSize,
TColor param1
)
member ThresholdAdaptive :
maxValue : 'TColor *
adaptiveType : AdaptiveThresholdType *
thresholdType : ThresholdType *
blockSize : int *
param1 : 'TColor -> Image<'TColor, 'TDepth>
Parameters
- maxValue
- Type: TColor
Maximum value to use with CV_THRESH_BINARY and CV_THRESH_BINARY_INV thresholding types - adaptiveType
- Type: Emgu.CV.CvEnumAdaptiveThresholdType
Adaptive_method - thresholdType
- Type: Emgu.CV.CvEnumThresholdType
Thresholding type. must be one of CV_THRESH_BINARY, CV_THRESH_BINARY_INV - blockSize
- Type: SystemInt32
The size of a pixel neighborhood that is used to calculate a threshold value for the pixel: 3, 5, 7, ... - param1
- Type: TColor
Constant subtracted from mean or weighted mean. It may be negative.
Return Value
Type:
ImageTColor,
TDepthThe result of the adaptive threshold
See Also