class MatrixUtils (Niantic.ARDK.Utilities.MatrixUtils)
Overview
A utility class to help grepping information from matrices. More...
class MatrixUtils {
public:
// methods
static Vector3 PositionFromMatrix(Matrix4x4 matrix);
static Quaternion RotationFromMatrix(Matrix4x4 matrix);
static Vector3 ToPosition(this Matrix4x4 matrix);
static Quaternion ToRotation(this Matrix4x4 matrix);
};
Detailed Documentation
A utility class to help grepping information from matrices.
Methods
static Vector3 PositionFromMatrix(Matrix4x4 matrix)
Returns the position from a transform matrix.
Parameters:
matrix |
The matrix from which to extract the position. |
static Quaternion RotationFromMatrix(Matrix4x4 matrix)
Returns the rotation as a quaternion from a transform matrix.
注釈
This does not work on matrices with negative scale values.
Parameters:
matrix |
The matrix from which to extract the rotation. |
static Quaternion ToRotation(this Matrix4x4 matrix)
Returns the rotation as a quaternion from a transform matrix.
注釈
This does not work on matrices with negative scaled values.
Parameters:
matrix |
The matrix from which to extract the rotation. |