Method PolygonsWithinRange
PolygonsWithinRange(List<Vector3>, List<Vector3>, float)
Determines if two convex coplanar polygons are within a certain distance from each other. This includes the polygon perimeters as well as their interiors.
Declaration
public static bool PolygonsWithinRange(List<Vector3> polygonA, List<Vector3> polygonB, float maxDistance)
Parameters
Type | Name | Description |
---|---|---|
List<Vector3> | polygonA | The first polygon to test. Must be convex and coplanar with |
List<Vector3> | polygonB | The second polygon to test. Must be convex and coplanar with |
float | maxDistance | The maximum distance allowed between the two polygons. |
Returns
Type | Description |
---|---|
bool | True if the polygons are within the specified distance from each other, false otherwise. |