Esempio n. 1
0
        public float GetValue(FunctionCall arg)
        {
            float accumulator = 0;
            float now         = 0;

            while (now < arg.LocalTime)
            {
                accumulator += precision * derivative.GetValue(new FunctionCall(now));
                now         += precision;
            }

            return(accumulator);
        }
Esempio n. 2
0
        public float GetValue(FunctionCall arg)
        {
            var local_var = 1f;

            var accumulator = 0f;

            for (int i = 0; i < Degree; i++)
            {
                accumulator += local_var * Coefficients[i];

                local_var *= arg.LocalTime;
            }

            return(accumulator);
        }
Esempio n. 3
0
        public float GetValue(FunctionCall arg)
        {
            var t      = arg.Time % 1f;
            var factor = 1f;

            if (t > activetime)
            {
                factor = 0;
            }

            if (context != null)
            {
                return(context.GetValue(arg) * factor);
            }

            return(factor);
        }
 public float GetValue(FunctionCall arg) =>
 context.GetValue(new FunctionCall(arg.LocalTime, arg.LocalTime, arg.RealTime));
Esempio n. 5
0
 public float GetValue(FunctionCall arg) =>
 (arg.LocalTime < 0 || arg.LocalTime > 1) ? 0 : 1;
Esempio n. 6
0
 public float GetValue(FunctionCall arg) =>
 function.data.GetIntegratedValue(arg.Time);
Esempio n. 7
0
 public float GetValue(FunctionCall arg) =>
 data.GetValue(arg.Time);