Skip to content

Commit

Permalink
Add helipads. Add runways as polygons.
Browse files Browse the repository at this point in the history
  • Loading branch information
Nakaner committed Jan 16, 2023
1 parent c32e558 commit 981aee9
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 5 deletions.
7 changes: 5 additions & 2 deletions config.json
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,12 @@
"simplify_ratio": 2
},
"street_polygons": {
"minzoom": 14,
"minzoom": 11,
"maxzoom": 14,
"combine_below": 15
"combine_below": 15,
"simplify_below": 14,
"simplify_level": 0.0001,
"simplify_ratio": 2
},
"streets_polygons_labels": {
"minzoom": 14,
Expand Down
13 changes: 10 additions & 3 deletions process.lua
Original file line number Diff line number Diff line change
Expand Up @@ -210,9 +210,12 @@ function process_public_transport_layer(obj, is_area)
elseif aerialway == "station" then
kind = "aerialway_station"
mz = 13
else
kind = obj:Find("aeroway")
elseif aeroway == "aerodrome" then
kind = aeroway
mz = 11
elseif aeroway == "helipad" then
kind = aeroway
mz = 13
end
if is_area then
obj:LayerAsCentroid("public_transport")
Expand Down Expand Up @@ -722,13 +725,17 @@ end

function process_street_polygons(way)
local highway = way:Find("highway")
local aeroway = way:Find("aeroway")
local surface = way:Find("surface")
local service = way:Find("service")
local kind = nil
local mz = inf_zoom
if highway == "pedestrian" or highway == "service" then
mz = 14
kind = highway
elseif aeroway == "runway" then
mz = 11
kind = aeroway
end
if mz < inf_zoom then
way:Layer("street_polygons", true)
Expand Down Expand Up @@ -862,7 +869,7 @@ function way_function(way)
end

-- Layer street_polygons, street_polygons_labels
if is_area_default_linear and way:Holds("highway") then
if is_area_default_linear and (way:Holds("highway") or way:Holds("aeroway")) then
process_street_polygons(way)
end

Expand Down

0 comments on commit 981aee9

Please sign in to comment.