[mkgmap-dev] Line direction flag, merging etc
From Gerd Petermann gpetermann_muenchen at hotmail.com on Tue May 18 13:49:48 BST 2021
Hi Ticker, this would be my intended patch for trunk, it makes StyledConverter in branch and trunk identical. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces at lists.mkgmap.org.uk> im Auftrag von Gerd Petermann <gpetermann_muenchen at hotmail.com> Gesendet: Dienstag, 18. Mai 2021 14:35 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] Line direction flag, merging etc Hi Ticker, in the branch I found a solution which doesn't set the direction flag for overlay lines when the OSM way is a oneway and a road with overlay type is created. With your patch still ALL lines created from the overlay type have the direction flag set in that case. Tested this with the unchanged OFM style without any new options. Do you see something wrong in the current branch version r4723? I think it's clearer. Gerd ________________________________________ Von: mkgmap-dev <mkgmap-dev-bounces at lists.mkgmap.org.uk> im Auftrag von Ticker Berkin <rwb-mkgmap at jagit.co.uk> Gesendet: Dienstag, 18. Mai 2021 13:00 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] Line direction flag, merging etc Hi Gerd ISTR there are 2 oneway flags in NET/NOD, along with the other access flags! I recommends patching trunk - it fixes --lines-types-with-direction and should clarify possible problems/solutions for Felix. Ticker On Tue, 2021-05-18 at 08:56 +0000, Gerd Petermann wrote: > Hi Ticker, > > I just noticed that NET also contains a oneway flag, so I think it > should be OK to have the direction flag in RGN be independant from > oneway in NET /NOD. > > Not sure if I use your patch for trunk or merge it into the low-res > -opt branch. I think only the branch cares about it because the > LineMerger in trunk doesn't reverse-merge. > > 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 19:37 > An: Development list for mkgmap > Betreff: Re: [mkgmap-dev] Line direction flag, merging etc > > Hi Gerd > > The ambition was to be able to turn off hasDirection if [oneway=yes/ > -1] > (roads only) and/or --lines-types-with-direction would have it on. > > As I'd never noticed the compass direction on oneway roads, I thought > I > might as well turn it off. It also allowed me to test if this > combination causes other problems. When LineMergeFilter does > reversals > it might be able to merge more. > > This might help some of Felix's problems - has-direction can be > turned > off for everything - towards the end of lines: > > <finalise> > ... > oneway=* {set mkgmap:has-direction=no} > > I presume r4719 was ignore-oneway-for-lines.patch and I took elements > from this, but redid the oneway/road handling slightly so it was all > in > the same place. > > I've updated the patch to include the unit test change. > > Ticker > > On Mon, 2021-05-17 at 15:38 +0000, Gerd Petermann wrote: > > 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=47 > > 19 > > 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 > > _______________________________________________ > > mkgmap-dev mailing list > > mkgmap-dev at lists.mkgmap.org.uk > > https://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev > _______________________________________________ > mkgmap-dev mailing list > mkgmap-dev at lists.mkgmap.org.uk > https://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev _______________________________________________ mkgmap-dev mailing list mkgmap-dev at lists.mkgmap.org.uk https://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev _______________________________________________ mkgmap-dev mailing list mkgmap-dev at lists.mkgmap.org.uk https://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev -------------- next part -------------- A non-text attachment was scrubbed... Name: dirFlagSetting_v3.patch Type: application/octet-stream Size: 4084 bytes Desc: dirFlagSetting_v3.patch URL: <http://www.mkgmap.org.uk/pipermail/mkgmap-dev/attachments/20210518/319e0a80/attachment-0001.obj>
- Previous message: [mkgmap-dev] Line direction flag, merging etc
- Next message: [mkgmap-dev] Line direction flag, merging etc
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the mkgmap-dev mailing list