Use Polygon Map Format
The map background may consist of a set of polygons; these are defined by a table in the Data Pool that must contain at least these fields:
Field Name
Contents
Name
The name of the layer. For geography, this is typically the country. A string.
Layer
An integer identifying a group of related polygons. This is 1:1 with Name.
Face
An integer identifying a singled closed polygon with the Layer. A Layer may be composed of multiple Faces. This supports describing country geometries where a single closed polygon is not adequate.
X
X coordinate of a point in the polygon.
Y
Y coordinate of a point in the polygon.
Note that no Z coordinate may be supplied; the polygons are only drawn on the 0 Z coordinate plane.
This table is used to draw the background polygons. Each set of coordinates for the same Layer Face is drawn as a closed polygon. Since this is a Data Pool table, it may be colored by any of these fields or by additional fields in the table. The color for the first coordinate in each Layer Face is used to color all of the polygon Faces in that Layer: a layer has a single color. "Name" is otherwise unused currently.
A typical use is to give polygons for a map, such as a world map. In this case, "Name" would be country name, "Layer" would be an unique integer ID for each country, and "Face" would be a closed polygon for a portion of the geometry of a country. Countries with simple boundaries that can be described by a single closed polygon have a single Face (e.g., Australia); countries with more complex outline use multiples Faces (e.g., Japan). The first two rows of the table must contain the coordinate range of the map. For example, for a map of the earth the coordinate range is given as:
Name
Layer
Face
X
Y
BOUNDARY
1
0
-180
-90
BOUNDARY
1
0
180
90
Note that the polygon must be closed: the first and last points must be the same.
To color each country separately, color the table by "Name".
For polygon backgrounds, the fourth token may be the name of a numeric field in the polygon table that is used to set the heights of the background polygons. A copy (join) may be used to merge numeric data fields from another table into the polygon table.
Last updated