Hello, I am looking into a bicycle routing problem and need some help on how to access certain information from within the bicycle profile.
The routing problem may be summarized as follows. Two routes are available; one of these crosses a large road (say, highway=primary), with an uncontrolled and unmarked crossing; the other is slightly longer, and crosses no roads at all, instead passing under the same road via a tunnel. The second route should be preferred if the detour is fairly brief. That is, in routing terms the level crossing should be penalized in certain cases, such as crossing higher priority roads (i.e., secondary and upwards), and additionally, penalized for having unmarked or uncontrolled crossings. The number of lanes may further penalize this route. This would let the bicycle profile prefer safer routes if reasonable in terms of delay incurred. It could apply to the foot profile as well. Example with the undesirable, but legal crossing: https://www.openstreetmap.org/directions?engine=fossgis_osrm_bike&route=53.20425%2C5.77589%3B53.20565%2C5.77266#map=19/53.20525/5.77427&layers=N The preferred route would start like this: https://www.openstreetmap.org/directions?engine=fossgis_osrm_bike&route=53.20425%2C5.77589%3B53.20528%2C5.77433#map=19/53.20506/5.77455&layers=N Looking at the API provided I can see that I can get at the crossing-tag (if any) in process_node, but it looks like the information I need to conclude that a route crosses a large road is not available. The process_turn method has it, but that method seems to be only called when the a node marks a point where permissible routes branch. However, in my sample case there is no branching for the bicycle route: the highway=primary being crossed does not allow bicycles, so at the crossings with this road there are no alternative paths, and thus process_turn is not called at that node. Is there another way to find out what type of road(s) I am crossing? Kind regards, Jeroen Hoek (GitHub: jdhoek, OpenStreetMap: JeroenHoek) _______________________________________________ OSRM-talk mailing list OSRM-talk@openstreetmap.org https://lists.openstreetmap.org/listinfo/osrm-talk