COGS
Computer Graphics Structures library
cogs::Mesh Struct Reference

A Mesh is structure containing a point-cloud a triangulation and a material. Not all of these are required. More...

Public Member Functions

bool HasPoints () const
 Returns true when mesh has points assigned - non nullptr.
 
bool HasFaces () const
 Returns true when mesh has faces assigned - non nullptr.
 
bool HasMaterial () const
 Returns true when mesh has material assigned - non nullptr.
 
virtual bool Import (const std::string &filename)
 Import from a file. Return success.
 
virtual bool Export (const std::string &filename) const
 Import to a file. Create a directory hierarchy if necessary. Return success.
 

Data Fields

std::shared_ptr< PointCloud > points
 
std::shared_ptr< Triangulation > faces
 
std::shared_ptr< MaterialModel > material
 

Detailed Description

A Mesh is structure containing a point-cloud a triangulation and a material. Not all of these are required.

Note
Each of the point-cloud, faces or material may be undefined.