summaryrefslogtreecommitdiff
path: root/maths.h
diff options
context:
space:
mode:
authorquou <quou@disroot.org>2024-07-17 21:28:38 +1000
committerquou <quou@disroot.org>2024-07-17 21:28:38 +1000
commit9bbef8bd2cc004ca1baa2306a8c42120eb5fdc36 (patch)
tree5099eaee667ee83325c0cb4b603a5fe5fef46d56 /maths.h
parent1453334863205022b9d8a830cecf3ed01390a3cc (diff)
Square root approx function and normalise.
Diffstat (limited to 'maths.h')
-rw-r--r--maths.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/maths.h b/maths.h
index af2a027..e72f8fd 100644
--- a/maths.h
+++ b/maths.h
@@ -21,6 +21,7 @@ extern int sqrt_table[sqrt_table_count];
void init_maths(void);
int fpow(int a, int p);
+int fsqrt(int a);
int* mtx_iden(int* m);
int* mtx_cpy(int* d, const int* s);
@@ -41,6 +42,8 @@ int* mtx_apply(const int* m, int* v);
int* vec_cpy(int* d, const int* s, int c);
int* vec_ref(int* d, const int* i, const int* n, int c);
int vec_dot(const int* a, const int* b, int d);
+int* vec_nrm(int* d, const int* a, int c);
+int* vec_minise(int* d, const int* a, int c);
int* persp(int* v, int asp);
int* ndc2clip(const int* c, int* p);