NAME
DtGroupGetVertices - Get a list of vertices for the given
group.
SYNOPSIS
#include <Dt.h>
int DtGroupGetVertices( int shapeID, int groupID, int *count, DtVec3f **vertices )
DESCRIPTION
DtGroupGetVertices() returns a vertex list for the group
indicated by the given shapeID and groupID. The number of
vertices is returned in count. A pointer to a list of the
vertices is placed in the variable pointed to by vertices.
The array returned by DtGroupGetVertices() is not an
internal array, and must be freed by the calling function.
It may be modified, but will not change data stored in the
model. C programmers can access the components of the
vertex array as though it were a simple structure as
follows:
typedef struct DtVec3f { float vec[3];};
DtVec3f *verts;
DtGroupGetVertices( groupID, DtVec3f &verts );
/* The first vertex */
x = verts[0].vec[0];
y = verts[0].vec[1];
z = verts[0].vec[2];
DIAGNOSTICS
DtGroupGetVertices() returns one on success and zero on
failure.
FILES
Link with -lDtOMio