We specify a polygon surface with a set of vertex coordinates
and associated attribute parameters
Objects : set of vertices and associated attributes
Geometry : stored as three tables : vertex table, edge table, polygon
table
Edge table ?
Tables also allow to store additional information
We specify objects as a set of vertices and associated attributes.
This information can be stored in tables, of which there are two types: geometric
tables and attribute tables.
The geometry can be stored as three tables: a vertex table, an edge table,
and a polygon table. Each entry in the vertex table is a list of coordinates
defining that point. Each entry in the edge table consists of a pointer to
each endpoint of that edge. And the entries in the polygon table define a
polygon by providing pointers to the edges that make up the polygon.
We can eliminate the edge table by letting the polygon table reference the
vertices directly, but we can run into problems, such as drawing some edges
twice, because we don't realize that we have visited the same set of points
before, in a different polygon. We could go even further and eliminate the
vertex table by listing all the coordinates explicitly in the polygon table,
but this wastes space because the same points appear in the polygon table
several times.
Using all three tables also allows for certain kinds of error checking.
We can confirm that each polygon is closed, that each point in the vertex
table is used in the edge table and that each edge is used in the polygon
table.
Tables also allow us to store additional information. Each entry in the
edge table could have a pointer back to the polygons that make use of it.
This would allow for quick look-up of those edges which are shared between
polygons. We could also store the slope of each edge or the bounding box for
each polygon--values which are repeatedly used in rendering and so would be
handy to have stored with the data.