PointCloud2BIM Library  1.0
Library to facilitate the transpormation of point clouds into digital BIM representation
Public Member Functions | List of all members
Project Class Reference

Public Member Functions

 Project (const fs::path &directory)
 Creates empty Project in a given directory path. More...
 
 Project (std::string project_name, const fs::path &full)
 Creates empty Project of a given name in a given directory path. More...
 
std::string & getFolder ()
 Returns Project folder path. More...
 
double * getTranslation ()
 Returns Project x, y, z translation. More...
 
void setTranslation (double tx, double ty, double tz)
 Set Project x, y, z translation. More...
 
void createProjectFile (const fs::path &path)
 Creates Project JSON file. More...
 
void save ()
 Saves the Project JSON file.
 
void openProjectFile (const fs::path &path)
 Opens the Project JSON file and read its contents. More...
 
void addPointCloud (PointCloud &pc, bool force_save=true)
 Add PointCloud to Project. More...
 
void update (PointCloud &p)
 Updates PointCloud after modifying. More...
 
std::vector< PointCloud > & getPointClouds ()
 Returns all PointClouds. More...
 
PointCloudgetPointCloud (int id)
 Returns a PointCloud by identifier. More...
 
void addRoom (Room &r, bool force_save=true)
 Add Room to Project. More...
 
void update (Room &r)
 Updates Room after modifying. More...
 
std::vector< Room > & getRooms ()
 Returns all Rooms. More...
 
RoomgetRoom (int id)
 Returns a Room by identifier. More...
 
void addFloor (Floor &f, bool force_save=true)
 Add Floor to Project. More...
 
void update (Floor &f)
 Updates Floor after modifying. More...
 
std::vector< Floor > & getFloors ()
 Returns all Floors. More...
 
FloorgetFloor (int id)
 Returns a Floor by identifier. More...
 
void addPlane (Plane &p, bool force_save=true)
 Add Plane to Project. More...
 
void update (Plane &p)
 Updates Plane after modifying. More...
 
std::vector< Plane > & getPlanes ()
 Returns all Planes. More...
 
PlanegetPlane (int id)
 Returns a Plane by identifier. More...
 
void addWall (Wall &p, bool force_save=true)
 Add Wall to Project. More...
 
void update (Wall &p)
 Updates Wall after modifying. More...
 
std::vector< Wall > & getWalls ()
 Returns all Walls. More...
 
WallgetWall (int id)
 Returns a Wall by identifier. More...
 
void addOpening (Opening &p, bool force_save=true)
 Add Opening to Project. More...
 
void update (Opening &p)
 Updates Opening after modifying. More...
 
std::vector< Opening > & getOpenings ()
 Returns all openings. More...
 
OpeninggetOpening (int id)
 Returns an Opening by identifier. More...
 
void import (std::string filename, bool translate=false)
 Imports points from a .pts file (space separated x, y, z(, r, g, b, i) points). More...
 

Constructor & Destructor Documentation

Project::Project ( const fs::path &  directory)
inline

Creates empty Project in a given directory path.

Parameters
directoryDirectory path
Returns
Project::Project ( std::string  project_name,
const fs::path &  full 
)
inline

Creates empty Project of a given name in a given directory path.

Parameters
project_nameProject name
fullDirectory path
Returns

Member Function Documentation

void Project::addFloor ( Floor f,
bool  force_save = true 
)
inline

Add Floor to Project.

Parameters
fFloor to add
force_saveWhether to save JSON after adding
void Project::addOpening ( Opening p,
bool  force_save = true 
)
inline

Add Opening to Project.

Parameters
pOpening to add
force_saveWhether to save JSON after adding
void Project::addPlane ( Plane p,
bool  force_save = true 
)
inline

Add Plane to Project.

Parameters
pPlane to add
force_saveWhether to save JSON after adding
void Project::addPointCloud ( PointCloud pc,
bool  force_save = true 
)
inline

Add PointCloud to Project.

Parameters
pcPoint cloud to add
force_saveWhether to save JSON after adding
void Project::addRoom ( Room r,
bool  force_save = true 
)
inline

Add Room to Project.

Parameters
rRoom to add
force_saveWhether to save JSON after adding
void Project::addWall ( Wall p,
bool  force_save = true 
)
inline

Add Wall to Project.

Parameters
pWall to add
force_saveWhether to save JSON after adding
void Project::createProjectFile ( const fs::path &  path)
inline

Creates Project JSON file.

Parameters
pathFile path
Floor& Project::getFloor ( int  id)
inline

Returns a Floor by identifier.

Parameters
idFloor identifier
Returns
Floor
std::vector<Floor>& Project::getFloors ( )
inline

Returns all Floors.

Returns
Floors
std::string& Project::getFolder ( )
inline

Returns Project folder path.

Returns
Project folder path
Opening& Project::getOpening ( int  id)
inline

Returns an Opening by identifier.

Parameters
idOpening identifier
Returns
Opening
std::vector<Opening>& Project::getOpenings ( )
inline

Returns all openings.

Returns
Openings
Plane& Project::getPlane ( int  id)
inline

Returns a Plane by identifier.

Parameters
idPlane identifier
Returns
Plane
std::vector<Plane>& Project::getPlanes ( )
inline

Returns all Planes.

Returns
Planes
PointCloud& Project::getPointCloud ( int  id)
inline

Returns a PointCloud by identifier.

Parameters
idPoint cloud identifier
Returns
Point cloud
std::vector<PointCloud>& Project::getPointClouds ( )
inline

Returns all PointClouds.

Returns
Point clouds
Room& Project::getRoom ( int  id)
inline

Returns a Room by identifier.

Parameters
idRoom identifier
Returns
Room
std::vector<Room>& Project::getRooms ( )
inline

Returns all Rooms.

Returns
Rooms
double* Project::getTranslation ( )
inline

Returns Project x, y, z translation.

Returns
Translation vector
Wall& Project::getWall ( int  id)
inline

Returns a Wall by identifier.

Parameters
idWall identifier
Returns
Wall
std::vector<Wall>& Project::getWalls ( )
inline

Returns all Walls.

Returns
Walls
void Project::import ( std::string  filename,
bool  translate = false 
)
inline

Imports points from a .pts file (space separated x, y, z(, r, g, b, i) points).

Parameters
filenamePath to import
translateSpecifies if imported points should be translated to bounding box minimum
void Project::openProjectFile ( const fs::path &  path)
inline

Opens the Project JSON file and read its contents.

Parameters
path
void Project::setTranslation ( double  tx,
double  ty,
double  tz 
)
inline

Set Project x, y, z translation.

Parameters
txTranslation in the x direction
tyTranslation in the y direction
tzTranslation in the z direction
void Project::update ( PointCloud p)
inline

Updates PointCloud after modifying.

Parameters
pPointCloud to update
void Project::update ( Room r)
inline

Updates Room after modifying.

Parameters
rRoom to update
void Project::update ( Floor f)
inline

Updates Floor after modifying.

Parameters
fFloor to update
void Project::update ( Plane p)
inline

Updates Plane after modifying.

Parameters
pPlane to update
void Project::update ( Wall p)
inline

Updates Wall after modifying.

Parameters
pWall to update
void Project::update ( Opening p)
inline

Updates Opening after modifying.

Parameters
pOpening to update

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