DD::Image::PolyMesh Class Reference

PolyMesh is a connected series of polygons comprising a contiguous surface. More...

Inherits DD::Image::PolygonPrimitive.

List of all members.

Public Member Functions

 PolyMesh (unsigned icount, unsigned fcount)
const char * Class () const
Primitiveduplicate () const
PrimitiveType getPrimitiveType () const
int add_face (unsigned nVerts, const int *vertIndices, bool reverse=false)
unsigned faces () const
Vector3 face_average_center (int n, const PointList *) const
unsigned face_vertices (int n) const
void get_face_vertices (int n, unsigned *array) const
Vector3 get_face_normal (int n, const PointList *points) const
void validate (PrimitiveContext *)
void draw_wireframe (ViewerContext *, PrimitiveContext *, Primitive *prev_prim=0) const
void draw_solid (ViewerContext *, PrimitiveContext *, Primitive *prev_prim=0) const
void draw_primitive_normal (ViewerContext *, PrimitiveContext *) const
void draw_primitive_num (ViewerContext *, PrimitiveContext *) const
void draw_vertex_num (ViewerContext *, PrimitiveContext *) const
void draw_solid_face (int n, ViewerContext *ctx, PrimitiveContext *ptx) const
void print_info () const
bool IntersectsRay (const Ray &ray, int n, const PointList *pointList, CollisionResult *result) const

Detailed Description

PolyMesh is a connected series of polygons comprising a contiguous surface.


Member Function Documentation

int PolyMesh::add_face ( unsigned  nVerts,
const int *  vertIndices,
bool  reverse = false 
)

Add a face to the mesh, return the face index of the new face or -1 if failure.

References DD::Image::Primitive::vertex_.