Beispiel #1
0
        /// <summary>
        /// Returns the minimum angle between two vectors.
        /// </summary>
        /// <param name="v0"></param>
        /// <param name="v1"></param>
        /// <returns></returns>
        public static float Angle(Vector3f v0, Vector3f v1)
        {
            var d = v0.SquareLength * v1.SquareLength;

            return(d > 0.0f ? SlurMath.AcosSafe(Dot(v0, v1) / SlurMath.Sqrt(d)) : 0.0f);
        }