Trying to cover too-small triangles with bigger triangles

This commit is contained in:
Erica Fischer
2023-10-26 08:57:28 -07:00
parent a3a0e36b9d
commit 546d2fd63d
2 changed files with 22 additions and 27 deletions
+8 -1
View File
@@ -613,6 +613,12 @@ void *partial_feature_worker(void *v) {
drawvec geom = (*partials)[i].geoms[0];
if (t == VT_POLYGON) {
geom = clean_or_clip_poly(geom, 0, 0, false, false);
geom = fix_by_triangulation(geom, z, out_detail);
}
#if 0
if (t == VT_POLYGON) {
drawvec cleaned = clean_or_clip_poly(geom, 0, 0, false, false);
drawvec fixed = fix_by_triangulation(geom, z, out_detail);
@@ -620,6 +626,7 @@ void *partial_feature_worker(void *v) {
geom = fixed;
}
}
#endif
to_tile_scale(geom, z, out_detail);
@@ -634,7 +641,7 @@ void *partial_feature_worker(void *v) {
check_polygon(geom);
}
if (geom.size() < 3) {
if (geom.size() < 4) {
if (area > 0) {
// area is in world coordinates, calculated before scaling down
geom = revive_polygon(before, area, z, out_detail);