summaryrefslogtreecommitdiff
path: root/arm9/lib/src
diff options
context:
space:
mode:
authorMade <made111@gmx.de>2020-05-01 19:06:20 +0200
committerMade <made111@gmx.de>2020-05-01 19:06:20 +0200
commitfefbe6b2dbc36e45fd521a75970fa58df5690615 (patch)
tree9443e55b12f434d3775f88a7799877d9384456a3 /arm9/lib/src
parent009d3fbcf7e1e3ea94656b5233e0bc96fa7b5a5b (diff)
better vector names
Diffstat (limited to 'arm9/lib/src')
-rw-r--r--arm9/lib/src/FX_vec_c.c36
1 files changed, 18 insertions, 18 deletions
diff --git a/arm9/lib/src/FX_vec_c.c b/arm9/lib/src/FX_vec_c.c
index a2e0ffe4..bebf7ca0 100644
--- a/arm9/lib/src/FX_vec_c.c
+++ b/arm9/lib/src/FX_vec_c.c
@@ -2,33 +2,33 @@
#include "main.h"
#include "fx.h"
-void VEC_Add(struct Vecx32 *x, struct Vecx32 *y, struct Vecx32 *dst){
- dst->x = x->x + y->x;
- dst->y = x->y + y->y;
- dst->z = x->z + y->z;
+void VEC_Add(struct Vecx32 *a, struct Vecx32 *b, struct Vecx32 *dst){
+ dst->x = a->x + b->x;
+ dst->y = a->y + b->y;
+ dst->z = a->z + b->z;
}
-void VEC_Subtract(struct Vecx32 *x, struct Vecx32 *y, struct Vecx32 *dst){
- dst->x = x->x - y->x;
- dst->y = x->y - y->y;
- dst->z = x->z - y->z;
+void VEC_Subtract(struct Vecx32 *a, struct Vecx32 *b, struct Vecx32 *dst){
+ dst->x = a->x - b->x;
+ dst->y = a->y - b->y;
+ dst->z = a->z - b->z;
}
-void VEC_Fx16Add(struct Vecx16 *x, struct Vecx16 *y, struct Vecx16 *dst){
- dst->x = x->x + y->x;
- dst->y = x->y + y->y;
- dst->z = x->z + y->z;
+void VEC_Fx16Add(struct Vecx16 *a, struct Vecx16 *b, struct Vecx16 *dst){
+ dst->x = a->x + b->x;
+ dst->y = a->y + b->y;
+ dst->z = a->z + b->z;
}
-s32 VEC_DotProduct(struct Vecx32 *x, struct Vecx32 *y){
- return ((s64)x->x * y->x + (s64)x->y * y->y + (s64)x->z * y->z + (1 << (FX64_INT_SHIFT - 1))) >> FX64_INT_SHIFT;
+s32 VEC_DotProduct(struct Vecx32 *a, struct Vecx32 *b){
+ return ((s64)a->x * b->x + (s64)a->y * b->y + (s64)a->z * b->z + (1 << (FX64_INT_SHIFT - 1))) >> FX64_INT_SHIFT;
}
-s32 VEC_Fx16DotProduct(struct Vecx16 *x, struct Vecx16 *y){
+s32 VEC_Fx16DotProduct(struct Vecx16 *a, struct Vecx16 *b){
s32 temp1, temp2;
- temp1 = (x->x * y->x) + (x->y * y->y);
- temp2 = (x->z * y->z) + (1 << (FX64_INT_SHIFT - 1));
+ temp1 = (a->x * b->x) + (a->y * b->y);
+ temp2 = (a->z * b->z) + (1 << (FX64_INT_SHIFT - 1));
return (s32)(((s64)temp1 + temp2) >> FX64_INT_SHIFT);
}
-void VEC_CrossProduct(struct Vecx32 *x, struct Vecx32 *y, struct Vecx32 *);
+void VEC_CrossProduct(struct Vecx32 *a, struct Vecx32 *b, struct Vecx32 *dst);