From 5c27e48ccfd490a9c2ba94b33902d5e3fe272847 Mon Sep 17 00:00:00 2001 From: stefan schippers Date: Sat, 21 Oct 2023 22:37:01 +0200 Subject: [PATCH] fix rectangle intersection checker macro (RECT_TOUCH) --- src/xschem.h | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/xschem.h b/src/xschem.h index 05233969..425a95cd 100644 --- a/src/xschem.h +++ b/src/xschem.h @@ -323,13 +323,7 @@ extern char win_temp_dir[PATH_MAX]; #define RECT_OUTSIDE(xa,ya,xb,yb,x1,y1,x2,y2) \ ( (xa) > (x2) || (xb) < (x1) || (ya) > (y2) || (yb) < (y1) ) -#define RECT_TOUCH(xa,ya,xb,yb,x1,y1,x2,y2) \ - ( POINTINSIDE(xa,ya,x1,y1,x2,y2) || \ - POINTINSIDE(xa,yb,x1,y1,x2,y2) || \ - POINTINSIDE(xb,ya,x1,y1,x2,y2) || \ - POINTINSIDE(xb,yb,x1,y1,x2,y2) ) - - +#define RECT_TOUCH(xa,ya,xb,yb,x1,y1,x2,y2) (!(xa > x2 || xb < x1 || ya > y2 || yb < y1)) #define ROTATION(rot, flip, x0, y0, x, y, rx, ry) \ { \