From 1ed3cc394667612e8045cc05b77c2b766aeb9c69 Mon Sep 17 00:00:00 2001 From: herbglitch Date: Thu, 14 Sep 2023 01:34:29 -0600 Subject: [PATCH] working on ARC_FPoint_Lerp --- src/math/point.c | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 src/math/point.c diff --git a/src/math/point.c b/src/math/point.c new file mode 100644 index 0000000..7e1767c --- /dev/null +++ b/src/math/point.c @@ -0,0 +1,8 @@ +#include "arc/math/point.h" + +ARC_FPoint ARC_FPoint_Lerp(ARC_FPoint *start, ARC_FPoint *end, float t){ + return (ARC_FPoint){ + (1.0f - t) * start->x + t * end->x, + (1.0f - t) * start->y + t * end->y + }; +} \ No newline at end of file