|
EBGeometry
Compact, header-only C++ library for fast evaluation of signed distance functions
|
Class for storing Stanford PLY meshes. More...
#include <EBGeometry_PLY.hpp>

Public Member Functions | |
| PLY () noexcept=default | |
| Default constructor. Initializes empty member data holder. | |
| PLY (const std::string &a_id) noexcept | |
| Constructor. Initializes empty vertices and facets but sets the PLY ID (usually the file name. | |
| PLY (const PLY &a_other)=default | |
| Copy constructor. | |
| PLY (PLY &&a_other) noexcept=default | |
| Move constructor. | |
| PLY & | operator= (const PLY &a_other)=default |
| Copy assignment operator. | |
| PLY & | operator= (PLY &&a_other) noexcept=default |
| Move assignment operator. | |
| ~PLY () noexcept=default | |
| Destructor (does nothing). | |
| std::string & | getID () noexcept |
| Get the identifier for this object. | |
| const std::string & | getID () const noexcept |
| Get the identifier for this object. | |
| std::vector< Vec3T< T > > & | getVertexCoordinates () noexcept |
| Get the vertex coordinates. | |
| const std::vector< Vec3T< T > > & | getVertexCoordinates () const noexcept |
| Get the vertex coordinates. | |
| std::vector< std::vector< size_t > > & | getFacets () noexcept |
| Get the face indices. | |
| const std::vector< std::vector< size_t > > & | getFacets () const noexcept |
| Get the face indices. | |
| std::vector< T > & | getVertexProperties (const std::string a_property) |
| Get the vertex properties. | |
| const std::vector< T > & | getVertexProperties (const std::string a_property) const |
| Get the vertex properties. | |
| std::vector< T > & | getFaceProperties (const std::string a_property) |
| Get the face properties. | |
| const std::vector< T > & | getFaceProperties (const std::string a_property) const |
| Get the face properties (const overload). | |
| void | setVertexProperties (const std::string a_property, std::vector< T > a_data) |
| Set vertex properties. | |
| void | setFaceProperties (const std::string a_property, std::vector< T > a_data) |
| Set face properties. | |
| template<typename Meta > | |
| std::shared_ptr< EBGeometry::DCEL::MeshT< T, Meta > > | convertToDCEL () const noexcept |
| Turn the PLY mesh into a DCEL mesh. | |
Protected Attributes | |
| std::string | m_id |
| PLY object ID. | |
| std::vector< Vec3T< T > > | m_vertexCoordinates |
| Vertex coordinates. | |
| std::vector< std::vector< size_t > > | m_facets |
| Faces – each entry in the outer vector contains the indices defining one face. | |
| std::map< std::string, std::vector< T > > | m_vertexProperties |
| Vertex properties. | |
| std::map< std::string, std::vector< T > > | m_faceProperties |
| Face properties. | |
Class for storing Stanford PLY meshes.
| T | Floating-point precision for vertex coordinates and scalar properties. |
|
noexcept |
|
default |
Copy constructor.
| [in] | a_other | Other PLY object. |
|
defaultnoexcept |
Move constructor.
| [in,out] | a_other | Other PLY object. |
|
noexcept |
Turn the PLY mesh into a DCEL mesh.
This call does not populate any meta-data in the DCEL mesh structures. If you need to also populate the meta-data on vertices and faces, you should not use this function but supply your own constructor.
| Meta | Metadata type attached to DCEL vertices, edges, and faces. |
| std::vector< T > & EBGeometry::PLY< T >::getFaceProperties | ( | const std::string | a_property | ) |
Get the face properties.
| [in] | a_property | Which property to fetch |
| const std::vector< T > & EBGeometry::PLY< T >::getFaceProperties | ( | const std::string | a_property | ) | const |
Get the face properties (const overload).
| [in] | a_property | Which property to fetch. |
|
noexcept |
Get the face indices.
|
noexcept |
Get the face indices.
|
noexcept |
Get the identifier for this object.
|
noexcept |
Get the identifier for this object.
|
noexcept |
Get the vertex coordinates.
|
noexcept |
Get the vertex coordinates.
| std::vector< T > & EBGeometry::PLY< T >::getVertexProperties | ( | const std::string | a_property | ) |
Get the vertex properties.
| [in] | a_property | Which property to fetch |
| const std::vector< T > & EBGeometry::PLY< T >::getVertexProperties | ( | const std::string | a_property | ) | const |
Get the vertex properties.
| [in] | a_property | Which property to fetch |
|
default |
|
defaultnoexcept |
| void EBGeometry::PLY< T >::setFaceProperties | ( | const std::string | a_property, |
| std::vector< T > | a_data | ||
| ) |
Set face properties.
| [in] | a_property | Property name |
| [in] | a_data | Property data |
| void EBGeometry::PLY< T >::setVertexProperties | ( | const std::string | a_property, |
| std::vector< T > | a_data | ||
| ) |
Set vertex properties.
| [in] | a_property | Property name |
| [in] | a_data | Property data |