Skip to content

Commit

Permalink
Merge pull request #4096 from pnorman/drop_minor_road_areas
Browse files Browse the repository at this point in the history
Remove rendering of residential, unclassified, cycleway, footway, path highway areas
  • Loading branch information
pnorman committed Apr 15, 2020
2 parents ff5c6a7 + 67df615 commit bd22cf5
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 28 deletions.
12 changes: 6 additions & 6 deletions project.mml
Original file line number Diff line number Diff line change
Expand Up @@ -643,15 +643,15 @@ Layer:
(SELECT
way,
COALESCE((
'highway_' || (CASE WHEN highway IN ('residential', 'unclassified', 'pedestrian', 'service', 'footway', 'cycleway', 'track', 'path', 'platform') THEN highway END)),
'highway_' || (CASE WHEN highway IN ('pedestrian', 'footway', 'service', 'platform') THEN highway END)),
('railway_' || (CASE WHEN (railway IN ('platform')
AND (tags->'location' NOT IN ('underground') OR (tags->'location') IS NULL)
AND (tunnel NOT IN ('yes', 'building_passage') OR tunnel IS NULL)
AND (covered NOT IN ('yes') OR covered IS NULL))
THEN railway END))
) AS feature
FROM planet_osm_polygon
WHERE highway IN ('residential', 'unclassified', 'pedestrian', 'service', 'footway', 'track', 'path', 'platform')
WHERE highway IN ('pedestrian', 'footway', 'service', 'platform')
OR (railway IN ('platform')
AND (tags->'location' NOT IN ('underground') OR (tags->'location') IS NULL)
AND (tunnel NOT IN ('yes', 'building_passage') OR tunnel IS NULL)
Expand Down Expand Up @@ -765,8 +765,8 @@ Layer:
(SELECT
way,
COALESCE(
('highway_' || (CASE WHEN highway IN ('residential', 'unclassified', 'pedestrian', 'service', 'footway', 'cycleway', 'living_street',
'track', 'path', 'platform', 'services') THEN highway END)),
('highway_' || (CASE WHEN highway IN ('pedestrian', 'footway', 'service', 'living_street',
'platform', 'services') THEN highway END)),
('railway_' || (CASE WHEN (railway IN ('platform')
AND (tags->'location' NOT IN ('underground') OR (tags->'location') IS NULL)
AND (tunnel NOT IN ('yes', 'building_passage') OR tunnel IS NULL)
Expand All @@ -775,7 +775,7 @@ Layer:
(('aeroway_' || CASE WHEN aeroway IN ('runway', 'taxiway', 'helipad') THEN aeroway END))
) AS feature
FROM planet_osm_polygon
WHERE highway IN ('residential', 'unclassified', 'pedestrian', 'service', 'footway', 'living_street', 'track', 'path', 'platform', 'services')
WHERE highway IN ('pedestrian', 'footway', 'service', 'living_street', 'platform', 'services')
OR (railway IN ('platform')
AND (tags->'location' NOT IN ('underground') OR (tags->'location') IS NULL)
AND (tunnel NOT IN ('yes', 'building_passage') OR tunnel IS NULL)
Expand Down Expand Up @@ -1785,7 +1785,7 @@ Layer:
name
FROM planet_osm_polygon
WHERE way && !bbox!
AND (highway IN ('residential', 'unclassified', 'pedestrian', 'service', 'footway', 'cycleway', 'living_street', 'track', 'path', 'platform')
AND (highway IN ('pedestrian', 'footway', 'service', 'living_street', 'platform')
OR (railway IN ('platform')
AND (tags->'location' NOT IN ('underground') OR (tags->'location') IS NULL)
AND (tunnel NOT IN ('yes', 'building_passage') OR tunnel IS NULL)
Expand Down
24 changes: 2 additions & 22 deletions style/roads.mss
Original file line number Diff line number Diff line change
Expand Up @@ -2570,33 +2570,21 @@ tertiary is rendered from z10 and is not included in osm_planet_roads. */
}

#highway-area-casing {
[feature = 'highway_residential'],
[feature = 'highway_unclassified'],
[feature = 'highway_service'] {
[zoom >= 14] {
line-color: #999;
line-width: 1;
}
}

[feature = 'highway_pedestrian'],
[feature = 'highway_footway'],
[feature = 'highway_cycleway'],
[feature = 'highway_path'] {
[feature = 'highway_pedestrian'] {
[zoom >= 15] {
line-color: grey;
line-width: 1;
}
}

[feature = 'highway_track'][zoom >= 15] {
line-color: @track-fill;
line-width: 1;
line-dasharray: 5,4,2,4;
line-cap: round;
line-join: round;
}

[feature = 'highway_platform'],
[feature = 'railway_platform'] {
[zoom >= 16] {
Expand All @@ -2613,27 +2601,19 @@ tertiary is rendered from z10 and is not included in osm_planet_roads. */
polygon-fill: @living-street-fill;
}

[feature = 'highway_residential'],
[feature = 'highway_unclassified'],
[feature = 'highway_service'] {
[zoom >= 14] {
polygon-fill: #fff;
}
}

[feature = 'highway_pedestrian'],
[feature = 'highway_footway'],
[feature = 'highway_cycleway'],
[feature = 'highway_path'] {
[feature = 'highway_pedestrian'] {
[zoom >= 15] {
polygon-fill: @pedestrian-fill;
}
}

[feature = 'highway_track'][zoom >= 15] {
polygon-fill: #cdbea0;
}

[feature = 'highway_platform'],
[feature = 'railway_platform'] {
[zoom >= 16] {
Expand Down

0 comments on commit bd22cf5

Please sign in to comment.