mirror of
https://github.com/encounter/tp.git
synced 2026-07-11 06:18:46 -07:00
delete unused asm, c_m3d_g
This commit is contained in:
@@ -7,7 +7,6 @@
|
||||
#include "dol2asm.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
|
||||
/* 80265E64-80265E78 0014+00 s=1 e=0 z=0 None .text cLs_Init__FP15node_list_class */
|
||||
void cLs_Init(node_list_class* pList) {
|
||||
pList->mpHead = NULL;
|
||||
|
||||
@@ -7,7 +7,6 @@
|
||||
#include "dol2asm.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
|
||||
/* 80266060-80266098 0038+00 s=0 e=5 z=0 None .text
|
||||
* cLsIt_Method__FP15node_list_classPFP10node_classPv_iPv */
|
||||
int cLsIt_Method(node_list_class* pList, cNdIt_MethodFunc pMethod, void* pUserData) {
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
// Translation Unit: c_m3d
|
||||
//
|
||||
|
||||
#include "SSystem/SComponent/c_m3d.h"
|
||||
// #include "SSystem/SComponent/c_m3d.h"
|
||||
#include "dol2asm.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
|
||||
@@ -3,118 +3,33 @@
|
||||
// Translation Unit: c_m3d_g_cps
|
||||
//
|
||||
|
||||
// #include "SSystem/SComponent/c_m3d_g_cps.h"
|
||||
#include "SSystem/SComponent/c_m3d_g_cps.h"
|
||||
#include "dol2asm.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
//
|
||||
// Types:
|
||||
//
|
||||
|
||||
struct cXyz {};
|
||||
|
||||
struct Vec {};
|
||||
|
||||
struct cM3dGLin {
|
||||
/* 8026F2E8 */ void SetStartEnd(cXyz const&, cXyz const&);
|
||||
/* 8026F31C */ void SetStartEnd(Vec const&, Vec const&);
|
||||
};
|
||||
|
||||
struct cM3dGCpsS {};
|
||||
|
||||
struct cM3dGCps {
|
||||
/* 8026EF88 */ cM3dGCps();
|
||||
/* 8026EFA4 */ ~cM3dGCps();
|
||||
/* 8026F000 */ void Set(cXyz const&, cXyz const&, f32);
|
||||
/* 8026F03C */ void Set(cM3dGCpsS const&);
|
||||
/* 8026F080 */ void SetCps(cM3dGCps const&);
|
||||
};
|
||||
|
||||
//
|
||||
// Forward References:
|
||||
//
|
||||
|
||||
extern "C" void __ct__8cM3dGCpsFv();
|
||||
extern "C" void __dt__8cM3dGCpsFv();
|
||||
extern "C" void Set__8cM3dGCpsFRC4cXyzRC4cXyzf();
|
||||
extern "C" void Set__8cM3dGCpsFRC9cM3dGCpsS();
|
||||
extern "C" void SetCps__8cM3dGCpsFRC8cM3dGCps();
|
||||
|
||||
//
|
||||
// External References:
|
||||
//
|
||||
|
||||
extern "C" void SetStartEnd__8cM3dGLinFRC4cXyzRC4cXyz();
|
||||
extern "C" void SetStartEnd__8cM3dGLinFRC3VecRC3Vec();
|
||||
extern "C" void __dl__FPv();
|
||||
extern "C" extern void* __vt__8cM3dGLin[3];
|
||||
|
||||
//
|
||||
// Declarations:
|
||||
//
|
||||
|
||||
/* ############################################################################################## */
|
||||
/* 803C3FF8-803C4020 021118 000C+1C 2/2 0/0 0/0 .data __vt__8cM3dGCps */
|
||||
SECTION_DATA extern void* __vt__8cM3dGCps[3 + 7 /* padding */] = {
|
||||
(void*)NULL /* RTTI */,
|
||||
(void*)NULL,
|
||||
(void*)__dt__8cM3dGCpsFv,
|
||||
/* padding */
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
NULL,
|
||||
};
|
||||
|
||||
/* 8026EF88-8026EFA4 2698C8 001C+00 0/0 5/5 20/20 .text __ct__8cM3dGCpsFv */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm cM3dGCps::cM3dGCps() {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cps/__ct__8cM3dGCpsFv.s"
|
||||
}
|
||||
#pragma pop
|
||||
cM3dGCps::cM3dGCps(void) {}
|
||||
|
||||
/* 8026EFA4-8026F000 2698E4 005C+00 1/0 7/7 6/6 .text __dt__8cM3dGCpsFv */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm cM3dGCps::~cM3dGCps() {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cps/__dt__8cM3dGCpsFv.s"
|
||||
}
|
||||
#pragma pop
|
||||
cM3dGCps::~cM3dGCps(void) {}
|
||||
|
||||
/* 8026F000-8026F03C 269940 003C+00 1/1 2/2 10/10 .text Set__8cM3dGCpsFRC4cXyzRC4cXyzf */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGCps::Set(cXyz const& param_0, cXyz const& param_1, f32 param_2) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cps/Set__8cM3dGCpsFRC4cXyzRC4cXyzf.s"
|
||||
void cM3dGCps::Set(const cXyz& pStart, const cXyz& pEnd, f32 pUnkF) {
|
||||
this->SetStartEnd(pStart, pEnd);
|
||||
unk_0x1c = pUnkF;
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F03C-8026F080 26997C 0044+00 0/0 1/1 10/10 .text Set__8cM3dGCpsFRC9cM3dGCpsS */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGCps::Set(cM3dGCpsS const& param_0) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cps/Set__8cM3dGCpsFRC9cM3dGCpsS.s"
|
||||
void cM3dGCps::Set(const cM3dGCpsS& other) {
|
||||
this->SetStartEnd(other.mStart, other.mEnd);
|
||||
unk_0x1c = other.unk_0x1c;
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F080-8026F0A8 2699C0 0028+00 0/0 1/1 0/0 .text SetCps__8cM3dGCpsFRC8cM3dGCps */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGCps::SetCps(cM3dGCps const& param_0) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cps/SetCps__8cM3dGCpsFRC8cM3dGCps.s"
|
||||
void cM3dGCps::SetCps(const cM3dGCps& other) {
|
||||
this->Set(other.GetStartP(), other.GetEndP(), other.unk_0x1c);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
@@ -3,149 +3,71 @@
|
||||
// Translation Unit: c_m3d_g_cyl
|
||||
//
|
||||
|
||||
// #include "SSystem/SComponent/c_m3d_g_cyl.h"
|
||||
#include "SSystem/SComponent/c_m3d_g_cyl.h"
|
||||
#include "SSystem/SComponent/c_m3d.h"
|
||||
#include "dol2asm.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
//
|
||||
// Types:
|
||||
//
|
||||
|
||||
struct cXyz {};
|
||||
|
||||
struct cM3dGSph {};
|
||||
|
||||
struct cM3dGCylS {};
|
||||
|
||||
struct cM3dGCyl {
|
||||
/* 8026F0A8 */ cM3dGCyl(cXyz const*, f32, f32);
|
||||
/* 8026F180 */ void Set(cXyz const&, f32, f32);
|
||||
/* 8026F114 */ void Set(cM3dGCylS const&);
|
||||
/* 8026F1DC */ void SetC(cXyz const&);
|
||||
/* 8026F1F8 */ void SetH(f32);
|
||||
/* 8026F200 */ void SetR(f32);
|
||||
/* 8026F208 */ void cross(cM3dGSph const*, cXyz*) const;
|
||||
/* 8026F22C */ void cross(cM3dGCyl const*, cXyz*) const;
|
||||
/* 8026F24C */ void calcMinMax(cXyz*, cXyz*);
|
||||
};
|
||||
|
||||
struct Vec {};
|
||||
|
||||
//
|
||||
// Forward References:
|
||||
//
|
||||
|
||||
extern "C" void __ct__8cM3dGCylFPC4cXyzff();
|
||||
extern "C" void Set__8cM3dGCylFRC9cM3dGCylS();
|
||||
extern "C" void Set__8cM3dGCylFRC4cXyzff();
|
||||
extern "C" void SetC__8cM3dGCylFRC4cXyz();
|
||||
extern "C" void SetH__8cM3dGCylFf();
|
||||
extern "C" void SetR__8cM3dGCylFf();
|
||||
extern "C" void cross__8cM3dGCylCFPC8cM3dGSphP4cXyz();
|
||||
extern "C" void cross__8cM3dGCylCFPC8cM3dGCylP4cXyz();
|
||||
extern "C" void calcMinMax__8cM3dGCylFP4cXyzP4cXyz();
|
||||
|
||||
//
|
||||
// External References:
|
||||
//
|
||||
|
||||
extern "C" void cM3d_Cross_CylSph__FPC8cM3dGCylPC8cM3dGSphP3VecPf();
|
||||
extern "C" void cM3d_Cross_CylCyl__FPC8cM3dGCylPC8cM3dGCylP3Vec();
|
||||
extern "C" extern void* __vt__8cM3dGCyl[3];
|
||||
|
||||
//
|
||||
// Declarations:
|
||||
//
|
||||
|
||||
/* 8026F0A8-8026F114 2699E8 006C+00 0/0 1/1 0/0 .text __ct__8cM3dGCylFPC4cXyzff */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm cM3dGCyl::cM3dGCyl(cXyz const* param_0, f32 param_1, f32 param_2) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cyl/__ct__8cM3dGCylFPC4cXyzff.s"
|
||||
cM3dGCyl::cM3dGCyl(const cXyz* pCenter, f32 pRadius, f32 pHeight) {
|
||||
this->SetC(*pCenter);
|
||||
this->SetR(pRadius);
|
||||
this->SetH(pHeight);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F114-8026F180 269A54 006C+00 0/0 1/1 4/4 .text Set__8cM3dGCylFRC9cM3dGCylS */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGCyl::Set(cM3dGCylS const& param_0) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cyl/Set__8cM3dGCylFRC9cM3dGCylS.s"
|
||||
void cM3dGCyl::Set(const cM3dGCylS& other) {
|
||||
this->SetC(cXyz(other.mCenter));
|
||||
this->SetR(other.mRadius);
|
||||
this->SetH(other.mHeight);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F180-8026F1DC 269AC0 005C+00 0/0 2/2 1/1 .text Set__8cM3dGCylFRC4cXyzff */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGCyl::Set(cXyz const& param_0, f32 param_1, f32 param_2) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cyl/Set__8cM3dGCylFRC4cXyzff.s"
|
||||
void cM3dGCyl::Set(const cXyz& pCenter, f32 pRadius, f32 pHeight) {
|
||||
this->SetC(pCenter);
|
||||
this->SetR(pRadius);
|
||||
this->SetH(pHeight);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F1DC-8026F1F8 269B1C 001C+00 3/3 13/13 257/257 .text SetC__8cM3dGCylFRC4cXyz */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGCyl::SetC(cXyz const& param_0) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cyl/SetC__8cM3dGCylFRC4cXyz.s"
|
||||
void cM3dGCyl::SetC(const cXyz& pCenter) {
|
||||
mCenter = pCenter;
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F1F8-8026F200 269B38 0008+00 3/3 11/11 197/197 .text SetH__8cM3dGCylFf */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGCyl::SetH(f32 param_0) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cyl/SetH__8cM3dGCylFf.s"
|
||||
void cM3dGCyl::SetH(f32 pHeight) {
|
||||
mHeight = pHeight;
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F200-8026F208 269B40 0008+00 3/3 6/6 204/204 .text SetR__8cM3dGCylFf */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGCyl::SetR(f32 param_0) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cyl/SetR__8cM3dGCylFf.s"
|
||||
void cM3dGCyl::SetR(f32 pRadius) {
|
||||
mRadius = pRadius;
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F208-8026F22C 269B48 0024+00 0/0 1/1 0/0 .text cross__8cM3dGCylCFPC8cM3dGSphP4cXyz
|
||||
*/
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGCyl::cross(cM3dGSph const* param_0, cXyz* param_1) const {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cyl/cross__8cM3dGCylCFPC8cM3dGSphP4cXyz.s"
|
||||
bool cM3dGCyl::cross(const cM3dGSph* pOther, cXyz* pOut) const {
|
||||
f32 f;
|
||||
return cM3d_Cross_CylSph(this, pOther, pOut, &f);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F22C-8026F24C 269B6C 0020+00 0/0 1/1 0/0 .text cross__8cM3dGCylCFPC8cM3dGCylP4cXyz
|
||||
*/
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGCyl::cross(cM3dGCyl const* param_0, cXyz* param_1) const {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cyl/cross__8cM3dGCylCFPC8cM3dGCylP4cXyz.s"
|
||||
bool cM3dGCyl::cross(const cM3dGCyl* pOther, cXyz* pOut) const {
|
||||
return cM3d_Cross_CylCyl(this, pOther, pOut);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F24C-8026F2A8 269B8C 005C+00 0/0 2/2 0/0 .text calcMinMax__8cM3dGCylFP4cXyzP4cXyz
|
||||
*/
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGCyl::calcMinMax(cXyz* param_0, cXyz* param_1) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_cyl/calcMinMax__8cM3dGCylFP4cXyzP4cXyz.s"
|
||||
void cM3dGCyl::calcMinMax(cXyz* pMin, cXyz* pMax) {
|
||||
pMin->x = mCenter.x - mRadius;
|
||||
pMin->y = mCenter.y;
|
||||
pMin->z = mCenter.z - mRadius;
|
||||
pMax->x = mCenter.x + mRadius;
|
||||
pMax->y = mCenter.y + mHeight;
|
||||
pMax->z = mCenter.z + mRadius;
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
@@ -7,35 +7,12 @@
|
||||
#include "dol2asm.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
//
|
||||
// Forward References:
|
||||
//
|
||||
|
||||
extern "C" void __ct__8cM3dGLinFRC4cXyzRC4cXyz();
|
||||
extern "C" void SetStartEnd__8cM3dGLinFRC4cXyzRC4cXyz();
|
||||
extern "C" void SetStartEnd__8cM3dGLinFRC3VecRC3Vec();
|
||||
extern "C" void CalcPos__8cM3dGLinCFP3Vecf();
|
||||
extern "C" void SetEnd__8cM3dGLinFRC4cXyz();
|
||||
|
||||
//
|
||||
// External References:
|
||||
//
|
||||
|
||||
extern "C" extern void* __vt__8cM3dGLin[3];
|
||||
|
||||
//
|
||||
// Declarations:
|
||||
//
|
||||
|
||||
/* 8026F2A8-8026F2E8 0040+00 s=0 e=8 z=1 None .text __ct__8cM3dGLinFRC4cXyzRC4cXyz */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm cM3dGLin::cM3dGLin(cXyz const& param_0, cXyz const& param_1) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_lin/__ct__8cM3dGLinFRC4cXyzRC4cXyz.s"
|
||||
}
|
||||
#pragma pop
|
||||
cM3dGLin::cM3dGLin(const cXyz& pStart, const cXyz& pEnd) : mStart(pStart), mEnd(pEnd) {}
|
||||
|
||||
/* 8026F2E8-8026F31C 0034+00 s=0 e=8 z=10 None .text SetStartEnd__8cM3dGLinFRC4cXyzRC4cXyz */
|
||||
void cM3dGLin::SetStartEnd(const cXyz& pStart, const cXyz& pEnd) {
|
||||
|
||||
@@ -4,123 +4,67 @@
|
||||
//
|
||||
|
||||
#include "SSystem/SComponent/c_m3d_g_pla.h"
|
||||
#include "SSystem/SComponent/c_m3d.h"
|
||||
#include "dol2asm.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
//
|
||||
// Types:
|
||||
//
|
||||
|
||||
struct cXyz {};
|
||||
|
||||
struct Vec {};
|
||||
|
||||
struct cM3dGPla {
|
||||
/* 8026F3DC */ cM3dGPla(cXyz const*, f32);
|
||||
/* 8026F408 */ void crossInfLin(cXyz const&, cXyz const&, cXyz&) const;
|
||||
/* 8026F4C4 */ void SetupNP0(Vec const&, Vec const&);
|
||||
/* 8026F52C */ void SetupNP(Vec const&, Vec const&);
|
||||
/* 8026F57C */ void getCrossY(cXyz const&, f32*) const;
|
||||
/* 8026F5D4 */ void getCrossYLessD(Vec const&, f32*) const;
|
||||
/* 8026F624 */ void Set(cM3dGPla const*);
|
||||
};
|
||||
|
||||
//
|
||||
// Forward References:
|
||||
//
|
||||
|
||||
extern "C" void __ct__8cM3dGPlaFPC4cXyzf();
|
||||
extern "C" void crossInfLin__8cM3dGPlaCFRC4cXyzRC4cXyzR4cXyz();
|
||||
extern "C" void SetupNP0__8cM3dGPlaFRC3VecRC3Vec();
|
||||
extern "C" void SetupNP__8cM3dGPlaFRC3VecRC3Vec();
|
||||
extern "C" void getCrossY__8cM3dGPlaCFRC4cXyzPf();
|
||||
extern "C" void getCrossYLessD__8cM3dGPlaCFRC3VecPf();
|
||||
extern "C" void Set__8cM3dGPlaFPC8cM3dGPla();
|
||||
|
||||
//
|
||||
// External References:
|
||||
//
|
||||
|
||||
extern "C" void cM3d_InDivPos2__FPC3VecPC3VecfP3Vec();
|
||||
extern "C" void PSVECNormalize();
|
||||
extern "C" void PSVECDotProduct();
|
||||
extern "C" void _savegpr_28();
|
||||
extern "C" void _restgpr_28();
|
||||
extern "C" extern void* __vt__8cM3dGPla[3];
|
||||
extern "C" extern f32 G_CM3D_F_ABS_MIN[1 + 1 /* padding */];
|
||||
#include "msl_c/math.h"
|
||||
|
||||
//
|
||||
// Declarations:
|
||||
//
|
||||
|
||||
/* 8026F3DC-8026F408 269D1C 002C+00 0/0 3/3 0/0 .text __ct__8cM3dGPlaFPC4cXyzf */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm cM3dGPla::cM3dGPla(cXyz const* param_0, f32 param_1) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_pla/__ct__8cM3dGPlaFPC4cXyzf.s"
|
||||
}
|
||||
#pragma pop
|
||||
cM3dGPla::cM3dGPla(const cXyz* pNormal, f32 pD) : mNormal(*pNormal), mD(pD) {}
|
||||
|
||||
/* 8026F408-8026F4C4 269D48 00BC+00 0/0 3/3 0/0 .text crossInfLin__8cM3dGPlaCFRC4cXyzRC4cXyzR4cXyz
|
||||
*/
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGPla::crossInfLin(cXyz const& param_0, cXyz const& param_1, cXyz& param_2) const {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_pla/crossInfLin__8cM3dGPlaCFRC4cXyzRC4cXyzR4cXyz.s"
|
||||
bool cM3dGPla::crossInfLin(const cXyz& pStart, const cXyz& pEnd, cXyz& out) const {
|
||||
f32 tmp1 = (mD + PSVECDotProduct(&mNormal, &pStart));
|
||||
f32 tmp2 = tmp1 - (mD + PSVECDotProduct(&mNormal, &pEnd));
|
||||
if (fabsf(tmp2) < G_CM3D_F_ABS_MIN) {
|
||||
out = pEnd;
|
||||
return false;
|
||||
} else {
|
||||
cM3d_InDivPos2(&pStart, &pEnd, (tmp1 / tmp2), &out);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F4C4-8026F52C 269E04 0068+00 0/0 1/1 0/0 .text SetupNP0__8cM3dGPlaFRC3VecRC3Vec */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGPla::SetupNP0(Vec const& param_0, Vec const& param_1) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_pla/SetupNP0__8cM3dGPlaFRC3VecRC3Vec.s"
|
||||
void cM3dGPla::SetupNP0(const Vec& pNormal, const Vec& pPoint) {
|
||||
mNormal = pNormal;
|
||||
PSVECNormalize(&mNormal, &mNormal);
|
||||
mD = -PSVECDotProduct(&mNormal, &pPoint);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F52C-8026F57C 269E6C 0050+00 0/0 2/2 0/0 .text SetupNP__8cM3dGPlaFRC3VecRC3Vec */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGPla::SetupNP(Vec const& param_0, Vec const& param_1) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_pla/SetupNP__8cM3dGPlaFRC3VecRC3Vec.s"
|
||||
void cM3dGPla::SetupNP(const Vec& pNormal, const Vec& pPoint) {
|
||||
mNormal = pNormal;
|
||||
mD = -PSVECDotProduct(&mNormal, &pPoint);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F57C-8026F5D4 269EBC 0058+00 0/0 2/2 0/0 .text getCrossY__8cM3dGPlaCFRC4cXyzPf */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGPla::getCrossY(cXyz const& param_0, f32* param_1) const {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_pla/getCrossY__8cM3dGPlaCFRC4cXyzPf.s"
|
||||
bool cM3dGPla::getCrossY(const cXyz& pPoint, f32* pOut) const {
|
||||
if (fabsf(mNormal.y) < G_CM3D_F_ABS_MIN) {
|
||||
return false;
|
||||
} else {
|
||||
*pOut = (-mNormal.x * pPoint.x - mNormal.z * pPoint.z - mD) / mNormal.y;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F5D4-8026F624 269F14 0050+00 0/0 1/1 0/0 .text getCrossYLessD__8cM3dGPlaCFRC3VecPf
|
||||
*/
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGPla::getCrossYLessD(Vec const& param_0, f32* param_1) const {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_pla/getCrossYLessD__8cM3dGPlaCFRC3VecPf.s"
|
||||
bool cM3dGPla::getCrossYLessD(const Vec& pPoint, f32* pOut) const {
|
||||
if (fabsf(mNormal.y) < G_CM3D_F_ABS_MIN) {
|
||||
return false;
|
||||
} else {
|
||||
*pOut = (-mNormal.x * pPoint.x - mNormal.z * pPoint.z) / mNormal.y;
|
||||
return true;
|
||||
}
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F624-8026F648 269F64 0024+00 0/0 1/1 0/0 .text Set__8cM3dGPlaFPC8cM3dGPla */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGPla::Set(cM3dGPla const* param_0) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_pla/Set__8cM3dGPlaFPC8cM3dGPla.s"
|
||||
void cM3dGPla::Set(const cM3dGPla* pOther) {
|
||||
*this = *pOther;
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
@@ -4,122 +4,55 @@
|
||||
//
|
||||
|
||||
#include "SSystem/SComponent/c_m3d_g_sph.h"
|
||||
#include "SSystem/SComponent/c_m3d.h"
|
||||
#include "dol2asm.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
//
|
||||
// Types:
|
||||
//
|
||||
|
||||
struct cXyz {};
|
||||
|
||||
struct cM3dGSphS {};
|
||||
|
||||
struct cM3dGCyl {};
|
||||
|
||||
struct cM3dGSph {
|
||||
/* 8026F648 */ void SetC(cXyz const&);
|
||||
/* 8026F664 */ void Set(cXyz const&, f32);
|
||||
/* 8026F6A8 */ void Set(cM3dGSphS const&);
|
||||
/* 8026F708 */ void SetR(f32);
|
||||
/* 8026F710 */ void cross(cM3dGSph const*, cXyz*) const;
|
||||
/* 8026F73C */ void cross(cM3dGCyl const*, cXyz*) const;
|
||||
/* 8026F76C */ void GetMinMaxCube(cXyz&, cXyz&) const;
|
||||
};
|
||||
|
||||
struct Vec {};
|
||||
|
||||
//
|
||||
// Forward References:
|
||||
//
|
||||
|
||||
extern "C" void SetC__8cM3dGSphFRC4cXyz();
|
||||
extern "C" void Set__8cM3dGSphFRC4cXyzf();
|
||||
extern "C" void Set__8cM3dGSphFRC9cM3dGSphS();
|
||||
extern "C" void SetR__8cM3dGSphFf();
|
||||
extern "C" void cross__8cM3dGSphCFPC8cM3dGSphP4cXyz();
|
||||
extern "C" void cross__8cM3dGSphCFPC8cM3dGCylP4cXyz();
|
||||
extern "C" void GetMinMaxCube__8cM3dGSphCFR4cXyzR4cXyz();
|
||||
|
||||
//
|
||||
// External References:
|
||||
//
|
||||
|
||||
extern "C" void cM3d_Cross_CylSph__FPC8cM3dGCylPC8cM3dGSphP3VecPf();
|
||||
extern "C" void cM3d_Cross_SphSph__FPC8cM3dGSphPC8cM3dGSphP3Vec();
|
||||
|
||||
//
|
||||
// Declarations:
|
||||
//
|
||||
|
||||
/* 8026F648-8026F664 269F88 001C+00 2/2 5/5 254/254 .text SetC__8cM3dGSphFRC4cXyz */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGSph::SetC(cXyz const& param_0) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_sph/SetC__8cM3dGSphFRC4cXyz.s"
|
||||
void cM3dGSph::SetC(const cXyz& pCenter) {
|
||||
mCenter = pCenter;
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F664-8026F6A8 269FA4 0044+00 0/0 3/3 2/2 .text Set__8cM3dGSphFRC4cXyzf */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGSph::Set(cXyz const& param_0, f32 param_1) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_sph/Set__8cM3dGSphFRC4cXyzf.s"
|
||||
void cM3dGSph::Set(const cXyz& pCenter, f32 pRadius) {
|
||||
this->SetC(pCenter);
|
||||
this->SetR(pRadius);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F6A8-8026F708 269FE8 0060+00 0/0 2/2 0/0 .text Set__8cM3dGSphFRC9cM3dGSphS */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGSph::Set(cM3dGSphS const& param_0) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_sph/Set__8cM3dGSphFRC9cM3dGSphS.s"
|
||||
void cM3dGSph::Set(const cM3dGSphS& pOther) {
|
||||
this->SetC(cXyz(pOther.mCenter));
|
||||
this->SetR(pOther.mRadius);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F708-8026F710 26A048 0008+00 2/2 10/10 197/197 .text SetR__8cM3dGSphFf */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGSph::SetR(f32 param_0) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_sph/SetR__8cM3dGSphFf.s"
|
||||
void cM3dGSph::SetR(f32 pRadius) {
|
||||
mRadius = pRadius;
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F710-8026F73C 26A050 002C+00 0/0 1/1 0/0 .text cross__8cM3dGSphCFPC8cM3dGSphP4cXyz
|
||||
*/
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGSph::cross(cM3dGSph const* param_0, cXyz* param_1) const {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_sph/cross__8cM3dGSphCFPC8cM3dGSphP4cXyz.s"
|
||||
bool cM3dGSph::cross(const cM3dGSph* pOther, cXyz* pOut) const {
|
||||
return cM3d_Cross_SphSph(pOther, this, pOut);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F73C-8026F76C 26A07C 0030+00 0/0 1/1 0/0 .text cross__8cM3dGSphCFPC8cM3dGCylP4cXyz
|
||||
*/
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGSph::cross(cM3dGCyl const* param_0, cXyz* param_1) const {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_sph/cross__8cM3dGSphCFPC8cM3dGCylP4cXyz.s"
|
||||
bool cM3dGSph::cross(const cM3dGCyl* pCylinder, cXyz* pOut) const {
|
||||
f32 f;
|
||||
return cM3d_Cross_CylSph(pCylinder, this, pOut, &f);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F76C-8026F7B0 26A0AC 0044+00 0/0 1/1 0/0 .text GetMinMaxCube__8cM3dGSphCFR4cXyzR4cXyz */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGSph::GetMinMaxCube(cXyz& param_0, cXyz& param_1) const {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_sph/GetMinMaxCube__8cM3dGSphCFR4cXyzR4cXyz.s"
|
||||
void cM3dGSph::GetMinMaxCube(cXyz& pMin, cXyz& pMax) const {
|
||||
pMin.x = mCenter.x - mRadius;
|
||||
pMin.y = mCenter.y - mRadius;
|
||||
pMin.z = mCenter.z - mRadius;
|
||||
pMax.x = mCenter.x + mRadius;
|
||||
pMax.y = mCenter.y + mRadius;
|
||||
pMax.z = mCenter.z + mRadius;
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
@@ -4,91 +4,41 @@
|
||||
//
|
||||
|
||||
#include "SSystem/SComponent/c_m3d_g_tri.h"
|
||||
#include "SSystem/SComponent/c_m3d.h"
|
||||
#include "dol2asm.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
//
|
||||
// Types:
|
||||
//
|
||||
|
||||
struct Vec {};
|
||||
|
||||
struct cM3dGPla {
|
||||
/* 8026F52C */ void SetupNP(Vec const&, Vec const&);
|
||||
/* 8026F624 */ void Set(cM3dGPla const*);
|
||||
};
|
||||
|
||||
struct cM3dGCyl {};
|
||||
|
||||
struct cM3dGTri {
|
||||
/* 8026F7B0 */ void cross(cM3dGCyl const*, Vec*) const;
|
||||
/* 8026F7DC */ void setPos(Vec const*, Vec const*, Vec const*);
|
||||
/* 8026F85C */ void setBg(Vec const*, Vec const*, Vec const*, cM3dGPla const*);
|
||||
/* 8026F8C8 */ void set(Vec const*, Vec const*, Vec const*, Vec const*);
|
||||
};
|
||||
|
||||
//
|
||||
// Forward References:
|
||||
//
|
||||
|
||||
extern "C" void cross__8cM3dGTriCFPC8cM3dGCylP3Vec();
|
||||
extern "C" void setPos__8cM3dGTriFPC3VecPC3VecPC3Vec();
|
||||
extern "C" void setBg__8cM3dGTriFPC3VecPC3VecPC3VecPC8cM3dGPla();
|
||||
extern "C" void set__8cM3dGTriFPC3VecPC3VecPC3VecPC3Vec();
|
||||
|
||||
//
|
||||
// External References:
|
||||
//
|
||||
|
||||
extern "C" void cM3d_CalcPla__FPC3VecPC3VecPC3VecP3VecPf();
|
||||
extern "C" void cM3d_Cross_CylTri__FPC8cM3dGCylPC8cM3dGTriP3Vec();
|
||||
extern "C" void SetupNP__8cM3dGPlaFRC3VecRC3Vec();
|
||||
extern "C" void Set__8cM3dGPlaFPC8cM3dGPla();
|
||||
|
||||
//
|
||||
// Declarations:
|
||||
//
|
||||
|
||||
/* 8026F7B0-8026F7DC 26A0F0 002C+00 0/0 1/1 0/0 .text cross__8cM3dGTriCFPC8cM3dGCylP3Vec
|
||||
*/
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGTri::cross(cM3dGCyl const* param_0, Vec* param_1) const {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_tri/cross__8cM3dGTriCFPC8cM3dGCylP3Vec.s"
|
||||
bool cM3dGTri::cross(const cM3dGCyl* pCylinder, Vec* out) const {
|
||||
return cM3d_Cross_CylTri(pCylinder, this, out);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F7DC-8026F85C 26A11C 0080+00 0/0 0/0 6/6 .text setPos__8cM3dGTriFPC3VecPC3VecPC3Vec */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGTri::setPos(Vec const* param_0, Vec const* param_1, Vec const* param_2) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_tri/setPos__8cM3dGTriFPC3VecPC3VecPC3Vec.s"
|
||||
void cM3dGTri::setPos(const Vec* pA, const Vec* pB, const Vec* pC) {
|
||||
mA = *pA;
|
||||
mB = *pB;
|
||||
mC = *pC;
|
||||
cM3d_CalcPla(&mA, &mB, &mC, &mPlane.mNormal, &mPlane.mD);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F85C-8026F8C8 26A19C 006C+00 0/0 2/2 0/0 .text
|
||||
* setBg__8cM3dGTriFPC3VecPC3VecPC3VecPC8cM3dGPla */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGTri::setBg(Vec const* param_0, Vec const* param_1, Vec const* param_2,
|
||||
cM3dGPla const* param_3) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_tri/setBg__8cM3dGTriFPC3VecPC3VecPC3VecPC8cM3dGPla.s"
|
||||
void cM3dGTri::setBg(const Vec* pA, const Vec* pB, const Vec* pC, const cM3dGPla* pPlane) {
|
||||
mA = *pA;
|
||||
mB = *pB;
|
||||
mC = *pC;
|
||||
mPlane.Set(pPlane);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 8026F8C8-8026F93C 26A208 0074+00 0/0 1/1 0/0 .text set__8cM3dGTriFPC3VecPC3VecPC3VecPC3Vec */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void cM3dGTri::set(Vec const* param_0, Vec const* param_1, Vec const* param_2,
|
||||
Vec const* param_3) {
|
||||
nofralloc
|
||||
#include "asm/SSystem/SComponent/c_m3d_g_tri/set__8cM3dGTriFPC3VecPC3VecPC3VecPC3Vec.s"
|
||||
void cM3dGTri::set(const Vec* pA, const Vec* pB, const Vec* pC, const Vec* pNormal) {
|
||||
mA = *pA;
|
||||
mB = *pB;
|
||||
mC = *pC;
|
||||
mPlane.SetupNP(*pNormal, *pA);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
|
||||
/* ############################################################################################## */
|
||||
/* 80451150-80451158 0004+04 s=3 e=0 z=0 None .sbss Heap__3cMl */
|
||||
JKRHeap *cMl::Heap;
|
||||
JKRHeap* cMl::Heap;
|
||||
|
||||
/* 80263220-80263228 0008+00 s=0 e=1 z=0 None .text init__3cMlFP7JKRHeap */
|
||||
void cMl::init(JKRHeap* heap) {
|
||||
@@ -31,5 +31,3 @@ void cMl::free(void* ptr) {
|
||||
Heap->free(ptr);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
// Declarations:
|
||||
//
|
||||
|
||||
const csXyz csXyz::Zero = csXyz(0,0,0);
|
||||
const csXyz csXyz::Zero = csXyz(0, 0, 0);
|
||||
|
||||
/* 802673F4-80267404 0010+00 s=4 e=19 z=119 None .text __ct__5csXyzFsss */
|
||||
csXyz::csXyz(s16 param_0, s16 param_1, s16 param_2) {
|
||||
@@ -39,5 +39,5 @@ csXyz csXyz::operator-(csXyz& param_0) {
|
||||
|
||||
/* 802674E8-8026758C 00A4+00 s=0 e=0 z=1 None .text __ml__5csXyzFf */
|
||||
csXyz csXyz::operator*(f32 param_0) {
|
||||
return csXyz(mX* param_0, mY * param_0, mZ * param_0);
|
||||
return csXyz(mX * param_0, mY * param_0, mZ * param_0);
|
||||
}
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
#include "SSystem/SComponent/c_xyz.h"
|
||||
#include "dol2asm.h"
|
||||
#include "dolphin/types.h"
|
||||
#include "mtx_vec.h"
|
||||
#include "msl_c/math.h"
|
||||
#include "mtx_vec.h"
|
||||
|
||||
#define FLOAT_LABEL(x) (*(f32*)&x)
|
||||
#define DOUBLE_LABEL(x) (*(f64*)&x)
|
||||
|
||||
Reference in New Issue
Block a user