[HN Gopher] A new way to make maps with OpenStreetMap ___________________________________________________________________ A new way to make maps with OpenStreetMap Author : hampelm Score : 173 points Date : 2021-04-23 19:28 UTC (3 hours ago) (HTM) web link (protomaps.com) (TXT) w3m dump (protomaps.com) | brunoqc wrote: | > Pricing | | > coming soon... | kennydude wrote: | At least it's open source and self hostable so if it's too | expensive for you, you can host it yourself | mourner wrote: | This is very nice! Happy to see a few of my libraries in the | dependencies :) | | Also check out https://github.com/kothic/kothic-js, an older but | similar attempt at making a full-fledged map renderer using 2D | Canvas. It has a pretty good label rendering in particular which | you might find useful. | xrd wrote: | This looks great. | | I am super excited about the parent tool, but unsure | whether/when I can generate these bundles programmatically. I | tried the web based tool and it works great, but what if I need | to do it many, many times? | | Can your tool do this easily? Is there a way to generate tiles | (tiles.pmtiles) that are imported in the same way? | | If I had stumbled on your project, I would not have been | enthusiastic about it with just the writeup as-is. Seeing the | parent project makes me see the possibilities: a completely | independent mapping solution, free of any server/service tie in | and additional costs. That is super exciting, and I would love | to know if and how your project compares. | iandanforth wrote: | Very interesting, I'm currently using Google My Maps as a dead- | simple custom mapping tool. I'm using it to collect layers of | information as I conduct a nationwide housing search. It would be | great if there were a solution that was as simple to get started | with as My Maps but also had the flexibility to easily add custom | data layers programmatically. | loa_in_ wrote: | > It would be great if there were a solution that was as simple | to get started with as My Maps but also had the flexibility to | easily add custom data layers programmatically. | | I believe _with some trickery_ you can use Google Earth for | that | wizzwizz4 wrote: | The computer version, not the web version, right? | jMyles wrote: | Curious about your tool chain for real estate metadata. Is | there a way to get a more retail-like experience and not have | to deal so much with agents? | DoreenMichele wrote: | I'm curious what sorts of data you are collecting and how it | helps to have it in map form rather than some other file | format. | Tomte wrote: | > Existing formats like MBTiles are based on SQLite. This limits | the ability to self-host maps to those confident running a server | in production. | | Is that comical, or is there a deeper meaning I don't understand? | [deleted] | jleedev wrote: | For comparison, Cloud Optimized GeoTIFF (COG) is specifically | designed to be readable with HTTP Range requests, so the single | file can be placed on S3 and be immediately usable. | | As others pointed out, the MVTs inside can be unpacked for | static serving. But a SQLite database is not itself usable in | this way. | rakoo wrote: | AFAIU MBTiles still need some application server to transform | x/y/z into proper tiles to be served, which means provisioning | a server, scaling it, maintaning it, and all the fun that comes | with it; PMTiles is a simple blob that the frontend will | download (only desired parts) and render directly in the | browser. | alohec wrote: | You can use tippecanoe (https://github.com/mapbox/tippecanoe) | with the --output-to-directory flag to output the individual | .pbf tiles instead of a single MBTiles file. These tiles can | then be hosted on something like s3 and your map-rendering | client can query the necessary tiles, no server required. | incanus77 wrote: | Originally, MBTiles was designed for mobile offline. Then, | Mapbox started serving directly from the SQLite for web & other | clients, creating the Node.js SQLite bindings in the process. | Eventually, they had an unpacker for MBTiles uploads that would | stick the tiles in CDN. So, really no more complex than old | school static content hosting. | | Source: I created MBTiles ;-) | leokennis wrote: | I read it as: existing solutions are too hard for simple people | with less technical skill. | [deleted] | codetrotter wrote: | Probably what they mean is that they want to be able to host | the maps as static files that are served to the web. | | So that you can FTP some html, js, css, images and map data | files to a web host and call it a day. | alwayshumans wrote: | You can already host vector tiles within S3 that work with Mapbox | and other libraries. | | Not really sure what problem this is trying to solve. | xrd wrote: | Is this a simple process? Can you share a link to how this is | done, I'm interested. I always assumed it was fairly | complicated. | alohec wrote: | At least for simple GeoJSON you can use tippecanoe | (https://github.com/mapbox/tippecanoe) with --output-to- | directory to get individual .pbf tiles. Most rendering | clients will have some scheme where you can provide a root | url and then the tiles need to be stored in some defined | structure beneath that (e.g. root/z/x/y.pbf) | | (posted something similar to another response) | gorbypark wrote: | I've used the utility tippecanoe with success to generate | vector tiles from geojson sources and am hosting them | statically. It's been overall pretty easy. The only gotcha I | can remember is I needed to pass the no compression flag | since mapbox gl can't read compressed tiles (and the file | host will gzip everything anyways). | worace wrote: | The typical way to build and distribute Mapbox vector tiles has | been by packing them into a sqlite database with individual | rows for each Z/X/Y quad tree coordinate. This is what tools | like tippecanoe typically produce. | | The problem with this is it still requires a running server | process colocated with that sqlite db in order to service | requests for individual tiles, like what you'll receive from a | client-side mapping library. | | This project has a lot of different parts, but one of them is a | spec for serving this type of data at low latency without a | server by combining a custom packing format with S3 range-get | requests to read individual tiles direct from blob storage. So | that is certainly interesting for this kind of use-case. | tppiotrowski wrote: | Super excited for your project. I have been using map tiles from | Mapbox, MapTiler, OSM Buildings for my project and am coming to | the point that I need to merge elevation data with building | height data in order to cast realistic shadows across the earth. | Unfortunately elevation data and building data come from two | different tile sets from two different tile providers and it's a | lot of download/processing overhead to merge the two data | sources. I need to make my own tiles! | | I spent part of today on the OSM wiki trying to wrap my head | around Mapnik, how tiles are generated, how I am going to host | this cheaply because my project is non-commercial, and then the | HN gods smiled on me. Thank you for taking this on and I'm coming | along for this journey! | gorbypark wrote: | I've had success using tippecanoe to generate mvt tiles from | geojson sources, which in turn came from various sources (osm | and otherwise) from QGIS. I didn't look into this project too | much but it appears to be bundling mvt tiles into a single | file? Either way, straight up mvt tiles are easy to generate | and can be easily hosted statically on any web server/s3 | bucket/cdn. | tppiotrowski wrote: | Thanks for sharing your experience. Much of this vocabulary | is still foreign to me but you've given me some the relevant | keywords to Google. | | One of the main challenges when entering a highly specialised | field is finding the vocabulary to express yourself. | schoenobates wrote: | I'd also recommend having a look at | https://openmaptiles.org/. They have workflows and editors | for working with MVT and Maplibre. You can combine a base | map from maplibre with other sources using Openlayers [0] | | [0]: https://openlayers.org/en/latest/examples/mapbox- | layer.html | TurkishPoptart wrote: | What kind of project can this tool be used for? | c0nsumer wrote: | This is really interesting to me. I do a lot of mapping of | natural surface single track trails (for hiking and mountain | biking) along the way be sure to properly name things, add | intersection markers, and create relations (routes and | superroutes) to document the systems. | | The biggest downside thus far is a good way of displaying the | data. mtb.waymarkedtrails.org gets close, but I'd really like | something that displays relations in the specified color, has | sane intersection markers, etc. | | I feel like there should be something out there which effectively | lets me design a style sheet and then apply it to a map which I | embed somewhere (maybe even in an app). | | This... feels like it? Or if not this, can any of you recommend | another system? | | Ideally I'd love something I can self-host. I tried getting a | copy of waymarkedtrails going and then modifying that, but it's a | bit too specialized and I kept running into quirks getting the | toolchain set up. | | EDIT: Looks like this might not include the highway=path data | that I need, much relations. Alas. | ourguile wrote: | Have you used GaiaGPS at all? I use it along with ridewithgps | for looking at trail conditions and mapping points of interest | on my rides and hikes. You can import your own custom map | layers as well. | | The developers are fairly consistently adding new content as | well, might not hurt to reach out. ___________________________________________________________________ (page generated 2021-04-23 23:00 UTC)