Json export of polygons (area)

joosty

Exporting polygon (area) data from SARTopo appears to have an extra level of indirection. Whereas a polyline (track) looks like:

"geometry": {
        "type": "LineString",
        "coordinates": [
          [
            -116.7741322517,
            33.264005184200002,
            0,
            1697641057
          ],
          [
            -116.7741322517,
            33.264005184200002,
            0,
            1697641059
          ],  <more coordinate data here> ]

 

a polygon (area) is exported with an extra, (unnecessary ?) level:

"geometry": {
        "type": "Polygon",
        "coordinates": [
          [
            [
              -116.7736065387726,
              33.263854678795347
            ],
            [
              -116.77332758903505,
              33.263406129926345
            ],

 

In other words, the geometry of a polyline is an array of array-coordinates, a polygon is an array of an array of an array-coordinates. That first array item in a polygon is always a single item. 

Its a bit cumbersome to process this in other software due to this extra array, am I not seeing something or can this be changed at some point?

 

0

Comments

0 comments

Please sign in to leave a comment.