mirror of
https://github.com/felt/tippecanoe.git
synced 2026-10-02 08:25:40 +02:00
Round upward to catch narrow-but-tall or wide-but-short features
This commit is contained in:
+2
-2
@@ -304,9 +304,9 @@ int serialize_geometry(json_object *geometry, json_object *properties, const cha
|
|||||||
|
|
||||||
if (prevent[P_CLIPPING]) {
|
if (prevent[P_CLIPPING]) {
|
||||||
static volatile long long warned = 0;
|
static volatile long long warned = 0;
|
||||||
long long extent = ((bbox[2] - bbox[0]) / (1LL << (32 - maxzoom))) * ((bbox[3] - bbox[1]) / (1LL << (32 - maxzoom)));
|
long long extent = ((bbox[2] - bbox[0]) / ((1LL << (32 - maxzoom)) + 1)) * ((bbox[3] - bbox[1]) / ((1LL << (32 - maxzoom)) + 1));
|
||||||
if (extent > warned) {
|
if (extent > warned) {
|
||||||
fprintf(stderr, "Warning: %s:%d: Large unclipped (-pc) feature will be duplicated across %lld tiles\n", fname, line, extent);
|
fprintf(stderr, "Warning: %s:%d: Large unclipped (-pc) feature may be duplicated across %lld tiles\n", fname, line, extent);
|
||||||
warned = extent;
|
warned = extent;
|
||||||
|
|
||||||
if (extent > 10000) {
|
if (extent > 10000) {
|
||||||
|
|||||||
Reference in New Issue
Block a user