logo separator

[mkgmap-dev] address index glitch?

From Henning Scholland osm at aighes.de on Sun Nov 25 16:21:44 GMT 2012

Am 25.11.2012 16:17, schrieb Richard Welty:
> On 11/25/12 9:51 AM, Thorsten Kukuk wrote:
>> I think this all comes down to calculate the shortest distance 
>> between a point (the addr:housenumber) and a line (highway=*). You 
>> can find some solutions on the net, like: 
>> http://stackoverflow.com/questions/849211/shortest-distance-between-a-point-and-a-line-segment 
>> No we face some problems: 1) streets are complex lines 
> you'd have to use the algorithm against the group of segments, but it
> could produce
> deceptive results with roads that "snake" about a bit.
>
> driveways?
> in rural areas, an address may be attached to a building which is some
> distance away
> from a rural road, connected by a driveway. in these cases, we need to
> deliver a route
> to the foot of the correct driveway. will have to think about this
> algorithm. at least,
> if the driveway is in OSM, there will be an appropriate node, if we can
> just figure out which
> one it is.
>
> driveways could, though, be a solution to the snaky road problem.
> closest driveway leads
> you to the correct node on the road.
Whats what I've learned while Operation Cowboy. In Europe this isn't 
really critical, because mainly buildings are next to the road. In US 
this is different in rural areas. There are houses in the middle of 
nowhere. What would a user assume? Routing ends at highway, where 
driveway starts or at the end of driveway? I'm mapping in Wyoming and 
there I've seen sometimes very long driveways [ 
http://mc.bbbike.org/mc/?lon=-105.10806&lat=41.83972&zoom=16&num=1&mt0=mapnik&mt-1=ol_bing-satellite&mt-1p=35 
] so I espect a routing to end of driveway.

>> For 3), we can use the same algorithm as we use for placing a
>> POI for a mulitpolygon, including entrance, etc.
> i don't know that algorithm, but either you can use the closest node on
> the polygon, or you can compute a centroid for the polygon and use
> that.
I think mkgmap has an algorithm for this. ( --add-poi-to-area )

Henning




More information about the mkgmap-dev mailing list