GraphHopper.com | Forum | GitHub | Maps | Blog

Interpolate bridges and tunnels for car


#1

Hello.
There is a problem with understanding of creation GraphHopper graph with bridges and tunnels. I set ElevationProvider to calculate nodes heights and set profile for cars:

graphHopper
.setEncodingManager(new EncodingManager(“car”))
.setElevation(true)
.setElevationProvider(new SRTMProvider());

But method GraphHopper.interpolateBridgesAndOrTunnels() works only for “generic” profile:

if (ghStorage.getEncodingManager().supports(“generic”)) { … }

My question:
how to make interpolation of bridges and tunnels for cars, and whether it is necessary to do this? Perhaps, the calculation of bridges and tunnels for the “car” profile is already done correctly by default?


#2

No it is not yet done. But as soon as we can store the road environment in every edge also in other encoders, which is what we try in https://github.com/graphhopper/graphhopper/pull/1112, then we’ll be able to do a bridge&tunnel interpolation like currently on done in DataFlagEncoder.