planetiler-openmaptiles icon indicating copy to clipboard operation
planetiler-openmaptiles copied to clipboard

Document how to add features to a built-in layer

Open zstadler opened this issue 11 months ago • 1 comments

The customizing section of the README.md has an example for adding an attribute to a built-in layer.

Please add an example of adding features to a built-in layer. For example, how to add historic=memorial OSM features to the poi layer in addition to the historic=monument features it already includes.

zstadler avatar Mar 15 '24 19:03 zstadler

The only way to do this today is to modify the filters in generated Tables.java file that define which OSM elements go into each layer, so you would replace this line in OsmPoiPoint

matchAny("historic", "monument", "castle", "ruins"),

with

matchAny("historic", "monument", "castle", "ruins", "memorial"),

Eventually when the openmaptiles profile is driven primarily by config, you'd just change your copy of the config but this is the best way right now. As a step in that direction, it might make sense for the generate script to copy openmaptiles config into this repo and read it at runtime instead of generating code from it. @phanecak-maptiler what do you think?

msbarry avatar Mar 16 '24 09:03 msbarry