Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Render leisure=ice_rink #3330

Merged
merged 9 commits into from
Dec 17, 2018
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions amenity-points.mss
Original file line number Diff line number Diff line change
Expand Up @@ -2045,6 +2045,7 @@
[feature = 'leisure_stadium'],
[feature = 'leisure_track'],
[feature = 'leisure_dog_park'],
[feature = 'leisure_ice_rink'],
[feature = 'leisure_pitch'] {
[zoom >= 10][way_pixels > 3000][is_building = 'no'],
[zoom >= 17][is_building = 'no'],
Expand Down Expand Up @@ -2176,6 +2177,7 @@
[feature = 'leisure_track'] {
text-fill: darken(@track, 40%);
}
[feature = 'leisure_ice_rink'],
[feature = 'leisure_pitch'] {
text-fill: darken(@pitch, 40%);
}
Expand Down
10 changes: 10 additions & 0 deletions landcover.mss
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,16 @@
}
}

[feature = 'leisure_ice_rink'] {
[zoom >= 10][way_pixels > 3000] {
polygon-fill: @glacier;
line-width: 0.5;
line-color: saturate(darken(@pitch, 30%), 20%);
[way_pixels >= 4] { polygon-gamma: 0.75; }
[way_pixels >= 64] { polygon-gamma: 0.3; }
}
}

[feature = 'leisure_dog_park'] {
[zoom >= 10] {
polygon-fill: @leisure;
Expand Down
7 changes: 4 additions & 3 deletions project.mml
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ Layer:
'recreation_ground', 'village_green', 'retail', 'industrial', 'railway', 'commercial',
'brownfield', 'landfill', 'construction', 'plant_nursery', 'religious') THEN landuse ELSE NULL END)) AS landuse,
('leisure_' || (CASE WHEN leisure IN ('swimming_pool', 'playground', 'park', 'recreation_ground', 'common', 'garden',
'golf_course', 'miniature_golf', 'sports_centre', 'stadium', 'pitch',
'golf_course', 'miniature_golf', 'sports_centre', 'stadium', 'pitch', 'ice_rink',
'track', 'dog_park', 'fitness_station') THEN leisure ELSE NULL END)) AS leisure,
('man_made_' || (CASE WHEN man_made IN ('works') THEN man_made ELSE NULL END)) AS man_made,
('military_' || (CASE WHEN military IN ('danger_area') THEN military ELSE NULL END)) AS military,
Expand All @@ -138,6 +138,7 @@ Layer:
('railway_' || (CASE WHEN railway = 'station' THEN railway ELSE NULL END)) AS railway,
CASE WHEN religion IN ('christian', 'jewish', 'muslim') THEN religion ELSE 'INT-generic'::text END AS religion,
way_area/NULLIF(!pixel_width!::real*!pixel_height!::real,0) AS way_pixels
CASE WHEN building = 'no' OR building IS NULL THEN 'no' ELSE 'yes' END AS is_building -- always no with the where conditions
jragusa marked this conversation as resolved.
Show resolved Hide resolved
jragusa marked this conversation as resolved.
Show resolved Hide resolved
FROM planet_osm_polygon
WHERE (landuse IS NOT NULL
OR leisure IS NOT NULL
Expand Down Expand Up @@ -2068,7 +2069,7 @@ Layer:
'office' || CASE WHEN tags->'office' IN ('no', 'vacant', 'closed', 'disused', 'empty') OR (tags->'office') IS NULL THEN NULL ELSE '' END,
'leisure_' || CASE WHEN leisure IN ('swimming_pool', 'water_park', 'miniature_golf', 'golf_course', 'fitness_centre', 'sports_centre', 'stadium', 'track',
'pitch', 'playground', 'park', 'recreation_ground', 'common', 'garden', 'nature_reserve', 'marina',
'picnic_table', 'dog_park', 'fitness_station', 'firepit', 'sauna', 'beach_resort', 'bowling_alley') THEN leisure ELSE NULL END,
'picnic_table', 'dog_park', 'fitness_station', 'firepit', 'sauna', 'beach_resort', 'bowling_alley', 'ice_rink') THEN leisure ELSE NULL END,
'power_' || CASE WHEN power IN ('plant', 'station', 'generator', 'sub_station', 'substation') THEN power ELSE NULL END,
'landuse_' || CASE WHEN landuse IN ('reservoir', 'basin', 'recreation_ground', 'village_green', 'quarry', 'vineyard', 'orchard', 'cemetery',
'residential', 'garages', 'meadow', 'grass', 'allotments', 'forest', 'farmyard', 'farmland',
Expand Down Expand Up @@ -2235,7 +2236,7 @@ Layer:
'office' || CASE WHEN tags->'office' IN ('no', 'vacant', 'closed', 'disused', 'empty') OR (tags->'office') IS NULL THEN NULL ELSE '' END,
'leisure_' || CASE WHEN leisure IN ('swimming_pool', 'water_park', 'miniature_golf', 'golf_course', 'fitness_centre', 'sports_centre', 'stadium', 'track',
'pitch','playground', 'park', 'recreation_ground', 'common', 'garden', 'nature_reserve', 'marina',
'slipway', 'picnic_table', 'dog_park', 'fitness_station', 'firepit', 'sauna', 'beach_resort', 'bowling_alley') THEN leisure ELSE NULL END,
'slipway', 'picnic_table', 'dog_park', 'fitness_station', 'firepit', 'sauna', 'beach_resort', 'bowling_alley', 'ice_rink') THEN leisure ELSE NULL END,
'power_' || CASE WHEN power IN ('plant', 'station', 'generator', 'sub_station', 'substation') THEN power ELSE NULL END,
'landuse_' || CASE WHEN landuse IN ('reservoir', 'basin', 'recreation_ground', 'village_green', 'quarry', 'vineyard', 'orchard', 'cemetery',
'residential', 'garages', 'meadow', 'grass', 'allotments', 'forest', 'farmyard', 'farmland',
Expand Down