CogRectangle SetCenterWidthHeight Method Cognex VisionPro 9.23
Initialize from CenterX,CenterY,Width,Height.

Namespace: Cognex.VisionPro
Assembly: Cognex.VisionPro.Core (in Cognex.VisionPro.Core.dll) Version: 91.0.0.0
Syntax

public void SetCenterWidthHeight(
	double centerX,
	double centerY,
	double width,
	double height
)
Events

Event TypeReason
CogRectangle Changed

Fires when the value of this property changes.

The following state flags may be affected:

    Exceptions

    ExceptionCondition
    ArgumentException

    width is <= 0 or height is <= 0.

    Remarks

    Sets the x- and y-coordinates of the center and the width and height of this rectangle.

    See Also