Assembly: Cognex.VisionPro.Core (in Cognex.VisionPro.Core.dll) Version: 87.0.0.0
Parameters
- x
- Type: System Double
The x-coordinate of the reference point of the new line.
- y
- Type: System Double
The y-coordinate of the reference point of the new line.
- line
- Type: Cognex.VisionPro CogLine
The line that the new line will be perpendicular to.
- image
- Type: Cognex.VisionPro ICogImage
An image that specifies the coordinate space to use.
Return Value
Type: CogLineThe new line.
| Exception | Condition |
|---|---|
| ArgumentException | line is NULL. |
| CogSpaceTreeInvalidNameSyntaxException | At least one shape's selected space names is not a legal space name. |
| CogSpaceTreeNotUniqueException | At least one shape's selected space names is a nonqualified space name and more than one instance of it exists in image's coordinate space tree. |
| CogSpaceTreeNotInTreeException | At least one shape does not exist in image's coordinate space tree. |
| CogImageNoTreeException | The coordinate space tree is missing from image. |
Creates a new CogLine that is perpendicular to line and whose reference point is (x,y).
The new line's rotation is line's rotation plus π/2 radians. The new lines has the same properties (such as Color) as line.
If you supply a value for the image parameter, then line is mapped to the selected space of image before the new line is created. The returned line has its selected space set to the selected space of image.
If you do not supply a value for image, then the returned line has its selected space set to ".".