CogLineSegment MakeShapeModel Method Cognex VisionPro 9.20
Returns a newly created shape model with the given weight and polarity. The 'Shape' property of the returned shape model will refer to this shape, or a copy of this shape, as specified by the CopyShape argument.

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

public ICogShapeModel MakeShapeModel(
	double weight,
	CogShapeModelPolarityConstants polarity,
	bool copyShape
)

Parameters

weight
Type: System Double

The weight of the shape model.

polarity
Type: Cognex.VisionPro CogShapeModelPolarityConstants

The polarity of the shape model.

copyShape
Type: System Boolean

If True, the returned shape model refers to a copy of this CogLineSegment; otherwise the shape model refers to this CogLineSegment.

Return Value

Type: ICogShapeModel

The returned shape model.

Exceptions

ExceptionCondition
ArgumentException

polarity is not in CogShapeModelPolarityConstants.

Remarks

Returns a newly created CogShapeModel with the given weight and polarity.

The Shape property of the returned shape will refer to this shape or to a copy of this shape depending on the copyShape argument.

See Also