Public Member Functions | Private Member Functions | List of all members
MeshParser Class Reference

#include <mesh_parser.hpp>

Inheritance diagram for MeshParser:
Inheritance graph
[legend]

Public Member Functions

 MeshParser (const std::string &file_path)
 
int8_t read (std::vector< TriangleSupport > &tri_vec)
 
virtual ~MeshParser ()
 
- Public Member Functions inherited from ParserBase
template<typename T >
int8_t createBVH (fcl::BVHModel< T > &bvh)
 
template<typename T >
int8_t createBVH (std::shared_ptr< fcl::BVHModel< T > > ptr_bvh)
 
const std::string getFilePath () const
 
 ParserBase (const std::string &file_path)
 
virtual ~ParserBase ()
 

Private Member Functions

int8_t toVec3f (uint32_t num_current_face, aiVector3D *vertex, fcl::Vec3f &out)
 

Additional Inherited Members

- Protected Attributes inherited from ParserBase
std::string file_path_
 

Detailed Description

Definition at line 27 of file mesh_parser.hpp.

Constructor & Destructor Documentation

MeshParser::MeshParser ( const std::string &  file_path)
inline

Definition at line 33 of file mesh_parser.hpp.

virtual MeshParser::~MeshParser ( )
inlinevirtual

Definition at line 39 of file mesh_parser.hpp.

Member Function Documentation

int8_t MeshParser::read ( std::vector< TriangleSupport > &  tri_vec)
virtual

Read from a mesh file by using assimp Importer. Iterates through the faces and tries to convert the corresponding vertices into a triangle vector.

Parameters
tri_vecReference to a triangle vector storing the mesh data.
Returns
Success status (0 means ok).

Implements ParserBase.

Definition at line 36 of file mesh_parser.cpp.

int8_t MeshParser::toVec3f ( uint32_t  num_current_face,
aiVector3D *  vertex,
fcl::Vec3f &  out 
)
private

Uses the current vertex (assimp 3d vector) and converts into fcl::Vec3f.

Parameters
num_current_faceThe number of the current face for error logging.
vertexPointer to the current vertex.
outThe fcl vector description.
Returns
Success status (0 means ok).

Definition at line 104 of file mesh_parser.cpp.


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


cob_obstacle_distance
Author(s): Marco Bezzon
autogenerated on Thu Apr 8 2021 02:39:47