Beispiel #1
0
        /// <summary>
        /// Returns a signed angle
        /// </summary>
        /// <param name="direction"></param>
        /// <param name="next"></param>
        /// <returns></returns>
        public static Angle GetSignedAngleBetween(LineSegment2 direction, Vector2 next)
        {
            var angle = next.GetAngleTo(direction.ToVector());

            return(angle * (direction.IsLeft(next) ? 1 : -1));
        }