34#define GEOMPROCS_API __declspec(dllexport)
36#define GEOMPROCS_API __declspec(dllimport)
65#define EXPANDBB(b0, b1) \
66 (_Generic((b0), box *: expandbb, boxf *: expandbbf)((b0), (b1)))
107 r.
x = (p.
x + q.
x) / 2.;
108 r.
y = (p.
y + q.
y) / 2.;
115 r.
x = p.
x + t * (q.
x - p.
x);
116 r.
y = p.
y + t * (q.
y - p.
y);
geometric types and macros (e.g. points and boxes)
static void expandbp(boxf *b, pointf p)
expand box b as needed to enclose point p
static WUR point add_point(point p, point q)
static WUR pointf perp(pointf p)
GEOMPROCS_API pointf cwrotatepf(pointf p, int cwrot)
static WUR point exch_xy(point p)
static WUR pointf mid_pointf(pointf p, pointf q)
GEOMPROCS_API int lineToBox(pointf p1, pointf p2, boxf b)
GEOMPROCS_API pointf ccwrotatepf(pointf p, int ccwrot)
GEOMPROCS_API boxf flip_rec_boxf(boxf b, pointf p)
static void expandbbf(boxf *b0, boxf b1)
static WUR pointf sub_pointf(pointf p, pointf q)
GEOMPROCS_API double ptToLine2(pointf l1, pointf l2, pointf p)
static WUR pointf add_pointf(pointf p, pointf q)
static WUR pointf interpolate_pointf(double t, pointf p, pointf q)
static WUR pointf exch_xyf(pointf p)
static void expandbb(box *b0, box b1)
expand box b0 as needed to enclose box b1
static WUR pointf scale(double c, pointf p)
GEOMPROCS_API void rect2poly(pointf *p)
static WUR bool boxf_overlap(boxf b0, boxf b1)
GEOMPROCS_API int line_intersect(pointf a, pointf b, pointf c, pointf d, pointf *p)
abstraction for squashing compiler warnings for unused symbols