Class GeometryUtils
Utility methods for common geometric operations.
Inherited Members
Namespace: Unity.XR.CoreUtils
Assembly: solution.dll
Syntax
public static class GeometryUtils
Methods
Name | Description |
---|---|
Closest |
Returns the point along a line segment closest to a given point. |
Closest |
Finds the closest points between two line segments. |
Closest |
Finds the closest points of the perimeters of two polygons. |
Closest |
Finds the times at which two linear trajectories are the closest to each other. |
Closest |
Finds the times of closest approach between two non-parallel trajectories. |
Convex |
Finds the smallest convex polygon in the XZ plane that contains |
Convex |
Finds the area of a convex polygon. |
Find |
Finds the side of a polygon closest to a specified world space position. |
Oriented |
Find the oriented minimum bounding box for a 2D convex hull. |
Point |
Determines if a point is inside of a polygon on the XZ plane. (The y value is not used.) |
Point |
Determines if a point is inside of a convex polygon and lies on the surface. |
Point |
Determines if a point lies on a line segment, ignoring the y components. |
Point |
Finds the point on a polygon perimeter farthest from a specified point in space. |
Point |
Determines if a point lies on the bounds of a polygon, ignoring the y components. |
Polygon |
Given a list of vertices of a 2d convex polygon, find the centroid of the polygon. This implementation operates only on the X and Z axes. |
Polygon |
Determines if one polygon lies completely inside another coplanar polygon. |
Polygon |
Gets a corrected polygon uv pose from a given plane pose. |
Polygon |
Takes a polygon UV coordinate, and produces a pose-corrected UV coordinate. |
Polygons |
Determines if two convex coplanar polygons are within a certain distance from each other. This includes the polygon perimeters as well as their interiors. |
Polygons |
Determines if two convex coplanar polygons are within a specified distance from each other. |
Project |
Returns the point on a plane closest to a specified point. |
Rotation |
Given a 2D bounding box's vertices, find the rotation of the box. |
Triangulate |
Generates a standard triangle buffer with a given number of indices and adds it to the specified list. |