Panda3D

addHash.I

00001 // Filename: add_hash.I
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 
00016 ////////////////////////////////////////////////////////////////////
00017 //     Function: AddHash::add_hash
00018 //       Access: Public, Static
00019 //  Description: Adds a linear sequence of uint32 words to the hash.
00020 ////////////////////////////////////////////////////////////////////
00021 INLINE size_t AddHash::
00022 add_hash(size_t start, const PN_uint32 *words, size_t num_words) {
00023   return (size_t)hashword(words, num_words, (PN_uint32)start);
00024 }
00025 
00026 ////////////////////////////////////////////////////////////////////
00027 //     Function: AddHash::add_hash
00028 //       Access: Public, Static
00029 //  Description: Adds a linear sequence of float32 words to the hash.
00030 ////////////////////////////////////////////////////////////////////
00031 INLINE size_t AddHash::
00032 add_hash(size_t start, const PN_float32 *floats, size_t num_floats) {
00033   return add_hash(start, (const PN_uint32 *)floats, num_floats);
00034 }
00035 
00036 ////////////////////////////////////////////////////////////////////
00037 //     Function: AddHash::add_hash
00038 //       Access: Public, Static
00039 //  Description: Adds a linear sequence of float64 words to the hash.
00040 ////////////////////////////////////////////////////////////////////
00041 INLINE size_t AddHash::
00042 add_hash(size_t start, const PN_float64 *floats, size_t num_floats) {
00043   return add_hash(start, (const PN_uint32 *)floats, num_floats * 2);
00044 }
00045 
 All Classes Functions Variables Enumerations