Esempio n. 1
0
        private static void TestBinaryOperationFloatExact(float a, float b, float expected, BinaryOperationType op)
        {
            BinaryOperation func   = binaryOperations[(int)op];
            sfloat          result = func((sfloat)a, (sfloat)b);
            bool            isOk   = result.Equals((sfloat)expected);

            Debug.Assert(isOk);
        }
Esempio n. 2
0
        private static void TestUnaryOperationFloatExact(float x, float expected, UnaryOperationType op)
        {
            UnaryOperation func   = unaryOperations[(int)op];
            sfloat         result = func((sfloat)x);
            bool           isOk   = result.Equals((sfloat)expected);

            Debug.Assert(isOk);
        }
Esempio n. 3
0
 public bool Equals(Constraint other)
 {
     return(ConstrainedAxes.Equals(other.ConstrainedAxes) &&
            Type == other.Type &&
            Min.Equals(other.Min) &&
            Max.Equals(other.Max) &&
            SpringFrequency.Equals(other.SpringFrequency) &&
            SpringDamping.Equals(other.SpringDamping));
 }
Esempio n. 4
0
 public bool Equals(FloatRange other) => Min.Equals(other.Min) && Max.Equals(other.Max);