107 double ax = a->
x - cx;
108 double ay = a->
y - cy;
109 double bx = b->
x - cx;
110 double by = b->
y - cy;
112 double denom = 2 *
det(ax, ay, bx, by);
113 double numx =
det(ay, ax * ax + ay * ay, by, bx * bx + by * by);
114 double numy =
det(ax, ax * ax + ay * ay, bx, bx * bx + by * by);
116 result->
x = cx - numx / denom;
117 result->
y = cy + numy / denom;
static double det(double m00, double m01, double m10, double m11)