CogHistogramResult GetMinimumWGVThreshold Method Cognex VisionPro 9.21
Returns a threshold using data from this histogram. The computed threshold is appropriate for segmenting an image into object and background pixels and is often used to compute a segmentation threshold for blob analysis. The returned threshold divides the histogram data into two groups such that the combined variance within the groups is a minimum.

Namespace: Cognex.VisionPro.ImageProcessing
Assembly: Cognex.VisionPro.ImageProcessing (in Cognex.VisionPro.ImageProcessing.dll) Version: 83.0.0.0
Syntax

public int GetMinimumWGVThreshold()

Return Value

Type: Int32
The computed threshold value.
Exceptions

ExceptionCondition
InvalidOperationExceptionIf the histogram contains only empty bins.
See Also