logo separator

[mkgmap-dev] There is not enough room in a single garmin map for all the input data

From WanMil wmgcnfg at web.de on Sun Dec 30 17:09:09 GMT 2012

> GerdP wrote
>> Another strange observation: Although my input file doesn't contain a
>> single way with highway=*
>> I see many coord objects with a highwayCount > 1, which in turn means
>> these coords are preserved by
>> the removeShortArcsByMergingNodes() method. I assume this is explained by
>> the fact that the
>> precompiled sea polygons contain the edges of the grid, so many points
>> share the same coords although
>> they are not on a highway. In short: the name highwayCount is missleading.
>
> No, it's worse: The sea generator adds one sea polygon and one land polygon,
> both share
> all (!) points that are one the coast line. All these points are later
> preserved in the
> removeShortArcsByMergingNodes() method. So, the coast line is saved very
> detailed for
> each resolution.
> I am pretty sure this is not intended ?
>
> Gerd

The sea generator of course adds the sea area with multiple polygons and 
also adds the land area with multiple polygons. They are used only if 
you have an according rule in the style. I don't see a chance to change 
anything here.

The question is why the highwayCount is > 1.
I have searched where the highwayCount is increased.
Some places are quite understandable but two are conspicuous:

Osm5XmlHandler.startInNode checks for a tag mkgmap:on-boundary. If that 
is set the highwayCount is increased. So far so good but this is not 
performed in the PBF and o5m handler. So maybe this can be removed or 
must be added to the other handlers too.

The base class OsmHandler has a method addCoordToWay(..). In this method 
the highwayCount is increased always - no matter if it is a way or not. 
This was introduced by merging the way-closing branch.
So Steve should have a look on it. I think that's not intended.

WanMil



More information about the mkgmap-dev mailing list