[mkgmap-dev] Building northeast map
From Gerd Petermann gpetermann_muenchen at hotmail.com on Fri Oct 31 09:11:18 GMT 2014
Hi Brian, reg. your patch: I don't understand why you think that this works better than adding place_name to the end of the name-tag-list. It seems to have the same effect, but would be hard-coded? Reg. is_in:country and is_in:state: I don't understand what change you have in mind. Do you want to fill fields like mkgmap:admin_level2 using the values given in is_in:country if the value would be null else? Gerd From: brianegge at gmail.com Date: Fri, 31 Oct 2014 00:10:56 -0400 To: mkgmap-dev at lists.mkgmap.org.uk Subject: Re: [mkgmap-dev] Building northeast map Hi Gerd, I found the first issue why so many cities were missing. It turns out in my area many boundaries contain 'place_name' instead of 'name'. Examples: http://overpass-turbo.eu/s/5HL I realize I could add this tag to name-tag-list, but i think it would be better to have it searched as a last resort. Thus, I propose the following patch: Index: src/uk/me/parabola/mkgmap/reader/osm/boundary/BoundaryLocationPreparer.java===================================================================--- src/uk/me/parabola/mkgmap/reader/osm/boundary/BoundaryLocationPreparer.java (revision 3341)+++ src/uk/me/parabola/mkgmap/reader/osm/boundary/BoundaryLocationPreparer.java (working copy)@@ -69,6 +69,9 @@ int admLevel = getAdminLevel(tags); boolean isISO = false; String name = getName(tags);+ if (name == null) {+ log.warn("No name found for boundary", tags);+ } if (locator != null){ if (admLevel == 2) { String isoCode = locator.addCountry(tags);@@ -142,6 +145,11 @@ } return nameParts[0].trim().intern(); }+ String place_name = tags.get("place_name");+ if (place_name != null) {+ log.warn("Boundry has controversial place_name:", place_name, tags, "http://wiki.openstreetmap.org/wiki/Proposed_features/drop_recommendation_for_place_name");+ return place_name;+ } return null; } Secondly, while I don't have a complete admin_level2 in my boundary file, most city, county and state boundaries contain is_in tags. For example, Danbury (http://www.openstreetmap.org/way/33271879), contains is_in:countryUSAis_in:stateConnecticutWith these tags, I should be able to set state and country information even if I don't have those boundaries explicitly loaded. I was thinking this extra information could be added to the BoundaryLocationInfo class, much like how the zip code is today. What do you think about that approach? Brian On Oct 30, 2014, at 4:00 AM, Gerd Petermann <gpetermann_muenchen at hotmail.com> wrote: Hi Brian, I see. I fear the meanings of the --country-xxx options are not well documented. If I got it right, they have an influence on the address search indexes, but they have no meaning for the rules in the style. Maybe your problem could be solved with an additional line in the address rule. Something like this mkgmap:admin_level5='New York City' & mkgmap:admin_level2!=* { set mkgmap:admin_level2='USA' } as a first line in inc/address. Another option would be to change the LocationHook to optionally use the values given with --country-xxx to fill the mkgmap:admin_level2 tag. Gerd From: brianegge at gmail.com Date: Thu, 30 Oct 2014 02:38:17 +0000 To: mkgmap-dev at lists.mkgmap.org.uk Subject: Re: [mkgmap-dev] Building northeast map Thanks Gerd, I've been adding/fixing city boundaries in my area, so I'm trying to create my own bounds file. If an admin_level2 can't be found, does it use the --country-abbr option? Brian _______________________________________________ mkgmap-dev mailing list mkgmap-dev at lists.mkgmap.org.uk http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://www.mkgmap.org.uk/pipermail/mkgmap-dev/attachments/20141031/54d7c7cb/attachment.html>
- Previous message: [mkgmap-dev] Building northeast map
- Next message: [mkgmap-dev] Building northeast map
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the mkgmap-dev mailing list