Public Member Functions | Private Member Functions | Private Attributes | List of all members
lvr2::BigGrid< BaseVecT > Class Template Reference

#include <BigGrid.hpp>

Public Member Functions

 BigGrid (std::vector< std::string > cloudPath, float voxelsize, float scale=0, size_t bufferSize=1024)
 
 BigGrid (float voxelsize, ScanProjectEditMarkPtr project, float scale=0)
 
 BigGrid (std::string path)
 
lvr2::ucharArr colors (float minx, float miny, float minz, float maxx, float maxy, float maxz, size_t &numPoints)
 
bool exists (size_t hash)
 
BoundingBox< BaseVecT > & getBB ()
 
size_t getDistanceFileOffset (size_t hash)
 
BoundingBox< BaseVecT > & getpartialBB ()
 
lvr2::floatArr getPointCloud (size_t &numPoints)
 
size_t getSizeofBox (float minx, float miny, float minz, float maxx, float maxy, float maxz)
 
bool hasColors ()
 
size_t hashValue (size_t i, size_t j, size_t k)
 
bool hasNormals ()
 
lvr2::floatArr normals (float minx, float miny, float minz, float maxx, float maxy, float maxz, size_t &numPoints)
 
lvr2::floatArr points (int i, int j, int k, size_t &numPoints)
 
lvr2::floatArr points (float minx, float miny, float minz, float maxx, float maxy, float maxz, size_t &numPoints)
 
size_t pointSize ()
 
size_t pointSize (int i, int j, int k)
 
void serialize (std::string path="serinfo.ls")
 
size_t size ()
 
virtual ~BigGrid ()
 

Private Member Functions

int calcIndex (float f)
 
bool exists (int i, int j, int k)
 
void insert (float x, float y, float z)
 

Private Attributes

BoundingBox< BaseVecT > m_bb
 
boost::iostreams::mapped_file m_ColorFile
 
bool m_extrude
 
std::unordered_map< size_t, CellInfom_gridNumPoints
 
bool m_has_color
 
bool m_has_normal
 
size_t m_maxIndex
 
size_t m_maxIndexSquare
 
size_t m_maxIndexX
 
size_t m_maxIndexY
 
size_t m_maxIndexZ
 
boost::iostreams::mapped_file m_NomralFile
 
size_t m_numPoints
 
BoundingBox< BaseVecT > m_partialbb
 
size_t m_pointBufferSize
 
boost::iostreams::mapped_file m_PointFile
 
float m_scale
 
std::vector< shared_ptr< Scan > > m_scans
 
float m_voxelSize
 

Detailed Description

template<typename BaseVecT>
class lvr2::BigGrid< BaseVecT >

Definition at line 71 of file BigGrid.hpp.

Constructor & Destructor Documentation

◆ BigGrid() [1/3]

template<typename BaseVecT>
lvr2::BigGrid< BaseVecT >::BigGrid ( std::vector< std::string >  cloudPath,
float  voxelsize,
float  scale = 0,
size_t  bufferSize = 1024 
)

Constructor:

Parameters
cloudPathpath to PointCloud in ASCII xyz Format // Todo: Add other file formats
voxelsize

◆ BigGrid() [2/3]

template<typename BaseVecT>
lvr2::BigGrid< BaseVecT >::BigGrid ( float  voxelsize,
ScanProjectEditMarkPtr  project,
float  scale = 0 
)

Constructor: specific case for incremental reconstruction/chunking. also compatible with simple reconstruction

Parameters
voxelsizespecified voxelsize
projectScanProject, which contain one or more Scans
scalescale value of for current scans

◆ BigGrid() [3/3]

template<typename BaseVecT>
lvr2::BigGrid< BaseVecT >::BigGrid ( std::string  path)

◆ ~BigGrid()

template<typename BaseVecT>
virtual lvr2::BigGrid< BaseVecT >::~BigGrid ( )
virtual

Member Function Documentation

◆ calcIndex()

template<typename BaseVecT>
int lvr2::BigGrid< BaseVecT >::calcIndex ( float  f)
inlineprivate

Definition at line 192 of file BigGrid.hpp.

◆ colors()

template<typename BaseVecT>
lvr2::ucharArr lvr2::BigGrid< BaseVecT >::colors ( float  minx,
float  miny,
float  minz,
float  maxx,
float  maxy,
float  maxz,
size_t &  numPoints 
)

◆ exists() [1/2]

template<typename BaseVecT>
bool lvr2::BigGrid< BaseVecT >::exists ( size_t  hash)
inline

Definition at line 182 of file BigGrid.hpp.

◆ exists() [2/2]

template<typename BaseVecT>
bool lvr2::BigGrid< BaseVecT >::exists ( int  i,
int  j,
int  k 
)
private

◆ getBB()

template<typename BaseVecT>
BoundingBox<BaseVecT>& lvr2::BigGrid< BaseVecT >::getBB ( )
inline

Definition at line 155 of file BigGrid.hpp.

◆ getDistanceFileOffset()

template<typename BaseVecT>
size_t lvr2::BigGrid< BaseVecT >::getDistanceFileOffset ( size_t  hash)
inline

Definition at line 173 of file BigGrid.hpp.

◆ getpartialBB()

template<typename BaseVecT>
BoundingBox<BaseVecT>& lvr2::BigGrid< BaseVecT >::getpartialBB ( )
inline

get the partial BB of the area, which needs to be reconstructed

Returns
partial BB

Definition at line 163 of file BigGrid.hpp.

◆ getPointCloud()

template<typename BaseVecT>
lvr2::floatArr lvr2::BigGrid< BaseVecT >::getPointCloud ( size_t &  numPoints)

◆ getSizeofBox()

template<typename BaseVecT>
size_t lvr2::BigGrid< BaseVecT >::getSizeofBox ( float  minx,
float  miny,
float  minz,
float  maxx,
float  maxy,
float  maxz 
)

return numbers of points in a specific area (defined by the params) of the grid

Parameters
minx
miny
minz
maxx
maxy
maxz
Returns
number of points in area

◆ hasColors()

template<typename BaseVecT>
bool lvr2::BigGrid< BaseVecT >::hasColors ( )
inline

Definition at line 188 of file BigGrid.hpp.

◆ hashValue()

template<typename BaseVecT>
size_t lvr2::BigGrid< BaseVecT >::hashValue ( size_t  i,
size_t  j,
size_t  k 
)
inline

Definition at line 168 of file BigGrid.hpp.

◆ hasNormals()

template<typename BaseVecT>
bool lvr2::BigGrid< BaseVecT >::hasNormals ( )
inline

Definition at line 189 of file BigGrid.hpp.

◆ insert()

template<typename BaseVecT>
void lvr2::BigGrid< BaseVecT >::insert ( float  x,
float  y,
float  z 
)
private

◆ normals()

template<typename BaseVecT>
lvr2::floatArr lvr2::BigGrid< BaseVecT >::normals ( float  minx,
float  miny,
float  minz,
float  maxx,
float  maxy,
float  maxz,
size_t &  numPoints 
)

◆ points() [1/2]

template<typename BaseVecT>
lvr2::floatArr lvr2::BigGrid< BaseVecT >::points ( int  i,
int  j,
int  k,
size_t &  numPoints 
)

Points of Voxel at position i,j,k

Parameters
i
j
k
numPoints,amountof points in lvr2::floatArr
Returns
lvr2::floatArr, containing points

◆ points() [2/2]

template<typename BaseVecT>
lvr2::floatArr lvr2::BigGrid< BaseVecT >::points ( float  minx,
float  miny,
float  minz,
float  maxx,
float  maxy,
float  maxz,
size_t &  numPoints 
)

Points that are within bounding box defined by a min and max point

Parameters
minx
miny
minz
maxx
maxy
maxz
numPointsnumber of points
Returns
lvr2::floatArr, containing points

◆ pointSize() [1/2]

template<typename BaseVecT>
size_t lvr2::BigGrid< BaseVecT >::pointSize ( )
Returns
Number Points

◆ pointSize() [2/2]

template<typename BaseVecT>
size_t lvr2::BigGrid< BaseVecT >::pointSize ( int  i,
int  j,
int  k 
)

Amount of Points in Voxel at position i,j,k

Parameters
i
j
k
Returns
amount of points, 0 if voxel does not exsist

◆ serialize()

template<typename BaseVecT>
void lvr2::BigGrid< BaseVecT >::serialize ( std::string  path = "serinfo.ls")

◆ size()

template<typename BaseVecT>
size_t lvr2::BigGrid< BaseVecT >::size ( )
Returns
Number of voxels

Member Data Documentation

◆ m_bb

template<typename BaseVecT>
BoundingBox<BaseVecT> lvr2::BigGrid< BaseVecT >::m_bb
private

Definition at line 217 of file BigGrid.hpp.

◆ m_ColorFile

template<typename BaseVecT>
boost::iostreams::mapped_file lvr2::BigGrid< BaseVecT >::m_ColorFile
private

Definition at line 216 of file BigGrid.hpp.

◆ m_extrude

template<typename BaseVecT>
bool lvr2::BigGrid< BaseVecT >::m_extrude
private

Definition at line 207 of file BigGrid.hpp.

◆ m_gridNumPoints

template<typename BaseVecT>
std::unordered_map<size_t, CellInfo> lvr2::BigGrid< BaseVecT >::m_gridNumPoints
private

Definition at line 224 of file BigGrid.hpp.

◆ m_has_color

template<typename BaseVecT>
bool lvr2::BigGrid< BaseVecT >::m_has_color
private

Definition at line 212 of file BigGrid.hpp.

◆ m_has_normal

template<typename BaseVecT>
bool lvr2::BigGrid< BaseVecT >::m_has_normal
private

Definition at line 211 of file BigGrid.hpp.

◆ m_maxIndex

template<typename BaseVecT>
size_t lvr2::BigGrid< BaseVecT >::m_maxIndex
private

Definition at line 198 of file BigGrid.hpp.

◆ m_maxIndexSquare

template<typename BaseVecT>
size_t lvr2::BigGrid< BaseVecT >::m_maxIndexSquare
private

Definition at line 197 of file BigGrid.hpp.

◆ m_maxIndexX

template<typename BaseVecT>
size_t lvr2::BigGrid< BaseVecT >::m_maxIndexX
private

Definition at line 199 of file BigGrid.hpp.

◆ m_maxIndexY

template<typename BaseVecT>
size_t lvr2::BigGrid< BaseVecT >::m_maxIndexY
private

Definition at line 200 of file BigGrid.hpp.

◆ m_maxIndexZ

template<typename BaseVecT>
size_t lvr2::BigGrid< BaseVecT >::m_maxIndexZ
private

Definition at line 201 of file BigGrid.hpp.

◆ m_NomralFile

template<typename BaseVecT>
boost::iostreams::mapped_file lvr2::BigGrid< BaseVecT >::m_NomralFile
private

Definition at line 215 of file BigGrid.hpp.

◆ m_numPoints

template<typename BaseVecT>
size_t lvr2::BigGrid< BaseVecT >::m_numPoints
private

Definition at line 202 of file BigGrid.hpp.

◆ m_partialbb

template<typename BaseVecT>
BoundingBox<BaseVecT> lvr2::BigGrid< BaseVecT >::m_partialbb
private

Definition at line 220 of file BigGrid.hpp.

◆ m_pointBufferSize

template<typename BaseVecT>
size_t lvr2::BigGrid< BaseVecT >::m_pointBufferSize
private

Definition at line 204 of file BigGrid.hpp.

◆ m_PointFile

template<typename BaseVecT>
boost::iostreams::mapped_file lvr2::BigGrid< BaseVecT >::m_PointFile
private

Definition at line 214 of file BigGrid.hpp.

◆ m_scale

template<typename BaseVecT>
float lvr2::BigGrid< BaseVecT >::m_scale
private

Definition at line 225 of file BigGrid.hpp.

◆ m_scans

template<typename BaseVecT>
std::vector<shared_ptr<Scan> > lvr2::BigGrid< BaseVecT >::m_scans
private

Definition at line 222 of file BigGrid.hpp.

◆ m_voxelSize

template<typename BaseVecT>
float lvr2::BigGrid< BaseVecT >::m_voxelSize
private

Definition at line 206 of file BigGrid.hpp.


The documentation for this class was generated from the following file:


lvr2
Author(s): Thomas Wiemann , Sebastian Pütz , Alexander Mock , Lars Kiesow , Lukas Kalbertodt , Tristan Igelbrink , Johan M. von Behren , Dominik Feldschnieders , Alexander Löhr
autogenerated on Mon Feb 28 2022 22:46:11