Closed swedneck closed 2 years ago
Great suggestion, thank you! This is definitely worth being implemented.
Hey, @swedneck! Could you please take a look at the progress? Does this fix the issue?
map-machine tile -b 2.364,48.854,2.367,48.857 -s 16-19
map-machine server
var map = L.map('mapid').setView([48.8555, 2.3655], 18);
L.tileLayer('http://127.0.0.1:8080/tiles/{z}/{x}/{y}', {
maxZoom: 19,
attribution: 'Map data © ' +
'<a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> ' +
'contributors, imagery © ' +
'<a href="https:/github.com/enzet/Roentgen">Röntgen</a>',
id: 'roentgen',
tileSize: 256,
zoomOffset: 0
}).addTo(map);
Looks about perfect, the only minor niggle i can see is that -s is unintuitive for zoom levels, could -z be used?
Also, can the server command accept a port flag?
Thank you! Yeah, -s
is a shortcut for --scale
. Since in OSM terminology it's zoom level, I will rename it to -z
and --zoom
respectively. Port option was also on my todo-list. I'll create issues.
Tile generation is still slow, partially because of SVG to PNG rasterization. And there are presumably a lot of bugs.
This would make it trivial to deploy maps, which is sorely needed for the OSM ecosystem. One concern is that this could lead to excessive API usage, so maybe it should require an input file?