Selective rendering of tracks and paths at z12-13 (#1190)
Closes #271 This PR adds track and path rendering at lower zooms than currently provided, and also achieves near-parity with openstreetmap-carto on track and path rendering. A previously-abandoned attempt, with significant discussion, was #1169.
This commit is contained in:
committed by
GitHub
parent
7f531c1dbb
commit
75d8c80228
@@ -14,6 +14,10 @@
|
||||
<node id="500052" visible="true" timestamp="2019-01-01T00:00:00Z" version="1" lat="33.5" lon="-90.05" />
|
||||
<node id="500061" visible="true" timestamp="2019-01-01T00:00:00Z" version="1" lat="33.0" lon="-90.06" />
|
||||
<node id="500062" visible="true" timestamp="2019-01-01T00:00:00Z" version="1" lat="33.5" lon="-90.06" />
|
||||
<node id="500071" visible="true" timestamp="2019-01-01T00:00:00Z" version="1" lat="33.0" lon="-90.07" />
|
||||
<node id="500072" visible="true" timestamp="2019-01-01T00:00:00Z" version="1" lat="33.5" lon="-90.07" />
|
||||
<node id="500081" visible="true" timestamp="2019-01-01T00:00:00Z" version="1" lat="33.0" lon="-90.07" />
|
||||
<node id="500082" visible="true" timestamp="2019-01-01T00:00:00Z" version="1" lat="33.5" lon="-90.07" />
|
||||
|
||||
<way id="5000" version="1" timestamp="2019-01-01T00:00:00Z" visible="true">
|
||||
<nd ref="500001" />
|
||||
@@ -65,4 +69,29 @@
|
||||
<tag k="highway" v="track"/>
|
||||
<tag k="name" v="OpenMapTiles Track"/>
|
||||
</way>
|
||||
<way id="5007" version="1" timestamp="2019-01-01T00:00:00Z" visible="true">
|
||||
<nd ref="500071" />
|
||||
<nd ref="500072" />
|
||||
<tag k="highway" v="path"/>
|
||||
<tag k="name" v="OpenMapTiles Path z13"/>
|
||||
</way>
|
||||
<way id="5008" version="1" timestamp="2019-01-01T00:00:00Z" visible="true">
|
||||
<nd ref="500081" />
|
||||
<nd ref="500082" />
|
||||
<tag k="highway" v="path"/>
|
||||
<tag k="name" v="OpenMapTiles Track z12"/>
|
||||
</way>
|
||||
|
||||
<relation id="507" visible="true" timestamp="2019-01-01T00:00:00Z" version="1" changeset="1" user="u" uid="1">
|
||||
<member type="way" ref="5007" role=""/>
|
||||
<tag k="type" v="route"/>
|
||||
<tag k="route" v="hiking"/>
|
||||
<tag k="colour" v="red"/>
|
||||
</relation>
|
||||
<relation id="508" visible="true" timestamp="2019-01-01T00:00:00Z" version="1" changeset="1" user="u" uid="1">
|
||||
<member type="way" ref="5008" role=""/>
|
||||
<tag k="type" v="route"/>
|
||||
<tag k="route" v="hiking"/>
|
||||
<tag k="network" v="nwn"/>
|
||||
</relation>
|
||||
</osm>
|
||||
|
||||
@@ -133,6 +133,20 @@ BEGIN
|
||||
INSERT INTO omt_test_failures VALUES(500, 'import', 'osm_transportation_linestring z9 import tags expected 1, got ' || cnt);
|
||||
END IF;
|
||||
|
||||
SELECT COUNT(*) INTO cnt FROM osm_transportation_name_linestring
|
||||
WHERE tags->'name' = 'OpenMapTiles Path z13'
|
||||
AND route_rank = 2;
|
||||
IF cnt <> 1 THEN
|
||||
INSERT INTO omt_test_failures VALUES(500, 'import', 'osm_transportation_name_linestring z13 route_rank expected 1, got ' || cnt);
|
||||
END IF;
|
||||
|
||||
SELECT COUNT(*) INTO cnt FROM osm_transportation_name_linestring
|
||||
WHERE tags->'name' = 'OpenMapTiles Track z12'
|
||||
AND route_rank = 1;
|
||||
IF cnt <> 1 THEN
|
||||
INSERT INTO omt_test_failures VALUES(500, 'import', 'osm_transportation_name_linestring z12 route_rank expected 1, got ' || cnt);
|
||||
END IF;
|
||||
|
||||
END;
|
||||
|
||||
$$
|
||||
|
||||
Reference in New Issue
Block a user