Skip to content

Commit

Permalink
Merge pull request #996 from tilezen/993-remove-props-road-merge
Browse files Browse the repository at this point in the history
Drop additional road props for z<=14
  • Loading branch information
rmarianski authored Aug 25, 2016
2 parents 3ba2d86 + e54d077 commit 4066ac4
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 2 deletions.
24 changes: 24 additions & 0 deletions integration-test/993-remove-props-road-merge.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Way: I 81 (302933871)
# http://www.openstreetmap.org/way/302933871
assert_has_feature(
14, 4496, 6381, 'roads',
{ 'id': 302933871, 'kind': 'highway', 'oneway': type(None) })

# http://www.openstreetmap.org/way/434308106
assert_has_feature(
14, 4933, 6066, 'roads',
{ 'id': 434308106, 'kind': 'path', 'crossing': type(None) })

# Way: The Embarcadero (397140734)
# http://www.openstreetmap.org/way/397140734
assert_has_feature(
14, 2621, 6331, 'roads',
{ 'name': 'The Embarcadero', 'kind': 'major_road',
'sidewalk': type(None) })

# Way: Carrie Furnace Boulevard (438362919)
# http://www.openstreetmap.org/way/438362919
assert_has_feature(
14, 4556, 6178, 'roads',
{ 'id': 438362919, 'kind': 'major_road',
'sidewalk_left': type(None), 'sidewalk_right': type(None) })
4 changes: 2 additions & 2 deletions queries.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -568,13 +568,13 @@ post_process:
where: >-
(kind == 'path' and zoom < 15) or
(kind in ['minor_road', 'major_road', 'highway', 'rail'] and zoom < 13)
# drop all oneway tags below zoom 14 (i.e: zoom >= 15) for all types.
# drop certain road properties at lower zooms
- fn: vectordatasource.transform.drop_properties
params:
source_layer: roads
start_zoom: 0
end_zoom: 14
properties: [oneway]
properties: [oneway, crossing, sidewalk, sidewalk_left, sidewalk_right]
- fn: vectordatasource.transform.drop_properties
params:
source_layer: roads
Expand Down

0 comments on commit 4066ac4

Please sign in to comment.