Re: [mkgmap-dev] My findings about the crash in MapSource
Hi Andrzej, I've uploaded my test data: http://files.mkgmap.org.uk/download/411/baddem6.7z Please adjust the hard coded paths so that splitter r590 and mkgmap r4102 are used. The script produces a few small tiles with splitter and 4 maps with slightly different options I think the hgt file in SRTM3_orig contains no voids, so I created a copy and placed a few voids (0x8000) into it. Those voids appear only in tile 63240004. The file crash.gdb contains two routes crossing tiles. The one starting in City park causes crashes in MapSource (version 6.16.3) when you don't use the map in folder map\orig\OSM map.gmap This changes when you compile r4102 with the no-dem-align.patch. The other route never causes a crash because all tiles have no extra flag. This changes when you use r4100. My current understanding is that there is a problem when mkgmap r4102 writes tiles with the has extra flag set to true. All routes crossing tile borders of those tiles seem to produce the crash. BTW: BuildDEMFile doesn't align and produces DEM which doesn't crash. That's why I thought that the alignment might be the problem. I guess that we should increase or decrease the overlap of the DEM tiles. Gerd Von: mkgmap-dev im Auftrag von Gerd Petermann Gesendet: Freitag, 2. Februar 2018 22:27 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] My findings about the crash in MapSource Hi Andrzej, I also think that it could be related to the alignment of DEM tiles. I think the problem is not (only) related to dem-polygon, you should be able to reproduce it when you change line 109 in DEMSection.java from boolean hasExtra = false; to boolean hasExtra = true; The polygon handling simply forces that this variable is set to true and when this happens I see the crashes, although it only changes the size of the header info. I'll prepare a test set tomorrow. Gerd Von: mkgmap-dev im Auftrag von Andrzej Popowski Gesendet: Freitag, 2. Februar 2018 22:14 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] My findings about the crash in MapSource Hi Gerd, maybe this is a problem of overlapping of DEM form different tiles? Or maybe size of DEM area is calculated incorrectly? Could you upload an example? I haven't used dem-poly on my maps and never noticed this problem. -- Best regards, Andrzej ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
[mkgmap-dev] args input-file path issue
Hi Gerd Have come across this problem with input-file path names when creating and args file: It seems to be due to the spaces in feb 1 2018 The following creates errors: input-file:F:\mp5\backup\feb 1 2018\args\40526979.osm.pbf This doesn't work either (using quotes) input-file:"F:\mp5\backup\feb 1 2018\args\40526979.osm.pbf" nor (using shortpaths for the whole filename) input-file:F:\mp5\backup\FEB120~1\405269~2.PBF This does works: input-file:F:\mp5\backup\FEB120~1\40526979.osm.pbf r Nick -- Sent from: http://gis.19327.n8.nabble.com/Mkgmap-Development-f5324443.html ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Please help with news about new DEM options
Hi Carlos, thanks again. Seems I need new glasses when I look at all those typos :O I like the introducing chapter about DEM, but I don't fully agree reg. dem-dists: "Reasonable values for the highest resolution are somewhere between 1648 and 5520 for 1'' hgt input files (3312 is often used), and 9942 for 3'' hgt input files." Since 9942 is close to the resolution of the 3'' hgt I think 5520 is also suitable for a 3'' file. Maybe we should add that 1'' means ~ 3314 distance and 3'' means ~ 9942 and that the 1st dist value should not be much smaller than 50% of that distance? Gerd Von: mkgmap-dev im Auftrag von Carlos Dávila Gesendet: Freitag, 2. Februar 2018 22:32 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] Please help with news about new DEM options El 30/01/18 a las 09:41, Gerd Petermann escribió: > Hi all, > > with r4093 I've merged the dem-tdb branch into trunk. I think it would be > good to mention this in the > "Latest news" on [1] , maybe with one or two screen shots, but I have no idea > how to write this "from a users view". > Do we need a how-to that describes the sources for hgt files and maybe more > about the new options? > It would be great if somebody could help with that. > > Gerd > > [1] http://www.mkgmap.org.uk/ > > > Attached patch is not exactly what you asked for, but I hope it adds some useful information about DEM. ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Why is mkgmap the option --country-name=name
Hi Eugeny, the name probably comes from nodes like this https://www.openstreetmap.org/node/27490597 Note that it has is_in:country="Russian Federation" I assume that the bounds file is incomplete and that mkgmap doesn't set mkgmap:admin_level2, maybe because you create the bounds with a file that doesn't fully contain relation 60189, maybe because there is another problem with the boundaries. Gerd Von: mkgmap-dev im Auftrag von Eugeny_B Gesendet: Freitag, 2. Februar 2018 23:35 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] Why is mkgmap the option --country-name=name I apologize for my English, I use Google translator. Yes, in the file RU-LEN.osm.pbf are the objects of 3 countries. I understand that "Country" is wrong. The question is different. I specify in the nations --code-page=1251 and --name-tag-list=name:ru, name, name:en, int_name "SUOMI" is correct (there is no Russian) "Эстония" is correct (there is a Russian) "Russian Federation" is wrong (there is a Russian "Россия") Style Address # # first set the country code # mkgmap:country!=* & mkgmap:admin_level2=* { set mkgmap:country='${mkgmap:admin_level2}' } mkgmap:country!=* & addr:country=* { set mkgmap:country='${addr:country|country-ISO:}' } mkgmap:country!=* & is_in:country=* { set mkgmap:country='${is_in:country|country-ISO:}' } https://www.openstreetmap.org/relation/60189#map=1/70/0 ISO3166-1 RU ISO3166-1:alpha2RU ISO3166-1:alpha3RUS ISO3166-1:numeric 643 admin_level 2 border_type nation boundaryadministrative int_nameRussia int_ref RU nameРоссия name:UN:ru Российская Федерация name:ru Россия official_name Российская Федерация official_name:ruРоссийская Федерация typeboundary Why "Russian Federation"? https://www.openstreetmap.org/relation/79510 ISO3166-1 EE ISO3166-1:alpha2EE ISO3166-1:alpha3EST ISO3166-1:numeric 233 admin_level 2 boundaryadministrative int_nameEstonia nameEesti name:ru Эстония typeboundary Here it is correct "Эстония" -- Sent from: http://gis.19327.n8.nabble.com/Mkgmap-Development-f5324443.html ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Problem with an empty CodePage key in TYP.txt
Hi Bernd TYPwiz creates an empty key 'CodePage=' in my styles_typ.txt every time i had changed this file, this leads to an error message at the end of the build process. The error can be fixed in mkgmap and I've attached a patch to do so. I will commit this tomorrow as it is fairly straightforward. Best wishes, Steve Index: src/uk/me/parabola/mkgmap/main/TypCompiler.java IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 === --- src/uk/me/parabola/mkgmap/main/TypCompiler.java (revision 4100) +++ src/uk/me/parabola/mkgmap/main/TypCompiler.java (date 1517590268000) @@ -246,10 +246,11 @@ if (line.charAt(0) == 0xfeff) return; - if (line.startsWith("CodePage")) { + if (line.startsWith("CodePage=")) { String[] split = line.split("="); try { - setCodePage("cp" + Integer.decode(split[1].trim())); + if (split.length > 1) +setCodePage("cp" + Integer.decode(split[1].trim())); } catch (NumberFormatException e) { setCodePage("cp1252"); } Index: src/uk/me/parabola/mkgmap/typ/TypTextReader.java IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 === --- src/uk/me/parabola/mkgmap/typ/TypTextReader.java (revision 4100) +++ src/uk/me/parabola/mkgmap/typ/TypTextReader.java (date 1517591167000) @@ -65,6 +65,9 @@ break; } } else { +if (currentSection == null) + throw new SyntaxException(scanner, "Missing section start"); + // Line inside a section String name = tok.getValue(); @@ -74,9 +77,6 @@ String value = scanner.readLine(); -if (currentSection == null) - throw new SyntaxException(scanner, "Missing section start"); - currentSection.processLine(scanner, name, value); } scanner.skipSpace(); ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Why is mkgmap the option --country-name=name
I apologize for my English, I use Google translator. Yes, in the file RU-LEN.osm.pbf are the objects of 3 countries. I understand that "Country" is wrong. The question is different. I specify in the nations --code-page=1251 and --name-tag-list=name:ru, name, name:en, int_name "SUOMI" is correct (there is no Russian) "Эстония" is correct (there is a Russian) "Russian Federation" is wrong (there is a Russian "Россия") Style Address # # first set the country code # mkgmap:country!=* & mkgmap:admin_level2=* { set mkgmap:country='${mkgmap:admin_level2}' } mkgmap:country!=* & addr:country=* { set mkgmap:country='${addr:country|country-ISO:}' } mkgmap:country!=* & is_in:country=* { set mkgmap:country='${is_in:country|country-ISO:}' } https://www.openstreetmap.org/relation/60189#map=1/70/0 ISO3166-1 RU ISO3166-1:alpha2RU ISO3166-1:alpha3RUS ISO3166-1:numeric 643 admin_level 2 border_type nation boundaryadministrative int_nameRussia int_ref RU nameРоссия name:UN:ru Российская Федерация name:ru Россия official_name Российская Федерация official_name:ruРоссийская Федерация typeboundary Why "Russian Federation"? https://www.openstreetmap.org/relation/79510 ISO3166-1 EE ISO3166-1:alpha2EE ISO3166-1:alpha3EST ISO3166-1:numeric 233 admin_level 2 boundaryadministrative int_nameEstonia nameEesti name:ru Эстония typeboundary Here it is correct "Эстония" -- Sent from: http://gis.19327.n8.nabble.com/Mkgmap-Development-f5324443.html ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Why is mkgmap the option --country-name=name
Hi Eugeny, I think what you see in this list depends on the content of the bounds file(s), your name-tag-list option, the style, and the content of the osm input files. The string "Country" comes from the default for country and missing information from the bounds. I think it happens when boundaries overlap. When you are sure that all objects in the map are in one country you may add a rule to set mkgmap:country to that name. Hope this helps? Gerd Von: mkgmap-dev im Auftrag von Eugeny_B Gesendet: Freitag, 2. Februar 2018 22:01 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] Why is mkgmap the option --country-name=name I'm downloading the former USSR http://data.gis-lab.info/osm_dump/dump/latest/local.osm.pbf and using mkgmap I create a directory of borders. Then I download the Leningrad Region http://data.gis-lab.info/osm_dump/dump/latest/RU-LEN.osm.pbf and create a gmapsupp without the options --country-name = name and --country-abbr = abbreviation . Device Nuvi 1310 Where-> Address-> Change country. shows 4 country names: "SUOMI", "Russian Federation", "Country" in English and "Estonia" in Russian. If the Nuvi shows "Estonia" in Russian, that's why it doesn't show "Russia" in Russian, and shows "Russian Federation" in English? -- Sent from: http://gis.19327.n8.nabble.com/Mkgmap-Development-f5324443.html ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Please help with news about new DEM options
El 30/01/18 a las 09:41, Gerd Petermann escribió: Hi all, with r4093 I've merged the dem-tdb branch into trunk. I think it would be good to mention this in the "Latest news" on [1] , maybe with one or two screen shots, but I have no idea how to write this "from a users view". Do we need a how-to that describes the sources for hgt files and maybe more about the new options? It would be great if somebody could help with that. Gerd [1] http://www.mkgmap.org.uk/ Attached patch is not exactly what you asked for, but I hope it adds some useful information about DEM. Index: resources/help/en/options === --- resources/help/en/options (revisión: 4097) +++ resources/help/en/options (copia de trabajo) @@ -439,15 +439,22 @@ Note that in resolution 24 the filter is not used. Hill Shading (DEM) options: + Hill Shading is rendered by PC programs (MapSource or BaseCamp) or GPS devices +when the map includes a Digital Elevation Model (DEM). Use the following options +to add a DEM to the map and control its characteristics. DEM creation requires +files containing height information for the area covered by the map, the so +called hgt files, which typically cover 1 degree latitude * 1 degree longitude +and are named by the coordinates of their bottom left corner (eg. N53E009). They +contain height information in a grid of points. Typical hgt files contain either +1'' or 3'' data. 3'' files have 1201 * 1201 points, which gives +2 * 1201 * 1201 = 2.884.802 bytes. 1'' files have 3601 * 3601 points, which gives +2 * 3601 * 3601 = 25.934.402 bytes. Other files are supported as long as the +formular sqrt(size/2) gives an integer value. --dem=path[,path] The option expects a comma separated list of paths to directories or zip - files containing *.hgt files (SRTM). Directories are searched for *.hgt - files and also for *.hgt.zip and *.zip files where * means a name like - N53E009. Typical hgt files contain either 1'' or 3'' data. - 3'' files have 2 * 1201 * 1201 = 2.884.802 bytes, 1'' files have - 2 * 3601 * 3601 = 25.934.402 bytes. Other files are supported as long as the - formular sqrt(size/2) gives an integer value. + files containing *.hgt files. Directories are searched for *.hgt files and + also for *.hgt.zip and *.zip files. The list is searched in the given order, so if you want to use 1'' files make sure that they are found first. There are different sources for *.hgt files, some have so called voids which are areas without data. @@ -457,17 +464,18 @@ If given, the option specifies the resolution(s) or zoom level for the DEM data. If not given, mkgmap tries to determine a reasonable value based on the resolution found in the *.hgt files. For PC programs like MapSource or - Basecamp you only need one zoom level, for gps devies you need one for each + Basecamp you only need one zoom level, for gps devices you need one for each resolution given with the --levels option. The actual values are given as - distance between two DEM points. Higher disances mean lower resolution and + distance between two DEM points. Higher distances mean lower resolution and thus fewer bytes in the map. Reasonable values for the highest resolution - are somewhere between 1648 and 5520, 3312 is often used. + are somewhere between 1648 and 5520 for 1'' hgt input files (3312 is often + used), and 9942 for 3'' hgt input files. Example which should work with levels="0:24, 1:22, 2:20, 3:18": --dem-dists=3312,13248,26512,53024 This was found in a Garmin Demo map for transalpin data created 2009. --dem-interpolation=auto|bicubic|bilinear - Use this option to speciy the method that is used to interpolate + Use this option to specify the method that is used to interpolate data from hgt raster to the DEM raster. The value bicubic gives the highest precision but is slower, bilinear is faster but less precise, it tends to smooth the profile and thus also reduces DEM size compared to ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] My findings about the crash in MapSource
Hi Andrzej, I also think that it could be related to the alignment of DEM tiles. I think the problem is not (only) related to dem-polygon, you should be able to reproduce it when you change line 109 in DEMSection.java from boolean hasExtra = false; to boolean hasExtra = true; The polygon handling simply forces that this variable is set to true and when this happens I see the crashes, although it only changes the size of the header info. I'll prepare a test set tomorrow. Gerd Von: mkgmap-dev im Auftrag von Andrzej Popowski Gesendet: Freitag, 2. Februar 2018 22:14 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] My findings about the crash in MapSource Hi Gerd, maybe this is a problem of overlapping of DEM form different tiles? Or maybe size of DEM area is calculated incorrectly? Could you upload an example? I haven't used dem-poly on my maps and never noticed this problem. -- Best regards, Andrzej ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] My findings about the crash in MapSource
Hi Gerd, maybe this is a problem of overlapping of DEM form different tiles? Or maybe size of DEM area is calculated incorrectly? Could you upload an example? I haven't used dem-poly on my maps and never noticed this problem. -- Best regards, Andrzej ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Why is mkgmap the option --country-name=name
I'm downloading the former USSR http://data.gis-lab.info/osm_dump/dump/latest/local.osm.pbf and using mkgmap I create a directory of borders. Then I download the Leningrad Region http://data.gis-lab.info/osm_dump/dump/latest/RU-LEN.osm.pbf and create a gmapsupp without the options --country-name = name and --country-abbr = abbreviation . Device Nuvi 1310 Where-> Address-> Change country. shows 4 country names: "SUOMI", "Russian Federation", "Country" in English and "Estonia" in Russian. If the Nuvi shows "Estonia" in Russian, that's why it doesn't show "Russia" in Russian, and shows "Russian Federation" in English? -- Sent from: http://gis.19327.n8.nabble.com/Mkgmap-Development-f5324443.html ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Why is mkgmap the option --country-name=name
Eugeny_B writes: > Why is mkgmap the option --country-name=name and --country-abbr=abbreviation, > that it can not take the country name from --bounds=directory|zipfile My experience, not really figured out, is that objects inherit the given country if they do not match anything from bounds (and probably, only if they are not explicitly tagged). I have not yet figured out how many objects get no country, when building from the geofabrik US Northeast extract. I also have not figured out what happens to those objects in terms of the indexes when there is no default country. signature.asc Description: PGP signature ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Why is mkgmap the option --country-name=name
Hi Eugeny, not sure what you mean. I think the two options are only needed when the bounds data doesn't contain enough information to retrieve the country name. I see no direct relation between country and code-page or country and name-tag-list. Gerd Von: mkgmap-dev im Auftrag von Eugeny_B Gesendet: Freitag, 2. Februar 2018 20:27 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: [mkgmap-dev] Why is mkgmap the option --country-name=name Why is mkgmap the option --country-name=name and --country-abbr=abbreviation, that it can not take the country name from --bounds=directory|zipfile with -code-page=number and -name-tag-list? -- Sent from: http://gis.19327.n8.nabble.com/Mkgmap-Development-f5324443.html ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
[mkgmap-dev] Why is mkgmap the option --country-name=name
Why is mkgmap the option --country-name=name and --country-abbr=abbreviation, that it can not take the country name from --bounds=directory|zipfile with -code-page=number and -name-tag-list? -- Sent from: http://gis.19327.n8.nabble.com/Mkgmap-Development-f5324443.html ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter
Hi Gerd, Maybe the dem-dist matter? I've used dem-dists: 9942,9942,9942,13248,44176 overview-dem-dist=88368 Van: mkgmap-dev namens Gerd Petermann Verzonden: vrijdag 2 februari 2018 09:30:59 Aan: Development list for mkgmap Onderwerp: Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Hi Minko, strange. I saw no more problems with the patched version, only when the route itself was a straight line. OK, I'll try to find out more tomorrow. Gerd Von: mkgmap-dev im Auftrag von lig fietser Gesendet: Freitag, 2. Februar 2018 18:24 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] Commit r4101: passoriginalbounding polygon to HGTConverter Hi Gerd, With a dem-poly no, still crashes. Without a dem-poly I see an improvement, I noticed just one crash but I can't reproduce it. Hope this helps, Minko Van: mkgmap-dev namens Gerd Petermann Verzonden: vrijdag 2 februari 2018 07:55:51 Aan: Development list for mkgmap Onderwerp: Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Hi Minko, please try if the errors are fixed with this binary: http://files.mkgmap.org.uk/download/410/mkgmap.jar Gerd Von: mkgmap-dev im Auftrag von Gerd Petermann Gesendet: Freitag, 2. Februar 2018 16:19 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Hi Minko, thanks for testing. Please see my new post http://www.mkgmap.org.uk/pipermail/mkgmap-dev/2018q1/028006.html Gerd Von: mkgmap-dev im Auftrag von lig fietser Gesendet: Freitag, 2. Februar 2018 16:16 An: mkgmap-...@lists.mkgmap.org.uk; mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Hi Gerd, I have tested r4101 with and without --dem-polygon, but in both maps I geto now and then crashes in the altitude profile in mapsource. Not as often as in previous mkgmap versions, but this issue is still present even without --dem-polygon. Van: mkgmap-dev namens svn commit Verzonden: vrijdag 2 februari 2018 05:10:05 Aan: mkgmap-...@lists.mkgmap.org.uk; mkgmap-dev@lists.mkgmap.org.uk Onderwerp: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Version mkgmap-r4101 was committed by gerd on Fri, 02 Feb 2018 pass original bounding polygon to HGTConverter This reduce problems with --dem-polygon but doesn't solve them all. It seems that we always run into problems when the hasExtra flag is set http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4101 ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter
Hi Minko, strange. I saw no more problems with the patched version, only when the route itself was a straight line. OK, I'll try to find out more tomorrow. Gerd Von: mkgmap-dev im Auftrag von lig fietser Gesendet: Freitag, 2. Februar 2018 18:24 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] Commit r4101: passoriginalbounding polygon to HGTConverter Hi Gerd, With a dem-poly no, still crashes. Without a dem-poly I see an improvement, I noticed just one crash but I can't reproduce it. Hope this helps, Minko Van: mkgmap-dev namens Gerd Petermann Verzonden: vrijdag 2 februari 2018 07:55:51 Aan: Development list for mkgmap Onderwerp: Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Hi Minko, please try if the errors are fixed with this binary: http://files.mkgmap.org.uk/download/410/mkgmap.jar Gerd Von: mkgmap-dev im Auftrag von Gerd Petermann Gesendet: Freitag, 2. Februar 2018 16:19 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Hi Minko, thanks for testing. Please see my new post http://www.mkgmap.org.uk/pipermail/mkgmap-dev/2018q1/028006.html Gerd Von: mkgmap-dev im Auftrag von lig fietser Gesendet: Freitag, 2. Februar 2018 16:16 An: mkgmap-...@lists.mkgmap.org.uk; mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Hi Gerd, I have tested r4101 with and without --dem-polygon, but in both maps I geto now and then crashes in the altitude profile in mapsource. Not as often as in previous mkgmap versions, but this issue is still present even without --dem-polygon. Van: mkgmap-dev namens svn commit Verzonden: vrijdag 2 februari 2018 05:10:05 Aan: mkgmap-...@lists.mkgmap.org.uk; mkgmap-dev@lists.mkgmap.org.uk Onderwerp: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Version mkgmap-r4101 was committed by gerd on Fri, 02 Feb 2018 pass original bounding polygon to HGTConverter This reduce problems with --dem-polygon but doesn't solve them all. It seems that we always run into problems when the hasExtra flag is set http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4101 ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter
Hi Gerd, With a dem-poly no, still crashes. Without a dem-poly I see an improvement, I noticed just one crash but I can't reproduce it. Hope this helps, Minko Van: mkgmap-dev namens Gerd Petermann Verzonden: vrijdag 2 februari 2018 07:55:51 Aan: Development list for mkgmap Onderwerp: Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Hi Minko, please try if the errors are fixed with this binary: http://files.mkgmap.org.uk/download/410/mkgmap.jar Gerd Von: mkgmap-dev im Auftrag von Gerd Petermann Gesendet: Freitag, 2. Februar 2018 16:19 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Hi Minko, thanks for testing. Please see my new post http://www.mkgmap.org.uk/pipermail/mkgmap-dev/2018q1/028006.html Gerd Von: mkgmap-dev im Auftrag von lig fietser Gesendet: Freitag, 2. Februar 2018 16:16 An: mkgmap-...@lists.mkgmap.org.uk; mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Hi Gerd, I have tested r4101 with and without --dem-polygon, but in both maps I geto now and then crashes in the altitude profile in mapsource. Not as often as in previous mkgmap versions, but this issue is still present even without --dem-polygon. Van: mkgmap-dev namens svn commit Verzonden: vrijdag 2 februari 2018 05:10:05 Aan: mkgmap-...@lists.mkgmap.org.uk; mkgmap-dev@lists.mkgmap.org.uk Onderwerp: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Version mkgmap-r4101 was committed by gerd on Fri, 02 Feb 2018 pass original bounding polygon to HGTConverter This reduce problems with --dem-polygon but doesn't solve them all. It seems that we always run into problems when the hasExtra flag is set http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4101 ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Problem with an empty CodePage key in TYP.txt
Hi Bend I think this should be in TYPWiz and perhaps a warning in mkgmap that codepages cant be 0 Nick On 02/02/2018 16:21, Bernd Weigelt wrote: Hello TYPwiz creates an empty key 'CodePage=' in my styles_typ.txt every time i had changed this file, this leads to an error message at the end of the build process. I don't know if this line is needed, but i can't see any problem, when i comment this key out, made it for very much builds. Should this problem fixed in MKGMAP or better in TYPwiz? Bernd ;generated by TYPWiz 5,82 ;created : 02-01-2018 ;-- [_id] ProductCode=46 FID=5 ;Header=5B CodePage= [end] II: building basemap Time started: Fri Feb 02 16:58:17 CET 2018 java.lang.ArrayIndexOutOfBoundsException: 1 at uk.me.parabola.mkgmap.main.TypCompiler $CharsetProbe.tryCharset(TypCompiler.java:252) at uk.me.parabola.mkgmap.main.TypCompiler $CharsetProbe.probeCharset(TypCompiler.java:222) at uk.me.parabola.mkgmap.main.TypCompiler$CharsetProbe.access $000(TypCompiler.java:205) at uk.me.parabola.mkgmap.main.TypCompiler.makeMap(TypCompiler.java:67) at uk.me.parabola.mkgmap.main.Main$1.call(Main.java:263) at uk.me.parabola.mkgmap.main.Main$1.call(Main.java:259) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java: 1149) at java.util.concurrent.ThreadPoolExecutor $Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748) Number of MapFailedExceptions: 0 Number of ExitExceptions: 0 Time finished: Fri Feb 02 17:01:42 CET 2018 Total time taken: 205566ms ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
[mkgmap-dev] Problem with an empty CodePage key in TYP.txt
Hello TYPwiz creates an empty key 'CodePage=' in my styles_typ.txt every time i had changed this file, this leads to an error message at the end of the build process. I don't know if this line is needed, but i can't see any problem, when i comment this key out, made it for very much builds. Should this problem fixed in MKGMAP or better in TYPwiz? Bernd ;generated by TYPWiz 5,82 ;created : 02-01-2018 ;-- [_id] ProductCode=46 FID=5 ;Header=5B CodePage= [end] II: building basemap Time started: Fri Feb 02 16:58:17 CET 2018 java.lang.ArrayIndexOutOfBoundsException: 1 at uk.me.parabola.mkgmap.main.TypCompiler $CharsetProbe.tryCharset(TypCompiler.java:252) at uk.me.parabola.mkgmap.main.TypCompiler $CharsetProbe.probeCharset(TypCompiler.java:222) at uk.me.parabola.mkgmap.main.TypCompiler$CharsetProbe.access $000(TypCompiler.java:205) at uk.me.parabola.mkgmap.main.TypCompiler.makeMap(TypCompiler.java:67) at uk.me.parabola.mkgmap.main.Main$1.call(Main.java:263) at uk.me.parabola.mkgmap.main.Main$1.call(Main.java:259) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java: 1149) at java.util.concurrent.ThreadPoolExecutor $Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748) Number of MapFailedExceptions: 0 Number of ExitExceptions: 0 Time finished: Fri Feb 02 17:01:42 CET 2018 Total time taken: 205566ms signature.asc Description: This is a digitally signed message part. ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter
Hi Minko, please try if the errors are fixed with this binary: http://files.mkgmap.org.uk/download/410/mkgmap.jar Gerd Von: mkgmap-dev im Auftrag von Gerd Petermann Gesendet: Freitag, 2. Februar 2018 16:19 An: Development list for mkgmap Betreff: Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Hi Minko, thanks for testing. Please see my new post http://www.mkgmap.org.uk/pipermail/mkgmap-dev/2018q1/028006.html Gerd Von: mkgmap-dev im Auftrag von lig fietser Gesendet: Freitag, 2. Februar 2018 16:16 An: mkgmap-...@lists.mkgmap.org.uk; mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Hi Gerd, I have tested r4101 with and without --dem-polygon, but in both maps I geto now and then crashes in the altitude profile in mapsource. Not as often as in previous mkgmap versions, but this issue is still present even without --dem-polygon. Van: mkgmap-dev namens svn commit Verzonden: vrijdag 2 februari 2018 05:10:05 Aan: mkgmap-...@lists.mkgmap.org.uk; mkgmap-dev@lists.mkgmap.org.uk Onderwerp: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Version mkgmap-r4101 was committed by gerd on Fri, 02 Feb 2018 pass original bounding polygon to HGTConverter This reduce problems with --dem-polygon but doesn't solve them all. It seems that we always run into problems when the hasExtra flag is set http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4101 ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter
Hi Minko, thanks for testing. Please see my new post http://www.mkgmap.org.uk/pipermail/mkgmap-dev/2018q1/028006.html Gerd Von: mkgmap-dev im Auftrag von lig fietser Gesendet: Freitag, 2. Februar 2018 16:16 An: mkgmap-...@lists.mkgmap.org.uk; mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Hi Gerd, I have tested r4101 with and without --dem-polygon, but in both maps I geto now and then crashes in the altitude profile in mapsource. Not as often as in previous mkgmap versions, but this issue is still present even without --dem-polygon. Van: mkgmap-dev namens svn commit Verzonden: vrijdag 2 februari 2018 05:10:05 Aan: mkgmap-...@lists.mkgmap.org.uk; mkgmap-dev@lists.mkgmap.org.uk Onderwerp: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Version mkgmap-r4101 was committed by gerd on Fri, 02 Feb 2018 pass original bounding polygon to HGTConverter This reduce problems with --dem-polygon but doesn't solve them all. It seems that we always run into problems when the hasExtra flag is set http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4101 ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
[mkgmap-dev] My findings about the crash in MapSource
Hi all, I found out that whenever mkgmap r4100 wrote a tile with DEM data that has the "extra flag" set to 2 (which means that the tile contains invalid height information which should be ignored) I was able to reproduce the crash in MapSource when clicking on "Show profile..." for a route which crosses the boundaries of this tile I found one error in the code for the --dem-poly option. This produced too many "invalid" values, even for tiles which are completely inside the bounding polygon. I fixed that with r4101. Still, the same problem occurs when a hgt file contains too many voids or the tile is in fact partly outside the polygon. It seems that Andrzejs patch dem-align-6.patch is part of the problem. When I disable parts of the code with the attached patch the problem seems to disappear. Gerd no-dem-align.patch Description: no-dem-align.patch ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter
Hi Gerd, I have tested r4101 with and without --dem-polygon, but in both maps I geto now and then crashes in the altitude profile in mapsource. Not as often as in previous mkgmap versions, but this issue is still present even without --dem-polygon. Van: mkgmap-dev namens svn commit Verzonden: vrijdag 2 februari 2018 05:10:05 Aan: mkgmap-...@lists.mkgmap.org.uk; mkgmap-dev@lists.mkgmap.org.uk Onderwerp: [mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter Version mkgmap-r4101 was committed by gerd on Fri, 02 Feb 2018 pass original bounding polygon to HGTConverter This reduce problems with --dem-polygon but doesn't solve them all. It seems that we always run into problems when the hasExtra flag is set http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4101 ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Error in style file relations?
Thanks for noticing this, I'll change it in my styles Van: mkgmap-dev namens Steve Ratcliffe Verzonden: vrijdag 2 februari 2018 06:42:14 Aan: mkgmap-dev@lists.mkgmap.org.uk Onderwerp: Re: [mkgmap-dev] Error in style file relations? Hi Gerd > line 124 is: > mkgmap:carpool_compat=yes { setaccess=no; set mkgmap:bus=yes; set > mkgmap:emergency=yes; set mkgmap:carpool=yes } > > I assume it should be > mkgmap:carpool_compat=yes { setaccess no; set mkgmap:bus=yes; set > mkgmap:emergency=yes; set mkgmap:carpool=yes } > > but maybe WanMil meant > mkgmap:carpool_compat=yes { set access=no; set mkgmap:bus=yes; set > mkgmap:emergency=yes; set mkgmap:carpool=yes } Ha.. yes it could be either. My guess would be that it should be 'setaccess no' as it is followed by some of the access flags. Steve ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Error in style file relations?
Hi Gerd line 124 is: mkgmap:carpool_compat=yes { setaccess=no; set mkgmap:bus=yes; set mkgmap:emergency=yes; set mkgmap:carpool=yes } I assume it should be mkgmap:carpool_compat=yes { setaccess no; set mkgmap:bus=yes; set mkgmap:emergency=yes; set mkgmap:carpool=yes } but maybe WanMil meant mkgmap:carpool_compat=yes { set access=no; set mkgmap:bus=yes; set mkgmap:emergency=yes; set mkgmap:carpool=yes } Ha.. yes it could be either. My guess would be that it should be 'setaccess no' as it is followed by some of the access flags. Steve ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Error in style file relations?
Hi Steve, I've tried it with Minkos style which uses this as last line in the lines file include 'inc/compat_lines'; I see this error message: Error in style: Error: (inc/compat_lines:124): Unrecognised command 'no' line 124 is: mkgmap:carpool_compat=yes { setaccess=no; set mkgmap:bus=yes; set mkgmap:emergency=yes; set mkgmap:carpool=yes } I assume it should be mkgmap:carpool_compat=yes { setaccess no; set mkgmap:bus=yes; set mkgmap:emergency=yes; set mkgmap:carpool=yes } but maybe WanMil meant mkgmap:carpool_compat=yes { set access=no; set mkgmap:bus=yes; set mkgmap:emergency=yes; set mkgmap:carpool=yes } I've never fully understood that syntax. Gerd Von: mkgmap-dev im Auftrag von Steve Ratcliffe Gesendet: Freitag, 2. Februar 2018 14:04 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] Error in style file relations? Hi Here is a patch to fix the problem where commands that are not separated by a semi-colon are not ignored. Various possible errors are now caught instead of being silently ignored. In the original relation file that Gerd fixed, there was the following: $route=road & $network='e-road' { apply { add ref='${ref}'; add int_ref='${int_ref}'; add network='e-road'# missing semi-colon add mkgmap:fast_road='yes'; } } this was being read as: $route=road & $network='e-road' { apply { add ref='${ref}'; add int_ref='${int_ref}'; add network='e-road' | 'add' | 'mkgmap:fast_road' | '=' | 'yes'; } } Since 'e-road' does not contain any variables, then it was always the value that 'network' was set to. Now you do not need any of the semi-colons, so the original code would be read as intended. I don't believe that there were any more similar errors in the style file, so this patch should have no effect for the default style. Of course it may find errors in custom styles, or something that did not work before may suddenly start to work as intended causing a difference. ..Steve ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
[mkgmap-dev] Commit r4102: code refactoring, no functional change
Version mkgmap-r4102 was committed by gerd on Fri, 02 Feb 2018 code refactoring, no functional change http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4102 ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
[mkgmap-dev] Commit r4101: pass original bounding polygon to HGTConverter
Version mkgmap-r4101 was committed by gerd on Fri, 02 Feb 2018 pass original bounding polygon to HGTConverter This reduce problems with --dem-polygon but doesn't solve them all. It seems that we always run into problems when the hasExtra flag is set http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4101 ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Error in style file relations?
Hi Here is a patch to fix the problem where commands that are not separated by a semi-colon are not ignored. Various possible errors are now caught instead of being silently ignored. In the original relation file that Gerd fixed, there was the following: $route=road & $network='e-road' { apply { add ref='${ref}'; add int_ref='${int_ref}'; add network='e-road'# missing semi-colon add mkgmap:fast_road='yes'; } } this was being read as: $route=road & $network='e-road' { apply { add ref='${ref}'; add int_ref='${int_ref}'; add network='e-road' | 'add' | 'mkgmap:fast_road' | '=' | 'yes'; } } Since 'e-road' does not contain any variables, then it was always the value that 'network' was set to. Now you do not need any of the semi-colons, so the original code would be read as intended. I don't believe that there were any more similar errors in the style file, so this patch should have no effect for the default style. Of course it may find errors in custom styles, or something that did not work before may suddenly start to work as intended causing a difference. ..Steve Index: src/uk/me/parabola/mkgmap/osmstyle/actions/ActionReader.java IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 === --- src/uk/me/parabola/mkgmap/osmstyle/actions/ActionReader.java (revision 4100) +++ src/uk/me/parabola/mkgmap/osmstyle/actions/ActionReader.java (date 1517574341000) @@ -55,6 +55,9 @@ if (tok.isValue(";")) continue; + if (tok.isValue("'") || tok.isValue("\"")) +throw new SyntaxException(scanner, "quoted word found where command expected"); + String cmd = tok.getValue(); if ("set".equals(cmd)) { actions.add(readTagValue(true, changeableTags)); @@ -131,14 +134,14 @@ * A name command has a number of alternatives separated by '|' characters. */ private Action readValueBuilder(ValueBuildedAction action) { - while (inActionCmd()) { - if (scanner.checkToken("|")) { -scanner.nextToken(); -continue; - } + do { + if (!inActionCmd()) +throw new SyntaxException(scanner, "unexpected end of add/set list"); + String val = scanner.nextWord(); action.add(val); - } + } while (hasMoreWords()); + usedTags.addAll(action.getUsedTags()); return action; } @@ -162,7 +165,9 @@ scanner.nextToken(); AddTagAction action = null; - while (inActionCmd()) { + do { + if (!inActionCmd()) +throw new SyntaxException(scanner, "unexpected end of add/set list"); String val = scanner.nextWord(); if (action == null) @@ -177,11 +182,9 @@ } else { changeableTags.add(key + "=" + val); } - if (scanner.checkToken("|")) -scanner.nextToken(); - } - if (action != null) - usedTags.addAll(action.getUsedTags()); + } while (hasMoreWords()); + + usedTags.addAll(action.getUsedTags()); return action; } @@ -199,7 +202,9 @@ */ private AddAccessAction readAccessValue(boolean modify, Set changeableTags) { AddAccessAction action = null; - while (inActionCmd()) { + do { + if (!inActionCmd()) +throw new SyntaxException(scanner, "unexpected end of access list"); String val = scanner.nextWord(); if (action == null) @@ -210,17 +215,15 @@ // If the value contains a variable, then we do not know what the // value will be. Otherwise save the full tag=value if (val.contains("$")) { -for (String accessTag : ACCESS_TAGS.keySet()) - changeableTags.add(accessTag); +changeableTags.addAll(ACCESS_TAGS.keySet()); } else { for (String accessTag : ACCESS_TAGS.keySet()) changeableTags.add(accessTag + "=" + val); } - if (scanner.checkToken("|")) -scanner.nextToken(); - } - if (action != null) - usedTags.addAll(action.getUsedTags()); + + } while (hasMoreWords()); + + usedTags.addAll(action.getUsedTags()); return action; } @@ -233,6 +236,17 @@ return !scanner.isEndOfFile() && !scanner.checkToken("}"); } + private boolean hasMoreWords() { + if (scanner.checkToken("|")) { + scanner.nextToken(); + + if (!inActionCmd()) +throw new SyntaxException(scanner, "unexpected end of list"); + return true; + } + return false; + } + public Set getUsedTags() { return usedTags; } Index: src/uk/me/parabola/mkgmap/scan/TokenScanner.java IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 === --- src/uk/me/parabola/mkgmap/scan/TokenScanner.java (revision 4100) +++ src/uk/me/parabola/mkgmap/scan/TokenScanner.java (date 1517571163000) @@ -356,7 +356,9 @@ } /** - * Check the value of the next token without consuming it. + * Check the value of the next non-space token without consuming it. + * + * Any white space will be consumed * * @param val String value to compare against. * @ret
Re: [mkgmap-dev] Remove option dem-polygon ?
I only use BaseCamp and have not seen any crashes so far. I have noticed a couple of tracks that don't show the elevation, and instead display a message "the current map does not contain any elevation data on the selected route(s)". There is no obvious hole in the relief that I can see, so not sure why this should happen, but perhaps it is related. Cheers, Mike -Original Message- From: Gerd Petermann [mailto:gpetermann_muenc...@hotmail.com] Sent: 02 February 2018 07:25 To: mkgmap-dev@lists.mkgmap.org.uk Subject: [mkgmap-dev] Remove option dem-polygon ? Hi all, I did not get much feedback on this thread [1], maybe because I wrote -dem-profile instead of dem-polygon in the subject? It seems that MapSource simply cannot handle routes on maps created with that option. Basecamp is more robust but also shows problems as I stated in the first post. Does anybody use this option for a routable map and is able to produce height profiles for routes crossing tile borders in Mapsource? If yes there may be hope... Gerd [1] http://www.mkgmap.org.uk/pipermail/mkgmap-dev/2018q1/027970.html ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Style Manual
Hi Gerd, that all looks fine. Thanks. When I saw these, I was actually looking to see whether I could find anything that would flag whether a relation had a member with the inner role. I would like to add a rule in my style file something like: highway=pedestrian & mkgmap:mp_created =true & is_closed()=true & area!=* & has_inner {set area=yes} Is there anything you can suggest? Cheers, Mike -Original Message- From: Gerd Petermann [mailto:gpetermann_muenc...@hotmail.com] Sent: 02 February 2018 07:29 To: Development list for mkgmap Subject: Re: [mkgmap-dev] Style Manual Mike, Henning, thanks for the comments, please check my changes in http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4098 and http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=4099 I hope this is okay now? Gerd Von: mkgmap-dev im Auftrag von Henning Scholland Gesendet: Donnerstag, 1. Februar 2018 12:29 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: Re: [mkgmap-dev] Style Manual Hi Gerd, regarding tagisincomplete I would suggest to get rid of it. I can't imagine any use of it. For 2nd tagg it seems to be somehow useful. Maybe document it like ' Don't use in relation-style, is set to indicate line/poygon is part of MP-relation'. The usage in relation-styles should be checked during check-style. Henning On 01.02.2018 18:22, Gerd Petermann wrote: > Hi all, > > to be honest, I don't fully understand what mkgmap:tagsincomplete is about. > The tag is set by the OSM readers when a type=multipolygon or type=boundary relation has a tag that is NOT evaluated by the style, > this is probably the case for many of those relations. The effect is that a mp relation with a normal tag like name=* is treated the same as > one with exotic:unused:nonsense=*. The only case where this seems to matter is when a relation has only the type=mulitpolygon tag. > > See this svn log message: http://www.mkgmap.org.uk/websvn/revision.php?repname=mkgmap&rev=2366 > The tag is evaluated before any style processing happens and I think it makes no sense to evaluate or change it in style rules. > > reg: mkgmap:stylefilter: > The tag is set in the MultipolygonRelation code. It is used to decide whether the rules in lines or in polygons should be used. > Without the tag it is likely that both are combined (rules in lines before those in polygons). > You should not see this tag in the relations style, only in lines or polygons, as long as you don't set it in the relations > rules. Doing this might cause trouble. > Maybe it makes sense to evaluate this tag in the lines rules, something like > # filter highways which are parts of multipolygon relations > highway=* & mkgmap:stylefilter=lines {...} > > tl;dr: > I can document these tags as e.g. "please don't set or change" > or I can try to get rid of them. What do you think? > > Gerd > > Von: mkgmap-dev im Auftrag von Gerd Petermann > Gesendet: Mittwoch, 31. Januar 2018 21:22 > An: Mike Baggaley; 'Development list for mkgmap' > Betreff: Re: [mkgmap-dev] Style Manual > > Hi Mike, > > I'd rather change the code so that you don't see those tags. They are for internal use only. > > Gerd > > > Von: mkgmap-dev im Auftrag von Mike Baggaley > Gesendet: Mittwoch, 31. Januar 2018 20:20 > An: 'Development list for mkgmap' > Betreff: [mkgmap-dev] Style Manual > > I notice the style manual has no mention of mkgmap:stylefilter or > mkgmap:tagsincomplete in it. I see these in the output of the echotags > command when handling a relation. Can they be added to the documentation? > > Cheers, > Mike > > ___ > mkgmap-dev mailing list > mkgmap-dev@lists.mkgmap.org.uk > http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev > ___ > mkgmap-dev mailing list > mkgmap-dev@lists.mkgmap.org.uk > http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev > ___ > mkgmap-dev mailing list > mkgmap-dev@lists.mkgmap.org.uk > http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev > ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Remove option dem-polygon ?
Sorry, I was wrong Gerd, it seems I didn't check routing over tile borders. Altitude profiles crashes there too. Hope you can solve this bug. Van: mkgmap-dev namens Gerd Petermann Verzonden: vrijdag 2 februari 2018 00:02:59 Aan: Development list for mkgmap Onderwerp: Re: [mkgmap-dev] Remove option dem-polygon ? Hi all, just found a bug in mkgmap which seems to cause this problem :-) Trying to fix it now... Gerd Von: mkgmap-dev im Auftrag von Gerd Petermann Gesendet: Freitag, 2. Februar 2018 08:25 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: [mkgmap-dev] Remove option dem-polygon ? Hi all, I did not get much feedback on this thread [1], maybe because I wrote -dem-profile instead of dem-polygon in the subject? It seems that MapSource simply cannot handle routes on maps created with that option. Basecamp is more robust but also shows problems as I stated in the first post. Does anybody use this option for a routable map and is able to produce height profiles for routes crossing tile borders in Mapsource? If yes there may be hope... Gerd [1] http://www.mkgmap.org.uk/pipermail/mkgmap-dev/2018q1/027970.html ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Remove option dem-polygon ?
Hi all, just found a bug in mkgmap which seems to cause this problem :-) Trying to fix it now... Gerd Von: mkgmap-dev im Auftrag von Gerd Petermann Gesendet: Freitag, 2. Februar 2018 08:25 An: mkgmap-dev@lists.mkgmap.org.uk Betreff: [mkgmap-dev] Remove option dem-polygon ? Hi all, I did not get much feedback on this thread [1], maybe because I wrote -dem-profile instead of dem-polygon in the subject? It seems that MapSource simply cannot handle routes on maps created with that option. Basecamp is more robust but also shows problems as I stated in the first post. Does anybody use this option for a routable map and is able to produce height profiles for routes crossing tile borders in Mapsource? If yes there may be hope... Gerd [1] http://www.mkgmap.org.uk/pipermail/mkgmap-dev/2018q1/027970.html ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
Re: [mkgmap-dev] Remove option dem-polygon ?
Gerd, I use dem-polygon and most profiles turn out ok, but sometimes it crashes yes. Van: mkgmap-dev namens Gerd Petermann Verzonden: donderdag 1 februari 2018 23:25:23 Aan: mkgmap-dev@lists.mkgmap.org.uk Onderwerp: [mkgmap-dev] Remove option dem-polygon ? Hi all, I did not get much feedback on this thread [1], maybe because I wrote -dem-profile instead of dem-polygon in the subject? It seems that MapSource simply cannot handle routes on maps created with that option. Basecamp is more robust but also shows problems as I stated in the first post. Does anybody use this option for a routable map and is able to produce height profiles for routes crossing tile borders in Mapsource? If yes there may be hope... Gerd [1] http://www.mkgmap.org.uk/pipermail/mkgmap-dev/2018q1/027970.html ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev ___ mkgmap-dev mailing list mkgmap-dev@lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev