Merge branch 'master' into wagyu-initializer

This commit is contained in:
Eric Fischer 2018-08-06 10:15:20 -07:00
commit 60629da37a
8 changed files with 1180 additions and 7 deletions

View File

@ -1,3 +1,7 @@
## 1.30.6
* Take cluster distance into account when guessing a maxzoom
## 1.30.4
* Features within the z0 tile buffer of the antimeridian (not only

View File

@ -296,7 +296,7 @@ csv-test:
cmp tests/csv/out-null.mbtiles.json.check tests/csv/out-null.mbtiles.json
rm -f tests/csv/out-null.mbtiles.json.check tests/csv/out-null.mbtiles
# Same, but specifying csv with -L format
./tippecanoe -q -zg -f -o tests/csv/out.mbtiles -L'{"file":"", "format":"csv", "layer":"ne_110m_populated_places_simplecsv"}' < tests/csv/ne_110m_populated_places_simple.csv
./tippecanoe -q -zg -f -o tests/csv/out.mbtiles -L'{"file":"", "format":"csv", "layer":"ne_110m_populated_places_simple"}' < tests/csv/ne_110m_populated_places_simple.csv
./tippecanoe-decode -x generator tests/csv/out.mbtiles > tests/csv/out.mbtiles.json.check
cmp tests/csv/out.mbtiles.json.check tests/csv/out.mbtiles.json
rm -f tests/csv/out.mbtiles.json.check tests/csv/out.mbtiles

View File

@ -94,7 +94,7 @@ void handle(std::string message, int z, unsigned x, unsigned y, std::set<std::st
fprintf(stderr, "Couldn't parse tile %d/%u/%u\n", z, x, y);
exit(EXIT_FAILURE);
}
} catch (protozero::unknown_pbf_wire_type_exception e) {
} catch (std::exception const& e) {
fprintf(stderr, "PBF decoding error in tile %d/%u/%u\n", z, x, y);
exit(EXIT_FAILURE);
}

View File

@ -1268,6 +1268,7 @@ int read_input(std::vector<source> &sources, char *fname, int maxzoom, int minzo
".geojson",
".geobuf",
".mbtiles",
".csv",
".gz",
};
@ -1985,6 +1986,20 @@ int read_input(std::vector<source> &sources, char *fname, int maxzoom, int minzo
if (!quiet) {
fprintf(stderr, "Choosing a maxzoom of -z%d for features about %d feet (%d meters) apart\n", maxzoom, (int) ceil(dist_ft), (int) ceil(dist_ft / 3.28084));
}
bool changed = false;
while (maxzoom < 32 - full_detail && maxzoom < 33 - low_detail && cluster_distance > 0) {
unsigned long long zoom_mingap = ((1LL << (32 - maxzoom)) / 256 * cluster_distance) * ((1LL << (32 - maxzoom)) / 256 * cluster_distance);
if (avg > zoom_mingap) {
break;
}
maxzoom++;
changed = true;
}
if (changed) {
printf("Choosing a maxzoom of -z%d to keep most features distinct with cluster distance %d\n", maxzoom, cluster_distance);
}
}
if (dist_count != 0) {

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,6 @@
#ifndef VERSION_HPP
#define VERSION_HPP
#define VERSION "v1.30.4"
#define VERSION "v1.30.6"
#endif