-
Notifications
You must be signed in to change notification settings - Fork 120
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for turf-line-intersect #1031
Comments
As is the case with many Turf methods, this method depends on other Turf methods and/or non-Turf libraries. This method uses We'd need to consider is how to deal with bringing this math logic into our port of this method. A similar conversation is happening at #987 (comment). |
Soooo, looks like we already have Returns a |
Well we don't have the exact method, because it's |
Indeed, mapbox-java/services-turf/src/main/java/com/mapbox/turf/TurfMisc.java Lines 314 to 320 in a86a614
The JavaScript implementation of turf-line-intersect is more efficient for longer lines, because it relies on a JavaScript implementation of the RBush algorithm, which isn’t available as part of mapbox-java yet. (But there may be Java implementations out there.) When we originally started porting Turf to Swift, we exposed /cc @LukasPaczos |
I opened the double |
Hi @OttyLab , @1ec5 , @LukasPaczos , May we have some updates please. Best, |
@762caliber The PR was merged. Next, it should be released. Is there any plan for the next release on |
We don't have any additional changes in the pipeline, so we'll release a mapbox-java |
What kind of issue is this?
Expected Behavior
I want to detect which roads intersect the route line I've drawn on the map and the coordinate pairs for these intersections.
Current Behavior
Currently there is no way to do this that's doesn't require a lot customer math on the part of the developer. This is because our Java Turf library does not support
turf-line-intersect
.Possible Implementation
Porting Turf's
lineIntersect
would be the most consistent, straightforward way to handle the above use case.The text was updated successfully, but these errors were encountered: