Exemple #1
0
        public static ulong Hash64(float x, float y, float z)
        {
            var hasher = Hasher.Create();

            hasher.AddAligned64(TwoSinglesULongUnion.ReinterpretCast(x, y));
            hasher.Add(SingleUIntUnion.ReinterpretCast(z));
            return(hasher.Finalize64());
        }
Exemple #2
0
        public static uint Hash32(float x, float y, float z, float w)
        {
            var hasher = Hasher.Create();

            hasher.AddAligned64(TwoSinglesULongUnion.ReinterpretCast(x, y));
            hasher.AddAligned64(TwoSinglesULongUnion.ReinterpretCast(z, w));
            return(hasher.Finalize32());
        }
Exemple #3
0
        public static (float, float) ReinterpretCast(ulong value)
        {
            var val = new TwoSinglesULongUnion(value);

            return(val.F0, val.F1);
        }
Exemple #4
0
 public static ulong Hash64(float x, float y)
 {
     return(Hash64(TwoSinglesULongUnion.ReinterpretCast(x, y)));
 }