Assembly: Cognex.VisionPro.Caliper (in Cognex.VisionPro.Caliper.dll) Version: 69.0.0.0
Parameters
- inputImage
- Type: Cognex.VisionPro ICogImage
The image to which the Caliper is applied.
- region
- Type: Cognex.VisionPro CogRectangleAffine
The Caliper input region. The supplied CogRectangleAffine (no other region type is allowed) is used to sample the image and create a one-dimensional projection image. The projection image is filtered, and the detected edge peaks are evaluated as possible caliper results.
Return Value
Type: CogCaliperResultsA CogCaliperResults object containing the results of this function.
| Exception | Condition |
|---|---|
| CogSecurityViolationException | Security is not enabled for this vision tool. See Resolving Security-Related Error Messages for more information. |
| CogOperatorNoInputImageException | Image is NULL. |
| CogOperatorInvalidRegionException | The selected space of region is not a valid space in Image or no part of region lies within Image. |
| CogCaliperNoScorersException | The supplied scoring collection is null or empty or all the scorers are disabled and a nonzero number of results has been requested. |
| CogCaliperBadScorerException | A single-edge scorer is in the two-edge scorers collection or a two-edge scorer is in the single-edge scorers collection. |
| CogCaliperImageTooSmallException | There are not enough pixels for the projected image. |
Apply the caliper to the given image with the given region of interest. If Region is not specified, the entire image will be used.