diff options
| author | Arne Dußin | 2020-11-12 23:37:43 +0100 |
|---|---|---|
| committer | Arne Dußin | 2020-11-12 23:37:43 +0100 |
| commit | 8ae528e9a2b219c5ac2f0b967c0cb91e79921e21 (patch) | |
| tree | d49d1133baae2c62170d6a84479806d57295d63a /src/math/line_segment.rs | |
| parent | a22faae428f7ff51a0b2eaea902e5b5ed1a7c8a5 (diff) | |
| download | graf_karto-8ae528e9a2b219c5ac2f0b967c0cb91e79921e21.tar.gz graf_karto-8ae528e9a2b219c5ac2f0b967c0cb91e79921e21.zip | |
Fix the polygon point containment algorithm
The algorithm before was really not working for a lot of edge cases and
very difficult to adapt. This version is definitely not the be-all and
end-all, but it should work for most (well, hopefully all) cases. After
refactoring and hopefully simplifying and straightening out the logic a
little more, it should be verifiable.
Diffstat (limited to 'src/math/line_segment.rs')
| -rw-r--r-- | src/math/line_segment.rs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/math/line_segment.rs b/src/math/line_segment.rs index d7bcdb1..338a681 100644 --- a/src/math/line_segment.rs +++ b/src/math/line_segment.rs @@ -3,6 +3,7 @@ use alga::general::{ClosedMul, ClosedSub}; use nalgebra::Scalar; use num_traits::Zero; +#[derive(Debug)] pub struct LineSegment<T: Scalar + Copy> { pub start: Vec2<T>, pub end: Vec2<T>, |
