← Back to team overview

dhis2-users team mailing list archive

Re: High-Definition Polygons

 

On Sun, Nov 7, 2010 at 9:36 PM, Friedman, Roger (CDC/CGH/DGHA) (CTR)
<rdf4@xxxxxxx> wrote:
> I have followed the steps for converting an ESRI shapefile to the JSON
> format as stored in the org unit table.  I am having a difficulty because
> the boundaries have too many points to fit into the field.  Is there a piece
> of software out there to replace two segments AB-BC with AC in order of area
> of ABC or length of AC?  Or do we have to change the field type to
> accommodate the larger length (and is the performance degradation
> acceptable)?

There are several ways to achieve simplification (aka generalization)
of shape files.

I recommend using Mapshaper, which allows you to try out different
degrees of simplification. Usually up to 80-90% will work nicely.
http://mapshaper.com/test/demo.html

Once you are happy, download the new .shp and .shx files, and then
make a copy of the original dbf file and name it the same as the
simlified shp file. Then use ogr2ogr to convert to GML, do the
renaming (ogr:Name) and import.

Knut



Follow ups

References