diff options
author | Leo Tenenbaum <pommicket@gmail.com> | 2021-02-08 11:33:43 -0500 |
---|---|---|
committer | Leo Tenenbaum <pommicket@gmail.com> | 2021-02-08 11:33:43 -0500 |
commit | abec84f7b2ee0f75c4622a6d4469dbf0c7eaf5ad (patch) | |
tree | 9cc6ccef1b897db7127f88a4de55c2f9b85c9535 /math.c | |
parent | f7828a0718b730ffdc6b9f25e5d11cbfd666acf1 (diff) |
find show number of matches
Diffstat (limited to 'math.c')
-rw-r--r-- | math.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -657,6 +657,8 @@ static float rect_x1(Rect r) { return r.pos.x; } static float rect_y1(Rect r) { return r.pos.y; } static float rect_x2(Rect r) { return r.pos.x + r.size.x; } static float rect_y2(Rect r) { return r.pos.y + r.size.y; } +static float rect_xmid(Rect r) { return r.pos.x + r.size.x * 0.5f; } +static float rect_ymid(Rect r) { return r.pos.y + r.size.y * 0.5f; } static void rect_coords(Rect r, float *x1, float *y1, float *x2, float *y2) { *x1 = r.pos.x; |