NAME
DtShapeGetNormals - Get a list of normals for the given
shape.
SYNOPSIS
#include <Dt.h>
int DtShapeGetNormals( int shapeID, int *count, DtVec3f **normals )
DESCRIPTION
DtShapeGetNormals() returns a normal list for the shape
indicated by the given shapeID. The number of normals is
returned in count. A read-only pointer to a list of the
normals is placed in the variable pointed to by normals.
This array is an internal buffer. Do not free or modify the
normal array. C programmers can access the components of
the normal array as though it were a simple structure as
follows:
typedef struct DtVec3f { float vec[3];};
DtVec3f *norms;
DtShapeGetNormals( shapeID, DtVec3f &norms );
/* The first normal */
x = norms[0].vec[0];
y = norms[0].vec[1];
z = norms[0].vec[2];
DIAGNOSTICS
DtShapeGetNormals() returns one on success and zero on
failure.
FILES
Link with -lDtOMio