35 #ifndef LAS_VEGAS_BIGGRID_HPP 36 #define LAS_VEGAS_BIGGRID_HPP 41 #include <boost/archive/binary_iarchive.hpp> 42 #include <boost/archive/binary_oarchive.hpp> 43 #include <boost/iostreams/device/mapped_file.hpp> 45 #include <unordered_map> 56 using Vec = BaseVector<float>;
70 template <
typename BaseVecT>
79 BigGrid(std::vector<std::string> cloudPath,
float voxelsize,
float scale = 0,
size_t bufferSize = 1024);
108 size_t pointSize(
int i,
int j,
int k);
132 float minx,
float miny,
float minz,
float maxx,
float maxy,
float maxz,
size_t& numPoints);
135 float minx,
float miny,
float minz,
float maxx,
float maxy,
float maxz,
size_t& numPoints);
138 float minx,
float miny,
float minz,
float maxx,
float maxy,
float maxz,
size_t& numPoints);
149 size_t getSizeofBox(
float minx,
float miny,
float minz,
float maxx,
float maxy,
float maxz);
151 void serialize(std::string path =
"serinfo.ls");
170 return i * m_maxIndexSquare + j * m_maxIndex + k;
177 return m_gridNumPoints[hash].dist_offset;
184 auto it = m_gridNumPoints.find(hash);
185 return it != m_gridNumPoints.end();
192 inline int calcIndex(
float f) {
return f < 0 ? f - .5 : f + .5; }
194 bool exists(
int i,
int j,
int k);
195 void insert(
float x,
float y,
float z);
208 #ifdef LVR2_USE_OPEN_MP 230 #include "lvr2/reconstruction/BigGrid.tcc" 232 #endif // LAS_VEGAS_BIGGRID_HPP
size_t hashValue(size_t i, size_t j, size_t k)
Datastructures for holding loaded data.
BoundingBox< BaseVecT > m_bb
BoundingBox< BaseVecT > & getBB()
size_t getDistanceFileOffset(size_t hash)
boost::shared_array< unsigned char > ucharArr
boost::iostreams::mapped_file m_ColorFile
std::unordered_map< size_t, CellInfo > m_gridNumPoints
A dynamic bounding box class.
std::vector< shared_ptr< Scan > > m_scans
boost::shared_array< float > floatArr
std::shared_ptr< ScanProjectEditMark > ScanProjectEditMarkPtr
BoundingBox< BaseVecT > & getpartialBB()
BoundingBox< BaseVecT > m_partialbb
boost::iostreams::mapped_file m_NomralFile
boost::iostreams::mapped_file m_PointFile