NAME
DtShapeGetVertices - Get a list of vertices for the given
shape.
SYNOPSIS
#include <Dt.h>
int DtShapeGetVertices( int shapeID, int *count, DtVec3f **vertices )
DESCRIPTION
DtShapeGetVertices() returns a vertex list for the shape
indicated by the given shapeID. The number of vertices is
returned in count. A read-only pointer to a list of the
vertices is placed in the variable pointed to by vertices.
This array is an internal buffer. Do not free or modify the
vertex array. 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;
DtShapeGetVertices( shapeID, DtVec3f &verts );
/* The first vertex */
x = verts[0].vec[0];
y = verts[0].vec[1];
z = verts[0].vec[2];
DIAGNOSTICS
DtShapeGetVertices() returns one on success and zero on
failure.
FILES
Link with -lDtOMio