logo separator

[mkgmap-dev] Line direction flag, merging etc

From Gerd Petermann gpetermann_muenchen at hotmail.com on Mon May 17 16:38:17 BST 2021

Hi Ticker,

not sure what you want to achive?
I agree that the evaluation of the --line-types-with-direction option should not depend on the --allow-reverse-merge option.

Seems like an alternative to the solution in r4719 : https://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4719
but without the correction for the unit test.
Reg. overlays:
Yes, first element just gets a different type, the others are forced to be MapLine. First element might also be a non-routable line.
The OpenFietsmap Styles use them, see https://github.com/ligfietser/mkgmap-style-sheets

Do you see a need for the possibility to have oneway roads which don't have the direction flag set?
In trunk it will not matter reg. merging, in the branch it might allow more merging in the overview map.

Gerd

________________________________________
Von: mkgmap-dev <mkgmap-dev-bounces at lists.mkgmap.org.uk> im Auftrag von Ticker Berkin <rwb-mkgmap at jagit.co.uk>
Gesendet: Montag, 17. Mai 2021 17:06
An: Development list for mkgmap
Betreff: Re: [mkgmap-dev] Line direction flag, merging etc

Hi Gerd

I've rearranged the direction flag setting logic a bit, taking bits
from ignore-oneway-for-line.patch

It ignores oneway except for roads and allows direction to be set false
even for routable oneways. I've tested routing when oneway=true,
hasDirection=false on eTrex HCx and gpsMapEdit and it respected the
oneway.

I couldn't find any references to the {style}/overlays file in any
documentation, but my reading of the code is that first substitution
element will get the full MapRoad info, including the hasDirection flag
and the MapLine copies will get also get the hasDirection flag.

Ticker

On Mon, 2021-05-17 at 11:29 +0100, Ticker Berkin wrote:
> Hi Gerd and others
>
> I'm starting a dedicated thread as previous posts are split between
> various svn commits.
>
> Looking at the current trunk code and ignore-oneway-for-lines.patch,
> there are bits I don't understand or didn't expect.
>
> This is what I hope for:
>
> --line-types-with-direction lists the lineTypes for which the initial
> state of the hasDirection flag is considered true. It should be
> independent of --allow-reverse-merge (see later). The purpose of this
> is to reduce the need to edit styles and clarity as to which
> lineTypes
> are displayed with direction.
>
> In the following, road means line with [road_class, road_speed], so
> includes ferries.
>
> Style processing, having produced a line/road, sets hasDirection, in
> order of precedence:
> 1/ value of mkgmap:has-direction if tag exists
> 2/ true if oneway road
> 3/ true if in line-types-with-direction list
>
> RoadMerger merges roads with same lineType, names, class, speed,
> oneway
> and hasDirection. It must not reverse oneway or hasDirection=true
> roads
> when doing this.
>
> I don't think we need --allow-reverse-merge.
>
> LineMergeFilter operates for level > 0. It merges any line/road with
> the same lineType, names, hasDirection. It must not reverse
> hasDirection=true.
>
> Ticker
>
> _______________________________________________
> mkgmap-dev mailing list
> mkgmap-dev at lists.mkgmap.org.uk
> https://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev


More information about the mkgmap-dev mailing list