Commit Graph
1935 Commits
Author SHA1 Message Date
Erica Fischer 52e6e7479a So many affected tests 2023-11-14 12:26:32 -08:00
Erica Fischer 78a964776f Don't revive spikes that are beyond the tile edge 2023-11-14 12:19:18 -08:00
Erica Fischer b22d6c8ba1 Remove debug spew 2023-11-14 10:06:42 -08:00
Erica Fischer 624c2b697a Try to fix winding reversals introduced by scaling 2023-11-14 09:56:31 -08:00
Erica Fischer bee87bdab2 Limit decay into polygon dust to reasonably compact polygons 2023-11-13 22:16:37 -08:00
Erica Fischer dd8762da1f Remove dead code 2023-11-13 16:03:52 -08:00
Erica Fischer c05ae1bbff Compare segments to the current pool as they come into scope 2023-11-13 13:08:46 -08:00
Erica Fischer 1238711571 Only reinspect segments that changed in the previous pass 2023-11-13 12:12:58 -08:00
Erica Fischer d23f0a243b Speed improvements from doing less repetitive rounding 2023-11-13 11:31:14 -08:00
Erica Fischer e80d8786b8 Drop holes that are not inside an outer ring 2023-11-13 10:30:14 -08:00
Erica Fischer 546b5fdbd3 Remove collinear points 2023-11-13 10:24:07 -08:00
Erica Fischer bd24168416 Add missing header 2023-11-13 10:10:26 -08:00
Erica Fischer d06363e9f9 Turn polygon revival back on; turn off some debug spew 2023-11-12 23:17:26 -08:00
Erica Fischer c0866b9cde Maybe right now? 2023-11-12 22:51:28 -08:00
Erica Fischer ba9dbda6f6 Something is wrong with the traversal 2023-11-12 19:19:35 -08:00
Erica Fischer 3eddb81d81 Trying to straighten out ring nesting 2023-11-12 18:28:43 -08:00
Erica Fischer 5d6a54a235 Ring nesting isn't right yet, so just keep the outer rings 2023-11-11 22:57:47 -08:00
Erica Fischer 10290b1b1b Committing to integer coordinates to fix more accidental mirror segs 2023-11-10 15:45:25 -08:00
Erica Fischer e849d42b13 Bow spindle polygons out in the center to prevent collapse 2023-11-10 14:40:49 -08:00
Erica Fischer c59202788a Remove debug spew 2023-11-10 12:35:56 -08:00
Erica Fischer 5e14b68560 Ring search basically works now? 2023-11-10 12:31:37 -08:00
Erica Fischer f6305b9b51 Deal with horizontals 2023-11-10 09:28:24 -08:00
Erica Fischer 35231d39e4 Deal with vertical lines 2023-11-09 15:15:57 -08:00
Erica Fischer 6bd0cdcb1b Fix multiply duplicated spikes 2023-11-09 14:26:13 -08:00
Erica Fischer 5ba24f0712 Get rid of most spikes 2023-11-09 14:04:38 -08:00
Erica Fischer 474270c151 Visual testing 2023-11-09 13:38:26 -08:00
Erica Fischer 22c308f623 Do some intersecting 2023-11-09 11:09:40 -08:00
Erica Fischer 3f98aa96b2 More missing headers and compiler warnings 2023-11-09 09:16:28 -08:00
Erica Fischer 690738b69c Add some missing headers 2023-11-09 09:11:41 -08:00
Erica Fischer c540ec5764 More progress on intersecting 2023-11-09 09:08:32 -08:00
Erica Fischer 31defc1dc2 Line intersection algorithms 2023-11-08 22:32:23 -08:00
Erica Fischer 6bebc1b427 Doing the scan line through the segments 2023-11-08 15:44:01 -08:00
Erica Fischer 966b911e1f Setting up for scanline 2023-11-08 14:55:27 -08:00
Erica Fischer e15239efdb Starting on my own polygon cleaner 2023-11-08 14:42:35 -08:00
Erica Fischer d359461e61 Reduce tile-join overzooming memory usage (#162)
* 16 bits is enough for tile numbers

* Revert "16 bits is enough for tile numbers"

This reverts commit 71a0c4e1cf.

* Check what child tiles each overzoomed tile will have

and don't queue further overzooming of empty tiles

* Clean up naming; use std::move to avoid copying large arrays
2.37.0
2023-11-08 12:51:28 -08:00
Erica Fischer 2c56187530 Make tile-join distrust source tilesets' metadata maxzoom and minzoom (#161)
* Special-case a longitude wraparound of exactly 360°

* Update version and changelog

* Make tile-join distrust source tilesets' metadata maxzoom and minzoom
2.36.0
2023-11-07 14:41:05 -08:00
Erica Fischer e1c665b35d Only detect longitude wraparound within each ring. (#150)
* Only detect longitude wraparound within each ring.

Between rings it's OK to jump around from one side of the world
to the other.

* Add test

* Update changelog
2.35.0
2023-10-17 12:04:47 -07:00
Erica Fischer 0ca14086a9 Pull from the back of the list of tiles to overzoom, not the front (#149) 2.34.1 2023-10-04 14:59:19 -07:00
Erica Fischer cc5c1c79df Speed up overzooming in tile-join (#147)
* Clip away entire features by bbox. Avoid unnecessary recompression.

* Move parent tile decoding in tile-join out of overzoom proper

* An ever-growing cache of parent tiles

* Limit the size of the cache

* Remove the current reader *before* checking if we can run the queue

* Clean up

* Add missing #include

* Add comment

* When the tile-join cache fills up, evict the least recently used

* Fix microsecond math

* Factoring out tile-join's cache for testing

* Add unit tests for tile-join cache

* Update changelog and version
2.34.0
2023-10-04 12:14:22 -07:00
Erica Fischer 26bf08deb2 Externalizing polygon shard detection (#146)
* Start of externalizing polygon shard detection

* Completely untested external quicksort

* Add unit test for external quicksort

* Remember to clean up temporary files

* Sort and scan the vertices

* Bring over more vertex logic

* Make nodes from vertices

* Checkpoint on switching over to global shared nodes

* Do the thing

* Revert unintended change to coalesced linestring behavior

* Take shared nodes into account in early simplification

* Let it do more sorting in memory

* Fix overnoding of collinear linestrings

* Remove duplicate nodes, since only duplicate vertices now matter

* Remember to delete temporary files

* Fix out of bounds memory access below, apparently

* Fix the actual undefined behavior

* Still running out of memory in one case. Find out where.

* Forgot the conditional

* Try again to make it not run out of memory

* Update version and changelog
2.33.0
2023-10-03 10:53:12 -07:00
hfs dcc3a11915 Fix "make test": build required binaries first (#143)
When running "make test" in a pristine working copy, the "test" target
calls the "raw-tiles-test" target, which tries to execute ./tile-join.
But that binary has not been built, yet, at this point. The target fails
with an error.

Add the required binaries as dependencies to the test targets in the
Makefile. This makes sure that they are built before they are attempted
to be executed.
2023-10-02 10:47:32 -07:00
Erica Fischer f7dc7faf31 Reduce memory use of polygon shard detection (#139)
* Crunch down memory required per polygon joint

* *Actually* reduce the size of the structure

* Update version and changelog
2.32.1
2023-09-21 10:59:12 -07:00
Erica Fischer 390771f855 Polygon shards (#105)
* Put all of this back in geometry.cpp for conflict resolution

* Stabilize line simplification to behave the same regardless of winding

* Round instead of truncating when clipping lines

* Restore non-Wagyu polygon clipping from prior to 2fdec7d2

* Make it round, not truncate, which reverts the last commit's test diffs

* Clip in floating point, not integers, which makes no difference

* Track nodes added at tile edges during clipping

* Scale geometry up before wagyu to prevent changes from precision loss

* Actually do the shared edge detection

* Fix cases where nodes were not being added at the tile boundary

* One more place I should have rounded

* Narrow down where the discrepancy comes in

* Revert "Narrow down where the discrepancy comes in"

This reverts commit 221c4c5fc0ac9a6567e091c6a94b3d87dc8ade83.

* Another attempt to narrow it down

* The discrepancy seems to be introduced in reordering. No obvious bug

* Was still truncating instead of rounding in projection

* Also makes no difference...

* Just forget that line reversal exists for a minute

* Just reversal no coalescing

* Try clipping in integers instead of floating point

* Don't simplify after coalescing if they said no simplification

* Check whether behavior is consistent with intentional simplification

* Replace more floating point with integer

* Are these three features enough to demonstrate the problem?

* Add a few more nearby borders

* All the features that touch tile 6/16/23

* Stay in integers in line simplification

* More attempts to solve failures to simplify consistently

* Fix most of the overflow errors

* Fix known cases of integer overflow

* All the tests change again

* Pull clipping and scaling code back out into clip.cpp

* Resolve the test conflicts

* Stabilize choice of which three points to keep with different windings

* Almost right, I think!

* Fix collapse of islands to shards

* Self-intersections in the same feature don't count

* Revert "Self-intersections in the same feature don't count"

This reverts commit e04b19916e.

* Don't scale down geometry if we are going to look for shared nodes

* Fix the missing multiply that was keeping simplification from happening

* Fix one more opportunity for overflow

* Somehow I deleted this test?

* Lost this test too

* Clean up debugging printfs

* Restore code sequence from main to make it reviewable

* Remove unneeded rounding

* Update documentation

* This test is no longer useful

* Back to floating point Douglas-Peucker to fix undersimplification

* Try an older ubuntu

* Revert "Try an older ubuntu"

This reverts commit 13fefacfd7.

* Log OS info

* Remove tests that are no longer needed

* Oops, did need that one after all

* Fix the arm vs x86 discrepancy?

* Try another quantization

* Cleanup from review

* Add a test for the actual purpose of this PR
2.32.0
2023-09-14 16:51:38 -07:00
Tobias dee40802fd Docs: Link to layer name section (#135)
Add internal link to help understand how the layer name will be derived (and how to overwrite the default behavior)
2023-09-14 16:18:06 -07:00
Erica Fischer e6d05bc317 Fix tile-join crash when trying to merge empty tilesets with --overzoom (#138)
* Fix tile-join crash when trying to merge empty tilesets with --overzoom

* Add an option not to reduce tiny polygons to dust at maxzoom

* Add test for prevention of tiny polygon reduction at maxzoom

* Change version number
2.31.0
2023-08-31 13:02:03 -07:00
Erica Fischer 2ec6180003 Fix "strategies" accounting for 0-length linestrings and degenerate polygons (#137)
* Dropping a 0-length feature doesn't count as dropping-as-needed

* Add an option not to reduce tiny polygons to dust at maxzoom

* Add test for prevention of tiny polygon reduction at maxzoom

* Fix accounting for tiny polygons not to include degenerate geometries

* Revert "Add test for prevention of tiny polygon reduction at maxzoom"

This reverts commit f931bbd73e.

* Revert "Add an option not to reduce tiny polygons to dust at maxzoom"

This reverts commit 03f0882bb6.

* Fix tests

* Another test that no longer has any really tiny polygons

* Oops, that broke LineString simplification

* This time for sure!

* Update changelog and version
2.30.1
2023-08-29 10:54:39 -07:00
Erica Fischer 6778aeac52 Add an option to extend zooms if still dropping, but with a limit (#131)
* Add an option to extend zooms if still dropping, but with a limit

* At least when to overzoom, even if not actually doing it yet

* Refactor to give tile-join access to overzoom()

* Didn't work, but *might* have worked

* OK, it did something now

* Ah, there's the bug!

* Hook up pmtiles and dirtiles as overzooming sources

* Add command line option to enable or disable overzooming

* Add (currently broken) test of overzooming in tile-join

* Slightly more abstraction for the tile-join readers

* Factor out duplicated code

* Move construction into a constructor

* More changing accessors to methods

* Reduce magic

* Start tracking a list of the tiles at maxzoom

* I think it worked?

* Add missing #include

* Fix sequence of overzoomed tiles (Y sorts backwards for TMS)

* Don't spend memory on overzooming when we aren't going to use it

* Diff rather than cmp, in the hope of figuring out this broken test

* Keep full coordinate precision if we might extend zooms

* Try a slightly different byte limit

* Make drop-densest more consistent across tile boundaries

* Also affects this test

* Does it behave any differently if it can extend forever?

* I think the discrepancy is a thread-safety problem here

* Revert "Does it behave any differently if it can extend forever?"

This reverts commit 0dff0a0acc.

* Lost this change to the test

* This time for sure!

* Revert "Also affects this test"

This reverts commit cd1f7c2e78.

* Revert "Make drop-densest more consistent across tile boundaries"

This reverts commit 563f7d2bc2.

* Revert "Try a slightly different byte limit"

This reverts commit 2e271213d6.

* Add some more explanatory comments

* Amend the join-test to detect my current bug

* Allow overzooming to complete the zoom if it ever starts

* Forgot to correct the test

* Update changelog and version

* Cleanups from code review

* Remove version number from fixture to fix test
2.30.0
2023-08-25 12:42:38 -07:00
Jason FerrierandJason Ferrier 39ad95ed73 Updated installation instructions to include Homebrew (#130)
Updated installation instructions. felt/tippecanoe#70

Co-authored-by: Jason Ferrier <Jason.Ferrier@nrel.gov>
2023-08-18 16:15:32 -07:00
Bert Temme 2b133a1def Update Dockerfile typo tippacanoe -> tippecanoe (#129) 2023-08-14 14:07:15 -07:00
Brandon Liu f00eeb486a Fix narrowing of index_size (#126)
Fix narrowing of index_size, affecting indexed flatgeobufs with lots of features [#125]
2023-08-14 14:06:38 -07:00