Skip to content

Commit

Permalink
Render Wind Turbines names, Change icon to gray, Do not render before…
Browse files Browse the repository at this point in the history
… z19 if location is rooftop (#3515)
  • Loading branch information
jeisenbe authored and kocio-pl committed Nov 24, 2018
1 parent bd0913f commit 8ba9c4a
Show file tree
Hide file tree
Showing 4 changed files with 59 additions and 50 deletions.
17 changes: 11 additions & 6 deletions amenity-points.mss
Original file line number Diff line number Diff line change
Expand Up @@ -1479,12 +1479,13 @@
marker-clip: false;
}

[feature = 'power_generator']['generator:source' = 'wind'],
[feature = 'power_generator'][power_source = 'wind'] {
[zoom >= 15] {
marker-file: url('symbols/power_wind.svg');
[feature = 'power_generator']['generator:source' = 'wind'] {
[zoom >= 15][location != 'rooftop'][location != 'roof'],
[zoom >= 15][location = null],
[zoom >= 19] {
marker-file: url('symbols/generator_wind.svg');
marker-placement: interior;
marker-fill: black;
marker-fill: @man-made-icon;
marker-clip: false;
}
}
Expand Down Expand Up @@ -1915,6 +1916,9 @@
}

[feature = 'man_made_cross'][zoom >= 17],
[feature = 'power_generator'][location != 'rooftop'][location != 'roof'][zoom >= 17],
[feature = 'power_generator'][location = null][zoom >= 17],
[feature = 'power_generator'][zoom >= 19],
[feature = 'historic_wayside_cross'][zoom >= 17],
[feature = 'historic_wayside_shrine'][zoom >= 17],
[feature = 'historic_city_gate'][zoom >= 17],
Expand All @@ -1939,6 +1943,7 @@
[feature = 'historic_wayside_cross'] {
text-dy: 6;
}
[feature = 'power_generator'],
[feature = 'historic_city_gate'],
[feature = 'man_made_mast'],
[feature = 'man_made_tower'],
Expand Down Expand Up @@ -2831,7 +2836,7 @@

[feature = 'power_plant'][is_building = 'no'][zoom >= 10],
[feature = 'power_station'][is_building = 'no'][zoom >= 10],
[feature = 'power_generator'][is_building = 'no'][zoom >= 10],
[feature = 'power_generator'][is_building = 'no']["generator:source" != 'wind'][zoom >= 10],
[feature = 'power_sub_station'][is_building = 'no'][zoom >= 13],
[feature = 'power_substation'][is_building = 'no'][zoom >= 13]{
[way_pixels > 3000],
Expand Down
14 changes: 10 additions & 4 deletions project.mml
Original file line number Diff line number Diff line change
Expand Up @@ -1488,7 +1488,7 @@ Layer:
END
ELSE NULL
END AS height,
tags->'power_source' as power_source,
tags->'location' as location,
tags->'icao' as icao,
tags->'iata' as iata,
tags->'office' as office,
Expand Down Expand Up @@ -1539,7 +1539,7 @@ Layer:
OR historic IN ('memorial', 'monument', 'archaeological_site', 'fort', 'castle', 'manor', 'city_gate')
OR military IN ('bunker')
OR highway IN ('bus_stop', 'elevator', 'traffic_signals')
OR (power = 'generator' AND (tags @> '"generator:source"=>wind' OR tags @> 'power_source=>wind'))
OR (power = 'generator' AND tags @> '"generator:source"=>wind')
ORDER BY way_area desc
) AS amenity_points_poly
properties:
Expand Down Expand Up @@ -1641,7 +1641,7 @@ Layer:
END
ELSE NULL
END AS height,
tags->'power_source' as power_source,
tags->'location' as location,
tags->'icao' as icao,
tags->'iata' as iata,
tags->'office' as office,
Expand Down Expand Up @@ -1697,7 +1697,7 @@ Layer:
OR tags @> 'emergency=>phone'
OR highway IN ('bus_stop', 'elevator', 'traffic_signals')
OR tags @> 'ford=>yes' OR tags @> 'ford=>stepping_stones'
OR (power = 'generator' AND (tags @> '"generator:source"=>wind' OR tags @> 'power_source=>wind'))
OR (power = 'generator' AND tags @> '"generator:source"=>wind')
ORDER BY score DESC NULLS LAST
) AS amenity_points
properties:
Expand Down Expand Up @@ -2123,6 +2123,8 @@ Layer:
ELSE NULL
END AS height,
tags->'operator' as operator,
tags->'generator:source' as "generator:source",
tags->'location' as location,
tags->'icao' as icao,
tags->'iata' as iata,
tags->'office' as office,
Expand Down Expand Up @@ -2229,6 +2231,8 @@ Layer:
office,
recycling_type,
"telescope:type",
"generator:source",
location,
castle_type,
sport,
information,
Expand Down Expand Up @@ -2317,6 +2321,8 @@ Layer:
"natural",
waterway,
tags->'operator' as operator,
tags->'location' as location,
tags->'generator:source' as "generator:source",
tags->'icao' as icao,
tags->'iata' as iata,
tags->'office' as office,
Expand Down
38 changes: 38 additions & 0 deletions symbols/generator_wind.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
40 changes: 0 additions & 40 deletions symbols/power_wind.svg

This file was deleted.

0 comments on commit 8ba9c4a

Please sign in to comment.