mirror of
https://github.com/TwilitRealm/dusklight
synced 2026-07-27 06:31:42 -04:00
J3duclip, fop_actor_mng and related stuff (#131)
* J3DUClipper sinit * sincosTable_ etc * decompile JMATrigonometric sinit * f_op_actor_mng * move f_op_actor_mng and parts of mDo_ext * J3DSys sinit * f_op_scene_req * failed matching attempt for decodeSZS__9JKRDecompFPUcPUcUlUl * mX -> x * fix mCull and fopAcM_prm_class members * fix a few function parameters * move missing NON_MATCHING * remove some unneeded data * turns out that data was not unused * remove unused asm * readd asm deleted by accident
This commit is contained in:
@@ -49,7 +49,6 @@ extern "C" void _savegpr_27();
|
||||
extern "C" void _savegpr_28();
|
||||
extern "C" void _restgpr_27();
|
||||
extern "C" void _restgpr_28();
|
||||
extern "C" extern u8 j3dSys[284];
|
||||
|
||||
//
|
||||
// Declarations:
|
||||
|
||||
@@ -97,7 +97,6 @@ extern "C" void __ptmf_scall();
|
||||
extern "C" void _savegpr_28();
|
||||
extern "C" void _restgpr_28();
|
||||
extern "C" u8 sortFuncTable__13J3DDrawBuffer[72];
|
||||
extern "C" extern u8 j3dSys[284];
|
||||
extern "C" extern u8 struct_804515B0[4];
|
||||
extern "C" u8 sTexGenBlock__17J3DDifferedTexMtx[4];
|
||||
extern "C" u8 sTexMtxObj__17J3DDifferedTexMtx[4];
|
||||
|
||||
@@ -13,29 +13,6 @@
|
||||
|
||||
struct _GXTexMapID {};
|
||||
|
||||
struct _GXTexCacheSize {};
|
||||
|
||||
struct J3DSys {
|
||||
/* 8030FDE8 */ J3DSys();
|
||||
/* 8030FEC0 */ void loadPosMtxIndx(int, u16) const;
|
||||
/* 8030FEE4 */ void loadNrmMtxIndx(int, u16) const;
|
||||
/* 8030FF0C */ void setTexCacheRegion(_GXTexCacheSize);
|
||||
/* 803100BC */ void drawInit();
|
||||
/* 8031073C */ void reinitGX();
|
||||
/* 8031079C */ void reinitGenMode();
|
||||
/* 803107E8 */ void reinitLighting();
|
||||
/* 80310894 */ void reinitTransform();
|
||||
/* 80310998 */ void reinitTexture();
|
||||
/* 80310A3C */ void reinitTevStages();
|
||||
/* 80310D44 */ void reinitIndStages();
|
||||
/* 80310E3C */ void reinitPixelProc();
|
||||
|
||||
static u8 mCurrentMtx[48];
|
||||
static f32 mCurrentS[3];
|
||||
static f32 mParentS[3];
|
||||
static u8 sTexCoordScaleTable[64 + 4 /* padding */];
|
||||
};
|
||||
|
||||
//
|
||||
// Forward References:
|
||||
//
|
||||
@@ -69,7 +46,6 @@ extern "C" void makeTexCoordTable__Fv();
|
||||
extern "C" void makeAlphaCmpTable__Fv();
|
||||
extern "C" void makeZModeTable__Fv();
|
||||
extern "C" void makeTevSwapTable__Fv();
|
||||
extern "C" void PSMTXIdentity();
|
||||
extern "C" void GXSetVtxAttrFmt();
|
||||
extern "C" void GXInvalidateVtxCache();
|
||||
extern "C" void GXSetTexCoordGen2();
|
||||
@@ -132,8 +108,7 @@ extern "C" extern u32 j3dDefaultTevKColor;
|
||||
|
||||
/* ############################################################################################## */
|
||||
/* 80434AC8-80434BE4 0617E8 011C+00 1/1 151/151 486/486 .bss j3dSys */
|
||||
extern u8 j3dSys[284];
|
||||
u8 j3dSys[284];
|
||||
J3DSys j3dSys;
|
||||
|
||||
/* 80434BE4-80434C14 061904 0030+00 0/0 17/17 154/154 .bss mCurrentMtx__6J3DSys */
|
||||
u8 J3DSys::mCurrentMtx[48];
|
||||
@@ -349,21 +324,6 @@ asm void J3DSys::reinitPixelProc() {
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 80310ED0-80310EF8 30B810 0028+00 0/0 1/0 0/0 .text __sinit_J3DSys_cpp */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void __sinit_J3DSys_cpp() {
|
||||
nofralloc
|
||||
#include "asm/JSystem/J3DGraphBase/J3DSys/__sinit_J3DSys_cpp.s"
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
#pragma push
|
||||
#pragma force_active on
|
||||
REGISTER_CTORS(0x80310ED0, __sinit_J3DSys_cpp);
|
||||
#pragma pop
|
||||
|
||||
/* ############################################################################################## */
|
||||
/* 80451598-804515A0 000A98 0004+04 0/0 1/1 0/0 .sbss j3dDefaultViewNo */
|
||||
extern u8 j3dDefaultViewNo[4 + 4 /* padding */];
|
||||
|
||||
@@ -5,20 +5,9 @@
|
||||
|
||||
#include "JSystem/J3DU/J3DUClipper.h"
|
||||
#include "dol2asm.h"
|
||||
#include "dolphin/mtx/mtxvec.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
//
|
||||
// Types:
|
||||
//
|
||||
|
||||
struct Vec {};
|
||||
|
||||
struct J3DUClipper {
|
||||
/* 80273778 */ void init();
|
||||
/* 8027378C */ void calcViewFrustum();
|
||||
/* 802738FC */ void clip(f32 const (*)[4], Vec, f32) const;
|
||||
/* 80273A44 */ void clip(f32 const (*)[4], Vec*, Vec*) const;
|
||||
};
|
||||
#include "msl_c/math.h"
|
||||
|
||||
//
|
||||
// Forward References:
|
||||
@@ -34,33 +23,18 @@ extern "C" extern char const* const J3DUClipper__stringBase0;
|
||||
// External References:
|
||||
//
|
||||
|
||||
extern "C" void PSMTXMultVec();
|
||||
extern "C" void PSVECNormalize();
|
||||
extern "C" void PSVECCrossProduct();
|
||||
extern "C" void _savegpr_29();
|
||||
extern "C" void _restgpr_29();
|
||||
extern "C" void tan();
|
||||
|
||||
//
|
||||
// Declarations:
|
||||
//
|
||||
|
||||
/* ############################################################################################## */
|
||||
/* 80455278-8045527C 003878 0004+00 1/1 0/0 0/0 .sdata2 @893 */
|
||||
SECTION_SDATA2 static f32 lit_893 = 1.0f;
|
||||
|
||||
/* 8045527C-80455280 00387C 0004+00 1/1 0/0 0/0 .sdata2 @894 */
|
||||
SECTION_SDATA2 static f32 lit_894 = 100000.0f;
|
||||
|
||||
/* 80273778-8027378C 26E0B8 0014+00 0/0 1/1 0/0 .text init__11J3DUClipperFv */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void J3DUClipper::init() {
|
||||
nofralloc
|
||||
#include "asm/JSystem/J3DU/J3DUClipper/init__11J3DUClipperFv.s"
|
||||
void J3DUClipper::init() {
|
||||
mNear = 1.0f;
|
||||
mFar = 100000.0f;
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* ############################################################################################## */
|
||||
/* 8039A948-8039A954 026FA8 000C+00 1/1 0/0 0/0 .rodata @898 */
|
||||
@@ -69,63 +43,30 @@ SECTION_RODATA static u8 const lit_898[12] = {
|
||||
};
|
||||
COMPILER_STRIP_GATE(0x8039A948, &lit_898);
|
||||
|
||||
/* 8039A954-8039A960 026FB4 000C+00 0/1 0/0 0/0 .rodata @899 */
|
||||
#pragma push
|
||||
#pragma force_active on
|
||||
SECTION_RODATA static u8 const lit_899[12] = {
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
};
|
||||
COMPILER_STRIP_GATE(0x8039A954, &lit_899);
|
||||
#pragma pop
|
||||
|
||||
/* 8039A960-8039A96C 026FC0 000C+00 0/1 0/0 0/0 .rodata @900 */
|
||||
#pragma push
|
||||
#pragma force_active on
|
||||
SECTION_RODATA static u8 const lit_900[12] = {
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
};
|
||||
COMPILER_STRIP_GATE(0x8039A960, &lit_900);
|
||||
#pragma pop
|
||||
|
||||
/* 8039A96C-8039A978 026FCC 000C+00 0/1 0/0 0/0 .rodata @901 */
|
||||
#pragma push
|
||||
#pragma force_active on
|
||||
SECTION_RODATA static u8 const lit_901[12] = {
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
};
|
||||
COMPILER_STRIP_GATE(0x8039A96C, &lit_901);
|
||||
#pragma pop
|
||||
|
||||
/* 8039A978-8039A984 026FD8 000C+00 0/1 0/0 0/0 .rodata @902 */
|
||||
#pragma push
|
||||
#pragma force_active on
|
||||
SECTION_RODATA static u8 const lit_902[12] = {
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
};
|
||||
COMPILER_STRIP_GATE(0x8039A978, &lit_902);
|
||||
#pragma pop
|
||||
|
||||
/* 80455280-80455284 003880 0004+00 1/1 0/0 0/0 .sdata2 @913 */
|
||||
SECTION_SDATA2 static f32 lit_913 = 0.01745329238474369f;
|
||||
|
||||
/* 80455284-80455288 003884 0004+00 1/1 0/0 0/0 .sdata2 @914 */
|
||||
SECTION_SDATA2 static f32 lit_914 = 0.5f;
|
||||
|
||||
/* 8027378C-802738FC 26E0CC 0170+00 0/0 3/3 4/4 .text calcViewFrustum__11J3DUClipperFv */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void J3DUClipper::calcViewFrustum() {
|
||||
nofralloc
|
||||
#include "asm/JSystem/J3DU/J3DUClipper/calcViewFrustum__11J3DUClipperFv.s"
|
||||
void J3DUClipper::calcViewFrustum() {
|
||||
f32 f0 = tan(0.5f * mFovY * 0.01745329238474369f);
|
||||
f32 f4 = mNear * f0;
|
||||
f32 f5 = mAspect * f4;
|
||||
Vec tmp1 = {-f5, -f4, -mNear};
|
||||
Vec tmp2 = {-f5, f4, -mNear};
|
||||
Vec tmp3 = {f5, f4, -mNear};
|
||||
Vec tmp4 = {f5, -f4, -mNear};
|
||||
PSVECCrossProduct(&tmp2, &tmp1, &_04);
|
||||
PSVECCrossProduct(&tmp3, &tmp2, &_10);
|
||||
PSVECCrossProduct(&tmp4, &tmp3, &_1C);
|
||||
PSVECCrossProduct(&tmp1, &tmp4, &_28);
|
||||
PSVECNormalize(&_04, &_04);
|
||||
PSVECNormalize(&_10, &_10);
|
||||
PSVECNormalize(&_1C, &_1C);
|
||||
PSVECNormalize(&_28, &_28);
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
/* 802738FC-80273A44 26E23C 0148+00 0/0 3/3 2/2 .text clip__11J3DUClipperCFPA4_Cf3Vecf */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void J3DUClipper::clip(f32 const (*param_0)[4], Vec param_1, f32 param_2) const {
|
||||
asm u32 J3DUClipper::clip(f32 const (*param_0)[4], Vec param_1, f32 param_2) const {
|
||||
nofralloc
|
||||
#include "asm/JSystem/J3DU/J3DUClipper/clip__11J3DUClipperCFPA4_Cf3Vecf.s"
|
||||
}
|
||||
@@ -143,7 +84,7 @@ SECTION_SDATA2 static f32 lit_991[1 + 1 /* padding */] = {
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void J3DUClipper::clip(f32 const (*param_0)[4], Vec* param_1, Vec* param_2) const {
|
||||
asm u32 J3DUClipper::clip(f32 const (*param_0)[4], Vec* param_1, Vec* param_2) const {
|
||||
nofralloc
|
||||
#include "asm/JSystem/J3DU/J3DUClipper/clip__11J3DUClipperCFPA4_CfP3VecP3Vec.s"
|
||||
}
|
||||
|
||||
@@ -156,15 +156,16 @@ JKRAram::~JKRAram() {
|
||||
void* JKRAram::run(void) {
|
||||
int result;
|
||||
JKRAMCommand* command;
|
||||
JKRAMCommand::Message* message;
|
||||
JKRAramPiece::Message* message;
|
||||
OSInitMessageQueue(&sMessageQueue, sMessageBuffer, 4);
|
||||
do {
|
||||
OSReceiveMessage(&sMessageQueue, &message, OS_MESSAGE_BLOCKING);
|
||||
result = message->field_0x0;
|
||||
OSReceiveMessage(&sMessageQueue, (OSMessage*)&message, OS_MESSAGE_BLOCKING);
|
||||
result = message->field_0x00;
|
||||
command = message->command;
|
||||
delete message;
|
||||
|
||||
if (result == 1) {
|
||||
if (result != 1) {
|
||||
} else {
|
||||
JKRAramPiece::startDMA(command);
|
||||
}
|
||||
} while (true);
|
||||
|
||||
@@ -265,6 +265,72 @@ asm void JKRDecomp::decodeSZP(u8* param_0, u8* param_1, u32 param_2, u32 param_3
|
||||
#endif
|
||||
|
||||
/* 802DBC14-802DBCF8 2D6554 00E4+00 1/1 0/0 0/0 .text decodeSZS__9JKRDecompFPUcPUcUlUl */
|
||||
#ifdef NON_MATCHING
|
||||
void JKRDecomp::decodeSZS(u8* src_buffer, u8* dst_buffer, u32 param_3, u32 param_4) {
|
||||
int copyByteCount;
|
||||
u8* decompEnd;
|
||||
u8* copyStart;
|
||||
int chunkBitsLeft = 0;
|
||||
int chunkBits;
|
||||
decompEnd = dst_buffer + *(int*)(src_buffer + 4) - param_4;
|
||||
if (param_3 == 0) {
|
||||
return;
|
||||
}
|
||||
if (param_4 > *(u32*)src_buffer) {
|
||||
return;
|
||||
}
|
||||
u8* curSrcPos = src_buffer + 0x10;
|
||||
do {
|
||||
if (chunkBitsLeft == 0) {
|
||||
chunkBits = *curSrcPos;
|
||||
chunkBitsLeft = 8;
|
||||
curSrcPos++;
|
||||
}
|
||||
if ((chunkBits & 0x80) != 0) {
|
||||
if (param_4 == 0) {
|
||||
*dst_buffer = *curSrcPos;
|
||||
param_3--;
|
||||
dst_buffer++;
|
||||
if (param_3 == 0) {
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
param_4--;
|
||||
}
|
||||
curSrcPos++;
|
||||
} else {
|
||||
int curVal = *curSrcPos;
|
||||
// load is inversed
|
||||
copyStart = dst_buffer - ((curVal & 0xF) << 8 | curSrcPos[1]);
|
||||
// copyByteCount = ;
|
||||
curSrcPos += 2;
|
||||
// instruction order differences
|
||||
if (curVal >> 4 == 0) {
|
||||
copyByteCount = *curSrcPos + 0x12;
|
||||
curSrcPos++;
|
||||
} else {
|
||||
copyByteCount = (curVal >> 4) + 2;
|
||||
}
|
||||
do {
|
||||
if (param_4 == 0) {
|
||||
*dst_buffer = *(copyStart - 1);
|
||||
param_3--;
|
||||
dst_buffer++;
|
||||
if (param_3 == 0) {
|
||||
return;
|
||||
}
|
||||
} else {
|
||||
param_4--;
|
||||
}
|
||||
copyByteCount--;
|
||||
copyStart++;
|
||||
} while (copyByteCount != 0);
|
||||
}
|
||||
chunkBits <<= 1;
|
||||
chunkBitsLeft--;
|
||||
} while (dst_buffer != decompEnd);
|
||||
}
|
||||
#else
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
@@ -273,6 +339,7 @@ asm void JKRDecomp::decodeSZS(u8* param_0, u8* param_1, u32 param_2, u32 param_3
|
||||
#include "asm/JSystem/JKernel/JKRDecomp/decodeSZS__9JKRDecompFPUcPUcUlUl.s"
|
||||
}
|
||||
#pragma pop
|
||||
#endif
|
||||
|
||||
/* 802DBCF8-802DBD70 2D6638 0078+00 1/1 4/4 0/0 .text checkCompressed__9JKRDecompFPUc */
|
||||
JKRCompression JKRDecomp::checkCompressed(u8* src) {
|
||||
|
||||
@@ -99,7 +99,7 @@ extern "C" u8 mErrorHandler__7JKRHeap[4];
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void JKRExpHeap::createRoot(int param_0, bool param_1) {
|
||||
asm JKRExpHeap* JKRExpHeap::createRoot(int param_0, bool param_1) {
|
||||
nofralloc
|
||||
#include "asm/JSystem/JKernel/JKRExpHeap/createRoot__10JKRExpHeapFib.s"
|
||||
}
|
||||
@@ -110,7 +110,7 @@ asm void JKRExpHeap::createRoot(int param_0, bool param_1) {
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void JKRExpHeap::create(u32 param_0, JKRHeap* param_1, bool param_2) {
|
||||
asm JKRExpHeap* JKRExpHeap::create(u32 param_0, JKRHeap* param_1, bool param_2) {
|
||||
nofralloc
|
||||
#include "asm/JSystem/JKernel/JKRExpHeap/create__10JKRExpHeapFUlP7JKRHeapb.s"
|
||||
}
|
||||
@@ -121,7 +121,7 @@ asm void JKRExpHeap::create(u32 param_0, JKRHeap* param_1, bool param_2) {
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void JKRExpHeap::create(void* param_0, u32 param_1, JKRHeap* param_2, bool param_3) {
|
||||
asm JKRExpHeap* JKRExpHeap::create(void* param_0, u32 param_1, JKRHeap* param_2, bool param_3) {
|
||||
nofralloc
|
||||
#include "asm/JSystem/JKernel/JKRExpHeap/create__10JKRExpHeapFPvUlP7JKRHeapb.s"
|
||||
}
|
||||
|
||||
@@ -3,113 +3,87 @@
|
||||
// Translation Unit: JMATrigonometric
|
||||
//
|
||||
|
||||
#include "JSystem/JMath/JMATrigonometric.h"
|
||||
// don't include header until this "zero" mess is figured out
|
||||
// #include "JSystem/JMath/JMATrigonometric.h"
|
||||
#include "dol2asm.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
//
|
||||
// Types:
|
||||
//
|
||||
#include "global.h"
|
||||
#include "msl_c/math.h"
|
||||
|
||||
namespace std {
|
||||
template <typename A1, typename B1>
|
||||
struct pair {};
|
||||
/* pair<f32, f32> */
|
||||
struct pair__template0 {
|
||||
/* 80339CB0 */ void func_80339CB0(void* _this);
|
||||
struct pair {
|
||||
A1 a1;
|
||||
B1 b1;
|
||||
pair() {
|
||||
f32 tmp = FLOAT_LABEL(zero);
|
||||
a1 = tmp;
|
||||
b1 = tmp;
|
||||
// a1 = A1();
|
||||
// b1 = B1();
|
||||
}
|
||||
};
|
||||
} // namespace std
|
||||
|
||||
// fake, but couldn't find another way to make 0.0f go first in sdata2 in this TU
|
||||
SECTION_SDATA2 static f32 zero[1 + 1] = {0.0f, 0.0f};
|
||||
|
||||
inline f64 getConst() {
|
||||
return 6.2831854820251465;
|
||||
}
|
||||
|
||||
struct TSinCosTable {
|
||||
std::pair<f32, f32> table[0x2000];
|
||||
TSinCosTable() {
|
||||
for (int i = 0; i < 0x2000; i++) {
|
||||
table[i].a1 = sin((i * getConst()) / 8192.0);
|
||||
table[i].b1 = cos((i * getConst()) / 8192.0);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
}; // namespace std
|
||||
inline f64 getConst2() {
|
||||
return 9.765625E-4;
|
||||
}
|
||||
|
||||
struct JMath {
|
||||
static u8 sincosTable_[65536];
|
||||
static f32 atanTable_[1032];
|
||||
static f32 asinAcosTable_[1032];
|
||||
struct TAtanTable {
|
||||
f32 table[1025];
|
||||
u8 pad[0x1C];
|
||||
TAtanTable() {
|
||||
// (u32) cast needed for cmplwi instead of cmpwi
|
||||
for (int i = 0; i < (u32)1024; i++) {
|
||||
table[i] = atan(getConst2() * i);
|
||||
}
|
||||
table[0] = FLOAT_LABEL(zero);
|
||||
table[1024] = 0.7853982; // 0.25 * PI
|
||||
}
|
||||
};
|
||||
|
||||
//
|
||||
// Forward References:
|
||||
//
|
||||
|
||||
extern "C" void __sinit_JMATrigonometric_cpp();
|
||||
extern "C" void func_80339CB0(void* _this);
|
||||
extern "C" u8 sincosTable___5JMath[65536];
|
||||
extern "C" f32 atanTable___5JMath[1032];
|
||||
extern "C" f32 asinAcosTable___5JMath[1032];
|
||||
|
||||
//
|
||||
// External References:
|
||||
//
|
||||
|
||||
extern "C" void __construct_array();
|
||||
extern "C" void _savegpr_27();
|
||||
extern "C" void _restgpr_27();
|
||||
extern "C" void atan();
|
||||
extern "C" void cos();
|
||||
extern "C" void sin();
|
||||
extern "C" void asin();
|
||||
struct TAsinAcosTable {
|
||||
f32 table[1025];
|
||||
u8 pad[0x1C];
|
||||
TAsinAcosTable() {
|
||||
for (int i = 0; i < 1024; i++) {
|
||||
table[i] = asin(getConst2() * i);
|
||||
}
|
||||
table[0] = FLOAT_LABEL(zero);
|
||||
table[1024] = 0.7853982; // 0.25 * PI
|
||||
}
|
||||
};
|
||||
|
||||
//
|
||||
// Declarations:
|
||||
//
|
||||
|
||||
namespace JMath {
|
||||
|
||||
/* ############################################################################################## */
|
||||
/* 80439A20-80449A20 066740 10000+00 1/1 265/265 705/705 .bss sincosTable___5JMath */
|
||||
u8 JMath::sincosTable_[65536];
|
||||
TSinCosTable sincosTable_;
|
||||
|
||||
/* 80449A20-8044AA40 076740 1020+00 1/1 0/0 0/0 .bss atanTable___5JMath */
|
||||
f32 JMath::atanTable_[1032];
|
||||
TAtanTable atanTable_;
|
||||
|
||||
/* 8044AA40-8044BA60 077760 1020+00 1/1 1/1 0/0 .bss asinAcosTable___5JMath */
|
||||
f32 JMath::asinAcosTable_[1032];
|
||||
TAsinAcosTable asinAcosTable_;
|
||||
|
||||
/* 804564D8-804564E0 004AD8 0004+04 2/2 0/0 0/0 .sdata2 @326 */
|
||||
SECTION_SDATA2 static f32 lit_326[1 + 1 /* padding */] = {
|
||||
0.0f,
|
||||
/* padding */
|
||||
0.0f,
|
||||
};
|
||||
|
||||
/* 804564E0-804564E8 004AE0 0008+00 1/1 0/0 0/0 .sdata2 @436 */
|
||||
SECTION_SDATA2 static f64 lit_436 = 6.2831854820251465;
|
||||
|
||||
/* 804564E8-804564F0 004AE8 0008+00 1/1 0/0 0/0 .sdata2 @437 */
|
||||
SECTION_SDATA2 static f64 lit_437 = 8192.0;
|
||||
|
||||
/* 804564F0-804564F8 004AF0 0008+00 1/1 0/0 0/0 .sdata2 @438 */
|
||||
SECTION_SDATA2 static f64 lit_438 = 0.0009765625;
|
||||
|
||||
/* 804564F8-80456500 004AF8 0004+04 1/1 0/0 0/0 .sdata2 @439 */
|
||||
SECTION_SDATA2 static f32 lit_439[1 + 1 /* padding */] = {
|
||||
0.7853981852531433f,
|
||||
/* padding */
|
||||
0.0f,
|
||||
};
|
||||
|
||||
/* 80456500-80456508 004B00 0008+00 1/1 0/0 0/0 .sdata2 @441 */
|
||||
SECTION_SDATA2 static f64 lit_441 = 4503601774854144.0 /* cast s32 to float */;
|
||||
|
||||
/* 80339AEC-80339CB0 33442C 01C4+00 0/0 1/0 0/0 .text __sinit_JMATrigonometric_cpp */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
asm void __sinit_JMATrigonometric_cpp() {
|
||||
nofralloc
|
||||
#include "asm/JSystem/JMath/JMATrigonometric/__sinit_JMATrigonometric_cpp.s"
|
||||
}
|
||||
#pragma pop
|
||||
|
||||
#pragma push
|
||||
#pragma force_active on
|
||||
REGISTER_CTORS(0x80339AEC, __sinit_JMATrigonometric_cpp);
|
||||
#pragma pop
|
||||
|
||||
/* 80339CB0-80339CC0 3345F0 0010+00 1/1 0/0 0/0 .text __ct__Q23std9pair<f,f>Fv */
|
||||
#pragma push
|
||||
#pragma optimization_level 0
|
||||
#pragma optimizewithasm off
|
||||
extern "C" asm void func_80339CB0(void* _this) {
|
||||
nofralloc
|
||||
#include "asm/JSystem/JMath/JMATrigonometric/func_80339CB0.s"
|
||||
}
|
||||
#pragma pop
|
||||
} // namespace JMath
|
||||
@@ -15,29 +15,29 @@ 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) {
|
||||
mX = param_0;
|
||||
mY = param_1;
|
||||
mZ = param_2;
|
||||
x = param_0;
|
||||
y = param_1;
|
||||
z = param_2;
|
||||
}
|
||||
|
||||
/* 80267404-8026745C 0058+00 s=0 e=0 z=3 None .text __pl__5csXyzFR5csXyz */
|
||||
csXyz csXyz::operator+(csXyz& param_0) {
|
||||
return csXyz(mX + param_0.mX, mY + param_0.mY, mZ + param_0.mZ);
|
||||
return csXyz(x + param_0.x, y + param_0.y, z + param_0.z);
|
||||
}
|
||||
|
||||
/* 8026745C-80267490 0034+00 s=0 e=2 z=11 None .text __apl__5csXyzFR5csXyz */
|
||||
void csXyz::operator+=(csXyz& param_0) {
|
||||
mX += param_0.mX;
|
||||
mY += param_0.mY;
|
||||
mZ += param_0.mZ;
|
||||
x += param_0.x;
|
||||
y += param_0.y;
|
||||
z += param_0.z;
|
||||
}
|
||||
|
||||
/* 80267490-802674E8 0058+00 s=0 e=0 z=1 None .text __mi__5csXyzFR5csXyz */
|
||||
csXyz csXyz::operator-(csXyz& param_0) {
|
||||
return csXyz(mX - param_0.mX, mY - param_0.mY, mZ - param_0.mZ);
|
||||
return csXyz(x - param_0.x, y - param_0.y, z - param_0.z);
|
||||
}
|
||||
|
||||
/* 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(x * param_0, y * param_0, z * param_0);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user