On 01.03.2011 20:09, Felix Hartmann wrote:
merge-lines is as discussed quite problematic, because it happens
after the routing notes are placed, and therefore causes some
problems. The closer you zoom in, the bigger these problems, while the
further you zoom out, the bigger the speed improvement of using this
option (at resolution 24 and 23 it makes basically no difference) and
the smaller the problems (22 vs 24 means 1/4 of the wrong distance for
info popup or jumping map when panning).
There was a discussion about this - archive here:
http://www.mail-archive.com/[email protected]/msg07262.html
This patch is working pretty well and makes --merge-lines usable. I
have been using it since back then without any probs. So for as long
as merge-lines cannot be implemented before creation of the routing
nodes (which according to the discussion is really difficult) this
tiny patch is great.
Sorry, above patch misses one line, here we go again (this happened as I
had several patches against the file and recreated it by hand).
Index: uk/me/parabola/mkgmap/build/MapBuilder.java
===================================================================
--- uk/me/parabola/mkgmap/build/MapBuilder.java (revision 1871)
+++ uk/me/parabola/mkgmap/build/MapBuilder.java (working copy)
@@ -876,13 +876,13 @@
//TODO: Maybe this is the wrong place to do merging.
// Maybe more efficient if merging before creating subdivisions.
- if (mergeLines && res < 24) {
+ if (mergeLines && res < 22) {
LineMergeFilter merger = new LineMergeFilter();
lines = merger.merge(lines);
}
LayerFilterChain filters = new LayerFilterChain(config);
- if (enableLineCleanFilters && (res < 24)) {
+ if (enableLineCleanFilters && (res < 22)) {
filters.addFilter(new PreserveHorizontalAndVerticalLinesFilter());
filters.addFilter(new RoundCoordsFilter());
filters.addFilter(new SizeFilter());
@@ -921,7 +921,7 @@
FilterConfig config = new FilterConfig();
config.setResolution(res);
LayerFilterChain filters = new LayerFilterChain(config);
- if (enableLineCleanFilters && (res < 24)) {
+ if (enableLineCleanFilters && (res < 22)) {
filters.addFilter(new PreserveHorizontalAndVerticalLinesFilter());
filters.addFilter(new RoundCoordsFilter());
filters.addFilter(new SizeFilter());
_______________________________________________
mkgmap-dev mailing list
[email protected]
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev