mapbox/vector-tile-spec

Describe Polygon Handling?

Closed this issue · 3 comments

Describing the implications of polygon handling in a tile setup would be useful, I think. Presumably users will want to transport polygons twice, once as a closed path, for filling, and once as an unclosed path for rendering the boundary.

I share the same concern, how do a polygon span accross multiple tiles? 👍

@pramsey I am not sure I fully understand that question. We are currently using one instance of a feature to render both a filled polygon as well as the perimeter as a separate line. The consuming implementation can derive appropriate geometries that it needs for the type of renderer it is using.

As for closed paths, the geometry format defines the ClosePath operation. Your implementation can either use this and pass it on to the rendering system (e.g. when using HTML5 canvas, you just call .closePath()), or manually track the initial starting position of this feature and create a new line segment to the beginning.

@fredmorin Your question is being tracked in #8.