示例#1
0
        public void MaxTest()
        {
            Half val1     = new Half(333);
            Half val2     = new Half(332);
            Half expected = new Half(333);
            Half actual   = Half.Max(val1, val2);

            Assert.Equal(expected, actual);
        }
示例#2
0
 /// <summary>
 /// Returns a hvec3 from component-wise application of Clamp (Half.Min(Half.Max(v, min), max)).
 /// </summary>
 public static Half Clamp(Half v, Half min, Half max) => Half.Min(Half.Max(v, min), max);
示例#3
0
 /// <summary>
 /// Returns a hvec3 from component-wise application of Max (Half.Max(lhs, rhs)).
 /// </summary>
 public static Half Max(Half lhs, Half rhs) => Half.Max(lhs, rhs);