UnityEditor.SerializedMinMaxCurve.IsCurveConstant C# (CSharp) Method

IsCurveConstant() private method

private IsCurveConstant ( Keyframe keyFrames, float &constantValue ) : bool
keyFrames UnityEngine.Keyframe
constantValue float
return bool
        private bool IsCurveConstant(Keyframe[] keyFrames, out float constantValue)
        {
            if (keyFrames.Length == 0)
            {
                constantValue = 0f;
                return false;
            }
            constantValue = keyFrames[0].value;
            for (int i = 1; i < keyFrames.Length; i++)
            {
                if (Mathf.Abs((float) (constantValue - keyFrames[i].value)) > 1E-05f)
                {
                    return false;
                }
            }
            return true;
        }