It only needs to look for other small features when coalescing, not dropping (#64)

* Back out the slow search for other small features when dropping features

* Actually, *do* look for small features still when coalescing

* Update changelog
This commit is contained in:
Erica Fischer
2023-01-27 12:04:36 -08:00
committed by GitHub
parent e615668475
commit b155b4671b
7 changed files with 15 additions and 215 deletions
+3 -1
View File
@@ -2100,7 +2100,9 @@ long long write_tile(FILE *geoms, std::atomic<long long> *geompos_in, char *meta
}
} else if (additional[A_DROP_SMALLEST_AS_NEEDED]) {
add_sample_to(extents, sf.extent, extents_increment, seq);
if (sf.extent + coalesced_area <= minextent && find_partial(partials, sf, which_partial, layer_unmaps, minextent)) {
// search here is for LLONG_MAX, not minextent, because we are dropping features, not coalescing them,
// so we shouldn't expect to find anything small that we can related this feature to.
if (sf.extent + coalesced_area <= minextent && find_partial(partials, sf, which_partial, layer_unmaps, LLONG_MAX)) {
preserve_attributes(arg->attribute_accum, sf, stringpool, pool_off, partials[which_partial]);
strategy->dropped_as_needed++;
continue;