|
2 | 2 | * Webpack will replace this file with config-local.js if it exists |
3 | 3 | */ |
4 | 4 | const config = { |
5 | | - // the url of the GraphHopper routing backend, either use graphhopper.com or point it to your own GH instance |
6 | | - routingApi: 'https://graphhopper.com/api/1/', |
7 | | - // the url of the geocoding backend, either use graphhopper.com or point it to another geocoding service. use an empty string to disable the address search |
8 | | - geocodingApi: 'https://graphhopper.com/api/1/', |
9 | | - // the tile layer used by default, see MapOptionsStore.ts for all options |
10 | | - defaultTiles: 'OpenStreetMap', |
11 | | - // various api keys used for the GH backend and the different tile providers |
| 5 | + // routingApi: 'https://graphhopper.com/api/1/', |
| 6 | + routingApi: 'http://localhost:8989/', |
| 7 | + // geocodingApi: 'https://graphhopper.com/api/1/', |
| 8 | + geocodingApi: 'http://localhost:8080/', |
| 9 | + defaultTiles: 'Planetiler', |
| 10 | + routingGraphLayerAllowed: true, |
12 | 11 | keys: { |
13 | | - graphhopper: 'efc33bcc-a9e6-450b-9221-c52c5bf57de3', |
14 | | - maptiler: 'missing_api_key', |
15 | | - omniscale: 'missing_api_key', |
16 | | - thunderforest: 'missing_api_key', |
17 | | - kurviger: 'missing_api_key', |
18 | | - tracestrack: 'missing_api_key', |
| 12 | + graphhopper: 'no_api_key', |
| 13 | + maptiler: 'no_api_key', |
| 14 | + omniscale: 'no_api_key', |
| 15 | + thunderforest: 'no_api_key', |
| 16 | + kurviger: 'no_api_key', |
| 17 | + tracestrack: 'no_api_key' |
| 18 | + }, |
| 19 | + externalMVTLayer: { |
| 20 | + // metric: dist,time or traffic_time -> specifies by which metric the GH routes shall be compared to the benchmark |
| 21 | + // alternative: -1, 0, 1, ... -> specifies which alternative route shall be taken from the benchmark. 0 is the 'best' route. -1 means we use the one that is closest to GH with respect to metric |
| 22 | + // profile: the GH profile we use for the comparison |
| 23 | + // min_error: for example a value of 10 means that only benchmarks with relative error >10% (regarding metric,profile+alternative) |
| 24 | + // only_if_first_two_profiles_different: if true only benchmarks are drawn on the map for which the GH results (regarding metric) for the first two profiles differ (by more than 1%) |
| 25 | + url: 'http://135.181.79.179:8900/benchmarks-mvt/{z}/{x}/{y}.mvt?metric=dist&alternative=-1&profile=car&min_error=0&only_if_first_two_profiles_different=true', |
| 26 | + styles: { |
| 27 | + // use this |
| 28 | + 'benchmark': { |
| 29 | + color: [255, 0, 0, 0.8], // red |
| 30 | + width: 3 |
| 31 | + }, |
| 32 | + 'gh_car': { |
| 33 | + color: [0, 255, 0, 0.8], // green |
| 34 | + width: 3 |
| 35 | + }, |
| 36 | + 'gh_car_old_ud_ee': { |
| 37 | + color: [0, 0, 255, 0.8], // blue |
| 38 | + width: 3 |
| 39 | + }, |
| 40 | + } |
19 | 41 | }, |
20 | | - // if true there will be an option to enable the GraphHopper routing graph and the urban density visualization in the layers menu |
21 | | - routingGraphLayerAllowed: false, |
22 | | - // parameters used for the routing request generation |
23 | 42 | request: { |
24 | | - details: [ |
25 | | - 'road_class', |
26 | | - 'road_environment', |
27 | | - 'road_access', |
28 | | - 'surface', |
29 | | - 'max_speed', |
30 | | - 'average_speed', |
31 | | - 'toll', |
32 | | - 'track_type', |
33 | | - 'country', |
34 | | - ], |
| 43 | + details: ["road_class","road_environment","road_access","surface","max_speed","average_speed","toll","track_type","country"], |
| 44 | + snapPreventions: [] |
35 | 45 | }, |
36 | | - |
37 | | - // Use 'profiles' to define which profiles are visible and how. Useful if the /info endpoint contains too many or too "ugly" profile |
38 | | - // names or in the wrong order. The key of each profile will be used as name and the given fields will overwrite the fields of the |
39 | | - // default routing request. The following example is tuned towards the GraphHopper Directions API. If you have an own server you might want to adapt it. |
40 | | - // |
41 | | - // profiles: { |
42 | | - // car:{}, small_truck:{}, truck:{}, scooter:{}, |
43 | | - // foot:{ details: ['foot_network', 'access_conditional', 'foot_conditional', 'hike_rating'] }, hike:{ details: ['foot_network', 'access_conditional', 'foot_conditional', 'hike_rating' ] }, |
44 | | - // bike:{ details: ['get_off_bike', 'bike_network', 'access_conditional', 'bike_conditional', 'mtb_rating' ] }, mtb:{ details: ['get_off_bike', 'bike_network', 'access_conditional', 'bike_conditional', 'mtb_rating'] }, racingbike:{ details: ['get_off_bike', 'bike_network', 'access_conditional', 'bike_conditional', 'mtb_rating'] }, |
45 | | - // } |
46 | | - // |
47 | | - // E.g. the 'bike' entry will add a "bike" profile for which we send a request with the specified 'details' parameter. You can even change the profile itself when you specify |
48 | | - // bike: { profile: 'raw_bike', ... } |
49 | | - |
50 | | - // You can 'collapse' or group certain profiles to reduce the number of profiles in the panel. Instead they're listed in the settings but still a profile icon is shown. |
51 | | - // Note: the name of the group must be the default option for this group. |
52 | 46 | profile_group_mapping: {}, |
53 | | - // profile_group_mapping: { |
54 | | - // car: { |
55 | | - // options: [ |
56 | | - // { profile: 'car' }, |
57 | | - // { profile: 'car_avoid_motorway' }, |
58 | | - // { profile: 'car_avoid_ferry' }, |
59 | | - // { profile: 'car_avoid_toll' } |
60 | | - // ] |
61 | | - // }, |
62 | | - // bike: { |
63 | | - // options: [ |
64 | | - // { profile: 'bike' }, |
65 | | - // { profile: 'mtb' }, |
66 | | - // { profile: 'racingbike' }, |
67 | | - // { profile: 'ecargobike' } |
68 | | - // ] |
69 | | - // } |
70 | | - // } |
| 47 | + //profile_group_mapping: { |
| 48 | + // car: { |
| 49 | + // options: [ |
| 50 | + // { profile: 'car', }, |
| 51 | + // { profile: 'car_avoid_motorway' }, |
| 52 | + // { profile: 'car_avoid_ferry' }, |
| 53 | + // { profile: 'car_avoid_toll' } |
| 54 | + // ] |
| 55 | + // }, |
| 56 | + //}, |
| 57 | + // racingbike: { |
| 58 | + // options: [ |
| 59 | + // { profile: 'racingbike' }, |
| 60 | + // { profile: 'ecargobike' } |
| 61 | + // ] |
| 62 | + // }, |
| 63 | + // truck: { |
| 64 | + // options: [ |
| 65 | + // { profile: 'small_truck' }, |
| 66 | + // { profile: 'truck' } |
| 67 | + // ] |
| 68 | + // }, |
| 69 | + // foot: { |
| 70 | + // options: [ |
| 71 | + // { profile: 'foot' }, |
| 72 | + // { profile: 'hike' } |
| 73 | + // ] |
| 74 | + // } |
| 75 | + // }, |
| 76 | + profiles: { |
| 77 | + car:{}, |
| 78 | + foot:{ details: ['foot_network', 'access_conditional', 'foot_conditional', 'hike_rating'] }, |
| 79 | + bike:{ details: ['get_off_bike', 'access_conditional', 'bike_network', 'bike_conditional' ] }, |
| 80 | + } |
71 | 81 | } |
72 | | - |
73 | | -// this is needed for jest (with our current setup at least) |
74 | | -if (module) module.exports = config |
|
0 commit comments