logo separator

[mkgmap-dev] Weird road speed

From Steve Ratcliffe steve at parabola.me.uk on Sun Jan 19 21:38:12 GMT 2014

On 19/01/14 20:06, WanMil wrote:
> @Gerd: StyledConverter.postConvertRules can change the road speed in the
> type. But this hasn't been copied before so I guess it's changing the
> global type of the rule. Can you check that?
> I added
>      type = new GType(type);
> at line 202 but this didn't change the overall result. So it seems not
> to be the only problem.
>

The way I see it is that the GType is simply a representation
of the type declaration in a rule. It is static and should
not be modified or copied per way.

The Converter converts Way -> MapRoad

The rules produce a Gtype and a set of variables, V (that we happen
to implement by adding mkgmap:* tags to the way).

You use the GType and V to initialise the MapRoad.

So to override the road_speed should be done in addRoadWithoutLoops()
where it is currently initialised directly from the GType.

..Steve


More information about the mkgmap-dev mailing list