next up previous contents index
Next: Related file (external) types Up: Polygon, a variant of Previous: Polygon, a variant of   Contents   Index

The structure Polygon

The first two fields of the structure register the global properties, assumed to be represented as an array of channels; each channel is a real number. The meaning of each channel has to be defined by the user; the number of channels can be selected using the function mw_alloc_polygon or mw_change_polygon (see below).

The next fields of the structure are similar to those in the Curvememory type.

typedef struct polygon {
  int nb_channels;  /* Number of channels */
  float *channel;  /* Tab to the channel */
                   /* The number of elements is given by nb_channels */
  Point_curve first; /* Pointer to the first point of the curve */

  /* For use in Polygons only */
  struct polygon *previous; /* Pointer to the previous poly. (may be NULL) */
  struct polygon *next; /* Pointer to the next poly. (may be NULL) */
} *Polygon;

mw 2004-05-05