Back to FabImage Library website
You are here: Start » Function Reference » Geometry 2D » Geometry 2D Spatial Transforms » RescalePointArray
Header: | FIL.h |
---|---|
Namespace: | fil |
Module: | FoundationLite |
Changes the distances of points from an array to a reference point.
Syntax
C++
C#
void fil::RescalePointArray ( const ftl::Array<fil::Point2D>& inPoints, ftl::Optional<const fil::Point2D&> inReferencePoint, float inScale, bool inInverse, ftl::Array<fil::Point2D>& outPoints )
Parameters
Name | Type | Default | Description | |
---|---|---|---|---|
![]() |
inPoints | const Array<Point2D>& | ||
![]() |
inReferencePoint | Optional<const Point2D&> | NIL | Point to which the distances will be changed (the mass center by default) |
![]() |
inScale | float | 1.0f | Scaling factor |
![]() |
inInverse | bool | Switches to the inverse operation | |
![]() |
outPoints | Array<Point2D>& |
In-place Processing
This function supports in-place data processing - you can pass the same reference to inPoints and outPoints
Read more about In-place Computation.
Errors
List of possible exceptions:
Error type | Description |
---|---|
DomainError | Scale cannot be zero in an inverse rescaling of a point in RescalePointArray. |