15 #ifndef PHYSXMESHHASH_H
16 #define PHYSXMESHHASH_H
18 #include "config_physx.h"
36 void set_grid_spacing(
float spacing);
37 INLINE NxF32 get_grid_spacing()
const;
39 void add(
const NxBounds3 &bounds,
int itemIndex);
40 void add(
const NxVec3 &pos,
int itemIndex);
42 void query(
const NxBounds3 &bounds,
pvector<int> &itemIndices,
int maxIndices=-1);
43 void query_unique(
const NxBounds3 &bounds,
pvector<int> &itemIndices,
int maxIndices=-1);
45 void query(
const NxVec3 &pos,
pvector<int> &itemIndices,
int maxIndices=-1);
46 void query_unique(
const NxVec3 &pos,
pvector<int> &itemIndices,
int maxIndices=-1);
54 struct MeshHashEntry {
63 static const int _hashIndexSize = 17011;
64 MeshHashRoot _hashIndex[_hashIndexSize];
68 INLINE
int hash_function(
int xi,
int yi,
int zi)
const;
69 INLINE
void cell_coord_of(
const NxVec3 &v,
int &xi,
int &yi,
int &zi)
const;
72 void quick_sort(
pvector<int> &itemIndices,
int l,
int r);
76 #include "physxMeshHash.I"
78 #endif // PHYSXMESHHASH_H
Utility class used in building links between a tetrahedron mesh (soft body) and a triangle mesh used ...