mirror of
https://github.com/mapbox/tippecanoe.git
synced 2025-04-19 08:16:21 +00:00
Merge branch 'master' of https://github.com/mapbox/tippecanoe into SkySight
This commit is contained in:
commit
881bfd7c11
@ -1,3 +1,7 @@
|
||||
## 1.32.10
|
||||
|
||||
* Fix a bug that disallowed a per-feature minzoom of 0
|
||||
|
||||
## 1.32.9
|
||||
|
||||
* Limit tile detail to 30 and buffer size to 127 to prevent coordinate
|
||||
|
@ -53,7 +53,7 @@ void parse_geometry(int t, json_object *j, drawvec &out, int op, const char *fna
|
||||
size_t i;
|
||||
for (i = 0; i < j->length; i++) {
|
||||
if (within == GEOM_POINT) {
|
||||
if (i == 0 || mb_geometry[t] == GEOM_MULTIPOINT) {
|
||||
if (i == 0 || mb_geometry[t] == VT_POINT) {
|
||||
op = VT_MOVETO;
|
||||
} else {
|
||||
op = VT_LINETO;
|
||||
@ -80,7 +80,6 @@ void parse_geometry(int t, json_object *j, drawvec &out, int op, const char *fna
|
||||
}
|
||||
}
|
||||
|
||||
draw d(op, x, y);
|
||||
out.push_back(draw(op, x, y));
|
||||
} else {
|
||||
fprintf(stderr, "%s:%d: malformed point\n", fname, line);
|
||||
|
@ -355,7 +355,7 @@ static long long scale_geometry(struct serialization_state *sst, long long *bbox
|
||||
}
|
||||
|
||||
if (!*(sst->initialized)) {
|
||||
if (x < 0 || x >= (1LL << 32) || y < 0 || y >= (1LL < 32)) {
|
||||
if (x < 0 || x >= (1LL << 32) || y < 0 || y >= (1LL << 32)) {
|
||||
*(sst->initial_x) = 1LL << 31;
|
||||
*(sst->initial_y) = 1LL << 31;
|
||||
} else {
|
||||
|
@ -1,3 +1,4 @@
|
||||
{ "type": "Feature", "properties": {}, "geometry": { "type": "Point", "coordinates": [ 0, 0 ] }, "tippecanoe": { "minzoom": 0, "maxzoom": 0 } }
|
||||
{ "type": "Feature", "properties": {}, "geometry": { "type": "Point", "coordinates": [ 1, 1 ] }, "tippecanoe": { "minzoom": 1, "maxzoom": 1 } }
|
||||
{ "type": "Feature", "properties": {}, "geometry": { "type": "Point", "coordinates": [ 2, 2 ] }, "tippecanoe": { "minzoom": 2, "maxzoom": 2 } }
|
||||
{ "type": "Feature", "properties": {}, "geometry": { "type": "Point", "coordinates": [ 3, 3 ] }, "tippecanoe": { "minzoom": 3, "maxzoom": 3 } }
|
||||
|
@ -1,15 +1,21 @@
|
||||
{ "type": "FeatureCollection", "properties": {
|
||||
"bounds": "1.000000,1.000000,6.000000,6.000000",
|
||||
"bounds": "0.000000,0.000000,6.000000,6.000000",
|
||||
"center": "6.000000,6.000000,6",
|
||||
"description": "tests/minzoom/out/-z6.json.check.mbtiles",
|
||||
"format": "pbf",
|
||||
"json": "{\"vector_layers\": [ { \"id\": \"in\", \"description\": \"\", \"minzoom\": 0, \"maxzoom\": 6, \"fields\": {} } ],\"tilestats\": {\"layerCount\": 1,\"layers\": [{\"layer\": \"in\",\"count\": 6,\"geometry\": \"Point\",\"attributeCount\": 0,\"attributes\": []}]}}",
|
||||
"json": "{\"vector_layers\": [ { \"id\": \"in\", \"description\": \"\", \"minzoom\": 0, \"maxzoom\": 6, \"fields\": {} } ],\"tilestats\": {\"layerCount\": 1,\"layers\": [{\"layer\": \"in\",\"count\": 7,\"geometry\": \"Point\",\"attributeCount\": 0,\"attributes\": []}]}}",
|
||||
"maxzoom": "6",
|
||||
"minzoom": "0",
|
||||
"name": "tests/minzoom/out/-z6.json.check.mbtiles",
|
||||
"type": "overlay",
|
||||
"version": "2"
|
||||
}, "features": [
|
||||
{ "type": "FeatureCollection", "properties": { "zoom": 0, "x": 0, "y": 0 }, "features": [
|
||||
{ "type": "FeatureCollection", "properties": { "layer": "in", "version": 2, "extent": 4096 }, "features": [
|
||||
{ "type": "Feature", "properties": { }, "geometry": { "type": "Point", "coordinates": [ 0.000000, 0.000000 ] } }
|
||||
] }
|
||||
] }
|
||||
,
|
||||
{ "type": "FeatureCollection", "properties": { "zoom": 1, "x": 0, "y": 1 }, "features": [
|
||||
{ "type": "FeatureCollection", "properties": { "layer": "in", "version": 2, "extent": 4096 }, "features": [
|
||||
{ "type": "Feature", "properties": { }, "geometry": { "type": "Point", "coordinates": [ 0.966797, 1.010690 ] } }
|
||||
|
2
text.cpp
2
text.cpp
@ -127,7 +127,7 @@ std::string truncate16(std::string const &s, size_t runes) {
|
||||
|
||||
int integer_zoom(std::string where, std::string text) {
|
||||
double d = atof(text.c_str());
|
||||
if (!isnormal(d) || d != floor(d) || d < 0 || d > 32) {
|
||||
if (!isfinite(d) || d != floor(d) || d < 0 || d > 32) {
|
||||
fprintf(stderr, "%s: Expected integer zoom level in \"tippecanoe\" GeoJSON extension, not %s\n", where.c_str(), text.c_str());
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
@ -1,6 +1,6 @@
|
||||
#ifndef VERSION_HPP
|
||||
#define VERSION_HPP
|
||||
|
||||
#define VERSION "v1.32.9"
|
||||
#define VERSION "v1.32.10"
|
||||
|
||||
#endif
|
||||
|
Loading…
x
Reference in New Issue
Block a user