TrinityCore
G3D::MeshAlg::Vertex Class Reference

#include <MeshAlg.h>

Public Member Functions

Vertex ()

bool inEdge (int e) const

bool inFace (int f) const

Public Attributes

SmallArray< int, 6 > edgeIndex

SmallArray< int, 6 > faceIndex

Detailed Description

Adjacency information for a vertex. Does not contain the vertex position or normal, which are stored in the MeshAlg::Geometry object. Vertexs must be stored in an array parallel to (indexed in the same way as) MeshAlg::Geometry::vertexArray.

Constructor & Destructor Documentation

 G3D::MeshAlg::Vertex::Vertex ( )
inline
59 {}

Member Function Documentation

 bool G3D::MeshAlg::Vertex::inEdge ( int e ) const
inline

Returns true if e or ~e is in the edgeIndex list.

75  {
76  return edgeIndex.contains(~e) || edgeIndex.contains(e);
77  }
bool contains(const T &value) const
Definition: SmallArray.h:162
SmallArray< int, 6 > edgeIndex
Definition: MeshAlg.h:70

Here is the call graph for this function:

 bool G3D::MeshAlg::Vertex::inFace ( int f ) const
inline
85  {
86  debugAssert(f >= 0);
87  return faceIndex.contains(f);
88  }
bool contains(const T &value) const
Definition: SmallArray.h:162
SmallArray< int, 6 > faceIndex
Definition: MeshAlg.h:83
#define debugAssert(exp)
Definition: debugAssert.h:160

Here is the call graph for this function:

Member Data Documentation

 SmallArray G3D::MeshAlg::Vertex::edgeIndex

Array of edges adjacent to this vertex. Let e = edgeIndex[i]. edge[(e >= 0) ? e : ~e].vertexIndex[0] == this vertex index.

Edges may be listed multiple times if they are degenerate.

 SmallArray G3D::MeshAlg::Vertex::faceIndex

Array of faces containing this vertex. Faces may be listed multiple times if they are degenerate.

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