Closed westnordost closed 1 year ago
It looks fine, but can you please use ??
instead of ||
in case you need to add a fallback value to a number | undefined
? In this particular case it probably doesn't matter, but this is just so that this code fits the general code style. Thank you.
Also, keep in mind that this code probably won't be used for long. I'm going to migrate to self-hosted tiles soon, and all the logic for handling tags on the frontend will get simplified as quite a lot of stuff can be parsed/calculated on the backend during the tile generation process. See https://github.com/StrandedKitty/planetiler
and all the logic for handling tags on the frontend will get simplified as quite a lot of stuff can be parsed/calculated on the backend during the tile generation process. See https://github.com/StrandedKitty/planetiler
Is it really necessary to fork it? I would have thought that what gets put into the vector tiles would be configurable through some scriptable configuration. After all, pretty much every commercial vector tile service (MapTiler, Thunderforest, jawg.io, MapBox, ...) has a different schema with different names etc.
Is it really necessary to fork it? I would have thought that what gets put into the vector tiles would be configurable through some scriptable configuration. After all, pretty much every commercial vector tile service (MapTiler, Thunderforest, jawg.io, MapBox, ...) has a different schema with different names etc.
Existing schemas don't really suit 3D applications, they are meant for 2D rendering. In the readme of my fork there's a list of the most substancial changes that were made. It's not possible to implement them by just modifying some config.
@westnordost Thank you, I will transfer your height calculation logic to the Planetiler fork soon.
Estimate tree height based on
est_height
,crown_diameter
,diameter
orcircumference
ifheight
is not available.Also, correctly subtract
min_height
fromheight
orest_height
.