Monday, 5 September 2016

algorithm - Fix Self Intersecting Polygons Manually



I are looking to implement a method to fix self-intersecting polygons by editing the vertex order. We want to take the polygon rings and re-arrange/add in vertices to make a valid polygon. This is similar to how ArcMap's Repair Geometry runs. I have used other methods such as PostGIS's ST_MakeValue, but we didn't like the results because it added extra area to the polygon. It is because of this, that I am looking to implement my own strategy.


I am looking to take the WKT of the feature shape and manually edit the coordinates. Doing something like a buffer operation, split and union, or anything else won't really work. What we want to do is be able to detect and add vertices to self-intersections similar to ArcMap's tool.



If I can get an explanation on some popular tools used to correct self-intersecting polygons and perhaps a code sample/algorithm sample, it would help me greatly.




No comments:

Post a Comment

arcpy - Changing output name when exporting data driven pages to JPG?

Is there a way to save the output JPG, changing the output file name to the page name, instead of page number? I mean changing the script fo...