Back to Aurora Vision Library Lite website

You are here: Start » Geometry 2D » Geometry 2D Spatial Transforms » TranslateSegment

TranslateSegment


Header: AVL.h
Namespace: avl

Translates a segment by a vector.

Syntax

void avl::TranslateSegment
(
	const avl::Segment2D& inSegment,
	const avl::Vector2D& inDelta,
	bool inInverse,
	const avl::TranslateAlignment::Type inDeltaAlignment,
	avl::Segment2D& outSegment
)

Parameters

Name Type Default Description
Input value inSegment const Segment2D&
Input value inDelta const Vector2D& Translation vector
Input value inInverse bool Switches to the inverse operation
Input value inDeltaAlignment const TranslateAlignment::Type
Output value outSegment Segment2D&

In-place Processing

This function supports in-place data processing - you can pass the same reference to inSegment and outSegment

Read more about In-place Computation.

Examples

TranslateSegment performed on the sample segment, inDelta = (-60.0, -80.0) and inInverse = False.