kopia lustrzana https://github.com/projecthorus/chasemapper
Add OpenTopoMap
rodzic
8c284eaa31
commit
a3e241c772
|
@ -74,6 +74,7 @@ default_lon = 138.6
|
|||
payload_max_age = 180
|
||||
|
||||
# ThunderForest API Key
|
||||
# NOTE: OpenTopoMaps is now available by default, and is a good alternative to ThunderForest's outdoors map.
|
||||
# If you want to use ThunderForest's Outdoors map (Topographic maps), you will need to
|
||||
# register for an API key here: https://manage.thunderforest.com/users/sign_up?plan_id=5
|
||||
# Once you have a key, enter it below:
|
||||
|
|
|
@ -917,6 +917,7 @@ if __name__ == "__main__":
|
|||
_data_age_monitor.start()
|
||||
|
||||
# Run the Flask app, which will block until CTRL-C'd.
|
||||
logging.info("Starting Chasemapper Server on: http://%s:%d/" % (chasemapper_config['flask_host'], chasemapper_config['flask_port']))
|
||||
socketio.run(app, host=chasemapper_config['flask_host'], port=chasemapper_config['flask_port'])
|
||||
|
||||
# Close the predictor and data age monitor threads.
|
||||
|
|
|
@ -212,6 +212,11 @@
|
|||
attribution: '© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
|
||||
}).addTo(map);
|
||||
|
||||
// Add OSM Topo Map Layer
|
||||
var osm_topo_map = L.tileLayer('https://{s}.tile.opentopomap.org/{z}/{x}/{y}.png', {
|
||||
attribution: '© <a href="https://wiki.openstreetmap.org/wiki/OpenTopoMap">OpenTopoMap</a> contributors'
|
||||
}).addTo(map);
|
||||
|
||||
// Add ESRI Satellite Map layers.
|
||||
var esrimapLink =
|
||||
'<a href="http://www.esri.com/">Esri</a>';
|
||||
|
@ -224,7 +229,7 @@
|
|||
maxZoom: 18,
|
||||
});
|
||||
|
||||
var map_layers = {'OSM':osm_map, 'ESRI Satellite':esri_sat_map};
|
||||
var map_layers = {'OSM':osm_map, 'OpenTopo':osm_topo_map, 'ESRI Satellite':esri_sat_map};
|
||||
|
||||
// Add ThunderForest layers, if we have a key provided.
|
||||
if (chase_config.thunderforest_api_key !== 'none'){
|
||||
|
|
Ładowanie…
Reference in New Issue