53 float x0 = line_pt_0->
pos.
x;
54 float x1 = line_pt_1->
pos.
x;
55 float y0 = line_pt_0->
pos.
y;
56 float y1 = line_pt_1->
pos.
y;
65 slope = (y0 - y1) / (x0 - x1);
66 intercept = y1 - x1 * slope;
69 p.
x = (int16_t) ((point->
pos.
x + (point->
pos.
y - intercept) * slope) /
71 p.
y = (int16_t) (slope * p.
x + intercept);
80 *near_pt =
closest(point, line_pt_0, line_pt_1);
EDGEPT * make_edgept(int x, int y, EDGEPT *next, EDGEPT *prev)
#define is_on_line(p, p0, p1)
bool near_point(EDGEPT *point, EDGEPT *line_pt_0, EDGEPT *line_pt_1, EDGEPT **near_pt)
#define closest(test_p, p1, p2)
#define same_point(p1, p2)