4
#include "predicates.h"
7
#define wrap2d(wrap_name,shewchuk_name) \
9
int wrap_name (double x1, double y1, double x2, double y2) \
11
double a[2], b[2], c[2]; \
12
a[0] = x1; a[1] = y1; \
13
b[0] = x2; b[1] = y2; \
15
double r = shewchuk_name (a, b, c); \
16
return (r > 0) ? 1 : ((r < 0) ? -1 : 0); \
18
wrap2d (ABDPY_det2x2, orient2d)
19
wrap2d (ABDPY_secure_det2x2, orient2dexact)
20
wrap2d (ABDPY__not_lazy_det2x2, orient2dslow)
21
//wrap2d (double_det2x2, orient2dfast)
22
//wrap2d (quadruple_det2x2, orient2dfast)
25
#define wrap3d(wrap_name,shewchuk_name) \
27
int wrap_name (double x1, double y1, double z1, \
28
double x2, double y2, double z2, \
29
double x3, double y3, double z3) \
31
double a[3], b[3], c[3], d[3]; \
32
a[0] = x1; a[1] = y1; a[2] = z1; \
33
b[0] = x2; b[1] = y2; b[2] = z2; \
34
c[0] = x3; c[1] = y3; c[2] = z3; \
35
d[0] = 0; d[1] = 0; d[2] = 0; \
36
double r = shewchuk_name (a, b, c, d); \
37
return (r > 0) ? 1 : ((r < 0) ? -1 : 0); \
39
wrap3d (ABDPY_det3x3, orient3d)
40
wrap3d (ABDPY_secure_det3x3, orient3dexact)
41
wrap3d (ABDPY__not_lazy_det3x3, orient3dslow)
42
//wrap3d (double_det3x3, orient3dfast)