Closed Huite closed 1 week ago
This is due to dx
, dy
not getting updated: https://github.com/Deltares/numba_celltree/blob/374a7a4a7606952d2487b0d96ec5c6603cfd286f/numba_celltree/algorithms/cohen_sutherland.py#L74
It can be triggered by this:
Where b
is equal to (xmin, ymax).
Liang-Barsky is also not consistent here, since it returns True
for intersection although the resulting edge is a single point.
Fixed by f47aa91c49af61657c8d8bb5d8aa60556e251518
This is fine:
But testing a grid against its own edges either enters a infinite loop or something else:
Needs testing with a smaller example.