Fix "strategies" accounting for 0-length linestrings and degenerate polygons (#137)

* Dropping a 0-length feature doesn't count as dropping-as-needed

* Add an option not to reduce tiny polygons to dust at maxzoom

* Add test for prevention of tiny polygon reduction at maxzoom

* Fix accounting for tiny polygons not to include degenerate geometries

* Revert "Add test for prevention of tiny polygon reduction at maxzoom"

This reverts commit f931bbd73e.

* Revert "Add an option not to reduce tiny polygons to dust at maxzoom"

This reverts commit 03f0882bb6.

* Fix tests

* Another test that no longer has any really tiny polygons

* Oops, that broke LineString simplification

* This time for sure!

* Update changelog and version
This commit is contained in:
Erica Fischer
2023-08-29 10:54:39 -07:00
committed by GitHub
parent 6778aeac52
commit 2ec6180003
42 changed files with 56 additions and 49 deletions
+1 -1
View File
@@ -9,7 +9,7 @@
"maxzoom": "4",
"minzoom": "0",
"name": "tests/nullisland/out/-b0_-z4.json.check.mbtiles",
"strategies": "[{\"dropped_by_rate\":4},{\"dropped_by_rate\":8,\"tiny_polygons\":12},{\"dropped_by_rate\":8},{\"dropped_by_rate\":3},{}]",
"strategies": "[{\"dropped_by_rate\":4},{\"dropped_by_rate\":8},{\"dropped_by_rate\":8},{\"dropped_by_rate\":3},{}]",
"type": "overlay",
"version": "2"
}, "features": [
@@ -10,7 +10,7 @@
"maxzoom": "4",
"minzoom": "0",
"name": "tests/nullisland/out/-b0_-z4_-ANullIsland.json.check.mbtiles",
"strategies": "[{\"dropped_by_rate\":4},{\"dropped_by_rate\":8,\"tiny_polygons\":12},{\"dropped_by_rate\":8},{\"dropped_by_rate\":3},{}]",
"strategies": "[{\"dropped_by_rate\":4},{\"dropped_by_rate\":8},{\"dropped_by_rate\":8},{\"dropped_by_rate\":3},{}]",
"type": "overlay",
"version": "2"
}, "features": [
@@ -9,7 +9,7 @@
"maxzoom": "4",
"minzoom": "0",
"name": "tests/nullisland/out/-b0_-z4_-NNullIsland.json.check.mbtiles",
"strategies": "[{\"dropped_by_rate\":4},{\"dropped_by_rate\":8,\"tiny_polygons\":12},{\"dropped_by_rate\":8},{\"dropped_by_rate\":3},{}]",
"strategies": "[{\"dropped_by_rate\":4},{\"dropped_by_rate\":8},{\"dropped_by_rate\":8},{\"dropped_by_rate\":3},{}]",
"type": "overlay",
"version": "2"
}, "features": [