AGXDynamics  2.31.1.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
agxCollide::TriangleVoronoiRegion Class Reference

Class containing the Voronoi region of a triangle as an uint8_t. More...

#include <TriangleVoronoiRegion.h>

Public Types

enum  Type { VERTEX = 0, EDGE, FACE }
 The type of Voronoi region. More...
 

Public Member Functions

 TriangleVoronoiRegion (uint8_t voronoiIndex)
 
Type getType () const
 
uint8_t getVoronoiIndex () const
 

Static Public Member Functions

static Type calculateType (unsigned index)
 

Static Public Attributes

static const uint8_t edgeFlaggedToStandard [8]
 
static const uint8_t edgeFlags [4]
 One way to create Voronoi regions is to set a flag for each edge that the point is in contact with. More...
 

Detailed Description

Class containing the Voronoi region of a triangle as an uint8_t.

0-2 stand for vertices, 3-5 for edges, and 6 for face. The edges are numerated in the same way as the vertices they start from.

Definition at line 31 of file TriangleVoronoiRegion.h.

Member Enumeration Documentation

The type of Voronoi region.

Enumerator
VERTEX 
EDGE 
FACE 

Definition at line 34 of file TriangleVoronoiRegion.h.

Constructor & Destructor Documentation

agxCollide::TriangleVoronoiRegion::TriangleVoronoiRegion ( uint8_t  voronoiIndex)
inline
Parameters
voronoiIndexAn uint8_t indicating the Triangle's Voronoi Region. 0-2 vertices, 3-5 edges, 6 face.

Definition at line 80 of file TriangleVoronoiRegion.h.

References agxAssert.

Member Function Documentation

TriangleVoronoiRegion::Type agxCollide::TriangleVoronoiRegion::calculateType ( unsigned  index)
inlinestatic

Definition at line 85 of file TriangleVoronoiRegion.h.

Referenced by getType().

TriangleVoronoiRegion::Type agxCollide::TriangleVoronoiRegion::getType ( ) const
inline
Returns
The type of the Voronoi region

Definition at line 90 of file TriangleVoronoiRegion.h.

References calculateType().

uint8_t agxCollide::TriangleVoronoiRegion::getVoronoiIndex ( ) const
inline
Returns
The Voronoi index of the Voronoi region. 0-2 stand for vertices, 3-5 for edges, and 6 for face.

Definition at line 96 of file TriangleVoronoiRegion.h.

Member Data Documentation

const uint8_t agxCollide::TriangleVoronoiRegion::edgeFlaggedToStandard[8]
static

Definition at line 69 of file TriangleVoronoiRegion.h.

const uint8_t agxCollide::TriangleVoronoiRegion::edgeFlags[4]
static

One way to create Voronoi regions is to set a flag for each edge that the point is in contact with.

Maximum 2 flags can be set in a non-degenerate triangle. This gives the ordering Face: 0 Edges: 1, 2 or 4 Vertices: 3, 6 or 5. These two static variables can be used in order to set the edge flags and convert from an edged-flagged to the general indexing version.

Definition at line 68 of file TriangleVoronoiRegion.h.


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