Panda3D
|
This hash_compare class hashes a float or a double. More...
#include "stl_compares.h"
Public Member Functions | |
floating_point_hash (Key threshold=get_nearly_zero_value((Key) 0)) | |
size_t | add_hash (size_t start, const Key &key) const |
Adds the indicated key into a running hash. More... | |
size_t | operator() (const Key &key) const |
Computes a size_t hash from the float. More... | |
bool | operator() (const Key &a, const Key &b) const |
Returns true if a sorts before b, false otherwise. More... | |
![]() | |
bool | is_equal (const Key &a, const Key &b) const |
size_t | operator() (const Key &key) const |
bool | operator() (const Key &a, const Key &b) const |
Public Attributes | |
const Key | _threshold |
This hash_compare class hashes a float or a double.
Definition at line 158 of file stl_compares.h.
|
inline |
Adds the indicated key into a running hash.
Definition at line 180 of file stl_compares.I.
References AddHash::add_hash(), and sequence_hash< Key, Compare >::operator()().
Referenced by LVecBase2f::add_hash(), LVecBase3f::add_hash(), LMatrix3f::add_hash(), LVecBase4f::add_hash(), LMatrix4f::add_hash(), LVecBase2d::add_hash(), LVecBase3d::add_hash(), LVecBase4d::add_hash(), LVecBase2i::add_hash(), LVecBase3i::add_hash(), LVecBase4i::add_hash(), LMatrix3d::add_hash(), LMatrix4d::add_hash(), and floating_point_hash< Key >::operator()().
|
inline |
Computes a size_t hash from the float.
Definition at line 158 of file stl_compares.I.
Referenced by pointer_hash::add_hash().
|
inline |
Returns true if a sorts before b, false otherwise.
Definition at line 169 of file stl_compares.I.
References floating_point_hash< Key >::add_hash().