[Geojson] polygon point order

Keith Jenkins kgj2 at cornell.edu
Mon Oct 15 06:37:14 PDT 2007


I agree that GeoJSON should be able to carry even self-intersecting
polygons, etc.  We may want to send such a polygon to a server so that
it can get "fixed" there.

I'm more concerned about the ambiguity of polygons and lines that
cross 180E.  If different clients/servers have a different idea of
which way a line goes, then we are going to have problems.  (How can
you create a buffer, etc. if you aren't sure where the feature is?)

Of course, all of this won't be an issue for 99% of polygons, but we
should try not to leave eastern Siberia out in the cold.

Two possibilities mentioned so far:

A. "Law of the minimum" =
> always take the smaller interpretation (the one < 180 degrees wide).  In
> exchange for that maximum size interpretation, you can ignore ordering,
> and the rule works for any line, not just closed polygons, the way
> clockwise/anti-clockwise does.

B. "Clockwise, west-to-east"

Simplicity seems to favor A.  Are there any cases where A would fail?
(If a user really wants a 181-degree line, then maybe the client could
insert a vertex mid-way.)

Keith

p.s. I hadn't realized that Google Earth doesn't allow user-created
polygons to wrap across 180E.  Try digitizing Antarctica!  Somehow the
built-in boundaries work, though.



More information about the GeoJSON mailing list