Repository: FlaxEngine/FlaxEngine
File: Source/Engine/Core/Math/Quaternion.cs (C#)

Code before:
        /// <returns>The created look-at quaternion.</returns>
        public static Quaternion LookAt(Vector3 eye, Vector3 target, Vector3 up  = Vector3.Up)
        {
            LookAt(ref eye, ref target, ref up, out var result);
            return result;
        }

        /// <summary>
        /// Creates a left-handed, look-at quaternion.
        /// </summary>
        /// <param name="forward">The camera's forward direction.</param>
        /// <param name="up">The camera's up vector.</param>
        /// <param name="result">When the method completes, contains the created look-at quaternion.</param>
        public static void RotationLookAt(ref Vector3 forward, ref Vector3 up, out Quaternion result)
        {
            Vector3 eye = Vector3.Zero;
            LookAt(ref eye, ref forward, ref up, out result);
        }

        /// <summary>
        /// Creates a left-handed, look-at quaternion.
        /// </summary>
        /// <param name="forward">The camera's forward direction.</param>
        /// <param name="up">The camera's up vector.</param>
        /// <returns>The created look-at quaternion.</returns>
        public static Quaternion RotationLookAt(Vector3 forward, Vector3 up = Vector3.Up)
        {
            RotationLookAt(ref forward, ref up, out var result);
            return result;
        }

        /// <summary>
        /// Creates a rotation with the specified forward and upwards directions.
        /// </summary>
        /// <param name="forward">The forward direction. Direction to orient towards.</param>
        /// <param name="up">Up direction. Constrains y axis orientation to a plane this vector lies on. This rule might be broken if forward and up direction are nearly parallel.</param>
        /// <returns>The calculated quaternion.</returns>
        public static Quaternion LookRotation(Vector3 forward, Vector3 up = Vector3.Up)
        {
            LookRotation(ref forward, ref up, out var result);
            return result;
        }

        /// <summary>
        /// Creates a rotation with the specified forward and upwards directions.
        /// </summary>
        /// <param name="forward">The forward direction. Direction to orient towards.</param>
        /// <param name="up">The up direction. Constrains y axis orientation to a plane this vector lies on. This rule might be broken if forward and up direction are nearly parallel.</param>
        /// <param name="result">The calculated quaternion.</param>
        public static void LookRotation(ref Vector3 forward, ref Vector3 up, out Quaternion result)
        {

Review comment (suggestion):
The default value must be a compile time constant, that's why it's not possible to set a custom value, C# limitation.
There is a workaround using nullable value but it's not very clean imo.

Code after:
        public static Quaternion LookAt(Vector3 eye, Vector3 target){
            return LookAt(eye, target, Vector3.Up);
        }
        
        /// <summary>
        /// Creates a left-handed, look-at quaternion.
        /// </summary>
        /// <param name="eye">The position of the viewer's eye.</param>
        /// <param name="target">The camera look-at target.</param>
        /// <param name="up">The camera's up vector.</param>
        /// <returns>The created look-at quaternion.</returns>
        public static Quaternion LookAt(Vector3 eye, Vector3 target, Vector3 up)
        {
            LookAt(ref eye, ref target, ref up, out var result);
            return result;
        }

        /// <summary>
        /// Creates a left-handed, look-at quaternion.
        /// </summary>
        /// <param name="forward">The camera's forward direction.</param>
        /// <param name="up">The camera's up vector.</param>
        /// <param name="result">When the method completes, contains the created look-at quaternion.</param>
        public static void RotationLookAt(ref Vector3 forward, ref Vector3 up, out Quaternion result)
        {
            Vector3 eye = Vector3.Zero;
            LookAt(ref eye, ref forward, ref up, out result);
        }

        /// <summary>
        /// Creates a left-handed, look-at quaternion.
        /// </summary>
        /// <param name="forward">The camera's forward direction.</param>
        /// <returns>The created look-at quaternion.</returns>
        public static Quaternion RotationLookAt(Vector3 forward)
        {
            return RotationLookAt(forward, Vector3.Up);
        }
        
        /// <summary>
        /// Creates a left-handed, look-at quaternion.
        /// </summary>
        /// <param name="forward">The camera's forward direction.</param>
        /// <param name="up">The camera's up vector.</param>
        /// <returns>The created look-at quaternion.</returns>
        public static Quaternion RotationLookAt(Vector3 forward, Vector3 up)
        {
            RotationLookAt(ref forward, ref up, out var result);
            return result;
        }