Beispiel #1
0
    public override bool Equals(object other)
    {
        if (!(other is Matrix4x4L))
        {
            return(false);
        }
        Matrix4x4L matrix4x = (Matrix4x4L)other;

        return(this.GetColumn(0).Equals(matrix4x.GetColumn(0)) && this.GetColumn(1).Equals(matrix4x.GetColumn(1)) && this.GetColumn(2).Equals(matrix4x.GetColumn(2)) && this.GetColumn(3).Equals(matrix4x.GetColumn(3)));
    }
Beispiel #2
0
 /// <summary>
 /// 从矩阵中提取Quaternion
 /// </summary>
 /// <param name="m"></param>
 /// <returns></returns>
 public static QuaternionL GetRotationFromMatrix(Matrix4x4L m)
 {
     return(QuaternionL.LookRotation(m.GetColumn(2), m.GetColumn(1)));
 }