Twilight Princess
Decompilation of The Legend of Zelda: Twilight Princess
Loading...
Searching...
No Matches
c_m3d_g_aab.h
Go to the documentation of this file.
1#ifndef C_M3D_G_AAB_H
2#define C_M3D_G_AAB_H
3
6#include "global.h"
7
8// Axis aligned bounding box
9class cM3dGAab {
10private:
11public:
12 /* 0x00 */ cXyz mMin;
13 /* 0x0C */ cXyz mMax;
14 /* 0x18 vtable */
15
16 virtual ~cM3dGAab() {}
17 void Set(const cXyz*, const cXyz*);
18 bool CrossY(const cXyz*) const;
19 bool UnderPlaneYUnder(f32) const;
20 bool TopPlaneYUnder(f32) const;
21 void ClearForMinMax(void);
22 void SetMinMax(const cXyz&);
23 void SetMinMax(const cM3dGAab&);
24 void SetMin(const cXyz&);
25 void SetMax(const cXyz&);
26 void CalcCenter(cXyz*) const;
27 void PlusR(f32);
28 const cXyz* GetMaxP(void) const { return &mMax; }
29 const cXyz* GetMinP(void) const { return &mMin; }
30 const f32 GetMaxX(void) const { return mMax.x; }
31 const f32 GetMaxY(void) const { return mMax.y; }
32 const f32 GetMaxZ(void) const { return mMax.z; }
33 const f32 GetMinX(void) const { return mMin.x; }
34 const f32 GetMinY(void) const { return mMin.y; }
35 const f32 GetMinZ(void) const { return mMin.z; }
36 bool Cross(const cM3dGLin *param_1) {
37 return cM3d_Cross_MinMaxBoxLine(GetMinP(), GetMaxP(), (Vec*)&param_1->GetStartP(), (Vec*)&param_1->GetEndP());
38 }
39 bool Cross(const cM3dGAab *param_1) {
40 return cM3d_Cross_AabAab(this, param_1);
41 }
42 bool Cross(const cM3dGCyl *param_1) {
43 return cM3d_Cross_AabCyl(this, param_1);
44 }
45 bool Cross(const cM3dGSph *param_1) {
46 return cM3d_Cross_AabSph(this, param_1);
47 }
48}; // Size = 0x1C
49
50STATIC_ASSERT(0x1C == sizeof(cM3dGAab));
51
52#endif /* C_M3D_G_AAB_H */
T cLib_calcTimer(T *value)
Definition c_lib.h:74
bool cM3d_Cross_AabSph(const cM3dGAab *pAab, const cM3dGSph *pSph)
Definition c_m3d.cpp:192
bool cM3d_Cross_AabAab(const cM3dGAab *pAabA, const cM3dGAab *pAabB)
Definition c_m3d.cpp:156
bool cM3d_Cross_MinMaxBoxLine(Vec const *param_0, Vec const *param_1, Vec const *param_2, Vec const *param_3)
Definition c_m3d.cpp:459
bool cM3d_Cross_AabCyl(const cM3dGAab *pAab, const cM3dGCyl *pCyl)
Definition c_m3d.cpp:172
STATIC_ASSERT(0x1C==sizeof(cM3dGAab))
Definition d_a_hozelda.cpp:18
f32 z
Definition vec.h:11
f32 x
Definition vec.h:11
f32 y
Definition vec.h:11
Definition d_a_npc_fguard.cpp:137
bool Cross(const cM3dGAab *param_1)
Definition c_m3d_g_aab.h:39
const cXyz * GetMaxP(void) const
Definition c_m3d_g_aab.h:28
const f32 GetMaxY(void) const
Definition c_m3d_g_aab.h:31
void SetMax(const cXyz &)
Definition c_m3d_g_aab.cpp:61
bool CrossY(const cXyz *) const
Definition c_m3d_g_aab.cpp:15
const f32 GetMinZ(void) const
Definition c_m3d_g_aab.h:35
bool UnderPlaneYUnder(f32) const
Definition c_m3d_g_aab.cpp:24
void CalcCenter(cXyz *) const
Definition c_m3d_g_aab.cpp:65
cXyz mMin
Definition c_m3d_g_aab.h:12
void SetMinMax(const cXyz &)
Definition c_m3d_g_aab.cpp:44
bool Cross(const cM3dGSph *param_1)
Definition c_m3d_g_aab.h:45
void ClearForMinMax(void)
Definition c_m3d_g_aab.cpp:34
const f32 GetMaxX(void) const
Definition c_m3d_g_aab.h:30
bool Cross(const cM3dGCyl *param_1)
Definition c_m3d_g_aab.h:42
void Set(const cXyz *, const cXyz *)
Definition c_m3d_g_aab.cpp:9
cXyz mMax
Definition c_m3d_g_aab.h:13
void PlusR(f32)
Definition c_m3d_g_aab.cpp:71
const f32 GetMinY(void) const
Definition c_m3d_g_aab.h:34
bool Cross(const cM3dGLin *param_1)
Definition c_m3d_g_aab.h:36
bool TopPlaneYUnder(f32) const
Definition c_m3d_g_aab.cpp:29
const f32 GetMaxZ(void) const
Definition c_m3d_g_aab.h:32
virtual ~cM3dGAab()
Definition c_m3d_g_aab.h:16
const cXyz * GetMinP(void) const
Definition c_m3d_g_aab.h:29
void SetMin(const cXyz &)
Definition c_m3d_g_aab.cpp:56
const f32 GetMinX(void) const
Definition c_m3d_g_aab.h:33
Definition d_a_npc_fguard.cpp:126
Definition d_a_tag_allmato.cpp:99
Definition d_a_tag_allmato.cpp:94
Definition d_a_hozelda.cpp:20
float f32
Definition types.h:22