#include <bn.h>
Data Fields | |
struct bu_list | l |
magic, forw, back | |
size_t | nused |
elements 0..nused active | |
int | cmd [BN_VLIST_CHUNK] |
VL_CMD_*. | |
point_t | pt [BN_VLIST_CHUNK] |
associated 3-point/vect |
B N _ V L I S T
Definitions for handling lists of vectors (really verticies, or points) and polygons in 3-space. Intented for common handling of wireframe display information, in the full resolution that is calculated in.
On 32-bit machines, BN_VLIST_CHUNK of 35 results in bn_vlist structures just less than 1k bytes.
The head of the doubly linked list can be just a "struct bu_list" head.
To visit all the elements in the vlist: for (BU_LIST_FOR(vp, bn_vlist, hp)) { register int i; register int nused = vp->nused; register int *cmd = vp->cmd; register point_t *pt = vp->pt; for (i = 0; i < nused; i++, cmd++, pt++) { access(*cmd, *pt); access(vp->cmd[i], vp->pt[i]); } }
Definition at line 1701 of file bn.h.