262 Commits
Author SHA1 Message Date
Erica Fischer 4ef430b913 Add an option for the Visvalingam simplification algorithm (#16)
* First attempt at porting Paul Mach's Visvalingam implementation

* Make indent

* Mostly working

* Approximate equivalence from Douglas-Peucker to Visvalingam levels

* Don't simplify away tile boundary crossing points

* Add a command-line option and test for Visvalingam simplification

* Update changelog

* Cleanup in response to review feedback

* Include <stdio.h> to fix compiler warnings
2022-09-30 12:00:07 -07:00
Erica Fischer af1a7ed7ae Once features can't possibly fit in a tile, stop trying (#9)
* Stop adding features to a tile if it can't possibly work

* Add --integer and --fraction options to tippecanoe-decode

* Carry the strategies field from tileset metadata through tile-join

* Update changelog

* Assign different codes to different kinds of error exits
2022-09-23 20:01:13 -04:00
Erica Fischer 073700aa38 Reduce maxzooms being guessed a little: (#2)
* Reduce maxzooms being guessed a little:

* Use 1.5 standard deviations, not 2, as the minimum distinguishable
* Give overlapping polygons and linestrings more distinct indices

* Add another drop rate guessing options, from the same metrics -zg uses

* Guard against using -rp without -zg
2022-09-08 15:47:32 -07:00
Erica Fischer a447dfc089 Extra coordinate precision; feature ordering; compression improvements
* Add an option to retain extra coordinate precision at maxzoom

* Make sure not to shift away the extra detail from coordinates

* Add an option to convert double-precision attributes to single

* Sort attribute values in tiles to make them compress a little better

* Slightly improve polygon simplification

By choosing a point that would be retained after simplification
to be the start/end point that always gets retained

* I regret making all of these tests involve polygons

* Add an option to specify the size of tiny polygons

* Fix accidental requiring of argument for --single-precision

* Guard against duplicate points when generating "sizes" for them

* Restore the intended behavior that tiny polygons don't get simplified

* Make the extra detail settable rather than always maximizing it

* Revert "Improve maxzoom guessing for tightly-clustered point data sources (#4)"

This reverts commit fec5e8354c.

* Add an option to prevent choosing a base zoom higher than the maxzoom

* Keep the drop rate high enough when the basezoom gets constrained

* Revert "Revert "Improve maxzoom guessing for tightly-clustered point data sources (#4)""

This reverts commit db6bc27d9e.

* Add --order-by and --order-descending options

* Accept multiple --order-by and --order-descending-by sort keys
2022-09-06 13:08:11 -07:00
Erica Fischer fec5e8354c Improve maxzoom guessing for tightly-clustered point data sources (#4)
* Improve maxzoom guessing for tightly-clustered point data sources

* Go back to the old distance estimate, since it is less mysterious

* Update changelog and version
2022-08-11 10:13:54 -07:00
Erica Fischer a9bf6cacd4 Add --smallest-maximum-zoom-guess to specify a minimum maxzoom to guess (#2)
* Add --maximum-zoom-at-least to specify a minimum maxzoom to guess

* Check whether the specified minimum maxzoom is out of range

* Rename the option to --smallest-maximum-zoom-guess

* Update tests, changelog, and version
2022-08-11 10:04:03 -07:00
Erica Fischer c65d6938a4 Drop or coalesce points too when dropping or coalescing smallest (#6)
* Handle points too when dropping or coalescing the "smallest" features.

* Add statistics of tile size reduction strategies to tileset metadata

* Update changelog and version

* Update documentation
2022-08-09 15:29:03 -07:00
Erica Fischer 67cd9d8d85 Reduce tippecanoe memory usage (#5)
* Change JSON objects to a union type to use less memory

* Stop storing the string representation of JSON numbers

* Restore the ability to create features with large integer attributes

* Make sure large-integer feature IDs still behave as before

* Add missing #include

* Don't preallocate as much space for arrays and objects

* Treat inability to check free disk space as a warning, not an error

* Update changelog and version
2022-08-09 15:18:51 -07:00
Erica Fischer 6978a0e102 Reindent with clang-format (#3) 2022-07-28 11:19:30 -07:00
Brandon Liu f442e403c5 add logging struct with -u json options flag, log tiling progress [#13] 2022-07-05 15:32:11 +08:00
Brandon Liu 33a9aef758 Handle indeterminate length FlatGeobuf headers, linestring geometries [#2] 2022-03-27 19:13:22 +08:00
Brandon Liu 88cedf54d4 FlatGeobuf column type parsing [#2] 2022-03-27 19:13:12 +08:00
Brandon Liu 8a5a2496c3 Implement FlatGeobuf Polygon type parsing [#2] 2022-03-27 19:13:03 +08:00
Brandon Liu a3dec5116d add flatgeobuf dependencies [#2] 2022-02-14 11:33:34 +08:00
Eric Fischer 42ee195bc3 Add an option to keep intersection nodes from being simplified away 2019-05-13 17:39:07 -07:00
Eric Fischer e89bdecb6d Merge branch 'master' into raw-tiles-zoom-enumerate 2019-04-08 16:28:12 -07:00
Eric Fischer 4f7459c797 Record the command line options in the tileset metadata 2019-04-04 17:03:36 -07:00
Eric Fischer e051c53051 Fix duplicated error message for unknown option 2019-03-19 10:16:14 -07:00
Eric Fischer ac12932089 Return a successful error status for --help and --version 2019-03-19 10:13:44 -07:00
Eric Fischer e805d113d0 Remove now-unused filter argument during parsing 2019-01-22 14:26:06 -08:00
Eric Fischer 32b14b1269 Limit detail to 30 and buffer 127 to prevent coordinate delta overflow 2018-12-18 15:53:11 -08:00
Eric Fischer 28f773a933 Better error message if the output tileset already exists 2018-12-13 11:20:06 -08:00
Eric Fischer 6376c283ba Add Hilbert Curve feature sequencing as an option 2018-12-12 10:51:00 -08:00
Eric Fischer 5229990523 Fix gridding of small squares; use less memory for small features 2018-11-21 15:34:43 -08:00
Eric Fischer bd2423a5ea Add an option to use a specified feature attribute as the feature ID 2018-11-02 15:21:52 -07:00
Eric Fischer 53de8a2014 Add an option to convert stringified number feature IDs to numbers 2018-11-01 17:07:33 -07:00
Eric Fischer 5dfbc4a281 Add --clip-bounding-box option to clip input geometry 2018-10-22 16:49:33 -07:00
Eric Fischer 7aebce7e0e Issue an error message in tile-join if minzoom is greater than maxzoom 2018-09-07 10:08:02 -07:00
Eric Fischer 216c0cf428 Be consistent about pluralization in the tilestats options 2018-08-31 16:19:55 -07:00
Eric Fischer bc84b41246 Add options to change the tilestats limits 2018-08-31 15:12:00 -07:00
Eric Fischer c9cc12e7ff Add "csv" to the list of suffixes to trim off of layer names 2018-08-01 17:49:54 -07:00
Eric Fischer 3fb833979e Take cluster distance into account when guessing a maxzoom 2018-08-01 13:14:14 -07:00
Eric Fischer 6f295f29fc Add an option to automatically assign ids to features 2018-07-26 15:08:47 -07:00
Eric Fischer 856c055857 Don't guess a higher maxzoom than is allowed for manual selection
If maxzoom + detail > 32, some geometric operations are undefined
2018-07-25 11:18:40 -07:00
Eric Fischer 87a1bb7851 Add an option to treat empty CSV columns as nulls, not empty strings 2018-07-19 14:33:33 -07:00
Eric Fischer 3cb09d0e2a Add the ability to specify the file format with -L{"format":"…"} 2018-07-17 14:57:56 -07:00
Eric Fischer 7f90ba5e1b Include version number in tile-join output too 2018-06-07 21:37:25 -07:00
Eric Fischer 4da6b932b3 Use "generator" instead of "creator". Silence another status message. 2018-06-07 15:17:58 -07:00
Eric Fischer b0229530ac Turn off progress indicators during tests
(For the sake of Travis's 4MB log limit)

Also fix a few places that logged progress even when told not to.
2018-06-07 13:27:49 -07:00
Eric Fischer 11c6c869aa Include a creator field in tileset metadata with the Tippecanoe version
Also finally eradicates binary diffs from the tests
2018-06-07 11:20:12 -07:00
Eric Fischer 48486b5d7b Add --use-source-polygon-winding and --reverse-source-polygon-winding 2018-06-01 12:59:28 -07:00
Eric Fischer bb8b01a702 Add option to specify description for attributes in tileset metadata 2018-05-24 14:18:22 -07:00
Eric Fischer 53731709b2 Add the option to specify layer file, name, and description as JSON 2018-05-24 11:30:42 -07:00
Eric Fischer 7128ac44d5 Track layer description as part of the tilestats 2018-05-24 10:27:43 -07:00
Eric Fischer 73398a0484 Use the FILE-like abstraction that zlib already provides 2018-05-14 12:40:38 -07:00
Eric Fischer 0244f04b71 Detect if the compressed input runs out before the stream is complete 2018-05-14 11:35:29 -07:00
Eric Fischer 974bfb3543 Add missing initializer in can't-be-compressed case 2018-05-11 17:13:06 -07:00
Eric Fischer 14b618adc9 Make stream lookahead work; simplify the interface 2018-05-11 16:02:53 -07:00
Eric Fischer 9f7dc4b46d Use zlib to decompress gzipped input 2018-05-11 15:51:53 -07:00
Eric Fischer 72b8142388 JSON-reading glue to use the stream abstraction 2018-05-11 14:58:29 -07:00