source: subversion/applications/rendering/mapnik/inc/layer-buildings.xml.inc @ 27566

Last change on this file since 27566 was 27515, checked in by ldp, 8 years ago

Convert & bump to mapnik 2.0.0 syntax. Stick with r27279 as final 0.7.x version.

File size: 3.1 KB
Line 
1<Style name="buildings-lz">
2    <Rule>
3      <Filter>[railway] = 'station' or [building] = 'station'</Filter>
4      &maxscale_zoom10;
5      <PolygonSymbolizer fill="#d4aaaa"/>
6    </Rule>
7    <Rule>
8      <Filter>[building] = 'supermarket'</Filter>
9      &maxscale_zoom10;
10      <PolygonSymbolizer fill-opacity="0.5" fill="pink"/>
11    </Rule>
12    <Rule>
13      <Filter>[amenity] = 'place_of_worship'</Filter>
14      &maxscale_zoom10;
15      &minscale_zoom14;
16      <PolygonSymbolizer fill-opacity="0.5" fill="#777"/>
17    </Rule>
18    <Rule>
19      <Filter>[amenity] = 'place_of_worship'</Filter>
20      &maxscale_zoom15;
21      <PolygonSymbolizer fill-opacity="0.9" fill="#aaa"/>
22      <LineSymbolizer stroke="#111" stroke-width="0.3"/>
23    </Rule>
24</Style>
25
26<Style name="buildings">
27    <Rule>
28      <Filter>[building] = 'INT-light'</Filter>
29      &maxscale_zoom12;
30      <PolygonSymbolizer fill-opacity="0.7" fill="#bca9a9"/>
31    </Rule>
32    <Rule>
33      <Filter>[building] != 'INT-light' and [building] != ''</Filter>
34      &maxscale_zoom12;
35      <PolygonSymbolizer fill-opacity="0.9" fill="#bca9a9"/>
36    </Rule>
37    <Rule>
38      <Filter>[building] != 'INT-light' and [building] != ''</Filter>
39      &maxscale_zoom16;
40      <LineSymbolizer stroke="#330066" stroke-width="0.2"/>
41    </Rule>
42    <Rule>
43      <Filter>[aeroway] = 'terminal'</Filter>
44      &maxscale_zoom12;
45      <PolygonSymbolizer fill="#cc99ff"/>
46    </Rule>
47    <Rule>
48      <Filter>[aeroway] = 'terminal'</Filter>
49      &maxscale_zoom14;
50      <LineSymbolizer stroke="#330066" stroke-width="0.2"/>
51    </Rule>
52</Style>
53
54<!-- Render only select building types starting at z10. -->
55<Layer name="buildings-lz" status="on" srs="&osm2pgsql_projection;">
56    <StyleName>buildings-lz</StyleName>
57    <Datasource>
58      <Parameter name="table">
59      (select way,building,railway,amenity from &prefix;_polygon
60       where railway='station'
61          or building in ('station','supermarket')
62          or amenity='place_of_worship'
63       order by z_order,way_area desc) as buildings
64      </Parameter>
65      &datasource-settings;
66    </Datasource>
67</Layer>
68
69<!-- Render the other building types. Some sql filtering is needed to exclude
70     any type not already specifically rendered in buildings-lz. -->
71<Layer name="buildings" status="on" srs="&osm2pgsql_projection;">
72    <StyleName>buildings</StyleName>
73    <Datasource>
74      <Parameter name="table">
75      (select way,aeroway,
76        case
77         when building in ('residential','house','garage','garages','detached','terrace','apartments') then 'INT-light'::text
78         else building
79        end as building
80       from &prefix;_polygon
81       where (building is not null
82         and building not in ('no','station','supermarket')
83         and (railway is null or railway != 'station')
84         and (amenity is null or amenity != 'place_of_worship'))
85          or aeroway = 'terminal'
86       order by z_order,way_area desc) as buildings
87      </Parameter>
88      &datasource-settings;
89    </Datasource>
90</Layer>
91
92
Note: See TracBrowser for help on using the repository browser.