GetRelativeMatrix(Transform, Transform, TransformPlane, bool)
Get the relative transformation matrix between the two specified transforms using the specified transform plane.
Read time 1 minuteLast updated 12 days ago
Definition
- Type: Method
- Namespace: UnityEngine.LowLevelPhysics2D
- Assembly: UnityEngine.Physics2DModule
public static Matrix4x4 GetRelativeMatrix(Transform transformFrom, Transform transformTo, PhysicsWorld.TransformPlane transformPlane = TransformPlane.XY, bool useScale = true)
Parameters
The transform used as a reference to transform from.
The transform used as a reference to transform to.
The transform plane to use.
If the returned matrix should include scale.
Returns
Type | Description |
|---|---|
| Matrix4x4 | The calculated relative transformation matrix. |