forked from Zverik/veloroad
-
Notifications
You must be signed in to change notification settings - Fork 1
/
project.mml
764 lines (764 loc) · 32.5 KB
/
project.mml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
{
"bounds": [
28.1799,
59.3332,
30.7178,
60.1579
],
"center": [
29.6191,
59.7619,
7
],
"format": "png8",
"interactivity": false,
"minzoom": 6,
"maxzoom": 22,
"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",
"Stylesheet": [
"style.mss",
"places.mss",
"roads.mss",
"contours.mss",
"nature.mss",
"rails.mss",
"buildings.mss"
],
"Layer": [
{
"extent": [
22.71561208176848,
51.024301313540015,
32.79624694636674,
56.36838768819846
],
"Datasource": {
"type": "postgis",
"table": "(select way,place,coalesce(\"name:be\", name) AS name from planet_osm_polygon where place in ('village', 'town', 'city', 'hamlet', 'isolated_dwelling')) as placep",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "2528690.37,6625593.47,3650861.51,7632103.5",
"dbname": "gis"
},
"id": "placep",
"class": "",
"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",
"advanced": {},
"name": "placep",
"geometry": "polygon"
},
{
"extent": [
20.67154065835024,
53.83894644201676,
41.64409284452203,
63.124710468885965
],
"Datasource": {
"type": "postgis",
"table": "(select way from planet_osm_polygon where \"natural\"='wood' or landuse = 'forest' or leisure='park') as forest",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "-20037508.34,-20037508.34,20037508.34,20037508.34",
"dbname": "gis"
},
"id": "forest",
"class": "",
"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",
"advanced": {},
"name": "forest"
},
{
"extent": [
-179.9999999749438,
-85.051,
179.9999999749438,
85.051
],
"Datasource": {
"type": "postgis",
"table": "(select way from planet_osm_polygon where landuse in ('residential', 'commercial', 'industrial', 'farmyard') or amenity is not null or power is not null) as landuse",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "-20037508.34,-20037508.34,20037508.34,20037508.34",
"dbname": "gis"
},
"id": "residential",
"class": "",
"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",
"advanced": {},
"name": "residential"
},
{
"geometry": "polygon",
"extent": [
7.292175469141206,
46.769969165920045,
32.79624694636674,
56.36838768819846
],
"Datasource": {
"type": "postgis",
"table": "(SELECT\n way,\nCASE WHEN \"natural\" IN ('marsh', 'mud') THEN \"natural\" ELSE wetland END AS int_wetland\nFROM planet_osm_polygon\n WHERE \"natural\" IN ('marsh', 'mud', 'wetland')\nAND building IS NULL\nAND way_area > 0.01*!pixel_width!::real*!pixel_height!::real\nORDER BY z_order, way_area DESC\n) AS water_areas_overlay",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "811761.26,5904607.68,3650861.51,7632103.5",
"dbname": "gis"
},
"id": "water-areas-overlay",
"class": "",
"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",
"advanced": {},
"name": "water-areas-overlay"
},
{
"geometry": "linestring",
"extent": [
22.467556599271887,
49.10078991480273,
33.24694070756235,
56.36710850981006
],
"Datasource": {
"type": "postgis",
"table": "(select way,waterway,coalesce(\"name:be\", name) AS name,ST_Length(way) as length from planet_osm_line where waterway in ('stream', 'river','drain','ditch','canal') and tunnel is null) as rivers",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "2501076.96,6291980.67,3701032.51,7631846.4",
"dbname": "gis"
},
"id": "rivers",
"class": "",
"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",
"advanced": {},
"name": "rivers"
},
{
"geometry": "polygon",
"extent": [
-180,
-85.051,
180,
85.051
],
"id": "ocean",
"class": "",
"Datasource": {
"type": "shape",
"file": "data/water-polygons-split-3857/water_polygons.shp"
},
"layer": null,
"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",
"advanced": {},
"name": "ocean"
},
{
"extent": [
22.71561208176848,
51.024301313540015,
32.79624694636674,
56.36838768819846
],
"Datasource": {
"type": "postgis",
"table": "(select way,coalesce(\"name:be\", name) AS name,way_area from planet_osm_polygon where \"natural\"='water' or waterway='riverbank') as lakes",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "2528690.37,6625593.47,3650861.51,7632103.5",
"dbname": "gis",
"id": "lakes",
"project": "lineart",
"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"
},
"id": "lakes",
"class": "",
"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",
"advanced": {},
"name": "lakes",
"geometry": "polygon"
},
{
"geometry": "linestring",
"extent": [
20.67154065835024,
53.84331987480243,
41.669801370312136,
63.12363083529556
],
"Datasource": {
"type": "postgis",
"table": "(select way,admin_level from planet_osm_roads where admin_level in ('6', '4', '2')) as admin",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "-20037508.34,-20037508.34,20037508.34,20037508.34",
"dbname": "gis"
},
"id": "admin",
"class": "",
"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",
"advanced": {},
"name": "admin"
},
{
"geometry": "linestring",
"extent": [
20.67154065835024,
53.84331987480243,
41.669801370312136,
63.12363083529556
],
"Datasource": {
"type": "postgis",
"table": "(select way,admin_level from planet_osm_roads where admin_level in ('4', '2')) as admin",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "-20037508.34,-20037508.34,20037508.34,20037508.34",
"dbname": "gis"
},
"id": "admin-line",
"class": "",
"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",
"advanced": {},
"name": "admin-line"
},
{
"geometry": "linestring",
"extent": [
-0.00013888888888888892,
49.999861111111116,
59.999861111111116,
69.99986111111112
],
"id": "contours",
"class": "",
"Datasource": {
"type": "shape",
"file": "data/gmted/gmted-contour25g.shp",
"id": "contours",
"project": "lineart",
"srs": "+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs"
},
"layer": null,
"srs-name": "WGS84",
"srs": "+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs",
"advanced": {},
"name": "contours"
},
{
"extent": [
-179.9999999749438,
-85.051,
179.9999999749438,
85.051
],
"Datasource": {
"type": "postgis",
"table": "(select way, left(md5(\"addr:street\"), 1) as streethash,left(md5(\"addr:postcode\"), 1) as posthash, case when way_area > 5*5*!pixel_height!*!pixel_width! then 'yes' else 'almost' end as visible from planet_osm_polygon where building is not null and way_area > 3*3*!pixel_height!*!pixel_width!) as buildings",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "-20037508.34,-20037508.34,20037508.34,20037508.34",
"dbname": "gis"
},
"id": "buildings",
"class": "",
"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",
"advanced": {},
"name": "buildings",
"geometry": "polygon"
},
{
"geometry": "linestring",
"extent": [
19.290104407572024,
41.16666668212161,
179.9537075425649,
76.98934997681025
],
"Datasource": {
"type": "postgis",
"table": "(select way from planet_osm_line where power='line') as power",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "-20037508.34,-20037508.34,20037508.34,20037508.34",
"dbname": "gis"
},
"id": "power",
"class": "",
"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",
"advanced": {},
"name": "power"
},
{
"geometry": "linestring",
"extent": [
-179.9999999749438,
-85.051,
179.9999999749438,
85.051
],
"Datasource": {
"type": "postgis",
"table": "(select way, railway from planet_osm_line where railway in ('rail', 'narrow_gauge') and service is null and tunnel is null) as railway",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "-20037508.34,-20037508.34,20037508.34,20037508.34",
"dbname": "gis"
},
"id": "railway",
"class": "railway",
"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",
"advanced": {},
"name": "railway"
},
{
"geometry": "linestring",
"extent": [
-179.9999999749438,
-85.051,
179.9999999749438,
85.051
],
"Datasource": {
"type": "postgis",
"table": "(select way, highway, tracktype, (case when living_street is not null or service is not null then 1 else 0 end) as service from planet_osm_line where highway in ('path', 'cycleway', 'footway', 'service', 'track','pedestrian','living_street','residential', 'unclassified', 'tertiary', 'secondary', 'primary', 'trunk', 'motorway', 'tertiary_link', 'secondary_link', 'primary_link', 'trunk_link', 'motorway_link') and tunnel in ('yes', 'true', '1') order by z_order) as tunnels",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "-20037508.34,-20037508.34,20037508.34,20037508.34",
"dbname": "gis"
},
"id": "tunnels",
"class": "",
"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",
"advanced": {},
"name": "tunnels"
},
{
"geometry": "linestring",
"extent": [
22.467556599271887,
49.10078991480273,
33.24694070756235,
56.36710850981006
],
"Datasource": {
"type": "postgis",
"table": "(select way, man_made from planet_osm_line where man_made is not NULL) as man_made",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "2501076.96,6291980.67,3701032.51,7631846.4",
"dbname": "gis"
},
"id": "man_made",
"class": "",
"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",
"advanced": {},
"name": "man_made"
},
{
"geometry": "linestring",
"extent": [
22.467556599271887,
49.10078991480273,
33.24694070756235,
56.36710850981006
],
"Datasource": {
"type": "postgis",
"table": "(select way, highway, tracktype, (case when living_street is not null or service is not null then 1 else 0 end) as service from planet_osm_line where highway in ('path', 'cycleway', 'footway', 'service', 'track','pedestrian','living_street','residential', 'unclassified', 'tertiary', 'secondary', 'primary', 'trunk', 'motorway', 'tertiary_link', 'secondary_link', 'primary_link', 'trunk_link', 'motorway_link', 'construction', 'proposed') and (bridge is null or not bridge in ('yes', 'true', '1')) and (tunnel is null or not tunnel in ('yes', 'true', '1')) order by z_order) as highways",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "2501076.96,6291980.67,3701032.51,7631846.4",
"dbname": "gis",
"id": "highways",
"project": "veloroad",
"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"
},
"id": "highways",
"class": "",
"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",
"advanced": {},
"name": "highways"
},
{
"geometry": "linestring",
"extent": [
23.179674121864707,
51.27266501642914,
32.750452180655266,
56.16550391115494
],
"Datasource": {
"type": "postgis",
"table": "(\nselect way from planet_osm_line where barrier is not null\nunion all \nselect way from planet_osm_polygon where barrier is not null\n) p",
"key_field": "",
"geometry_field": "",
"extent_cache": "custom",
"extent": "",
"dbname": "gis"
},
"id": "barriers",
"class": "",
"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",
"advanced": {},
"name": "barriers"
},
{
"geometry": "linestring",
"extent": [
-179.9999999749438,
-85.051,
179.9999999749438,
85.051
],
"Datasource": {
"type": "postgis",
"table": "(select way, highway, tracktype, (case when living_street is not null or service is not null then 1 else 0 end) as service from planet_osm_line where highway in ('path', 'cycleway', 'footway', 'service', 'track','pedestrian','living_street','residential', 'unclassified', 'tertiary', 'secondary', 'primary', 'trunk', 'motorway', 'tertiary_link', 'secondary_link', 'primary_link', 'trunk_link', 'motorway_link') and bridge in ('yes', 'true', '1') order by z_order) as bridges",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "-20037508.34,-20037508.34,20037508.34,20037508.34",
"dbname": "gis"
},
"id": "bridges",
"class": "",
"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",
"advanced": {},
"name": "bridges"
},
{
"geometry": "linestring",
"id": "route",
"class": "route",
"Datasource": {
"type": "ogr",
"file": "data/route.gpx",
"layer": "tracks",
"all_layers": [
"route_points",
"routes",
"track_points",
"waypoints"
]
},
"layer": "tracks",
"srs-name": "WGS84",
"srs": "+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs",
"advanced": {},
"name": "route",
"status": "off"
},
{
"geometry": "point",
"extent": [
23.048804047844566,
51.26288996353496,
33.24694070756235,
56.173291296246354
],
"Datasource": {
"type": "postgis",
"table": "(select way,coalesce(\"name:be\", name) as name from planet_osm_point where railway='subway_entrance') as subway",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "2565781.13,6667928.32,3701032.51,7592990.68",
"dbname": "gis"
},
"id": "subway",
"class": "",
"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",
"advanced": {},
"name": "subway"
},
{
"geometry": "point",
"extent": [
23.048804047844566,
51.26288996353496,
33.24694070756235,
56.173291296246354
],
"Datasource": {
"type": "postgis",
"table": "(select way,place,coalesce(\"name:be\", \"name:ru\", name) as name,(case when place='city' then 9 when place='town' then 8 when place='village' then 7 when place='hamlet' then 6 when place='suburb' then 5 when place='locality' then 4 when place in ('isolated_dwelling', 'allotments') then 3 else 0 end) as p_order, (case when coalesce(population, '')~E'^\\\\d+$' then population::int else 0 end) as pop from planet_osm_point where place in ('village', 'town', 'city', 'hamlet', 'suburb', 'locality', 'isolated_dwelling', 'island', 'allotments') order by p_order desc, pop desc) as places",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "2565781.13,6667928.32,3701032.51,7592990.68",
"dbname": "gis",
"id": "places",
"project": "lineart",
"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"
},
"id": "places",
"class": "",
"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",
"advanced": {},
"name": "places"
},
{
"geometry": "point",
"extent": [
23.048804047844566,
51.26288996353496,
33.24694070756235,
56.173291296246354
],
"Datasource": {
"type": "postgis",
"table": "(select way,railway,station,coalesce(\"name:be\", name) as name,length(coalesce(\"name:be\", name)) as len,(select 90+degrees(ST_Azimuth(ST_StartPoint(inter), ST_EndPoint(inter))) from (select ST_Intersection(r.way, ST_Buffer(p.way, 100)) as inter from planet_osm_line r where r.railway in ('rail', 'narrow_gauge') and r.way && ST_Buffer(p.way, 100) order by ST_Distance(r.way, p.way) limit 1) rr) as angle from planet_osm_point p where railway in ('station', 'halt') and (station is null or (station != 'subway' and station != 'disused'))) as stations",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "2565781.13,6667928.32,3701032.51,7592990.68",
"dbname": "gis",
"id": "stations",
"project": "lineart",
"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"
},
"id": "stations",
"class": "",
"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",
"advanced": {},
"name": "stations"
},
{
"geometry": "linestring",
"extent": [
22.467556599271887,
49.10078991480273,
33.24694070756235,
56.36710850981006
],
"Datasource": {
"type": "postgis",
"table": "(select way, highway,(case when ref = 'А-118' then 'КАД' when length(ref) <= 5 then ref else null end) as ref,coalesce(\"name:be\", name) AS name from planet_osm_line where highway in ('tertiary', 'secondary', 'primary', 'trunk', 'motorway')) as highwaysh",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "2501076.96,6291980.67,3701032.51,7631846.4",
"dbname": "gis"
},
"id": "hlabels",
"class": "",
"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",
"advanced": {},
"name": "hlabels"
},
{
"geometry": "linestring",
"extent": [
22.467556599271887,
49.10078991480273,
33.24694070756235,
56.36710850981006
],
"Datasource": {
"type": "postgis",
"table": "(select way,waterway,coalesce(\"name:be\", name) AS name from planet_osm_line where waterway in ('river', 'canal') and tunnel is null) as rivers",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "2501076.96,6291980.67,3701032.51,7631846.4",
"dbname": "gis"
},
"id": "wlabels",
"class": "",
"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",
"advanced": {},
"name": "wlabels"
},
{
"geometry": "linestring",
"extent": [
22.467556599271887,
49.10078991480273,
33.24694070756235,
56.36710850981006
],
"Datasource": {
"type": "postgis",
"table": "(\nselect \n streethash,\n case when ST_X(ST_LineInterpolatePoint(way, 0.5)) > ST_X(ST_StartPoint(way)) then way else ST_Reverse(way) end\n as way,\n name\nfrom (\n select \n left(md5(street), 1) as streethash, \n (ST_Dump(ST_Simplify(ST_LineMerge(ST_Union(ST_SnapToGrid(way, 2*!pixel_height!))), 4*!pixel_height!))).geom as way, \n replace(replace(replace(replace(replace(replace(name, 'завулак', 'зав.'), 'вуліца', 'вул.'), 'набережная', 'наб.'), 'улица', 'ул.'), 'проспект', 'пр.'), 'переулок', 'пер.') as name \n from (\n select \n name as street,\n way, \n coalesce(\"name:be\", name) AS name \n from planet_osm_line \n where \n highway is not null and \n name is not null and \n way && !bbox!) p \n group by \n name, \n streethash\n ) pp \n order by ST_Length(way) desc\n) as highwaysl",
"key_field": "",
"geometry_field": "",
"extent_cache": "auto",
"extent": "2501076.96,6291980.67,3701032.51,7631846.4",
"dbname": "gis"
},
"id": "hslabels",
"class": "",
"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",
"advanced": {},
"name": "hslabels"
},
{
"extent": [
22.71561208176848,
51.024301313540015,
32.79624694636674,
56.36838768819846
],
"Datasource": {
"type": "postgis",
"table": "(select way,way_area, coalesce(\"name:be\", name) AS name from planet_osm_polygon where leisure = 'park') as wol",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "2528690.37,6625593.47,3650861.51,7632103.5",
"dbname": "gis"
},
"id": "plabels",
"class": "",
"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",
"advanced": {},
"name": "plabels",
"geometry": "polygon"
},
{
"extent": [
22.71561208176848,
51.024301313540015,
32.79624694636674,
56.36838768819846
],
"Datasource": {
"type": "postgis",
"table": "(select place, coalesce(\"name:be\", name) as name, ST_PointOnSurface(way) as way, way_area from planet_osm_polygon where place='island' order by way_area desc) as islands",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "2528690.37,6625593.47,3650861.51,7632103.5",
"dbname": "gis"
},
"id": "islands",
"class": "",
"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",
"advanced": {},
"name": "islands",
"geometry": "point"
},
{
"geometry": "polygon",
"extent": [
22.71561208176848,
51.024301313540015,
32.79624694636674,
56.36838768819846
],
"Datasource": {
"type": "postgis",
"table": "(select way,way_area, coalesce(\"name:be\", name) AS name from planet_osm_polygon where \"natural\" = 'water' and (water is null or water != 'river')) as wol",
"key_field": "",
"geometry_field": "way",
"extent_cache": "auto",
"extent": "2528690.37,6625593.47,3650861.51,7632103.5",
"dbname": "gis"
},
"id": "wolabels",
"class": "",
"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",
"advanced": {},
"name": "wolabels"
},
{
"geometry": "linestring",
"extent": [
-180,
-85.051,
180,
85.051
],
"Datasource": {
"type": "postgis",
"table": "(select id+1 as id, (case when id<n or id>n*2+1 or (id-n > 1 and id < n*2) then '' when id < n*2 then cast((id-n)*scale as text) when id=n*2 then (n*scale)||' км' else 'Карта © OpenStreetMap' end) as label, id%2 as id2,\n(case when id < n then ST_MakeLine(st_project(st_project(pt, 1000*scale*n/2, -pi()/2), 1000*scale*id, pi()/2)::geometry,\nst_project(st_project(pt, 1000*scale*n/2, -pi()/2), 1000*scale*(id+1), pi()/2)::geometry)\nwhen id <= n*2 then st_project(st_project(pt, 1000*scale*n/2, -pi()/2), 1000*scale*(id-n), pi()/2)::geometry\nelse pt\nend) as way\nfrom\n(select 5 as n, 1 as scale, ST_SetSRID(ST_Point(30, 60), 4326) as pt) d,\ngenerate_series(0, 11) id) as scale",
"key_field": "",
"geometry_field": "way",
"extent_cache": "custom",
"extent": "-20037508.34,-20037508.34,20037508.34,20037508.34",
"dbname": "gis",
"id": "scale",
"project": "lineart",
"srs": "+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs"
},
"id": "scale",
"class": "",
"srs-name": "WGS84",
"srs": "+proj=longlat +ellps=WGS84 +datum=WGS84 +no_defs",
"advanced": {},
"name": "scale",
"status": "off"
},
{
"geometry": "linestring",
"extent": [
-179.9999999749438,
-85.051,
179.9999999749438,
85.051
],
"Datasource": {
"type": "postgis",
"table": "(\nwith \nhousenumbers as (\n select \n \"addr:housenumber\" as hno,\n \"addr:street\", \n way,\n way as point \n from planet_osm_point \n where (\n \"addr:housenumber\" is not null\n and shop is null\n and office is null\n and amenity is null\n and way && !bbox!) \n\n union all\n\n select \n \"addr:housenumber\" as hno,\n \"addr:street\", \n way,\n ST_PointOnSurface(way) as point \n from planet_osm_polygon \n where (\"addr:housenumber\" is not null and way_area > 2*3*!pixel_height!*!pixel_width! and way && !bbox!)\n),\nhouse_extent as (select ST_Expand(ST_Extent(way), 600) extent from housenumbers),\nstreets as (\n select way, name, highway from planet_osm_line l, house_extent where l.name is not null and l.highway is not null and l.way && extent\n union all\n select ST_Centroid(way), name, highway from planet_osm_polygon l, house_extent where l.name is not null and l.highway is not null and l.way && extent\n),\nstreet_length as (\n select sum(ST_Length(way)) as len, name from streets group by name\n)\n -- stupid mapnik asks 5 first buildings in the world to get geometry type.\n -- that fucks everything up because of ordering by distance to street.\n -- let's feed it with something while waiting for something better\n select 0 as angle, ''::text as hno, ST_GeomFromEWKT('SRID=900913;LINESTRING(-200 0, 200 0)') as way, ''::text as highway\n union all\n select 0 as angle, ''::text as hno, ST_GeomFromEWKT('SRID=900913;LINESTRING(-200 0, 200 0)') as way, ''::text as highway\n union all\n select 0 as angle, ''::text as hno, ST_GeomFromEWKT('SRID=900913;LINESTRING(-200 0, 200 0)') as way, ''::text as highway\n union all\n select 0 as angle, ''::text as hno, ST_GeomFromEWKT('SRID=900913;LINESTRING(-200 0, 200 0)') as way, ''::text as highway\n union all\n select 0 as angle, ''::text as hno, ST_GeomFromEWKT('SRID=900913;LINESTRING(-200 0, 200 0)') as way, ''::text as highway\n union all\n select \n angle,\n hno || case \n when \n angle > 75 and \n angle < 275 and\n (hno like '%6%' or hno like '%9%')\n then '.' \n else '' \n end, \n way,\n highway\n from ( \n select\n hno,\n angle,\n point as way,\n highway\n from \n housenumbers h\n left outer join lateral (select ST_Distance(h.way, l.way) dist, name, way, highway from streets l where l.name = h.\"addr:street\" order by 1 asc limit 1) l on true\n left outer join street_length sl on (sl.name = h.\"addr:street\")\n left outer join lateral (\n select \n mod(case when angle > 90 and angle < 270 then 180+angle else angle end::integer, 360) angle\n from (\n select\n 360 - degrees(ST_Azimuth(\n ST_StartPoint(ST_ShortestLine(h.point, l.way)),\n ST_EndPoint(ST_ShortestLine(h.point, l.way))\n )) angle) p\n ) a on true\n left outer join lateral (select ST_Distance(h.way, l.way) dist, name from streets l where l.name != h.\"addr:street\" order by 1 asc limit 1) fs on true\n left outer join street_length fsl on (fsl.name = fs.name)\n --where l.highway in ('tertiary', 'secondary', 'primary')\n where (l.dist > !pixel_height!*3 or l.dist is null) and (fs.dist > !pixel_height!*2 or fs.dist is null)\n order by \n sl.len desc, -- longer streets need more housenumbers\n fsl.len desc, -- crossings with longer streets need more attention\n round(fs.dist/10) asc, -- better to show houses closer to crossings\n least(angle, 360-angle) asc -- better to show upright labels\n --(hno like '%0' or hno like '%1') -- better to show round numbers\n ) p\n) p\n",
"key_field": "",
"geometry_field": "way",
"extent_cache": "custom",
"extent": "-20037508.34,-20037508.34,20037508.34,20037508.34",
"dbname": "gis",
"srid": "900913"
},
"id": "hnolabels",
"class": "",
"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",
"advanced": {
"srid": "900913"
},
"name": "hnolabels"
}
],
"scale": 1,
"metatile": 3,
"name": "Belroad",
"description": "",
"attribution": ""
}