-
-
Notifications
You must be signed in to change notification settings - Fork 119
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
368 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 3 additions & 1 deletion
4
...ustommap/src/main/java/com/onthegomap/planetiler/custommap/configschema/FeatureLayer.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,10 @@ | ||
package com.onthegomap.planetiler.custommap.configschema; | ||
|
||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
import java.util.Collection; | ||
|
||
public record FeatureLayer( | ||
String id, | ||
Collection<FeatureItem> features | ||
Collection<FeatureItem> features, | ||
@JsonProperty("tile_post_process") PostProcess postProcess | ||
) {} |
9 changes: 9 additions & 0 deletions
9
...mmap/src/main/java/com/onthegomap/planetiler/custommap/configschema/MergeLineStrings.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
package com.onthegomap.planetiler.custommap.configschema; | ||
|
||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
|
||
public record MergeLineStrings( | ||
@JsonProperty("min_length") double minLength, | ||
@JsonProperty("tolerance") double tolerance, | ||
@JsonProperty("buffer") double buffer | ||
) {} |
7 changes: 7 additions & 0 deletions
7
...stommap/src/main/java/com/onthegomap/planetiler/custommap/configschema/MergePolygons.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
package com.onthegomap.planetiler.custommap.configschema; | ||
|
||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
|
||
public record MergePolygons( | ||
@JsonProperty("min_area") double minArea | ||
) {} |
8 changes: 8 additions & 0 deletions
8
...custommap/src/main/java/com/onthegomap/planetiler/custommap/configschema/PostProcess.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
package com.onthegomap.planetiler.custommap.configschema; | ||
|
||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
|
||
public record PostProcess( | ||
@JsonProperty("merge_line_strings") MergeLineStrings mergeLineStrings, | ||
@JsonProperty("merge_polygons") MergePolygons mergePolygons | ||
) {} |
43 changes: 43 additions & 0 deletions
43
planetiler-custommap/src/main/resources/samples/railways.yml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
schema_name: Railways | ||
schema_description: Railways (layers outputting merged & un-merged lines) | ||
attribution: <a href="https://www.openstreetmap.org/copyright" target="_blank">© OpenStreetMap contributors</a> | ||
args: | ||
area: | ||
description: Geofabrik area to download | ||
default: greater-london | ||
osm_url: | ||
description: OSM URL to download | ||
default: '${ args.area == "planet" ? "aws:latest" : ("geofabrik:" + args.area) }' | ||
sources: | ||
osm: | ||
type: osm | ||
url: '${ args.osm_url }' | ||
layers: | ||
- id: railways_merged | ||
features: | ||
- source: osm | ||
geometry: line | ||
min_zoom: 4 | ||
min_size: 0 | ||
include_when: | ||
__all__: | ||
- railway: rail | ||
- usage: main | ||
exclude_when: | ||
service: __any__ | ||
tile_post_process: | ||
merge_line_strings: | ||
min_length: 0 | ||
tolerance: -1 | ||
buffer: -1 | ||
- id: railways_unmerged | ||
features: | ||
- source: osm | ||
geometry: line | ||
min_zoom: 4 | ||
include_when: | ||
__all__: | ||
- railway: rail | ||
- usage: main | ||
exclude_when: | ||
service: __any__ |
Oops, something went wrong.