[PATCH v3] - merge nodes to remove evil short arcs

v3 now requires the --remove-short-arcs option to enable this feature now deletes consecutive identical points ---------- v2 now reports OSM ids of merged/replaced nodes (at the cost of using more memory while the XML is being converted). only does this stuff if route option enabled. ---------- The attached patch is a first stab at a solution for this problem. Please test. It is implemented in an iterative fashion and it should terminate after a few passes. If 10 passes are executed it will give up, please report if you see it doing that. It would be nice if the diagnostics reported the OSM id of the nodes rather than their coordinates but I haven't worked out the best way of achieving that yet. Cheers, Mark

Mark Burton wrote:
v3
now requires the --remove-short-arcs option to enable this feature
The attached patch is a first stab at a solution for this problem.
Please test.
I am trying to apply this patch to r1044 and I get the following error patch -p1 < mb-short-arc-fix-v3.patch patching file resources/help/en/options Hunk #1 succeeded at 129 (offset 3 lines). patching file src/uk/me/parabola/mkgmap/reader/osm/xml/Osm5XmlHandler.java Hunk #3 FAILED at 86. Hunk #4 succeeded at 402 (offset 32 lines). Hunk #5 succeeded at 436 (offset 32 lines). Hunk #6 succeeded at 630 (offset 32 lines). 1 out of 6 hunks FAILED -- saving rejects to file src/uk/me/parabola/mkgmap/reader/osm/xml/Osm5XmlHandler.java.rej Any suggestions? The .rej file is not created so I can't post details Thanks Paul
participants (2)
-
Mark Burton
-
Paul