SegmentDistance(SegmentGeometry, PhysicsTransform, SegmentGeometry, PhysicsTransform)
Calculate the distance and closest points between two segments.
Read time 1 minuteLast updated 10 days ago
Definition
- Type: Method
- Namespace: UnityEngine.LowLevelPhysics2D
- Assembly: UnityEngine.Physics2DModule
public static PhysicsQuery.SegmentDistanceResult SegmentDistance(SegmentGeometry geometryA, PhysicsTransform transformA, SegmentGeometry geometryB, PhysicsTransform transformB)
Parameters
The first geometry to use.
The transform used to specify where the first geometry is positioned.
The second geometry to use.
The transform used to specify where the second geometry is positioned.
Returns
Type | Description |
|---|---|
| SegmentDistanceResult | The segment distance results. |