Sorry, I modified my code :
GraphHopper Hopp = new GraphHopper().forMobile();
Hopp.load(new File(mapsFolder, currentArea).getAbsolutePath()
Hopp.setEncodingManager(new EncodingManager("bike"));
); //load graph.........
.................
GHRequest req = new GHRequest(fromLat, fromLon, toLat, toLon);
req.setVehicle("bike").setAlgorithm(AlgorithmOptions.ASTAR_BI);
I have still an error :
An error happend while creating graph:Encoding does not match:
Graphhopper config:
bike|speedFactor=2.0|speedBits=4|turnCosts=false|version=1
Graph: car|speedFactor=5.0|speedBits=5|turnCosts=false|version=1,
dir:/storage/sdcard0/graphhopper/maps/data-gh/
how create graph for bike? To create graph I make ./graphhopper import
data.osm.pbf
2015-06-29 11:45 GMT+02:00 Emux <[email protected]>:
> Actually the error mentions what's happening.
>
> The graph was created with supported vehicles [car].
> And you try to perform a request with a different one [bike].
>
> The graph and the request need to be compatible, regarding vehicles,
> contraction hierarchies etc.
>
> --
> Emux
> Cruiser <http://wiki.openstreetmap.org/wiki/Cruiser> - Atlas
> <http://wiki.openstreetmap.org/wiki/Atlas_%28navigation_application%29>
>
> _______________________________________________
> GraphHopper mailing list
> [email protected]
> https://lists.openstreetmap.org/listinfo/graphhopper
>
>
_______________________________________________
GraphHopper mailing list
[email protected]
https://lists.openstreetmap.org/listinfo/graphhopper