Assembly: Cognex.VisionPro.ImageProcessing (in Cognex.VisionPro.ImageProcessing.dll) Version: 65.1.0.0
Parameters
- inputImage
- Type: Cognex.VisionPro ICogImage
The image for which to generate a histogram.
- region
- Type: Cognex.VisionPro ICogRegion
A region that, together with the RegionMode and InputImageMask, specifies the region of the image for which the histogram will be generated.
Return Value
Type: CogHistogramResultThe histogram result.
| Exception | Condition |
|---|---|
| CogOperatorNoInputImageException | inputImage is NULL. |
| CogImageNoPixelsException | inputImage is not allocated. |
| CogOperatorInvalidRegionException | The selected space of one of the regions is not a valid space of the corresponding input image. |
| ArgumentException | RegionMode is not PixelAlignedBoundingBox or PixelAlignedBoundingBoxAdjustMask. |
| OUTOFMEMORYException | Could not allocate memory for OutputImage. |
Generates a histogram from the provided inputImage and optional region, creating a CogHistogramResult object that provides the result of the analysis. If region is Nothing (the default), the histogram will be generated from the entire inputImage.