SSBM Decomp
Loading...
Searching...
No Matches
lbvector.h
Go to the documentation of this file.
1#ifndef GALE01_00D2EC
2#define GALE01_00D2EC
3
4#include <baselib/forward.h>
5
6#include <dolphin/mtx.h>
8
9static float lbVector_Len(Vec3* vec);
10static float lbVector_Len_xy(Vec3* vec);
11
12float lbVector_Normalize(Vec3* vec);
13float lbVector_NormalizeXY(Vec3* a);
14Vec3* lbVector_Add(Vec3* a, Vec3* b);
15Vec3* lbVector_Add_xy(Vec3* a, Vec3* b);
16Vec3* lbVector_Sub(Vec3* a, Vec3* b);
17Vec3* lbVector_Diff(Vec3* a, Vec3* b, Vec3* result);
18Vec3* lbVector_CrossprodNormalized(Vec3* a, Vec3* b, Vec3* result);
19
20float lbVector_Angle(Vec3* a, Vec3* b);
21float lbVector_AngleXY(Vec3* a, Vec3* b);
22
23static float sin(float angle);
24static float cos(float angle);
25
26void lbVector_RotateAboutUnitAxis(Vec3* v, Vec3* axis, float angle);
27void lbVector_Rotate(Vec3* v, int axis, float angle);
28
29float dummy(void);
30void lbVector_Mirror(Vec3* a, Vec3* b);
31float lbVector_CosAngle(Vec3* a, Vec3* b);
32Vec3* lbVector_Lerp(Vec3* a, Vec3* b, Vec3* result, float f);
33Vec3* lbVector_8000DE38(Mtx m, Vec3* v, float c);
34
35Vec3* lbVector_EulerAnglesFromONB(Vec3* result_angles, Vec3* a, Vec3* b,
36 Vec3* c);
37Vec3* lbVector_EulerAnglesFromPartialONB(Vec3* result_angles, Vec3* a,
38 Vec3* c);
39Vec3* lbVector_ApplyEulerRotation(Vec3* v, Vec3* angles);
40float lbVector_sqrtf_accurate(float x);
41
42Vec3* lbVector_WorldToScreen(HSD_CObj* cobj, const Vec3* pos3d,
43 Vec3* screenCoords, int d);
44void lbVector_CreateEulerMatrix(Mtx m, Vec3* angles);
45float lbVector_8000E838(Vec3* a, Vec3* b, Vec3* c, Vec3* d);
46
47#endif
u8 b
Definition grstadium.c:48
Vec3 * lbVector_Add(Vec3 *a, Vec3 *b)
Definition lbvector.c:53
float lbVector_NormalizeXY(Vec3 *a)
Definition lbvector.c:39
Vec3 * lbVector_ApplyEulerRotation(Vec3 *v, Vec3 *angles)
8000E138
Definition lbvector.c:354
static float cos(float angle)
Vec3 * lbVector_Lerp(Vec3 *a, Vec3 *b, Vec3 *result, float f)
8000DDAC - linearly interpolates between a and b as f goes from 0 to 1, returns a + f*(b-a).
Definition lbvector.c:280
Vec3 * lbVector_8000DE38(Mtx m, Vec3 *v, float c)
Definition lbvector.c:290
float dummy(void)
Definition lbvector.c:253
Vec3 * lbVector_Diff(Vec3 *a, Vec3 *b, Vec3 *result)
Definition lbvector.c:76
float lbVector_CosAngle(Vec3 *a, Vec3 *b)
8000DCA8 - returns <a/|a|, b/|b|>, which is the cosine of the angle between a and b.
Definition lbvector.c:271
static float lbVector_Len_xy(Vec3 *vec)
float lbVector_Angle(Vec3 *a, Vec3 *b)
8000D620 - returns the angle between a and b
Definition lbvector.c:92
void lbVector_RotateAboutUnitAxis(Vec3 *v, Vec3 *axis, float angle)
8000D8F4 Rotates v by angle about the given axis.
Definition lbvector.c:162
Vec3 * lbVector_Add_xy(Vec3 *a, Vec3 *b)
Definition lbvector.c:61
void lbVector_Rotate(Vec3 *v, int axis, float angle)
Definition lbvector.c:223
Vec3 * lbVector_EulerAnglesFromPartialONB(Vec3 *result_angles, Vec3 *a, Vec3 *c)
8000DFF4 - returns lbVector_EulerAnglesFromONB(result_angles, a, c cross a, c).
Definition lbvector.c:343
static float sin(float angle)
Vec3 * lbVector_Sub(Vec3 *a, Vec3 *b)
Definition lbvector.c:68
static float lbVector_Len(Vec3 *vec)
void lbVector_CreateEulerMatrix(Mtx m, Vec3 *angles)
8000E530 - Sets m to the 3x3 euler matrix that rotates about the x,y,z axes with angles angles....
Definition lbvector.c:457
Vec3 * lbVector_EulerAnglesFromONB(Vec3 *result_angles, Vec3 *a, Vec3 *b, Vec3 *c)
8000DF0C - computes euler angles phi_x,phi_y,phi_z that rotate the standard basis (e1,...
Definition lbvector.c:319
Vec3 * lbVector_CrossprodNormalized(Vec3 *a, Vec3 *b, Vec3 *result)
Definition lbvector.c:84
float lbVector_AngleXY(Vec3 *a, Vec3 *b)
8000D790 - returns the angle between a and b
Definition lbvector.c:111
float lbVector_Normalize(Vec3 *vec)
Definition lbvector.c:24
void lbVector_Mirror(Vec3 *a, Vec3 *b)
8000DC6C - compute a -= 2*<a,b>*b.
Definition lbvector.c:260
Vec3 * lbVector_WorldToScreen(HSD_CObj *cobj, const Vec3 *pos3d, Vec3 *screenCoords, int d)
8000E210
Definition lbvector.c:369
float lbVector_8000E838(Vec3 *a, Vec3 *b, Vec3 *c, Vec3 *d)
8000E838 - This function seems to have a very specific use case and is only used once in Camera_Check...
Definition lbvector.c:496
float lbVector_sqrtf_accurate(float x)
8000E19C
Definition lbvector.c:363
Definition cobj.h:39
Definition ground.c:2352
int c
Definition tev.c:12