development
Polygon Geometry
A GeoJSON shape defined by a ring of coordinate points that encloses a geographic area, used to define routing coverage boundaries.
Polygon geometry is a GeoJSON geometry type that represents a closed shape on a map by connecting a series of coordinate points. In Apple Maps routing integration, polygons define the exact geographic boundaries where your app can provide directions. Each polygon consists of at least one linear ring - an ordered array of longitude-latitude pairs where the first and last point match, closing the shape.
Structure of a GeoJSON Polygon
A polygon’s outer boundary is called the exterior ring. You can also include interior rings that act as holes, carving out areas where your service does not operate. Coordinates use the WGS 84 reference system and are written as [longitude, latitude] pairs. A simple rectangular coverage area needs five coordinate points: four corners plus a repeat of the first point to close the ring.
Using Polygons in Routing Coverage Files
When building your routing app coverage file, place polygon geometry inside GeoJSON Feature objects. For apps that serve multiple disconnected regions, use a MultiPolygon geometry type that groups several polygons into a single feature. Keep polygons simple to reduce file size and processing time. Avoid unnecessary detail in coastlines or borders unless your service boundary follows those contours precisely.