#include <cx/Geometry.h>enum cxGeoBindingLevel { CX_GEO_PER_DEFAULT, CX_GEO_PER_OBJECT, CX_GEO_PER_PART, CX_GEO_PER_FACE, CX_GEO_PER_FACE_INDEXED, CX_GEO_PER_VERTEX, CX_GEO_PER_VERTEX_INDEXED };
void cxGeoNormalAdd( int n, float *normal, cxGeoBindingLevel per )
integer CX_GEO_PER_DEFAULT integer CX_GEO_PER_OBJECT integer CX_GEO_PER_PART integer CX_GEO_PER_FACE integer CX_GEO_PER_FACE_INDEXED integer CX_GEO_PER_VERTEX integer CX_GEO_PER_VERTEX_INDEXEDparameter (CX_GEO_PER_DEFAULT = 0) parameter (CX_GEO_PER_OBJECT = 1) parameter (CX_GEO_PER_PART = 2) parameter (CX_GEO_PER_FACE = 3) parameter (CX_GEO_PER_FACE_INDEXED = 4) parameter (CX_GEO_PER_VERTEX = 5) parameter (CX_GEO_PER_VERTEX_INDEXED = 6)
subroutine cxGeoNormalAdd(n,normal,per) integer n real normal(3, n) integer per
Colors may be applied in different ways, depending on the setting of the per flag:
The normals are expected to have been normalized to unit length.
Polygons specified by cxGeoPolysDefine must have their vertices supplied in a counter-clockwise fashion so that the implicit frontfacing/backfacing normal for the polygon is computed correctly according to the "right-hand rule". You cannot use cxGeoNormalAdd to override this frontfacing/backfacing normal computation for purposes of rendering.