summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Baines <cbaines8@gmail.com>2013-12-27 13:10:49 +0000
committerChristopher Baines <cbaines8@gmail.com>2013-12-27 13:10:49 +0000
commit9eec6520509399c6b1c7e5ebde1ee05876e4232e (patch)
tree6e0312bf0c2d38dde2b5f74eebc8077fd3dd1f3c
parent5eff992956b78b539c5fb1562a4692c065878fd4 (diff)
downloadsum-carto-9eec6520509399c6b1c7e5ebde1ee05876e4232e.tar
sum-carto-9eec6520509399c6b1c7e5ebde1ee05876e4232e.tar.gz
Better trees from the osmfr style
https://github.com/cquest/osmfr-cartocss.git
-rwxr-xr-xlandcover.mss16
-rwxr-xr-xproject.mml5
2 files changed, 12 insertions, 9 deletions
diff --git a/landcover.mss b/landcover.mss
index 642662e..33214de 100755
--- a/landcover.mss
+++ b/landcover.mss
@@ -101,12 +101,14 @@
}
#trees {
- [zoom >= 16] {
- point-file: url('symbols/tree.png');
- point-ignore-placement: true;
- point-placement: interior;
- [zoom >= 17] {
- point-file: url('symbols/tree2.png');
+ image-filters: agg-stack-blur(1,1);
+ [type='poly'] {
+ polygon-fill: green;
+ polygon-opacity: 0.3;
+ }
+ [zoom>=19][type='point'] {
+ marker-fill: #b27f36;
+ marker-width: 3;
+ marker-height: 3;
}
- }
}
diff --git a/project.mml b/project.mml
index f3e739c..d8a8e5d 100755
--- a/project.mml
+++ b/project.mml
@@ -40,7 +40,8 @@
"id": "coast-poly",
"class": "",
"Datasource": {
- "file": "data/processed_p/processed_p.shp"
+ "file": "data/processed_p/processed_p.shp",
+ "type": "shape"
},
"srs-name": "900913",
"srs": "+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0.0 +k=1.0 +units=m +nadgrids=@null +wktext +no_defs +over",
@@ -83,7 +84,7 @@
],
"Datasource": {
"type": "postgis",
- "table": "(select way,\"natural\" from planet_osm_point where \"natural\"='tree') as trees",
+ "table": "(select st_buffer(st_collect(way),3) as way, 'poly' as type from planet_osm_point where \"natural\"='tree' AND way && !bbox! UNION select way, 'point' as type from planet_osm_point where \"natural\"='tree' AND way && !bbox! union select st_buffer(st_collect(way),3) as way, 'poly' as type from planet_osm_line where \"natural\"='tree_row' and way && !bbox! ) as trees",
"key_field": "",
"geometry_field": "",
"extent_cache": "auto",