HoleDetection/util.hpp
/**
 * @brief Read the provided dataset and create a point cloud
 * 
 * The input file must contain points in the following format:
 * 1. Each line will contain one point
 * 2. Each point will have 3 float coordinates, space separated
 * 
 * For example:
 * 0.1 0.3 3.4
 * 3.3 9.2 1.0
 * 
 * @param  path Path to the file that is to be read 
 * @return A shared pointer to the created point cloud
*/
@brief Read the provided dataset and create a point cloud

The input file must contain points in the following format:
1. Each line will contain one point
2. Each point will have 3 float coordinates, space separated



@param  path Path to the file that is to be read
@return A shared pointer to the created point cloud
@brief Read the provided dataset and create a point cloud The input file must contain points in the following format : 1 . Each line will contain one point 2 . Each point will have 3 float coordinates space separated @param path Path to the file that is to be read @return A shared pointer to the created point cloud
PCRef ReadIn(const std::string& path)
{
    auto pc = std::make_shared<PC>();
    std::ifstream file(path);
    float x, y, z;
    while (file >> x >> y >> z)
    {
        pc->points.push_back(Point{ x, y, z });
    }
    return pc;
}
PCRef ReadIn ( const std :: string & path ) { auto pc = std :: make_shared < PC > ( ) ; std :: ifstream file ( path ) ; float x , y , z ; while ( file >> x >> y >> z ) { pc -> points . push_back ( Point { x , y , z } ) ; } return pc ; }
@brief Read the provided dataset and create a point cloud
@brief Read the provided dataset and create a point cloud