CogOCVMaxPattern Execute Method Cognex VisionPro 9.8 SR1
Performs an inspection upon the specified image with the specified run parameters.

Namespace: Cognex.VisionPro.OCVMax
Assembly: Cognex.VisionPro.OCVMax (in Cognex.VisionPro.OCVMax.dll) Version: 75.0.0.0
Syntax

public CogOCVMaxResult Execute(
	CogImage8Grey pImg,
	ICogRegion pRegion,
	CogOCVMaxRunParams pRunParams
)

Parameters

pImg
Type: Cognex.VisionPro CogImage8Grey
The image to inspect. May not be NULL.
pRegion
Type: Cognex.VisionPro ICogRegion
An optional region. May be NULL. If supplied, this region is used to limit the amount of processing performed on the input image. This is done in conjunction with the run parameter RegionMode, which may be either PixelAlignedBoundingBox or AffineTransform. If RegionMode is AffineTransform, then this region must correspond to a CogRectangleAffine. If no Region is supplied, the entire input image is processed.
pRunParams
Type: Cognex.VisionPro.OCVMax CogOCVMaxRunParams
The run parameters that specify how to perform this inspection.

Return Value

Type: CogOCVMaxResult
The results of this inspection. Note that this may be a partial result if inspection has timed out. Be sure to check the CogOCVMaxResult.TimedOut property.
Exceptions

ExceptionCondition
CogSecurityViolationExceptionIf licensing for this operator cannot be confirmed.
ArgumentNullExceptionIf the supplied CogOCVMaxRunParams argument is NULL.
ObjectDisposedExceptionIf this CogOCVMaxPattern object has already been disposed.
InvalidOperationExceptionIf an internal error occurs during training.
Remarks

The optional region limits the portion of the image to use. Note that the pattern must be trained before you can call this method.

See Also