Public Member Functions | Public Attributes | Private Attributes | Static Private Attributes | List of all members
Opcode::MeshInterface Class Reference

#include <Opcode.h>

Public Member Functions

udword CheckTopology () const
 
inline_ udword GetNbTriangles () const
 
inline_ udword GetNbVertices () const
 
inline_ void GetTriangle (VertexPointers &vp, udword index) const
 
inline_ const IndexedTriangleGetTris () const
 
inline_ const PointGetVerts () const
 
bool IsValid () const
 
 MeshInterface ()
 
bool RemapClient (udword nb_indices, const udword *permutation) const
 
inline_ void SetNbTriangles (udword nb)
 
inline_ void SetNbVertices (udword nb)
 
bool SetPointers (const IndexedTriangle *tris, const Point *verts)
 
 ~MeshInterface ()
 

Public Attributes

bool Single
 Use single or double precision vertices. More...
 

Private Attributes

udword mNbTris
 Number of triangles in the input model. More...
 
udword mNbVerts
 Number of vertices in the input model. More...
 
const IndexedTrianglemTris
 Array of indexed triangles. More...
 
const PointmVerts
 Array of vertices. More...
 

Static Private Attributes

static Point VertexCache [3]
 

Detailed Description

Definition at line 54 of file Opcode.h.

Constructor & Destructor Documentation

MeshInterface::MeshInterface ( )

Constructor.

Definition at line 130 of file OPC_MeshInterface.cpp.

MeshInterface::~MeshInterface ( )

Destructor.

Definition at line 154 of file OPC_MeshInterface.cpp.

Member Function Documentation

udword MeshInterface::CheckTopology ( ) const

Checks the mesh itself is valid. Currently we only look for degenerate faces.

Returns
number of degenerate faces

Definition at line 182 of file OPC_MeshInterface.cpp.

inline_ udword Opcode::MeshInterface::GetNbTriangles ( ) const
inline

Definition at line 61 of file Opcode.h.

inline_ udword Opcode::MeshInterface::GetNbVertices ( ) const
inline

Definition at line 62 of file Opcode.h.

inline_ void Opcode::MeshInterface::GetTriangle ( VertexPointers vp,
udword  index 
) const
inline

Fetches a triangle given a triangle index.

Parameters
vp[out] required triangle's vertex pointers
index[in] triangle index

Definition at line 119 of file Opcode.h.

inline_ const IndexedTriangle* Opcode::MeshInterface::GetTris ( ) const
inline

Definition at line 92 of file Opcode.h.

inline_ const Point* Opcode::MeshInterface::GetVerts ( ) const
inline

Definition at line 93 of file Opcode.h.

bool MeshInterface::IsValid ( ) const

Checks the mesh interface is valid, i.e. things have been setup correctly.

Returns
true if valid

Definition at line 164 of file OPC_MeshInterface.cpp.

bool MeshInterface::RemapClient ( udword  nb_indices,
const udword permutation 
) const

Remaps client's mesh according to a permutation.

Parameters
nb_indices[in] number of indices in the permutation (will be checked against number of triangles)
permutation[in] list of triangle indices
Returns
true if success

Definition at line 269 of file OPC_MeshInterface.cpp.

inline_ void Opcode::MeshInterface::SetNbTriangles ( udword  nb)
inline

Definition at line 63 of file Opcode.h.

inline_ void Opcode::MeshInterface::SetNbVertices ( udword  nb)
inline

Definition at line 64 of file Opcode.h.

bool MeshInterface::SetPointers ( const IndexedTriangle tris,
const Point verts 
)

Pointers control: setups object pointers. Must provide access to faces and vertices for a given object.

Parameters
tris[in] pointer to triangles
verts[in] pointer to vertices
Returns
true if success

Definition at line 232 of file OPC_MeshInterface.cpp.

Member Data Documentation

udword Opcode::MeshInterface::mNbTris
private

Number of triangles in the input model.

Definition at line 179 of file Opcode.h.

udword Opcode::MeshInterface::mNbVerts
private

Number of vertices in the input model.

Definition at line 180 of file Opcode.h.

const IndexedTriangle* Opcode::MeshInterface::mTris
private

Array of indexed triangles.

Definition at line 187 of file Opcode.h.

const Point* Opcode::MeshInterface::mVerts
private

Array of vertices.

Definition at line 188 of file Opcode.h.

bool Opcode::MeshInterface::Single

Use single or double precision vertices.

Definition at line 194 of file Opcode.h.

Point MeshInterface::VertexCache
staticprivate

Definition at line 196 of file Opcode.h.


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


openhrp3
Author(s): AIST, General Robotix Inc., Nakamura Lab of Dept. of Mechano Informatics at University of Tokyo
autogenerated on Sat May 8 2021 02:42:45