1 #ifndef _SPICA_HASH_GRID_H_
2 #define _SPICA_HASH_GRID_H_
6 #include "../core/point3d.h"
7 #include "../core/bounds3d.h"
23 void construct(std::vector<T>& points,
const int imageW = -1,
const int imageH = -1);
26 void init(
const int hashSize,
const double hashScale,
const Bounds3d& bbox);
34 const std::vector<T>& operator[](
const Point3d& v)
const;
38 unsigned int hash(
const int ix,
const int iy,
const int iz)
const;
44 std::vector<std::vector<T> > _data;
50 #include "hash_grid_detail.h"
52 #endif // _SPICA_HASH_GRID_H_
void init(const int hashSize, const double hashScale, const Bounds3d &bbox)
Initialize grid.
Definition: hash_grid_detail.h:28
void add(const T &p, const Point3d &boxMin, const Point3d &boxMax)
Set point data for the cells inside the specifed bounding box.
Definition: hash_grid_detail.h:36
void construct(std::vector< T > &points, const int imageW=-1, const int imageH=-1)
Construct hash grid.
Definition: hash_grid_detail.h:23
void clear()
Clear grid data.
Definition: hash_grid_detail.h:57
Definition: hash_grid.h:12