-
Notifications
You must be signed in to change notification settings - Fork 18
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
Line interception #73
base: main
Are you sure you want to change the base?
Conversation
assert_equal [Geometry::Point[1,1]], line2.intersection(line1) | ||
assert_equal [Geometry::Point[1,1]], line1.intersection(line2) | ||
end | ||
it "paralells lines shouldn't intercept" do |
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 this should be 'intersect' instead of 'intercept'
Thanks. We're off to a good start. I have a few comments...
Thanks for taking care of this. It's almost ready to go. |
lib/geometry/line.rb
Outdated
return [] | ||
end | ||
|
||
if object.vertical? || self.vertical? then |
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.
Can this be an elsif?
d49c509
to
b8ddf0e
Compare
4e17e62
to
492c9db
Compare
Any reason this is not yet merged to master? Seems legit to me, and most certainly a useful feature. I am debating using this library for re-implementation of my laser-cutter gem, since I had to build my own geometry objects, but I'd rather use something more feature rich and well tested. |
Because I completely forgot about it 😳 Nice gem. Why do I feel like I've heard about it somewhere? Hackaday? |
b6f172d
to
0a3ca21
Compare
Well ... this is my interception method. Whatever you think I should change just tell me.