A virtual base class that implements the capability of importing 3D point clouds and faces from a file in the Stanford PLY format.
Definition at line 26 of file PLY_import_export.h.
#include <mrpt/utils/PLY_import_export.h>
Public Member Functions | |
bool | loadFromPlyFile (const std::string &filename, CStringList *file_comments=NULL, CStringList *file_obj_info=NULL) |
Loads from a PLY file. | |
std::string | getLoadPLYErrorString () const |
Return a description of the error if loadFromPlyFile() returned false, or an empty string if the file was loaded without problems. | |
Protected Member Functions | |
PLY Import virtual methods to implement in base classes | |
virtual void | PLY_import_set_vertex_count (const size_t N)=0 |
In a base class, reserve memory to prepare subsequent calls to PLY_import_set_vertex. | |
virtual void | PLY_import_set_face_count (const size_t N)=0 |
In a base class, reserve memory to prepare subsequent calls to PLY_import_set_face. | |
virtual void | PLY_import_set_vertex (const size_t idx, const mrpt::math::TPoint3Df &pt, const mrpt::utils::TColorf *pt_color=NULL)=0 |
In a base class, will be called after PLY_import_set_vertex_count() once for each loaded point. | |
Private Attributes | |
std::string | m_ply_import_last_error |
|
inline |
Return a description of the error if loadFromPlyFile() returned false, or an empty string if the file was loaded without problems.
Definition at line 41 of file PLY_import_export.h.
bool mrpt::utils::PLY_Importer::loadFromPlyFile | ( | const std::string & | filename, |
CStringList * | file_comments = NULL , |
||
CStringList * | file_obj_info = NULL |
||
) |
Loads from a PLY file.
[in] | filename | The filename to open. It can be either in binary or text format. |
[out] | file_comments | If provided (!=NULL) the list of comment strings stored in the file will be returned. |
[out] | file_obj_info | If provided (!=NULL) the list of "object info" strings stored in the file will be returned. |
|
protectedpure virtual |
In a base class, reserve memory to prepare subsequent calls to PLY_import_set_face.
Implemented in mrpt::maps::CPointsMap, mrpt::opengl::CPointCloud, and mrpt::opengl::CPointCloudColoured.
|
protectedpure virtual |
In a base class, will be called after PLY_import_set_vertex_count() once for each loaded point.
pt_color | Will be NULL if the loaded file does not provide color info. |
Implemented in mrpt::maps::CColouredPointsMap, mrpt::maps::CPointsMap, mrpt::opengl::CPointCloud, and mrpt::opengl::CPointCloudColoured.
|
protectedpure virtual |
In a base class, reserve memory to prepare subsequent calls to PLY_import_set_vertex.
Implemented in mrpt::maps::CColouredPointsMap, mrpt::maps::CSimplePointsMap, mrpt::maps::CWeightedPointsMap, mrpt::opengl::CPointCloud, and mrpt::opengl::CPointCloudColoured.
|
private |
Definition at line 61 of file PLY_import_export.h.
Page generated by Doxygen 1.9.6 for MRPT 1.4.0 SVN: at Fri Jan 20 02:28:26 UTC 2023 |