Skip to content
This repository has been archived by the owner on Dec 4, 2024. It is now read-only.

Kill jsts #10

Closed
wants to merge 11 commits into from
Closed

Kill jsts #10

wants to merge 11 commits into from

Conversation

tcql
Copy link
Member

@tcql tcql commented May 8, 2015

This PR uses the greiner-hormann algorithm that I've been working on implementing. It's considerably faster than JSTS, and removes our dependency on JSTS, aside from turf-buffer.

There are likely some quirks / edge case failures here, but we'll deal with those as they come up. Here's some known differences in the behavior:

  • Intersect / Union / Difference no longer will return linestrings or points for cases where polygons touch at only an edge or a point (or several edges or points)
  • Returned point orders may be different

@tcql
Copy link
Member Author

tcql commented May 8, 2015

oh woops, messed up some of the comments / docblock. I'll fix it up.

@tcql
Copy link
Member Author

tcql commented May 8, 2015

Note: I changed the tests and pulled in dev-dependency geojson-equality because point orders in results changed

@anandthakker
Copy link

@tchannel @morganherlocker Anything I could do to help this along?

@morganherlocker
Copy link
Member

@anandthakker the one remaining JSTS dependency is for polygon buffering.

@anandthakker
Copy link

@morganherlocker Oof

@tcql
Copy link
Member Author

tcql commented Jul 21, 2015

@anandthakker I've also noticed a few bugs in the Greiner-Hormann implementation, which I've been chipping away at (tcql/greiner-hormann#15, tcql/greiner-hormann#14)

I also want to clean up, RE: tcql/greiner-hormann#11

@DrColossos
Copy link

is there any progress on this? we would love to have this inside turf-intersect since JSTS bloats our build immensely.

@DenisCarriere
Copy link
Member

@tcql great work on these commits 👍
I want to merge this, however could you send a PR to the main TurfJS repo instead.

https://github.com/Turfjs/turf/tree/master/packages/turf-intersect

If not, let me know and I can help out with merging it into main Turf repo.

@tcql
Copy link
Member Author

tcql commented Mar 16, 2017

@DenisCarriere the greiner-hormann has some pretty serious bugs that I found after putting this PR together. The package also hasn't been under development recently. I'd still love to circle back sometime and improve it, but for now this dependency murderquest is dead.

@tcql tcql closed this Mar 16, 2017
This was referenced Mar 16, 2017
@DenisCarriere
Copy link
Member

@tcql that's a shame... I'm very PRO removing jsts, however it's not going to be an easy task.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants