You are here: Start » AVL.NET » AVL.RescaleSegment Method

AVL.RescaleSegment Method

Lengthens or shortens a segment relatively.

Namespace:AvlNet
Assembly:AVL.NET.dll

Syntax

public static void RescaleSegment(
	AvlNet.Segment2D inSegment,
	AvlNet.Point2D? inReferencePoint,
	float inScale,
	bool inInverse,
	out AvlNet.Segment2D outSegment
)

Parameters

Name Type Range Default Description
inSegmentAvlNet.Segment2D
inReferencePointAvlNet.Point2D?The point to which all distances change linearly (the mass center by default). Default value: atl::NIL, or null.
inScalefloat1.0fScaling factor (negative values invert the segment). Default value: 1.0f.
inInverseboolSwitches to the inverse operation.
outSegmentAvlNet.Segment2D

Examples

RescaleSegment performed on the sample segment, inReferencePoint = auto, inScale = 2.0 and inInverse = false.

See also