diff options
author | David Thompson <dthompson2@worcester.edu> | 2020-11-13 22:26:14 -0500 |
---|---|---|
committer | David Thompson <dthompson2@worcester.edu> | 2020-11-13 22:26:44 -0500 |
commit | cf69fb3440d59bddc9b37374330b12e1365a407c (patch) | |
tree | f98aebe7601b55cf2e71190073145cd5dd291cce | |
parent | 34057231e45651a4e3d8ec1d11d958e6ea76653f (diff) |
math: rect: Fix rect-union and rect-clip.
-rw-r--r-- | chickadee/math/rect.scm | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/chickadee/math/rect.scm b/chickadee/math/rect.scm index cd83e2e..8c80a75 100644 --- a/chickadee/math/rect.scm +++ b/chickadee/math/rect.scm @@ -332,15 +332,15 @@ same point." "Return a new rect that completely covers the area of RECT1 and RECT2." (with-new-rect rect - (rect-copy! rect2 rect1) - (rect-union! rect1 rect2))) + (rect-copy! rect1 rect) + (rect-union! rect rect2))) (define (rect-clip rect1 rect2) "Return a new rectangle that is the overlapping region of RECT1 and RECT2. If the rects do not overlap, a rect of size 0 is returned." (with-new-rect rect - (rect-copy! rect2 rect1) - (rect-clip! rect1 rect2))) + (rect-copy! rect1 rect) + (rect-clip! rect rect2))) ;;; |