From b6519e558f0863b7daeaebf6cda972f94784a510 Mon Sep 17 00:00:00 2001 From: bkaradzic Date: Sat, 10 Nov 2012 19:47:09 -0800 Subject: [PATCH] Added helper func to murmur hash class. --- include/bx/hash.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/include/bx/hash.h b/include/bx/hash.h index 1722515..7582eb2 100644 --- a/include/bx/hash.h +++ b/include/bx/hash.h @@ -48,6 +48,12 @@ namespace bx mixTail(data, _len); } + template + void add(Ty _value) + { + add(&_value, sizeof(Ty) ); + } + uint32_t end() { mmix(m_hash, m_tail);