Panda3D
 All Classes Functions Variables Enumerations
addHash.h
00001 // Filename: addHash.h
00002 // Created by:  drose (01Sep06)
00003 //
00004 ////////////////////////////////////////////////////////////////////
00005 //
00006 // PANDA 3D SOFTWARE
00007 // Copyright (c) Carnegie Mellon University.  All rights reserved.
00008 //
00009 // All use of this software is subject to the terms of the revised BSD
00010 // license.  You should have received a copy of this license along
00011 // with this source code in a file named "LICENSE."
00012 //
00013 ////////////////////////////////////////////////////////////////////
00014 
00015 #ifndef ADDHASH_H
00016 #define ADDHASH_H
00017 
00018 #include "dtoolbase.h"
00019 #include "numeric_types.h"
00020 #include "lookup3.h"
00021 
00022 ////////////////////////////////////////////////////////////////////
00023 //       Class : AddHash
00024 // Description : This class is used just as a namespace scope to
00025 //               collect together a handful of static functions, which
00026 //               are used to wrap calls to Bob Jenkins' public-domain
00027 //               hash generation function (defined in lookup3.c).
00028 ////////////////////////////////////////////////////////////////////
00029 class EXPCL_DTOOL AddHash {
00030 public:
00031   INLINE static size_t add_hash(size_t start, const PN_uint32 *words, size_t num_words);
00032   static size_t add_hash(size_t start, const PN_uint8 *bytes, size_t num_bytes);
00033   INLINE static size_t add_hash(size_t start, const PN_float32 *floats, size_t num_floats);
00034   INLINE static size_t add_hash(size_t start, const PN_float64 *floats, size_t num_floats);
00035 };
00036 
00037 #include "addHash.I"
00038 
00039 #endif
 All Classes Functions Variables Enumerations