| 181 |
|
/* Add a new face to our scene, using current group and material */ |
| 182 |
|
extern Face * addFace(Scene *sc, VNDX vid[], int nv); |
| 183 |
|
|
| 184 |
+ |
/* Get neighbor vertices: malloc array with valence in index[0] */ |
| 185 |
+ |
extern int * getVertexNeighbors(Scene *sc, int vid); |
| 186 |
+ |
|
| 187 |
|
/* Expand bounding box min & max (initialize bbox to all zeroes) */ |
| 188 |
|
extern int growBoundingBox(Scene *sc, double bbox[2][3], |
| 189 |
|
int flreq, int flexc); |
| 211 |
|
#define getGroupID(sc,nm) findName(nm, (const char **)(sc)->grpname, (sc)->ngrps) |
| 212 |
|
#define getMaterialID(sc,nm) findName(nm, (const char **)(sc)->matname, (sc)->nmats) |
| 213 |
|
|
| 214 |
< |
#define CHUNKSIZ 128 /* object allocation chunk size */ |
| 214 |
> |
#define CHUNKBITS 7 /* object allocation chunk bits */ |
| 215 |
> |
#define CHUNKSIZ (1<<CHUNKBITS) /* object allocation chunk size */ |
| 216 |
|
|
| 217 |
|
#define chunk_alloc(typ, arr, nold) \ |
| 218 |
< |
((nold)%CHUNKSIZ ? (arr) : \ |
| 218 |
> |
((nold)&(CHUNKSIZ-1) ? (arr) : \ |
| 219 |
|
(typ *)erealloc((char *)(arr), sizeof(typ)*((nold)+CHUNKSIZ))) |
| 220 |
|
|
| 221 |
|
#ifdef __cplusplus |