What you're looking for is a routing program, i.e. a program able to
find the shortest/best sequence of vertices in a graph to join two
nodes. That's not Mapnik's business but some FOSS solutions exists. You
should have a look at:
- http://pgrouting.postlbs.org/
- http://graphserver.sourceforge.net/

Once, you have a route (the above-mentionned sequence of vertices)
computed out of your road data, your two requirements are easy to meet.
The route being a linestring (or something really close to a it), you
can ask Mapnik to render it or send it to your UI using popular vector
formats. Assuming your dataset stores road names along with road
geometries, it should be possible to iterate over this route and output
"turn <direction> on <road name>" every time the direction change (the
direction being computed from geometry's azimuth).

Hope it helps
Gilles

Jim Irrer wrote:
> Hi -
> 
> I would like to use Mapnik to make driving directions, much like
> is done with Google's maps.  Could anyone recommend a method
> or a package for doing so?
> 
> I was looking for both a way to highlight a route on a map, and also
> generate the cues (ie: turn left on Oak Street).
> 
> Thanks for any information,
> 
> - Jim
> 
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> Mapnik-users mailing list
> [email protected]
> https://lists.berlios.de/mailman/listinfo/mapnik-users


-- 
Gilles Bassiere - MAKINA CORPUS
http://www.makina-corpus.com
_______________________________________________
Mapnik-users mailing list
[email protected]
https://lists.berlios.de/mailman/listinfo/mapnik-users

Reply via email to