From 921d7d5fd0a424c34ecdf8e0171152fefdf0fe8c Mon Sep 17 00:00:00 2001 From: Paul Norman Date: Sat, 28 Mar 2020 22:22:18 -0700 Subject: [PATCH 1/5] Remove rendering of residential & unclassified highway areas --- project.mml | 8 ++++---- style/roads.mss | 4 ---- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/project.mml b/project.mml index d4d80a4194..12d828b11a 100644 --- a/project.mml +++ b/project.mml @@ -642,7 +642,7 @@ 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', 'service', 'footway', 'cycleway', 'track', 'path', '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) @@ -650,7 +650,7 @@ Layer: THEN railway END)) ) AS feature FROM planet_osm_polygon - WHERE highway IN ('residential', 'unclassified', 'pedestrian', 'service', 'footway', 'track', 'path', 'platform') + WHERE highway IN ('pedestrian', 'service', 'footway', 'cycleway', 'track', 'path', '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) @@ -764,7 +764,7 @@ Layer: (SELECT way, COALESCE( - ('highway_' || (CASE WHEN highway IN ('residential', 'unclassified', 'pedestrian', 'service', 'footway', 'cycleway', 'living_street', + ('highway_' || (CASE WHEN highway IN ('pedestrian', 'service', 'footway', 'cycleway', 'living_street', 'track', 'path', 'platform', 'services') THEN highway END)), ('railway_' || (CASE WHEN (railway IN ('platform') AND (tags->'location' NOT IN ('underground') OR (tags->'location') IS NULL) @@ -774,7 +774,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', 'service', 'footway', 'cycleway', 'living_street', 'track', 'path', '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) diff --git a/style/roads.mss b/style/roads.mss index 5ccc85dbc2..ae8405b221 100644 --- a/style/roads.mss +++ b/style/roads.mss @@ -2570,8 +2570,6 @@ 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; @@ -2613,8 +2611,6 @@ 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; From 0a3d4dcfbbc74141439de3b1ec3353393a651c5d Mon Sep 17 00:00:00 2001 From: Paul Norman Date: Sun, 29 Mar 2020 18:12:33 -0700 Subject: [PATCH 2/5] Remove rendering of more highway areas These are also mainly inappropriately used where area:highway could be used instead. --- project.mml | 10 +++++----- style/roads.mss | 22 ++-------------------- 2 files changed, 7 insertions(+), 25 deletions(-) diff --git a/project.mml b/project.mml index 12d828b11a..09655bcd33 100644 --- a/project.mml +++ b/project.mml @@ -642,7 +642,7 @@ Layer: (SELECT way, COALESCE(( - 'highway_' || (CASE WHEN highway IN ('pedestrian', 'service', 'footway', 'cycleway', 'track', 'path', 'platform') THEN highway END)), + 'highway_' || (CASE WHEN highway IN ('pedestrian', '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) @@ -650,7 +650,7 @@ Layer: THEN railway END)) ) AS feature FROM planet_osm_polygon - WHERE highway IN ('pedestrian', 'service', 'footway', 'cycleway', 'track', 'path', 'platform') + WHERE highway IN ('pedestrian', '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) @@ -764,8 +764,8 @@ Layer: (SELECT way, COALESCE( - ('highway_' || (CASE WHEN highway IN ('pedestrian', 'service', 'footway', 'cycleway', 'living_street', - 'track', 'path', 'platform', 'services') THEN highway END)), + ('highway_' || (CASE WHEN highway IN ('pedestrian', '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) @@ -774,7 +774,7 @@ Layer: (('aeroway_' || CASE WHEN aeroway IN ('runway', 'taxiway', 'helipad') THEN aeroway END)) ) AS feature FROM planet_osm_polygon - WHERE highway IN ('pedestrian', 'service', 'footway', 'cycleway', 'living_street', 'track', 'path', 'platform', 'services') + WHERE highway IN ('pedestrian', '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) diff --git a/style/roads.mss b/style/roads.mss index ae8405b221..a7982be702 100644 --- a/style/roads.mss +++ b/style/roads.mss @@ -2577,24 +2577,13 @@ tertiary is rendered from z10 and is not included in osm_planet_roads. */ } } - [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] { @@ -2617,19 +2606,12 @@ tertiary is rendered from z10 and is not included in osm_planet_roads. */ } } - [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] { From 31f46c499dcb363781822f37636b11561aa2f052 Mon Sep 17 00:00:00 2001 From: Paul Norman Date: Sat, 4 Apr 2020 18:49:03 -0700 Subject: [PATCH 3/5] Remove some roads from roads-area-text-name This keeps the layer consistent with the changes to the fills. --- project.mml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/project.mml b/project.mml index 09655bcd33..0a36d7f764 100644 --- a/project.mml +++ b/project.mml @@ -1758,7 +1758,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', '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) From 63554ebf7fbcde903a4b8a7ddd9175b96da69fc4 Mon Sep 17 00:00:00 2001 From: Paul Norman Date: Thu, 9 Apr 2020 19:20:38 -0700 Subject: [PATCH 4/5] Restore highway=footway area rendering --- project.mml | 8 ++++---- style/roads.mss | 2 ++ 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/project.mml b/project.mml index 0a36d7f764..03f2938e27 100644 --- a/project.mml +++ b/project.mml @@ -642,7 +642,7 @@ Layer: (SELECT way, COALESCE(( - 'highway_' || (CASE WHEN highway IN ('pedestrian', 'service', '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) @@ -650,7 +650,7 @@ Layer: THEN railway END)) ) AS feature FROM planet_osm_polygon - WHERE highway IN ('pedestrian', 'service', '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) @@ -764,7 +764,7 @@ Layer: (SELECT way, COALESCE( - ('highway_' || (CASE WHEN highway IN ('pedestrian', 'service', 'living_street', + ('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) @@ -774,7 +774,7 @@ Layer: (('aeroway_' || CASE WHEN aeroway IN ('runway', 'taxiway', 'helipad') THEN aeroway END)) ) AS feature FROM planet_osm_polygon - WHERE highway IN ('pedestrian', 'service', 'living_street', '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) diff --git a/style/roads.mss b/style/roads.mss index a7982be702..817bce10b3 100644 --- a/style/roads.mss +++ b/style/roads.mss @@ -2577,6 +2577,7 @@ tertiary is rendered from z10 and is not included in osm_planet_roads. */ } } + [feature = 'highway_footway'], [feature = 'highway_pedestrian'] { [zoom >= 15] { line-color: grey; @@ -2606,6 +2607,7 @@ tertiary is rendered from z10 and is not included in osm_planet_roads. */ } } + [feature = 'highway_footway'], [feature = 'highway_pedestrian'] { [zoom >= 15] { polygon-fill: @pedestrian-fill; From 67df615f2fb6e488c077fd42389c9cb6d81f94c7 Mon Sep 17 00:00:00 2001 From: Paul Norman Date: Sat, 11 Apr 2020 13:21:24 -0700 Subject: [PATCH 5/5] Restore footway area names --- project.mml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/project.mml b/project.mml index 03f2938e27..e089df0409 100644 --- a/project.mml +++ b/project.mml @@ -1758,7 +1758,7 @@ Layer: name FROM planet_osm_polygon WHERE way && !bbox! - AND (highway IN ('pedestrian', 'service', 'living_street', '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)