Back to FabImage Library website
You are here: Start » Function Reference » Geometry 2D » Geometry 2D Distance Metrics » PointToRectangleDistance
Header: | FIL.h |
---|---|
Namespace: | fil |
Module: | FoundationLite |
Measures the distance between point and rectangle.
Syntax
C++
C#
void fil::PointToRectangleDistance ( const fil::Point2D& inPoint, const fil::Rectangle2D& inRectangle, const float inResolution, const bool inIsFilled, float& outDistance, ftl::Conditional<fil::Segment2D>& outConnectingSegment )
Parameters
Name | Type | Range | Default | Description | |
---|---|---|---|---|---|
![]() |
inPoint | const Point2D& | |||
![]() |
inRectangle | const Rectangle2D& | |||
![]() |
inResolution | const float | 0.0 - ![]() |
1.0f | Number of real-world units per one pixel |
![]() |
inIsFilled | const bool | True | Whether the rectangle is filled inside or not | |
![]() |
outDistance | float& | |||
![]() |
outConnectingSegment | Conditional<Segment2D>& |