-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Add intersects function
#6967
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
Open
seadowg
wants to merge
43
commits into
getodk:master
Choose a base branch
from
seadowg:intersects
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+918
−156
Open
Add intersects function
#6967
Changes from 40 commits
Commits
Show all changes
43 commits
Select commit
Hold shift + click to select a range
1c5868b
Add intersects util
seadowg fd4a6a1
Add intersects function handler
seadowg ab235b8
Use prototypes to get already evaluated args
seadowg 4fb7739
Add test for non geotrace/shape strings
seadowg 3419811
Add test cases for repeated segments and closed traced intersection
seadowg 9641e08
Add intersects function handler to Collect
seadowg b2f3cc7
Move parseGeometry and parseGeometryPoint tests to geo
seadowg a11a20d
Convert GeoUtils to Kotlin
seadowg 7508fe8
Move parseGeometryPoint to GeoUtils
seadowg 17e52e8
Fix import in test
seadowg 83a60e2
Throw exception for non-geotrace inputs
seadowg 281fd94
Improve converted code
seadowg d21470c
Use zipWithNext to simplify creating segments
seadowg 7256252
Add test to check arg length is enforced
seadowg 77bec29
Switch test to Hamcrest
seadowg 2a3cd02
Remove unused imports
seadowg da8e9a7
Add another test case to make sure we check intersections from both s…
seadowg d853d05
Add failing tests for non crossing intersections
seadowg 292b7be
Rename method
seadowg e074729
Fix origin of one segment touching another case
seadowg 7055bdc
Correct test
seadowg 527ae8e
Fix line moving back on itself case
seadowg e7a8662
Add test for shape that closes outside the origin
seadowg 0800a0e
Simplify non-origin vertex closing
seadowg 602fee7
Use bounding box check based on orientation to solve right angled tri…
seadowg ad81da9
Fix special case with two segmnt intersection
seadowg 69d4c8a
Pull out specific 2D geometry code
seadowg 8860a4a
Make sure checking instersection between segments is exhaustive
seadowg e7b2a71
Remove unneeded return
seadowg 30dbba2
Correct bounding box check direction
seadowg 8822207
Add additional (failing) test for 2 segment self intersection
seadowg 8e0e0c7
Account for case where first endpoint intersects with second segment …
seadowg 970b508
Filter out zero length segments in traces
seadowg 1d1a320
Remove unneeded return
seadowg bba4264
Fix reversed line with 3 points case
seadowg 2fb19f8
Add basic metamorphic test for intersects
seadowg 9f596bc
Improve adding intersecting segment using interpolation
seadowg 29936a8
Add epsilon to colinearity check to prevent precision errors
seadowg 08c5997
Fix accidental map
seadowg c6aa7c0
Add docs for interpolate
seadowg 6a0e2e0
Increase the number of possible random intersection points in test
seadowg ac13533
Add tests for LineSegment#interpolate
seadowg d88de71
Add quickCheck helper
seadowg File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm in two minds about this being untested. It can be seen as pure "configuration" from one angle, but also if I delete it then
intersectswon't work. Maybe it's worth replacing one of theIntersectsFunctionHandlertests (probably the detects intersection path) with a feature test?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would make sense.