AudaciousTunes/Audacious/Utils.cs
/// <summary>
/// Clamps a double to the value range of a float.
/// </summary>
Clamps a double to the value range of a float.
Clamps a double to the value range of a float .
public static float Clamp(double value)
        {
            if (value > float.MaxValue)
            {
                value = float.MaxValue;
            }
            else if (value < float.MinValue)
            {
                value = float.MinValue;
            }
            return (float)value;
        }
public static float Clamp ( double value ) { if ( value > float . MaxValue ) { value = float . MaxValue ; } else if ( value < float . MinValue ) { value = float . MinValue ; } return ( float ) value ; }
Clamps a double to the value range of a float.
Clamps a double to the value range of a float .
value
double