This commit is contained in:
TakaRikka
2025-11-30 14:35:25 -08:00
2422 changed files with 53851 additions and 74495 deletions
-68
View File
@@ -12,16 +12,10 @@
#include "m_Do/m_Do_dvd_thread.h"
#include "m_Do/m_Do_ext.h"
/* 80451138-8045113C 000638 0004+00 3/3 0/0 0/0 .sbss mFirst__24DynamicModuleControlBase
*/
DynamicModuleControlBase* DynamicModuleControlBase::mFirst;
/* 8045113C-80451140 00063C 0004+00 2/2 0/0 0/0 .sbss mLast__24DynamicModuleControlBase
*/
DynamicModuleControlBase* DynamicModuleControlBase::mLast;
/* 802621CC-80262284 25CB0C 00B8+00 1/0 2/2 0/0 .text __dt__24DynamicModuleControlBaseFv
*/
DynamicModuleControlBase::~DynamicModuleControlBase() {
force_unlink();
if (mPrev != NULL) {
@@ -40,8 +34,6 @@ DynamicModuleControlBase::~DynamicModuleControlBase() {
mPrev = NULL;
}
/* 80262284-802622D0 25CBC4 004C+00 1/1 0/0 0/0 .text __ct__24DynamicModuleControlBaseFv
*/
DynamicModuleControlBase::DynamicModuleControlBase() {
mLinkCount = 0;
mDoLinkCount = 0;
@@ -56,8 +48,6 @@ DynamicModuleControlBase::DynamicModuleControlBase() {
mLast = this;
}
/* 802622D0-80262364 25CC10 0094+00 0/0 2/2 0/0 .text link__24DynamicModuleControlBaseFv
*/
BOOL DynamicModuleControlBase::link() {
if (mLinkCount == 0) {
do_load();
@@ -74,7 +64,6 @@ BOOL DynamicModuleControlBase::link() {
return true;
}
/* 80262364-802623EC 25CCA4 0088+00 0/0 1/1 0/0 .text unlink__24DynamicModuleControlBaseFv */
BOOL DynamicModuleControlBase::unlink() {
if (mLinkCount != 0) {
mLinkCount--;
@@ -89,7 +78,6 @@ BOOL DynamicModuleControlBase::unlink() {
return true;
}
/* 802623EC-8026242C 25CD2C 0040+00 0/0 1/1 0/0 .text load_async__24DynamicModuleControlBaseFv */
BOOL DynamicModuleControlBase::load_async() {
if (mLinkCount == 0) {
return do_load_async();
@@ -97,8 +85,6 @@ BOOL DynamicModuleControlBase::load_async() {
return true;
}
/* 8026242C-80262470 25CD6C 0044+00 1/1 0/0 0/0 .text force_unlink__24DynamicModuleControlBaseFv
*/
bool DynamicModuleControlBase::force_unlink() {
if (mLinkCount != 0) {
mLinkCount = 0;
@@ -107,8 +93,6 @@ bool DynamicModuleControlBase::force_unlink() {
return true;
}
/* 80262470-80262660 25CDB0 01F0+00 2/0 2/2 0/0 .text dump__24DynamicModuleControlBaseFv
*/
void DynamicModuleControlBase::dump() {
u16 doLinkCount;
u16 linkCount;
@@ -142,7 +126,6 @@ void DynamicModuleControlBase::dump() {
JUTReportConsole_f("TotalSize %6.2f %06x\n\n", totalSize / 1024.0f, totalSize);
}
/* 80262660-802626D0 25CFA0 0070+00 0/0 2/2 0/0 .text __ct__20DynamicModuleControlFPCc */
DynamicModuleControl::DynamicModuleControl(char const* name) {
mModule = NULL;
mBss = NULL;
@@ -155,21 +138,14 @@ DynamicModuleControl::DynamicModuleControl(char const* name) {
mAsyncLoadCallback = NULL;
}
/* ############################################################################################## */
/* 80451140-80451144 000640 0004+00 3/3 0/0 0/0 .sbss sAllocBytes__20DynamicModuleControl
*/
u32 DynamicModuleControl::sAllocBytes;
/* 80451144-80451148 000644 0004+00 3/3 0/0 0/0 .sbss sArchive__20DynamicModuleControl */
JKRArchive* DynamicModuleControl::sArchive;
/* 80451148-80451150 000648 0004+04 3/3 0/0 0/0 .sbss sFileCache__20DynamicModuleControl
*/
JKRFileCache* DynamicModuleControl::sFileCache;
static const char* baseString = "Base";
/* 802626D0-8026275C 25D010 008C+00 1/1 0/0 0/0 .text mountCallback__20DynamicModuleControlFPv */
JKRArchive* DynamicModuleControl::mountCallback(void* param_0) {
JKRExpHeap* heap = mDoExt_getArchiveHeap();
sFileCache = JKRFileCache::mount("/rel/Final/Release", heap, NULL);
@@ -183,7 +159,6 @@ JKRArchive* DynamicModuleControl::mountCallback(void* param_0) {
return sArchive;
}
/* 8026275C-80262794 25D09C 0038+00 0/0 1/1 0/0 .text initialize__20DynamicModuleControlFv */
bool DynamicModuleControl::initialize() {
sFileCache = NULL;
sAllocBytes = 0;
@@ -192,14 +167,11 @@ bool DynamicModuleControl::initialize() {
return true;
}
/* 80262794-802627C0 25D0D4 002C+00 1/1 0/0 0/0 .text callback__20DynamicModuleControlFPv
*/
bool DynamicModuleControl::callback(void* moduleControlPtr) {
DynamicModuleControl* moduleControl = (DynamicModuleControl*)moduleControlPtr;
return moduleControl->do_load();
}
/* 802627C0-802627E8 25D100 0028+00 1/1 0/0 0/0 .text calcSum2__FPCUsUl */
static u32 calcSum2(u16 const* data, u32 size) {
u32 sum = 0;
while (size > 0) {
@@ -210,8 +182,6 @@ static u32 calcSum2(u16 const* data, u32 size) {
return sum;
}
/* 802627E8-80262AFC 25D128 0314+00 1/0 0/0 0/0 .text do_load__20DynamicModuleControlFv
*/
bool DynamicModuleControl::do_load() {
if (mModule != NULL) {
return true;
@@ -311,7 +281,6 @@ bool DynamicModuleControl::do_load() {
return true;
}
/* 80262AFC-80262BC4 25D43C 00C8+00 1/0 0/0 0/0 .text do_load_async__20DynamicModuleControlFv */
BOOL DynamicModuleControl::do_load_async() {
if (mAsyncLoadCallback == NULL) {
if (mModule != NULL) {
@@ -334,8 +303,6 @@ BOOL DynamicModuleControl::do_load_async() {
}
}
/* 80262BC4-80262C0C 25D504 0048+00 1/0 0/0 0/0 .text do_unload__20DynamicModuleControlFv
*/
bool DynamicModuleControl::do_unload() {
if (mModule != NULL) {
JKRFree(mModule);
@@ -344,7 +311,6 @@ bool DynamicModuleControl::do_unload() {
return true;
}
/* 80262C0C-80262C5C 25D54C 0050+00 1/0 0/0 0/0 .text dump2__20DynamicModuleControlFv */
void DynamicModuleControl::dump2() {
if (mModule != NULL) {
OSSectionInfo* section = (OSSectionInfo*)mModule->info.sectionInfoOffset;
@@ -354,8 +320,6 @@ void DynamicModuleControl::dump2() {
}
}
/* 80262C5C-80262F28 25D59C 02CC+00 1/0 0/0 0/0 .text do_link__20DynamicModuleControlFv
*/
BOOL DynamicModuleControl::do_link() {
OSGetTime();
if (mModule == NULL) {
@@ -452,8 +416,6 @@ error:
return FALSE;
}
/* 80262F28-80263000 25D868 00D8+00 1/0 0/0 0/0 .text do_unlink__20DynamicModuleControlFv
*/
bool DynamicModuleControl::do_unlink() {
OSTime time1 = OSGetTime();
((void (*)())mModule->epilog)();
@@ -474,7 +436,6 @@ bool DynamicModuleControl::do_unlink() {
return true;
}
/* 80263000-80263070 25D940 0070+00 1/0 0/0 0/0 .text getModuleSize__20DynamicModuleControlCFv */
int DynamicModuleControl::getModuleSize() const {
if (mModule != NULL) {
u32 size = JKRGetMemBlockSize(NULL, mModule);
@@ -487,24 +448,19 @@ int DynamicModuleControl::getModuleSize() const {
}
}
/* 80263070-80263088 25D9B0 0018+00 1/0 0/0 0/0 .text
* getModuleTypeString__20DynamicModuleControlCFv */
const char* DynamicModuleControl::getModuleTypeString() const {
static const char* strings[4] = {"????", "MEM", "ARAM", "DVD"};
return strings[mResourceType & 3];
}
/* 80263088-8026308C 25D9C8 0004+00 0/0 0/0 756/756 .text ModuleProlog */
extern "C" void ModuleProlog() {
/* empty function */
}
/* 8026308C-80263090 25D9CC 0004+00 0/0 0/0 756/756 .text ModuleEpilog */
extern "C" void ModuleEpilog() {
/* empty function */
}
/* 80263090-8026314C 25D9D0 00BC+00 0/0 0/0 757/757 .text ModuleUnresolved */
extern "C" void ModuleUnresolved() {
// "\nError: Unlinked function was called.\n"
OSReport_Error("\nError: リンクされていない関数が呼び出されました.\n");
@@ -518,7 +474,6 @@ extern "C" void ModuleUnresolved() {
OSReport_Error("\n");
}
/* 8026314C-80263190 25DA8C 0044+00 0/0 0/0 757/757 .text ModuleConstructorsX */
extern "C" void ModuleConstructorsX(void (**ctors)()) {
while (*ctors != 0) {
(**ctors)();
@@ -526,32 +481,9 @@ extern "C" void ModuleConstructorsX(void (**ctors)()) {
}
}
/* 80263190-802631D4 25DAD0 0044+00 0/0 0/0 757/757 .text ModuleDestructorsX */
extern "C" void ModuleDestructorsX(void (**dtors)()) {
while (*dtors != 0) {
(**dtors)();
dtors++;
}
}
/* 802631D4-802631DC 25DB14 0008+00 1/0 0/0 0/0 .text do_link__24DynamicModuleControlBaseFv */
/* 802631DC-802631E4 25DB1C 0008+00 1/0 0/0 0/0 .text do_load__24DynamicModuleControlBaseFv */
/* 802631E4-802631EC 25DB24 0008+00 1/0 0/0 0/0 .text do_unload__24DynamicModuleControlBaseFv */
/* 802631EC-802631F4 25DB2C 0008+00 1/0 0/0 0/0 .text do_unlink__24DynamicModuleControlBaseFv */
/* 802631F4-802631FC 25DB34 0008+00 1/0 0/0 0/0 .text do_load_async__24DynamicModuleControlBaseFv
*/
/* 802631FC-80263200 25DB3C 0004+00 1/0 0/0 0/0 .text dump2__24DynamicModuleControlBaseFv
*/
/* 80263200-80263210 25DB40 0010+00 1/0 0/0 0/0 .text
* getModuleTypeString__24DynamicModuleControlBaseCFv */
/* 80263210-80263218 25DB50 0008+00 1/0 0/0 0/0 .text getModuleSize__24DynamicModuleControlBaseCFv
*/
/* 80263218-80263220 25DB58 0008+00 1/0 0/0 0/0 .text getModuleName__20DynamicModuleControlCFv */
-36
View File
@@ -10,8 +10,6 @@
f32 J2DGetKeyFrameInterpolationf(f32 param_0, J3DAnmKeyTableBase* param_1, f32* param_2);
f32 J2DGetKeyFrameInterpolations(f32 param_0, J3DAnmKeyTableBase* param_1, s16* param_2);
/* 8030A590-8030AAFC 304ED0 056C+00 1/0 0/0 0/0 .text
* getTransform__19J2DAnmTransformFullCFUsP16J3DTransformInfo */
void J2DAnmTransformFull::getTransform(u16 param_0, J3DTransformInfo* transformInfo) const {
u16 idx = (param_0 * 3);
J3DAnmTransformFullTable* xPart = &mTableInfo[idx];
@@ -91,8 +89,6 @@ void J2DAnmTransformFull::getTransform(u16 param_0, J3DTransformInfo* transformI
}
}
/* 8030AAFC-8030AF24 30543C 0428+00 1/0 0/0 0/0 .text
* calcTransform__18J2DAnmTransformKeyCFfUsP16J3DTransformInfo */
void J2DAnmTransformKey::calcTransform(f32 param_0, u16 param_1,
J3DTransformInfo* transformInfo) const {
u16 idx = param_1 * 3;
@@ -206,8 +202,6 @@ void J2DAnmTransformKey::calcTransform(f32 param_0, u16 param_1,
}
}
/* 8030AF24-8030AFC8 305864 00A4+00 3/0 0/0 0/0 .text
* searchUpdateMaterialID__11J2DAnmColorFP9J2DScreen */
void J2DAnmColor::searchUpdateMaterialID(J2DScreen* pScreen) {
if (pScreen != NULL && pScreen->mNameTable != NULL) {
for (u16 entry = 0; entry < this->getUpdateMaterialNum(); entry++) {
@@ -221,7 +215,6 @@ void J2DAnmColor::searchUpdateMaterialID(J2DScreen* pScreen) {
}
}
/* 8030AFC8-8030B200 305908 0238+00 1/0 0/0 0/0 .text getColor__15J2DAnmColorFullCFUsP8_GXColor */
void J2DAnmColorFull::getColor(u16 param_0, _GXColor* pColor) const {
J3DAnmColorFullTable* info = &mInfoTable[param_0];
u16 maxFrame = info->mRMaxFrame;
@@ -258,7 +251,6 @@ void J2DAnmColorFull::getColor(u16 param_0, _GXColor* pColor) const {
}
}
/* 8030B200-8030B4C4 305B40 02C4+00 1/0 0/0 0/0 .text getColor__14J2DAnmColorKeyCFUsP8_GXColor */
void J2DAnmColorKey::getColor(u16 param_0, _GXColor* pColor) const {
J3DAnmColorKeyTable* info = &mInfoTable[param_0];
f32 val;
@@ -336,8 +328,6 @@ void J2DAnmColorKey::getColor(u16 param_0, _GXColor* pColor) const {
}
}
/* 8030B4C4-8030B704 305E04 0240+00 1/0 0/0 0/0 .text
* getColor__18J2DAnmVtxColorFullCFUcUsP8_GXColor */
void J2DAnmVtxColorFull::getColor(u8 param_0, u16 param_1, _GXColor* pColor) const {
J3DAnmColorFullTable* info = &mInfoTable[param_0][param_1];
u16 maxFrame = info->mRMaxFrame;
@@ -374,8 +364,6 @@ void J2DAnmVtxColorFull::getColor(u8 param_0, u16 param_1, _GXColor* pColor) con
}
}
/* 8030B704-8030B9F0 306044 02EC+00 1/0 0/0 0/0 .text
* getColor__17J2DAnmVtxColorKeyCFUcUsP8_GXColor */
void J2DAnmVtxColorKey::getColor(u8 param_0, u16 param_1, _GXColor* pColor) const {
J3DAnmColorKeyTable* info = &mInfoTable[param_0][param_1];
f32 val;
@@ -453,8 +441,6 @@ void J2DAnmVtxColorKey::getColor(u8 param_0, u16 param_1, _GXColor* pColor) cons
}
}
/* 8030B9F0-8030BC60 306330 0270+00 0/0 1/1 0/0 .text
* calcTransform__19J2DAnmTextureSRTKeyCFfUsP17J3DTextureSRTInfo */
void J2DAnmTextureSRTKey::calcTransform(f32 param_0, u16 param_1, J3DTextureSRTInfo* pInfo) const {
u16 idx = param_1 * 3;
J3DAnmTransformKeyTable* xInf = &mInfoTable[idx];
@@ -519,8 +505,6 @@ void J2DAnmTextureSRTKey::calcTransform(f32 param_0, u16 param_1, J3DTextureSRTI
}
}
/* 8030BC60-8030BD10 3065A0 00B0+00 1/0 0/0 0/0 .text
* searchUpdateMaterialID__19J2DAnmTextureSRTKeyFP9J2DScreen */
void J2DAnmTextureSRTKey::searchUpdateMaterialID(J2DScreen* pScreen) {
if (pScreen != NULL && pScreen->mNameTable != NULL) {
for (u16 entry = 0; entry < this->getUpdateMaterialNum(); entry++) {
@@ -534,8 +518,6 @@ void J2DAnmTextureSRTKey::searchUpdateMaterialID(J2DScreen* pScreen) {
}
}
/* 8030BD10-8030BEE8 306650 01D8+00 1/0 0/0 0/0 .text
* searchUpdateMaterialID__16J2DAnmTexPatternFP9J2DScreen */
void J2DAnmTexPattern::searchUpdateMaterialID(J2DScreen* pScreen) {
if (pScreen != NULL && pScreen->mNameTable != NULL && pScreen->mTexRes != NULL) {
for (u16 entry = 0; entry < this->getUpdateMaterialNum(); entry++) {
@@ -573,8 +555,6 @@ void J2DAnmTexPattern::searchUpdateMaterialID(J2DScreen* pScreen) {
}
}
/* 8030BEE8-8030BF9C 306828 00B4+00 2/2 1/1 0/0 .text getTexNo__16J2DAnmTexPatternCFUsPUs
*/
void J2DAnmTexPattern::getTexNo(u16 param_0, u16* pTexNo) const {
u16 maxFrame = mAnmTable[param_0].mMaxFrame;
f32 frame = getFrame();
@@ -587,8 +567,6 @@ void J2DAnmTexPattern::getTexNo(u16 param_0, u16* pTexNo) const {
}
}
/* 8030BF9C-8030BFF0 3068DC 0054+00 0/0 1/1 0/0 .text getResTIMG__16J2DAnmTexPatternCFUs
*/
ResTIMG* J2DAnmTexPattern::getResTIMG(u16 param_0) const {
if (mTIMGPtrArray == NULL) {
return NULL;
@@ -599,8 +577,6 @@ ResTIMG* J2DAnmTexPattern::getResTIMG(u16 param_0) const {
}
}
/* 8030BFF0-8030C048 306930 0058+00 0/0 1/1 0/0 .text getPalette__16J2DAnmTexPatternCFUs
*/
JUTPalette* J2DAnmTexPattern::getPalette(u16 param_0) const {
if (mTIMGPtrArray == NULL) {
return NULL;
@@ -611,8 +587,6 @@ JUTPalette* J2DAnmTexPattern::getPalette(u16 param_0) const {
}
}
/* 8030C048-8030C0F0 306988 00A8+00 0/0 3/3 0/0 .text getVisibility__20J2DAnmVisibilityFullCFUsPUc
*/
void J2DAnmVisibilityFull::getVisibility(u16 param_0, u8* pOut) const {
u16 maxFrame = mTable[param_0]._0;
if (getFrame() < 0) {
@@ -625,8 +599,6 @@ void J2DAnmVisibilityFull::getVisibility(u16 param_0, u8* pOut) const {
}
}
/* 8030C0F0-8030C3B4 306A30 02C4+00 0/0 1/1 0/0 .text
* getTevColorReg__15J2DAnmTevRegKeyCFUsP11_GXColorS10 */
void J2DAnmTevRegKey::getTevColorReg(u16 param_0, _GXColorS10* pColor) const {
J3DAnmCRegKeyTable* info = &mAnmCRegKeyTable[param_0];
f32 val;
@@ -704,8 +676,6 @@ void J2DAnmTevRegKey::getTevColorReg(u16 param_0, _GXColorS10* pColor) const {
}
}
/* 8030C3B4-8030C678 306CF4 02C4+00 0/0 1/1 0/0 .text
* getTevKonstReg__15J2DAnmTevRegKeyCFUsP8_GXColor */
void J2DAnmTevRegKey::getTevKonstReg(u16 param_0, _GXColor* pColor) const {
J3DAnmKRegKeyTable* info = &mAnmKRegKeyTable[param_0];
f32 val;
@@ -783,8 +753,6 @@ void J2DAnmTevRegKey::getTevKonstReg(u16 param_0, _GXColor* pColor) const {
}
}
/* 8030C678-8030C77C 306FB8 0104+00 1/0 0/0 0/0 .text
* searchUpdateMaterialID__15J2DAnmTevRegKeyFP9J2DScreen */
void J2DAnmTevRegKey::searchUpdateMaterialID(J2DScreen* pScreen) {
if (pScreen != NULL && pScreen->mNameTable != NULL) {
for (u16 i = 0; i < mCRegUpdateMaterialNum; i++) {
@@ -806,8 +774,6 @@ void J2DAnmTevRegKey::searchUpdateMaterialID(J2DScreen* pScreen) {
}
}
/* 8030C77C-8030C9B0 3070BC 0234+00 6/6 0/0 0/0 .text
* J2DGetKeyFrameInterpolation<s>__FfP18J3DAnmKeyTableBasePs */
// should be J2DGetKeyFrameInterpolation<s16>
f32 J2DGetKeyFrameInterpolations(f32 param_0, J3DAnmKeyTableBase* param_1, s16* param_2) {
if (param_0 < param_2[0]) {
@@ -853,8 +819,6 @@ f32 J2DGetKeyFrameInterpolations(f32 param_0, J3DAnmKeyTableBase* param_1, s16*
}
}
/* 8030C9B0-8030CB2C 3072F0 017C+00 2/2 0/0 0/0 .text
* J2DGetKeyFrameInterpolation<f>__FfP18J3DAnmKeyTableBasePf */
// should be J2DGetKeyFrameInterpolation<s16>
f32 J2DGetKeyFrameInterpolationf(f32 param_0, J3DAnmKeyTableBase* param_1, f32* param_2) {
if (param_0 < param_2[0]) {
-52
View File
@@ -7,8 +7,6 @@
#include "JSystem/J2DGraph/J2DAnmLoader.h"
#include "JSystem/JSupport/JSupport.h"
/* 80308A6C-80309290 3033AC 0824+00 0/0 26/26 2/2 .text load__20J2DAnmLoaderDataBaseFPCv
*/
J2DAnmBase* J2DAnmLoaderDataBase::load(void const* p_data) {
const J3DAnmDataHeader* hdr = (const J3DAnmDataHeader*)p_data;
@@ -85,13 +83,10 @@ J2DAnmBase* J2DAnmLoaderDataBase::load(void const* p_data) {
}
}
/* 80309290-803092AC 303BD0 001C+00 1/1 0/0 0/0 .text __ct__19J2DAnmKeyLoader_v15Fv */
J2DAnmKeyLoader_v15::J2DAnmKeyLoader_v15() {}
/* 803092AC-80309308 303BEC 005C+00 2/1 0/0 0/0 .text __dt__19J2DAnmKeyLoader_v15Fv */
J2DAnmKeyLoader_v15::~J2DAnmKeyLoader_v15() {}
/* 80309308-80309414 303C48 010C+00 2/1 0/0 0/0 .text load__19J2DAnmKeyLoader_v15FPCv */
void* J2DAnmKeyLoader_v15::load(void const* p_data) {
const J3DAnmDataHeader* hdr = (const J3DAnmDataHeader*)p_data;
const J3DAnmDataBlockHeader* dataPtr = &hdr->mFirst;
@@ -120,8 +115,6 @@ void* J2DAnmKeyLoader_v15::load(void const* p_data) {
return mpResource;
}
/* 80309414-80309570 303D54 015C+00 1/0 0/0 0/0 .text
* setResource__19J2DAnmKeyLoader_v15FP10J2DAnmBasePCv */
void J2DAnmKeyLoader_v15::setResource(J2DAnmBase* p_anm, void const* p_data) {
const J3DAnmDataHeader* hdr = (const J3DAnmDataHeader*)p_data;
const J3DAnmDataBlockHeader* dataPtr = &hdr->mFirst;
@@ -159,14 +152,10 @@ void J2DAnmKeyLoader_v15::setResource(J2DAnmBase* p_anm, void const* p_data) {
}
}
/* 80309570-80309598 303EB0 0028+00 1/1 0/0 0/0 .text
* readAnmTransform__19J2DAnmKeyLoader_v15FPC22J3DAnmTransformKeyData */
void J2DAnmKeyLoader_v15::readAnmTransform(J3DAnmTransformKeyData const* p_data) {
setAnmTransform((J2DAnmTransformKey*)mpResource, p_data);
}
/* 80309598-80309634 303ED8 009C+00 2/2 0/0 0/0 .text
* setAnmTransform__19J2DAnmKeyLoader_v15FP18J2DAnmTransformKeyPC22J3DAnmTransformKeyData */
void J2DAnmKeyLoader_v15::setAnmTransform(J2DAnmTransformKey* p_anm,
J3DAnmTransformKeyData const* p_data) {
p_anm->field_0x22 = p_data->field_0xc;
@@ -182,14 +171,10 @@ void J2DAnmKeyLoader_v15::setAnmTransform(J2DAnmTransformKey* p_anm,
JSUConvertOffsetToPtr<f32>(p_data, (void*)p_data->field_0x20);
}
/* 80309634-8030965C 303F74 0028+00 1/1 0/0 0/0 .text
* readAnmTextureSRT__19J2DAnmKeyLoader_v15FPC23J3DAnmTextureSRTKeyData */
void J2DAnmKeyLoader_v15::readAnmTextureSRT(J3DAnmTextureSRTKeyData const* p_data) {
setAnmTextureSRT((J2DAnmTextureSRTKey*)mpResource, p_data);
}
/* 8030965C-80309848 303F9C 01EC+00 2/2 0/0 0/0 .text
* setAnmTextureSRT__19J2DAnmKeyLoader_v15FP19J2DAnmTextureSRTKeyPC23J3DAnmTextureSRTKeyData */
void J2DAnmKeyLoader_v15::setAnmTextureSRT(J2DAnmTextureSRTKey* p_anm,
J3DAnmTextureSRTKeyData const* p_data) {
p_anm->mUpdateMaterialNum = p_data->field_0xc;
@@ -240,14 +225,10 @@ void J2DAnmKeyLoader_v15::setAnmTextureSRT(J2DAnmTextureSRTKey* p_anm,
}
}
/* 80309848-80309870 304188 0028+00 1/1 0/0 0/0 .text
* readAnmColor__19J2DAnmKeyLoader_v15FPC18J3DAnmColorKeyData */
void J2DAnmKeyLoader_v15::readAnmColor(J3DAnmColorKeyData const* p_data) {
setAnmColor((J2DAnmColorKey*)mpResource, p_data);
}
/* 80309870-8030995C 3041B0 00EC+00 2/2 0/0 0/0 .text
* setAnmColor__19J2DAnmKeyLoader_v15FP14J2DAnmColorKeyPC18J3DAnmColorKeyData */
void J2DAnmKeyLoader_v15::setAnmColor(J2DAnmColorKey* p_anm, J3DAnmColorKeyData const* p_data) {
p_anm->mFrameMax = p_data->mFrameMax;
p_anm->field_0x4 = p_data->field_0x8;
@@ -269,14 +250,10 @@ void J2DAnmKeyLoader_v15::setAnmColor(J2DAnmColorKey* p_anm, J3DAnmColorKeyData
JSUConvertOffsetToPtr<ResNTAB>(p_data, (void*)p_data->mNameTabOffset));
}
/* 8030995C-80309984 30429C 0028+00 1/1 0/0 0/0 .text
* readAnmVtxColor__19J2DAnmKeyLoader_v15FPC21J3DAnmVtxColorKeyData */
void J2DAnmKeyLoader_v15::readAnmVtxColor(J3DAnmVtxColorKeyData const* p_data) {
setAnmVtxColor((J2DAnmVtxColorKey*)mpResource, p_data);
}
/* 80309984-80309A80 3042C4 00FC+00 2/2 0/0 0/0 .text
* setAnmVtxColor__19J2DAnmKeyLoader_v15FP17J2DAnmVtxColorKeyPC21J3DAnmVtxColorKeyData */
void J2DAnmKeyLoader_v15::setAnmVtxColor(J2DAnmVtxColorKey* p_anm,
J3DAnmVtxColorKeyData const* p_data) {
p_anm->mFrameMax = p_data->mFrameMax;
@@ -302,7 +279,6 @@ void J2DAnmKeyLoader_v15::setAnmVtxColor(J2DAnmVtxColorKey* p_anm,
p_anm->mAValues = JSUConvertOffsetToPtr<s16>(p_data, (void*)p_data->mAValOffset);
}
/* 80309A80-80309B8C 3043C0 010C+00 2/1 0/0 0/0 .text load__20J2DAnmFullLoader_v15FPCv */
void* J2DAnmFullLoader_v15::load(void const* p_data) {
const J3DAnmDataHeader* hdr = (const J3DAnmDataHeader*)p_data;
const J3DAnmDataBlockHeader* dataPtr = &hdr->mFirst;
@@ -330,8 +306,6 @@ void* J2DAnmFullLoader_v15::load(void const* p_data) {
return mpResource;
}
/* 80309B8C-80309CE8 3044CC 015C+00 1/0 0/0 0/0 .text
* setResource__20J2DAnmFullLoader_v15FP10J2DAnmBasePCv */
void J2DAnmFullLoader_v15::setResource(J2DAnmBase* p_anm, void const* p_data) {
const J3DAnmDataHeader* hdr = (const J3DAnmDataHeader*)p_data;
const J3DAnmDataBlockHeader* dataPtr = &hdr->mFirst;
@@ -365,20 +339,14 @@ void J2DAnmFullLoader_v15::setResource(J2DAnmBase* p_anm, void const* p_data) {
}
}
/* 80309CE8-80309D04 304628 001C+00 1/1 0/0 0/0 .text __ct__20J2DAnmFullLoader_v15Fv */
J2DAnmFullLoader_v15::J2DAnmFullLoader_v15() {}
/* 80309D04-80309D60 304644 005C+00 2/1 0/0 0/0 .text __dt__20J2DAnmFullLoader_v15Fv */
J2DAnmFullLoader_v15::~J2DAnmFullLoader_v15() {}
/* 80309D60-80309D88 3046A0 0028+00 1/1 0/0 0/0 .text
* readAnmTransform__20J2DAnmFullLoader_v15FPC23J3DAnmTransformFullData */
void J2DAnmFullLoader_v15::readAnmTransform(J3DAnmTransformFullData const* p_data) {
setAnmTransform((J2DAnmTransformFull*)mpResource, p_data);
}
/* 80309D88-80309E1C 3046C8 0094+00 2/2 0/0 0/0 .text
* setAnmTransform__20J2DAnmFullLoader_v15FP19J2DAnmTransformFullPC23J3DAnmTransformFullData */
void J2DAnmFullLoader_v15::setAnmTransform(J2DAnmTransformFull* p_anm,
J3DAnmTransformFullData const* p_data) {
p_anm->field_0x22 = p_data->field_0xc;
@@ -392,14 +360,10 @@ void J2DAnmFullLoader_v15::setAnmTransform(J2DAnmTransformFull* p_anm,
p_anm->mTranslateValues = JSUConvertOffsetToPtr<f32>(p_data, (void*)p_data->mTransValOffset);
}
/* 80309E1C-80309E44 30475C 0028+00 1/1 0/0 0/0 .text
* readAnmColor__20J2DAnmFullLoader_v15FPC19J3DAnmColorFullData */
void J2DAnmFullLoader_v15::readAnmColor(J3DAnmColorFullData const* p_data) {
setAnmColor((J2DAnmColorFull*)mpResource, p_data);
}
/* 80309E44-80309F10 304784 00CC+00 2/2 0/0 0/0 .text
* setAnmColor__20J2DAnmFullLoader_v15FP15J2DAnmColorFullPC19J3DAnmColorFullData */
void J2DAnmFullLoader_v15::setAnmColor(J2DAnmColorFull* p_anm, J3DAnmColorFullData const* p_data) {
p_anm->mFrameMax = p_data->mFrameMax;
p_anm->field_0x4 = p_data->field_0x8;
@@ -417,14 +381,10 @@ void J2DAnmFullLoader_v15::setAnmColor(J2DAnmColorFull* p_anm, J3DAnmColorFullDa
JSUConvertOffsetToPtr<ResNTAB>(p_data, (void*)p_data->mNameTabOffset));
}
/* 80309F10-80309F38 304850 0028+00 1/1 0/0 0/0 .text
* readAnmTexPattern__20J2DAnmFullLoader_v15FPC24J3DAnmTexPatternFullData */
void J2DAnmFullLoader_v15::readAnmTexPattern(J3DAnmTexPatternFullData const* p_data) {
setAnmTexPattern((J2DAnmTexPattern*)mpResource, p_data);
}
/* 80309F38-80309FDC 304878 00A4+00 2/2 0/0 0/0 .text
* setAnmTexPattern__20J2DAnmFullLoader_v15FP16J2DAnmTexPatternPC24J3DAnmTexPatternFullData */
void J2DAnmFullLoader_v15::setAnmTexPattern(J2DAnmTexPattern* p_anm,
J3DAnmTexPatternFullData const* p_data) {
p_anm->mFrameMax = p_data->mFrameMax;
@@ -441,14 +401,10 @@ void J2DAnmFullLoader_v15::setAnmTexPattern(J2DAnmTexPattern* p_anm,
JSUConvertOffsetToPtr<ResNTAB>(p_data, (void*)p_data->mNameTabOffset));
}
/* 80309FDC-8030A004 30491C 0028+00 1/1 0/0 0/0 .text
* readAnmTevReg__19J2DAnmKeyLoader_v15FPC19J3DAnmTevRegKeyData */
void J2DAnmKeyLoader_v15::readAnmTevReg(J3DAnmTevRegKeyData const* p_data) {
setAnmTevReg((J2DAnmTevRegKey*)mpResource, p_data);
}
/* 8030A004-8030A190 304944 018C+00 2/2 0/0 0/0 .text
* setAnmTevReg__19J2DAnmKeyLoader_v15FP15J2DAnmTevRegKeyPC19J3DAnmTevRegKeyData */
void J2DAnmKeyLoader_v15::setAnmTevReg(J2DAnmTevRegKey* p_anm, J3DAnmTevRegKeyData const* p_data) {
p_anm->mFrameMax = p_data->mFrameMax;
p_anm->field_0x4 = p_data->field_0x8;
@@ -485,14 +441,10 @@ void J2DAnmKeyLoader_v15::setAnmTevReg(J2DAnmTevRegKey* p_anm, J3DAnmTevRegKeyDa
p_anm->mKAValues = JSUConvertOffsetToPtr<s16>(p_data, (void*)p_data->mKAValuesOffset);
}
/* 8030A190-8030A1B8 304AD0 0028+00 1/1 0/0 0/0 .text
* readAnmVisibility__20J2DAnmFullLoader_v15FPC24J3DAnmVisibilityFullData */
void J2DAnmFullLoader_v15::readAnmVisibility(J3DAnmVisibilityFullData const* p_data) {
setAnmVisibility((J2DAnmVisibilityFull*)mpResource, p_data);
}
/* 8030A1B8-8030A234 304AF8 007C+00 2/2 0/0 0/0 .text
* setAnmVisibility__20J2DAnmFullLoader_v15FP20J2DAnmVisibilityFullPC24J3DAnmVisibilityFullData */
void J2DAnmFullLoader_v15::setAnmVisibility(J2DAnmVisibilityFull* p_anm,
J3DAnmVisibilityFullData const* p_data) {
p_anm->mFrameMax = p_data->mFrameMax;
@@ -505,14 +457,10 @@ void J2DAnmFullLoader_v15::setAnmVisibility(J2DAnmVisibilityFull* p_anm,
p_anm->mValues = JSUConvertOffsetToPtr<u8>(p_data, p_data->mValuesOffset);
}
/* 8030A234-8030A25C 304B74 0028+00 1/1 0/0 0/0 .text
* readAnmVtxColor__20J2DAnmFullLoader_v15FPC22J3DAnmVtxColorFullData */
void J2DAnmFullLoader_v15::readAnmVtxColor(J3DAnmVtxColorFullData const* p_data) {
setAnmVtxColor((J2DAnmVtxColorFull*)mpResource, p_data);
}
/* 8030A25C-8030A358 304B9C 00FC+00 2/2 0/0 0/0 .text
* setAnmVtxColor__20J2DAnmFullLoader_v15FP18J2DAnmVtxColorFullPC22J3DAnmVtxColorFullData */
void J2DAnmFullLoader_v15::setAnmVtxColor(J2DAnmVtxColorFull* p_anm,
J3DAnmVtxColorFullData const* p_data) {
p_anm->mFrameMax = p_data->mFrameMax;
-18
View File
@@ -3,7 +3,6 @@
#include "JSystem/J2DGraph/J2DGrafContext.h"
#include "dolphin/gx.h"
/* 802E8B08-802E8BB4 2E3448 00AC+00 0/0 2/2 0/0 .text __ct__14J2DGrafContextFffff */
J2DGrafContext::J2DGrafContext(f32 x, f32 y, f32 width, f32 height)
: mBounds(x, y, x + width, y + height), mScissorBounds(x, y, x + width, y + height) {
JUtility::TColor color(-1);
@@ -11,7 +10,6 @@ J2DGrafContext::J2DGrafContext(f32 x, f32 y, f32 width, f32 height)
setLineWidth(6);
}
/* 802E8BB4-802E8C44 2E34F4 0090+00 1/0 1/1 0/0 .text setPort__14J2DGrafContextFv */
void J2DGrafContext::setPort() {
setScissor();
setup2D();
@@ -27,7 +25,6 @@ void J2DGrafContext::setPort() {
GXSetViewport(bounds.i.x, bounds.i.y, bounds.getWidth(), bounds.getHeight(), 0.0f, 1.0f);
}
/* 802E8C44-802E8E20 2E3584 01DC+00 1/0 1/0 0/0 .text setup2D__14J2DGrafContextFv */
void J2DGrafContext::setup2D() {
GXSetNumIndStages(0);
for (int i = 0; i < GX_MAX_TEVSTAGE; i++) {
@@ -63,7 +60,6 @@ void J2DGrafContext::setup2D() {
GXSetVtxDesc(GX_VA_TEX0, GX_NONE);
}
/* 802E8E20-802E90C0 2E3760 02A0+00 1/0 2/1 0/0 .text setScissor__14J2DGrafContextFv */
void J2DGrafContext::setScissor() {
JGeometry::TBox2<f32> bounds(0, 0, 1024, 1024);
JGeometry::TBox2<f32> curBounds(mScissorBounds);
@@ -80,14 +76,10 @@ void J2DGrafContext::setScissor() {
}
}
/* 802E90C0-802E90E4 2E3A00 0024+00 0/0 10/10 0/0 .text
* scissor__14J2DGrafContextFRCQ29JGeometry8TBox2<f> */
void J2DGrafContext::scissor(JGeometry::TBox2<f32> const& bounds) {
mScissorBounds = bounds;
}
/* 802E90E4-802E9118 2E3A24 0034+00 1/0 1/0 0/0 .text
* place__14J2DGrafContextFRCQ29JGeometry8TBox2<f> */
void J2DGrafContext::place(JGeometry::TBox2<f32> const& bounds) {
mBounds = bounds;
mScissorBounds = bounds;
@@ -134,15 +126,11 @@ void J2DGrafContext::setColor(JUtility::TColor colorTL, JUtility::TColor colorTR
mBoxPart.mDstFactor = GX_BL_ZERO;
}
/* 802E9234-802E9260 2E3B74 002C+00 1/1 2/2 0/0 .text setLineWidth__14J2DGrafContextFUc
*/
void J2DGrafContext::setLineWidth(u8 lineWidth) {
mLineWidth = lineWidth;
GXSetLineWidth(mLineWidth, GX_TO_ZERO);
}
/* 802E9260-802E9368 2E3BA0 0108+00 0/0 2/2 0/0 .text
* fillBox__14J2DGrafContextFRCQ29JGeometry8TBox2<f> */
void J2DGrafContext::fillBox(JGeometry::TBox2<f32> const& box) {
GXSetBlendMode((GXBlendMode)mBoxPart.mType, (GXBlendFactor)mBoxPart.mSrcFactor,
(GXBlendFactor)mBoxPart.mDstFactor, GX_LO_SET);
@@ -161,8 +149,6 @@ void J2DGrafContext::fillBox(JGeometry::TBox2<f32> const& box) {
GXSetVtxAttrFmt(GX_VTXFMT0, GX_VA_POS, GX_CLR_RGBA, GX_RGBA4, 0);
}
/* 802E9368-802E9488 2E3CA8 0120+00 0/0 1/1 0/0 .text
* drawFrame__14J2DGrafContextFRCQ29JGeometry8TBox2<f> */
void J2DGrafContext::drawFrame(JGeometry::TBox2<f32> const& box) {
GXSetBlendMode((GXBlendMode)mBoxPart.mType, (GXBlendFactor)mBoxPart.mSrcFactor,
(GXBlendFactor)mBoxPart.mDstFactor, GX_LO_SET);
@@ -183,8 +169,6 @@ void J2DGrafContext::drawFrame(JGeometry::TBox2<f32> const& box) {
GXSetVtxAttrFmt(GX_VTXFMT0, GX_VA_POS, GX_CLR_RGBA, GX_RGBA4, 0);
}
/* 802E9488-802E9564 2E3DC8 00DC+00 1/1 0/0 0/0 .text
* line__14J2DGrafContextFQ29JGeometry8TVec2<f>Q29JGeometry8TVec2<f> */
void J2DGrafContext::line(JGeometry::TVec2<f32> start, JGeometry::TVec2<f32> end) {
GXSetBlendMode((GXBlendMode)mLinePart.mType, (GXBlendFactor)mLinePart.mSrcFactor,
(GXBlendFactor)mLinePart.mDstFactor, GX_LO_SET);
@@ -199,8 +183,6 @@ void J2DGrafContext::line(JGeometry::TVec2<f32> start, JGeometry::TVec2<f32> end
GXSetVtxAttrFmt(GX_VTXFMT0, GX_VA_POS, GX_CLR_RGBA, GX_RGBA4, 0);
}
/* 802E9564-802E95D4 2E3EA4 0070+00 0/0 1/1 0/0 .text
* lineTo__14J2DGrafContextFQ29JGeometry8TVec2<f> */
void J2DGrafContext::lineTo(JGeometry::TVec2<f32> pos) {
this->line(mPrevPos, pos);
mPrevPos = pos;
-4
View File
@@ -4,7 +4,6 @@
#include "JSystem/JSupport/JSUInputStream.h"
#include "string.h"
/* 8030CE18-8030CE7C 307758 0064+00 1/1 3/3 0/0 .text get__13J2DDataManageFPCc */
void* J2DDataManage::get(char const* name) {
for (J2DataManageLink* link = mList; link != NULL; link = link->mNext) {
if (strcmp(link->mName, name) == 0) {
@@ -14,7 +13,6 @@ void* J2DDataManage::get(char const* name) {
return NULL;
}
/* 8030CE7C-8030CF10 3077BC 0094+00 0/0 1/1 0/0 .text get__13J2DDataManageFP14JSUInputStream */
void* J2DDataManage::get(JSUInputStream* inputStream) {
inputStream->skip(1);
u8 nameLen = inputStream->readU8();
@@ -29,7 +27,6 @@ void* J2DDataManage::get(JSUInputStream* inputStream) {
}
}
/* 8030CF10-8030CF44 307850 0034+00 1/1 2/2 0/0 .text getResReference__15J2DResReferenceCFUs */
s8* J2DResReference::getResReference(u16 idx) const {
if (mCount <= idx || idx == 0xFFFF) {
return NULL;
@@ -38,7 +35,6 @@ s8* J2DResReference::getResReference(u16 idx) const {
}
}
/* 8030CF44-8030D098 307884 0154+00 0/0 2/2 0/0 .text getName__15J2DResReferenceCFUs */
char* J2DResReference::getName(u16 idx) const {
static char p_name[257];
-121
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J2DMatBlock
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J2DGraph/J2DMatBlock.h"
@@ -12,7 +7,6 @@
#include "JSystem/JUtility/JUTTexture.h"
#include "dolphin/gx.h"
/* 802EB394-802EB424 2E5CD4 0090+00 0/0 1/1 0/0 .text initialize__13J2DColorBlockFv */
// NONMATCHING - instruction order
void J2DColorBlock::initialize() {
for (int i = 0; i < 2; i++) {
@@ -25,7 +19,6 @@ void J2DColorBlock::initialize() {
mCullMode = GX_CULL_NONE;
}
/* 802EB424-802EB510 2E5D64 00EC+00 0/0 1/1 0/0 .text setGX__13J2DColorBlockFv */
void J2DColorBlock::setGX() {
for (int i = 0; i < 2; i++) {
GXSetChanMatColor(GXChannelID(GX_COLOR0A0 + i), mMatColor[i]);
@@ -39,7 +32,6 @@ void J2DColorBlock::setGX() {
GXSetCullMode((GXCullMode)mCullMode);
}
/* 802EB510-802EB570 2E5E50 0060+00 0/0 1/1 0/0 .text initialize__14J2DTexGenBlockFv */
void J2DTexGenBlock::initialize() {
mTexGenNum = 0;
for (int i = 0; i < 8; i++) {
@@ -50,7 +42,6 @@ void J2DTexGenBlock::initialize() {
}
}
/* 802EB570-802EB620 2E5EB0 00B0+00 0/0 1/1 0/0 .text setGX__14J2DTexGenBlockFv */
void J2DTexGenBlock::setGX() {
GXSetNumTexGens(mTexGenNum);
for (int i = 0; i < mTexGenNum; i++) {
@@ -64,14 +55,12 @@ void J2DTexGenBlock::setGX() {
}
}
/* 802EB620-802EB6A4 2E5F60 0084+00 1/0 1/1 0/0 .text __dt__14J2DTexGenBlockFv */
J2DTexGenBlock::~J2DTexGenBlock() {
for (int i = 0; i < 8; i++) {
delete mTexMtx[i];
}
}
/* 802EB6A4-802EB7E0 2E5FE4 013C+00 0/0 3/3 0/0 .text setTexMtx__14J2DTexGenBlockFUlR9J2DTexMtx */
void J2DTexGenBlock::setTexMtx(u32 param_0, J2DTexMtx& param_1) {
J3D_PANIC(103, param_0 < 8, "Error : range over.");
@@ -86,7 +75,6 @@ void J2DTexGenBlock::setTexMtx(u32 param_0, J2DTexMtx& param_1) {
mTexMtx[param_0]->calc();
}
/* 802EB7E0-802EB87C 2E6120 009C+00 0/0 1/1 0/0 .text getTexMtx__14J2DTexGenBlockFUlR9J2DTexMtx */
void J2DTexGenBlock::getTexMtx(u32 param_0, J2DTexMtx& param_1) {
J3D_PANIC(123, param_0 < 8, "Error : range over.");
@@ -96,24 +84,20 @@ void J2DTexGenBlock::getTexMtx(u32 param_0, J2DTexMtx& param_1) {
}
}
/* 802EB87C-802EB884 2E61BC 0008+00 1/0 0/0 0/0 .text getTexture__11J2DTevBlockFUl */
JUTTexture* J2DTevBlock::getTexture(u32) {
return NULL;
}
/* 802EB884-802EB88C 2E61C4 0008+00 1/0 0/0 0/0 .text getPalette__11J2DTevBlockFUl */
JUTPalette* J2DTevBlock::getPalette(u32) {
return NULL;
}
/* 802EB88C-802EB998 2E61CC 010C+00 0/0 1/1 0/0 .text __ct__12J2DTevBlock1Fv */
J2DTevBlock1::J2DTevBlock1() {
mTexture[0] = NULL;
mUndeleteFlag = 0;
initialize();
}
/* 802EB998-802EBA50 2E62D8 00B8+00 1/0 0/0 0/0 .text __dt__12J2DTevBlock1Fv */
J2DTevBlock1::~J2DTevBlock1() {
if (mUndeleteFlag & 1) {
delete mTexture[0];
@@ -126,7 +110,6 @@ J2DTevBlock1::~J2DTevBlock1() {
}
}
/* 802EBA50-802EBC0C 2E6390 01BC+00 1/0 0/0 0/0 .text initialize__12J2DTevBlock1Fv */
void J2DTevBlock1::initialize() {
mTexNo[0] = -1;
mFontNo = -1;
@@ -148,7 +131,6 @@ void J2DTevBlock1::initialize() {
mFont = NULL;
}
/* 802EBC0C-802EBCC0 2E654C 00B4+00 1/0 0/0 0/0 .text prepareTexture__12J2DTevBlock1FUc */
bool J2DTevBlock1::prepareTexture(u8 param_0) {
bool rv;
if (param_0 == 0) {
@@ -173,7 +155,6 @@ bool J2DTevBlock1::prepareTexture(u8 param_0) {
return rv;
}
/* 802EBCC0-802EBDE4 2E6600 0124+00 1/0 0/0 0/0 .text insertTexture__12J2DTevBlock1FUlPC7ResTIMGP10JUTPalette */
bool J2DTevBlock1::insertTexture(u32 param_0, ResTIMG const* p_timg, JUTPalette* p_tlut) {
if (param_0 != 0 || p_timg == NULL) {
return false;
@@ -205,7 +186,6 @@ bool J2DTevBlock1::insertTexture(u32 param_0, ResTIMG const* p_timg, JUTPalette*
return true;
}
/* 802EBDE4-802EBE8C 2E6724 00A8+00 1/0 0/0 0/0 .text insertTexture__12J2DTevBlock1FUlP10JUTTexture */
bool J2DTevBlock1::insertTexture(u32 param_0, JUTTexture* p_tex) {
if (mTexture[0] != NULL && mTexture[0]->getTexInfo() != NULL) {
return false;
@@ -226,7 +206,6 @@ bool J2DTevBlock1::insertTexture(u32 param_0, JUTTexture* p_tex) {
return true;
}
/* 802EBE8C-802EC01C 2E67CC 0190+00 1/0 0/0 0/0 .text setTexture__12J2DTevBlock1FUlPC7ResTIMG */
bool J2DTevBlock1::setTexture(u32 param_0, ResTIMG const* p_timg) {
if (param_0 != 0) {
return false;
@@ -272,7 +251,6 @@ bool J2DTevBlock1::setTexture(u32 param_0, ResTIMG const* p_timg) {
return true;
}
/* 802EC01C-802EC0A8 2E695C 008C+00 1/0 0/0 0/0 .text setTexture__12J2DTevBlock1FUlP10JUTTexture */
bool J2DTevBlock1::setTexture(u32 param_0, JUTTexture* p_tex) {
if (param_0 != 0) {
return false;
@@ -290,7 +268,6 @@ bool J2DTevBlock1::setTexture(u32 param_0, JUTTexture* p_tex) {
return true;
}
/* 802EC0A8-802EC124 2E69E8 007C+00 1/0 0/0 0/0 .text removeTexture__12J2DTevBlock1FUl */
bool J2DTevBlock1::removeTexture(u32 param_0) {
if (param_0 >= 1) {
return false;
@@ -307,7 +284,6 @@ bool J2DTevBlock1::removeTexture(u32 param_0) {
return true;
}
/* 802EC124-802EC1D8 2E6A64 00B4+00 1/0 0/0 0/0 .text setFont__12J2DTevBlock1FP7ResFONT */
bool J2DTevBlock1::setFont(ResFONT* p_font) {
if (p_font == NULL) {
return false;
@@ -327,7 +303,6 @@ bool J2DTevBlock1::setFont(ResFONT* p_font) {
return true;
}
/* 802EC1D8-802EC258 2E6B18 0080+00 1/0 0/0 0/0 .text setFont__12J2DTevBlock1FP7JUTFont */
bool J2DTevBlock1::setFont(JUTFont* p_font) {
if (p_font == NULL) {
return false;
@@ -342,7 +317,6 @@ bool J2DTevBlock1::setFont(JUTFont* p_font) {
return true;
}
/* 802EC258-802EC318 2E6B98 00C0+00 1/0 0/0 0/0 .text setPalette__12J2DTevBlock1FUlPC7ResTLUT */
bool J2DTevBlock1::setPalette(u32 param_0, ResTLUT const* p_tlut) {
if (param_0 != 0) {
return false;
@@ -370,12 +344,10 @@ bool J2DTevBlock1::setPalette(u32 param_0, ResTLUT const* p_tlut) {
return true;
}
/* 802EC318-802EC328 2E6C58 0010+00 1/0 0/0 0/0 .text shiftDeleteFlag__12J2DTevBlock1FUcb */
void J2DTevBlock1::shiftDeleteFlag(u8, bool) {
mUndeleteFlag &= 0x80;
}
/* 802EC328-802EC570 2E6C68 0248+00 1/0 0/0 0/0 .text setGX__12J2DTevBlock1Fv */
void J2DTevBlock1::setGX() {
loadTexture(GX_TEXMAP0, 0);
GXSetTevOrder(GX_TEVSTAGE0, (GXTexCoordID)mTevOrder[0].getTexCoord(), (GXTexMapID)mTevOrder[0].getTexMap(), (GXChannelID)mTevOrder[0].getColor());
@@ -414,14 +386,12 @@ void J2DTevBlock1::setGX() {
mIndTevStage->load(0);
}
/* 802EC570-802EC5B8 2E6EB0 0048+00 1/0 0/0 0/0 .text loadTexture__12J2DTevBlock1F11_GXTexMapIDUl */
void J2DTevBlock1::loadTexture(GXTexMapID texmapID, u32 texIndex) {
if (texIndex == 0 && mTexture[texIndex] != NULL && mTexture[texIndex]->getTexInfo() != NULL) {
mTexture[texIndex]->load(texmapID);
}
}
/* 802EC5B8-802EC6C8 2E6EF8 0110+00 0/0 1/1 0/0 .text __ct__12J2DTevBlock2Fv */
J2DTevBlock2::J2DTevBlock2() {
mTexture[0] = NULL;
mTexture[1] = NULL;
@@ -429,7 +399,6 @@ J2DTevBlock2::J2DTevBlock2() {
initialize();
}
/* 802EC6C8-802EC7A0 2E7008 00D8+00 1/0 0/0 0/0 .text __dt__12J2DTevBlock2Fv */
J2DTevBlock2::~J2DTevBlock2() {
if (mUndeleteFlag & 1) {
delete mTexture[0];
@@ -447,7 +416,6 @@ J2DTevBlock2::~J2DTevBlock2() {
}
}
/* 802EC7A0-802ECA18 2E70E0 0278+00 1/0 0/0 0/0 .text initialize__12J2DTevBlock2Fv */
void J2DTevBlock2::initialize() {
mTexNo[0] = 0xffff;
mTexNo[1] = 0xffff;
@@ -477,8 +445,6 @@ void J2DTevBlock2::initialize() {
mFont = NULL;
}
/* 802ECA18-802ECAE8 2E7358 00D0+00 1/0 0/0 0/0 .text prepareTexture__12J2DTevBlock2FUc
*/
bool J2DTevBlock2::prepareTexture(u8 param_0) {
for (u8 i = 0; i < param_0; i++) {
if (i >= 2) {
@@ -498,7 +464,6 @@ bool J2DTevBlock2::prepareTexture(u8 param_0) {
return true;
}
/* 802ECAE8-802ECDE8 2E7428 0300+00 1/0 0/0 0/0 .text insertTexture__12J2DTevBlock2FUlPC7ResTIMGP10JUTPalette */
bool J2DTevBlock2::insertTexture(u32 param_0, ResTIMG const* p_timg, JUTPalette* p_tlut) {
if (param_0 >= 2 || p_timg == NULL) {
return false;
@@ -586,7 +551,6 @@ bool J2DTevBlock2::insertTexture(u32 param_0, ResTIMG const* p_timg, JUTPalette*
return true;
}
/* 802ECDE8-802ECF48 2E7728 0160+00 1/0 0/0 0/0 .text insertTexture__12J2DTevBlock2FUlP10JUTTexture */
bool J2DTevBlock2::insertTexture(u32 param_0, JUTTexture* p_tex) {
if (param_0 >= 2 || p_tex == NULL) {
return false;
@@ -629,7 +593,6 @@ bool J2DTevBlock2::insertTexture(u32 param_0, JUTTexture* p_tex) {
return true;
}
/* 802ECF48-802ED16C 2E7888 0224+00 1/0 0/0 0/0 .text setTexture__12J2DTevBlock2FUlPC7ResTIMG */
bool J2DTevBlock2::setTexture(u32 param_0, ResTIMG const* p_timg) {
if (param_0 >= 2) {
return false;
@@ -691,7 +654,6 @@ bool J2DTevBlock2::setTexture(u32 param_0, ResTIMG const* p_timg) {
return true;
}
/* 802ED16C-802ED21C 2E7AAC 00B0+00 1/0 0/0 0/0 .text setTexture__12J2DTevBlock2FUlP10JUTTexture */
bool J2DTevBlock2::setTexture(u32 param_0, JUTTexture* p_tex) {
if (param_0 >= 2) {
return false;
@@ -709,7 +671,6 @@ bool J2DTevBlock2::setTexture(u32 param_0, JUTTexture* p_tex) {
return true;
}
/* 802ED21C-802ED2F0 2E7B5C 00D4+00 1/0 0/0 0/0 .text removeTexture__12J2DTevBlock2FUl */
bool J2DTevBlock2::removeTexture(u32 param_0) {
if (param_0 >= 2) {
return false;
@@ -733,7 +694,6 @@ bool J2DTevBlock2::removeTexture(u32 param_0) {
return true;
}
/* 802ED2F0-802ED3A4 2E7C30 00B4+00 1/0 0/0 0/0 .text setFont__12J2DTevBlock2FP7ResFONT */
bool J2DTevBlock2::setFont(ResFONT* p_font) {
if (p_font == NULL) {
return false;
@@ -753,7 +713,6 @@ bool J2DTevBlock2::setFont(ResFONT* p_font) {
return true;
}
/* 802ED3A4-802ED424 2E7CE4 0080+00 1/0 0/0 0/0 .text setFont__12J2DTevBlock2FP7JUTFont */
bool J2DTevBlock2::setFont(JUTFont* p_font) {
if (p_font == NULL) {
return false;
@@ -768,7 +727,6 @@ bool J2DTevBlock2::setFont(JUTFont* p_font) {
return true;
}
/* 802ED424-802ED4FC 2E7D64 00D8+00 1/0 0/0 0/0 .text setPalette__12J2DTevBlock2FUlPC7ResTLUT */
bool J2DTevBlock2::setPalette(u32 param_0, ResTLUT const* p_tlut) {
if (param_0 >= 2) {
return false;
@@ -796,7 +754,6 @@ bool J2DTevBlock2::setPalette(u32 param_0, ResTLUT const* p_tlut) {
return true;
}
/* 802ED4FC-802ED584 2E7E3C 0088+00 1/0 0/0 0/0 .text shiftDeleteFlag__12J2DTevBlock2FUcb */
void J2DTevBlock2::shiftDeleteFlag(u8 param_0, bool param_1) {
u8 tmpFlags = mUndeleteFlag & 0x80;
mUndeleteFlag = mUndeleteFlag & 0x7F;
@@ -810,7 +767,6 @@ void J2DTevBlock2::shiftDeleteFlag(u8 param_0, bool param_1) {
mUndeleteFlag = (mUndeleteFlag | tmpFlags) & 0xFF;
}
/* 802ED584-802ED874 2E7EC4 02F0+00 1/0 0/0 0/0 .text setGX__12J2DTevBlock2Fv */
void J2DTevBlock2::setGX() {
for (int i = 0; i < 2; i++) {
loadTexture(GXTexMapID(i), i);
@@ -864,14 +820,12 @@ void J2DTevBlock2::setGX() {
}
}
/* 802ED874-802ED8BC 2E81B4 0048+00 1/0 0/0 0/0 .text loadTexture__12J2DTevBlock2F11_GXTexMapIDUl */
void J2DTevBlock2::loadTexture(GXTexMapID texmapID, u32 texIndex) {
if (texIndex < 2 && mTexture[texIndex] != NULL && mTexture[texIndex]->getTexInfo() != NULL) {
mTexture[texIndex]->load(texmapID);
}
}
/* 802ED8BC-802ED9E4 2E81FC 0128+00 0/0 1/1 0/0 .text __ct__12J2DTevBlock4Fv */
J2DTevBlock4::J2DTevBlock4() {
for (int i = 0; i < 4; i++) {
mTexture[i] = NULL;
@@ -881,7 +835,6 @@ J2DTevBlock4::J2DTevBlock4() {
initialize();
}
/* 802ED9E4-802EDAC4 2E8324 00E0+00 1/0 0/0 0/0 .text __dt__12J2DTevBlock4Fv */
J2DTevBlock4::~J2DTevBlock4() {
for (int i = 0; i < 4; i++) {
if (mUndeleteFlag & (1 << i)) {
@@ -895,7 +848,6 @@ J2DTevBlock4::~J2DTevBlock4() {
}
}
/* 802EDAC4-802EDD34 2E8404 0270+00 1/0 0/0 0/0 .text initialize__12J2DTevBlock4Fv */
// NONMATCHING - inlines
void J2DTevBlock4::initialize() {
for (int i = 0; i < 4; i++) {
@@ -931,8 +883,6 @@ void J2DTevBlock4::initialize() {
mFont = NULL;
}
/* 802EDD34-802EDE04 2E8674 00D0+00 1/0 0/0 0/0 .text prepareTexture__12J2DTevBlock4FUc
*/
bool J2DTevBlock4::prepareTexture(u8 param_0) {
for (u8 i = 0; i < param_0; i++) {
if (i >= 4) {
@@ -952,8 +902,6 @@ bool J2DTevBlock4::prepareTexture(u8 param_0) {
return true;
}
/* 802EDE04-802EE1D4 2E8744 03D0+00 1/0 0/0 0/0 .text
* insertTexture__12J2DTevBlock4FUlPC7ResTIMGP10JUTPalette */
bool J2DTevBlock4::insertTexture(u32 param_0, ResTIMG const* p_timg, JUTPalette* p_tlut) {
if (param_0 >= 4 || !p_timg) {
return false;
@@ -1044,8 +992,6 @@ bool J2DTevBlock4::insertTexture(u32 param_0, ResTIMG const* p_timg, JUTPalette*
return true;
}
/* 802EE1D4-802EE364 2E8B14 0190+00 1/0 0/0 0/0 .text
* insertTexture__12J2DTevBlock4FUlP10JUTTexture */
bool J2DTevBlock4::insertTexture(u32 param_0, JUTTexture* p_tex) {
if (param_0 >= 4 || p_tex == NULL) {
return false;
@@ -1088,7 +1034,6 @@ bool J2DTevBlock4::insertTexture(u32 param_0, JUTTexture* p_tex) {
return true;
}
/* 802EE364-802EE5F0 2E8CA4 028C+00 1/0 0/0 0/0 .text setTexture__12J2DTevBlock4FUlPC7ResTIMG */
bool J2DTevBlock4::setTexture(u32 param_0, ResTIMG const* p_timg) {
if (param_0 >= 4) {
return false;
@@ -1160,8 +1105,6 @@ bool J2DTevBlock4::setTexture(u32 param_0, ResTIMG const* p_timg) {
return true;
}
/* 802EE5F0-802EE6A0 2E8F30 00B0+00 1/0 0/0 0/0 .text setTexture__12J2DTevBlock4FUlP10JUTTexture
*/
bool J2DTevBlock4::setTexture(u32 param_0, JUTTexture* p_tex) {
if (param_0 >= 4) {
return false;
@@ -1179,7 +1122,6 @@ bool J2DTevBlock4::setTexture(u32 param_0, JUTTexture* p_tex) {
return true;
}
/* 802EE6A0-802EE798 2E8FE0 00F8+00 1/0 0/0 0/0 .text removeTexture__12J2DTevBlock4FUl */
bool J2DTevBlock4::removeTexture(u32 param_0) {
if (param_0 >= 4) {
return false;
@@ -1203,8 +1145,6 @@ bool J2DTevBlock4::removeTexture(u32 param_0) {
return true;
}
/* 802EE798-802EE84C 2E90D8 00B4+00 1/0 0/0 0/0 .text setFont__12J2DTevBlock4FP7ResFONT
*/
bool J2DTevBlock4::setFont(ResFONT* p_font) {
if (p_font == NULL) {
return false;
@@ -1224,8 +1164,6 @@ bool J2DTevBlock4::setFont(ResFONT* p_font) {
return true;
}
/* 802EE84C-802EE8CC 2E918C 0080+00 1/0 0/0 0/0 .text setFont__12J2DTevBlock4FP7JUTFont
*/
bool J2DTevBlock4::setFont(JUTFont* p_font) {
if (p_font == NULL) {
return false;
@@ -1240,7 +1178,6 @@ bool J2DTevBlock4::setFont(JUTFont* p_font) {
return true;
}
/* 802EE8CC-802EE9A4 2E920C 00D8+00 1/0 0/0 0/0 .text setPalette__12J2DTevBlock4FUlPC7ResTLUT */
bool J2DTevBlock4::setPalette(u32 param_0, ResTLUT const* p_tlut) {
if (param_0 >= 4) {
return false;
@@ -1268,8 +1205,6 @@ bool J2DTevBlock4::setPalette(u32 param_0, ResTLUT const* p_tlut) {
return true;
}
/* 802EE9A4-802EEA2C 2E92E4 0088+00 1/0 0/0 0/0 .text shiftDeleteFlag__12J2DTevBlock4FUcb
*/
void J2DTevBlock4::shiftDeleteFlag(u8 param_0, bool param_1) {
u8 tmpFlags = mUndeleteFlag & 0x80;
mUndeleteFlag = mUndeleteFlag & 0x7F;
@@ -1283,7 +1218,6 @@ void J2DTevBlock4::shiftDeleteFlag(u8 param_0, bool param_1) {
mUndeleteFlag |= tmpFlags;
}
/* 802EEA2C-802EED1C 2E936C 02F0+00 1/0 0/0 0/0 .text setGX__12J2DTevBlock4Fv */
void J2DTevBlock4::setGX() {
for (int i = 0; i < 4; i++) {
loadTexture(GXTexMapID(i), i);
@@ -1330,15 +1264,12 @@ void J2DTevBlock4::setGX() {
}
}
/* 802EED1C-802EED64 2E965C 0048+00 1/0 0/0 0/0 .text loadTexture__12J2DTevBlock4F11_GXTexMapIDUl
*/
void J2DTevBlock4::loadTexture(GXTexMapID texmapID, u32 texIndex) {
if (texIndex < 4 && mTexture[texIndex] != NULL && mTexture[texIndex]->getTexInfo() != NULL) {
mTexture[texIndex]->load(texmapID);
}
}
/* 802EED64-802EEE8C 2E96A4 0128+00 0/0 1/1 0/0 .text __ct__12J2DTevBlock8Fv */
J2DTevBlock8::J2DTevBlock8() {
for (int i = 0; i < 8; i++) {
mTexture[i] = NULL;
@@ -1348,7 +1279,6 @@ J2DTevBlock8::J2DTevBlock8() {
initialize();
}
/* 802EEE8C-802EEF6C 2E97CC 00E0+00 1/0 0/0 0/0 .text __dt__12J2DTevBlock8Fv */
J2DTevBlock8::~J2DTevBlock8() {
for (int i = 0; i < 8; i++) {
if (mUndeleteFlag & (1 << i)) {
@@ -1362,7 +1292,6 @@ J2DTevBlock8::~J2DTevBlock8() {
}
}
/* 802EEF6C-802EF1E0 2E98AC 0274+00 1/0 0/0 0/0 .text initialize__12J2DTevBlock8Fv */
// NONMATCHING - inlines
void J2DTevBlock8::initialize() {
for (int i = 0; i < 8; i++) {
@@ -1399,8 +1328,6 @@ void J2DTevBlock8::initialize() {
mFontUndeleteFlag = 0;
}
/* 802EF1E0-802EF2B0 2E9B20 00D0+00 1/0 0/0 0/0 .text prepareTexture__12J2DTevBlock8FUc
*/
bool J2DTevBlock8::prepareTexture(u8 param_0) {
for (u8 i = 0; i < param_0; i++) {
if (i >= 8) {
@@ -1420,8 +1347,6 @@ bool J2DTevBlock8::prepareTexture(u8 param_0) {
return true;
}
/* 802EF2B0-802EF67C 2E9BF0 03CC+00 1/0 0/0 0/0 .text
* insertTexture__12J2DTevBlock8FUlPC7ResTIMGP10JUTPalette */
bool J2DTevBlock8::insertTexture(u32 param_0, ResTIMG const* p_timg, JUTPalette* p_tlut) {
if (param_0 >= 8 || !p_timg) {
return false;
@@ -1512,8 +1437,6 @@ bool J2DTevBlock8::insertTexture(u32 param_0, ResTIMG const* p_timg, JUTPalette*
return true;
}
/* 802EF67C-802EF80C 2E9FBC 0190+00 1/0 0/0 0/0 .text
* insertTexture__12J2DTevBlock8FUlP10JUTTexture */
bool J2DTevBlock8::insertTexture(u32 param_0, JUTTexture* p_tex) {
if (param_0 >= 8 || p_tex == NULL) {
return false;
@@ -1556,7 +1479,6 @@ bool J2DTevBlock8::insertTexture(u32 param_0, JUTTexture* p_tex) {
return true;
}
/* 802EF80C-802EFA98 2EA14C 028C+00 1/0 0/0 0/0 .text setTexture__12J2DTevBlock8FUlPC7ResTIMG */
bool J2DTevBlock8::setTexture(u32 param_0, ResTIMG const* p_timg) {
if (param_0 >= 8) {
return false;
@@ -1628,8 +1550,6 @@ bool J2DTevBlock8::setTexture(u32 param_0, ResTIMG const* p_timg) {
return true;
}
/* 802EFA98-802EFB48 2EA3D8 00B0+00 1/0 0/0 0/0 .text setTexture__12J2DTevBlock8FUlP10JUTTexture
*/
bool J2DTevBlock8::setTexture(u32 param_0, JUTTexture* p_tex) {
if (param_0 >= 8) {
return false;
@@ -1647,7 +1567,6 @@ bool J2DTevBlock8::setTexture(u32 param_0, JUTTexture* p_tex) {
return true;
}
/* 802EFB48-802EFC40 2EA488 00F8+00 1/0 0/0 0/0 .text removeTexture__12J2DTevBlock8FUl */
bool J2DTevBlock8::removeTexture(u32 param_0) {
if (param_0 >= 8) {
return false;
@@ -1671,8 +1590,6 @@ bool J2DTevBlock8::removeTexture(u32 param_0) {
return true;
}
/* 802EFC40-802EFCEC 2EA580 00AC+00 1/0 0/0 0/0 .text setFont__12J2DTevBlock8FP7ResFONT
*/
bool J2DTevBlock8::setFont(ResFONT* p_font) {
if (p_font == NULL) {
return false;
@@ -1692,8 +1609,6 @@ bool J2DTevBlock8::setFont(ResFONT* p_font) {
return true;
}
/* 802EFCEC-802EFD68 2EA62C 007C+00 1/0 0/0 0/0 .text setFont__12J2DTevBlock8FP7JUTFont
*/
bool J2DTevBlock8::setFont(JUTFont* p_font) {
if (p_font == NULL) {
return false;
@@ -1708,7 +1623,6 @@ bool J2DTevBlock8::setFont(JUTFont* p_font) {
return true;
}
/* 802EFD68-802EFE40 2EA6A8 00D8+00 1/0 0/0 0/0 .text setPalette__12J2DTevBlock8FUlPC7ResTLUT */
bool J2DTevBlock8::setPalette(u32 param_0, ResTLUT const* p_tlut) {
if (param_0 >= 8) {
return false;
@@ -1736,8 +1650,6 @@ bool J2DTevBlock8::setPalette(u32 param_0, ResTLUT const* p_tlut) {
return true;
}
/* 802EFE40-802EFEAC 2EA780 006C+00 1/0 0/0 0/0 .text shiftDeleteFlag__12J2DTevBlock8FUcb
*/
void J2DTevBlock8::shiftDeleteFlag(u8 param_0, bool param_1) {
if (param_1) {
mUndeleteFlag = (mUndeleteFlag & ((1 << param_0) - 1)) | ((mUndeleteFlag & ~((1 << param_0) - 1)) * 2);
@@ -1746,7 +1658,6 @@ void J2DTevBlock8::shiftDeleteFlag(u8 param_0, bool param_1) {
}
}
/* 802EFEAC-802F019C 2EA7EC 02F0+00 1/0 0/0 0/0 .text setGX__12J2DTevBlock8Fv */
void J2DTevBlock8::setGX() {
for (int i = 0; i < 8; i++) {
loadTexture(GXTexMapID(i), i);
@@ -1793,15 +1704,12 @@ void J2DTevBlock8::setGX() {
}
}
/* 802F019C-802F01E4 2EAADC 0048+00 1/0 0/0 0/0 .text loadTexture__12J2DTevBlock8F11_GXTexMapIDUl
*/
void J2DTevBlock8::loadTexture(GXTexMapID texmapID, u32 texIndex) {
if (texIndex < 8 && mTexture[texIndex] != NULL && mTexture[texIndex]->getTexInfo() != NULL) {
mTexture[texIndex]->load(texmapID);
}
}
/* 802F01E4-802F030C 2EAB24 0128+00 0/0 1/1 0/0 .text __ct__13J2DTevBlock16Fv */
J2DTevBlock16::J2DTevBlock16() {
for (int i = 0; i < 8; i++) {
mTexture[i] = NULL;
@@ -1811,7 +1719,6 @@ J2DTevBlock16::J2DTevBlock16() {
initialize();
}
/* 802F030C-802F03EC 2EAC4C 00E0+00 1/0 0/0 0/0 .text __dt__13J2DTevBlock16Fv */
J2DTevBlock16::~J2DTevBlock16() {
for (int i = 0; i < 8; i++) {
if (mUndeleteFlag & (1 << i)) {
@@ -1825,7 +1732,6 @@ J2DTevBlock16::~J2DTevBlock16() {
}
}
/* 802F03EC-802F0660 2EAD2C 0274+00 1/0 0/0 0/0 .text initialize__13J2DTevBlock16Fv */
// NONMATCHING - inlines
void J2DTevBlock16::initialize() {
for (int i = 0; i < 8; i++) {
@@ -1862,8 +1768,6 @@ void J2DTevBlock16::initialize() {
mFontUndeleteFlag = 0;
}
/* 802F0660-802F0730 2EAFA0 00D0+00 1/0 0/0 0/0 .text prepareTexture__13J2DTevBlock16FUc
*/
bool J2DTevBlock16::prepareTexture(u8 param_0) {
for (u8 i = 0; i < param_0; i++) {
if (i >= 8) {
@@ -1883,8 +1787,6 @@ bool J2DTevBlock16::prepareTexture(u8 param_0) {
return true;
}
/* 802F0730-802F0AFC 2EB070 03CC+00 1/0 0/0 0/0 .text
* insertTexture__13J2DTevBlock16FUlPC7ResTIMGP10JUTPalette */
bool J2DTevBlock16::insertTexture(u32 param_0, ResTIMG const* p_timg, JUTPalette* p_tlut) {
if (param_0 >= 8 || !p_timg) {
return false;
@@ -1975,8 +1877,6 @@ bool J2DTevBlock16::insertTexture(u32 param_0, ResTIMG const* p_timg, JUTPalette
return true;
}
/* 802F0AFC-802F0C8C 2EB43C 0190+00 1/0 0/0 0/0 .text
* insertTexture__13J2DTevBlock16FUlP10JUTTexture */
bool J2DTevBlock16::insertTexture(u32 param_0, JUTTexture* p_tex) {
if (param_0 >= 8 || p_tex == NULL) {
return false;
@@ -2019,7 +1919,6 @@ bool J2DTevBlock16::insertTexture(u32 param_0, JUTTexture* p_tex) {
return true;
}
/* 802F0C8C-802F0F18 2EB5CC 028C+00 1/0 0/0 0/0 .text setTexture__13J2DTevBlock16FUlPC7ResTIMG */
bool J2DTevBlock16::setTexture(u32 param_0, ResTIMG const* p_timg) {
if (param_0 >= 8) {
return false;
@@ -2091,8 +1990,6 @@ bool J2DTevBlock16::setTexture(u32 param_0, ResTIMG const* p_timg) {
return true;
}
/* 802F0F18-802F0FC8 2EB858 00B0+00 1/0 0/0 0/0 .text setTexture__13J2DTevBlock16FUlP10JUTTexture
*/
bool J2DTevBlock16::setTexture(u32 param_0, JUTTexture* p_tex) {
if (param_0 >= 8) {
return false;
@@ -2110,8 +2007,6 @@ bool J2DTevBlock16::setTexture(u32 param_0, JUTTexture* p_tex) {
return true;
}
/* 802F0FC8-802F10C0 2EB908 00F8+00 1/0 0/0 0/0 .text removeTexture__13J2DTevBlock16FUl
*/
bool J2DTevBlock16::removeTexture(u32 param_0) {
if (param_0 >= 8) {
return false;
@@ -2135,8 +2030,6 @@ bool J2DTevBlock16::removeTexture(u32 param_0) {
return true;
}
/* 802F10C0-802F116C 2EBA00 00AC+00 1/0 0/0 0/0 .text setFont__13J2DTevBlock16FP7ResFONT
*/
bool J2DTevBlock16::setFont(ResFONT* p_font) {
if (p_font == NULL) {
return false;
@@ -2156,8 +2049,6 @@ bool J2DTevBlock16::setFont(ResFONT* p_font) {
return true;
}
/* 802F116C-802F11E8 2EBAAC 007C+00 1/0 0/0 0/0 .text setFont__13J2DTevBlock16FP7JUTFont
*/
bool J2DTevBlock16::setFont(JUTFont* p_font) {
if (p_font == NULL) {
return false;
@@ -2172,7 +2063,6 @@ bool J2DTevBlock16::setFont(JUTFont* p_font) {
return true;
}
/* 802F11E8-802F12C0 2EBB28 00D8+00 1/0 0/0 0/0 .text setPalette__13J2DTevBlock16FUlPC7ResTLUT */
bool J2DTevBlock16::setPalette(u32 param_0, ResTLUT const* p_tlut) {
if (param_0 >= 8) {
return false;
@@ -2200,7 +2090,6 @@ bool J2DTevBlock16::setPalette(u32 param_0, ResTLUT const* p_tlut) {
return true;
}
/* 802F12C0-802F132C 2EBC00 006C+00 1/0 0/0 0/0 .text shiftDeleteFlag__13J2DTevBlock16FUcb */
void J2DTevBlock16::shiftDeleteFlag(u8 param_0, bool param_1) {
if (param_1) {
mUndeleteFlag = (mUndeleteFlag & ((1 << param_0) - 1)) | ((mUndeleteFlag & ~((1 << param_0) - 1)) * 2);
@@ -2209,7 +2098,6 @@ void J2DTevBlock16::shiftDeleteFlag(u8 param_0, bool param_1) {
}
}
/* 802F132C-802F161C 2EBC6C 02F0+00 1/0 0/0 0/0 .text setGX__13J2DTevBlock16Fv */
void J2DTevBlock16::setGX() {
for (int i = 0; i < 8; i++) {
loadTexture(GXTexMapID(i), i);
@@ -2256,15 +2144,12 @@ void J2DTevBlock16::setGX() {
}
}
/* 802F161C-802F1664 2EBF5C 0048+00 1/0 0/0 0/0 .text loadTexture__13J2DTevBlock16F11_GXTexMapIDUl
*/
void J2DTevBlock16::loadTexture(GXTexMapID texmapID, u32 texIndex) {
if (texIndex < 8 && mTexture[texIndex] != NULL && mTexture[texIndex]->getTexInfo() != NULL) {
mTexture[texIndex]->load(texmapID);
}
}
/* 802F1664-802F1730 2EBFA4 00CC+00 1/0 0/0 0/0 .text initialize__15J2DIndBlockFullFv */
void J2DIndBlockFull::initialize() {
mIndTexStageNum = 0;
for (int i = 0; i < 4; i++) {
@@ -2278,7 +2163,6 @@ void J2DIndBlockFull::initialize() {
}
}
/* 802F1730-802F17FC 2EC070 00CC+00 1/0 0/0 0/0 .text setGX__15J2DIndBlockFullFv */
void J2DIndBlockFull::setGX() {
GXSetNumIndStages(mIndTexStageNum);
for (u8 i = 0; i < mIndTexStageNum; i++) {
@@ -2292,28 +2176,23 @@ void J2DIndBlockFull::setGX() {
}
}
/* 802F17FC-802F1840 2EC13C 0044+00 0/0 1/1 0/0 .text initialize__10J2DPEBlockFv */
void J2DPEBlock::initialize() {
mAlphaComp = J2DAlphaComp();
mBlend.setBlendInfo(j2dDefaultBlendInfo);
mDither = j2dDefaultPEBlockDither;
}
/* 802F1840-802F18A0 2EC180 0060+00 0/0 1/1 0/0 .text setGX__10J2DPEBlockFv */
void J2DPEBlock::setGX() {
GXSetAlphaCompare(GXCompare(mAlphaComp.getComp0()), mAlphaComp.getRef0(), GXAlphaOp(mAlphaComp.getOp()), GXCompare(mAlphaComp.getComp1()), mAlphaComp.getRef1());
GXSetBlendMode(GXBlendMode(mBlend.getType()), GXBlendFactor(mBlend.getSrcFactor()), GXBlendFactor(mBlend.getDstFactor()), GXLogicOp(mBlend.getOp()));
GXSetDither(mDither);
}
/* 802F1940-802F19A8 2EC280 0068+00 5/5 1/1 0/0 .text __ct__11J2DTevStageFv */
J2DTevStage::J2DTevStage() {
setTevStageInfo(j2dDefaultTevStageInfo);
setTevSwapModeInfo(j2dDefaultTevSwapMode);
}
/* 802F19A8-802F1B70 2EC2E8 01C8+00 1/1 1/1 0/0 .text
* setTevStageInfo__11J2DTevStageFRC15J2DTevStageInfo */
void J2DTevStage::setTevStageInfo(J2DTevStageInfo const& info) {
setColorABCD(info.mColorA, info.mColorB, info.mColorC, info.mColorD);
setTevColorOp(info.mCOp, info.mCBias, info.mCScale, info.mCClamp, info.mCReg);
-21
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J2DMaterial
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J2DGraph/J2DMaterial.h"
@@ -11,7 +6,6 @@
#include "JSystem/JUtility/JUTPalette.h"
#include "JSystem/JUtility/JUTTexture.h"
/* 802EA1AC-802EA2CC 2E4AEC 0120+00 0/0 1/1 0/0 .text __ct__11J2DMaterialFv */
J2DMaterial::J2DMaterial() {
field_0x4 = 0;
mIndex = -1;
@@ -28,7 +22,6 @@ J2DMaterial::~J2DMaterial() {
delete mAnmPointer;
}
/* 802EA38C-802EA410 2E4CCC 0084+00 0/0 8/8 0/0 .text setGX__11J2DMaterialFv */
void J2DMaterial::setGX() {
if (mVisible) {
getColorBlock()->setGX();
@@ -46,7 +39,6 @@ void J2DMaterial::setGX() {
}
}
/* 802EA410-802EA5C4 2E4D50 01B4+00 0/0 1/1 0/0 .text createTevBlock__11J2DMaterialFib */
J2DTevBlock* J2DMaterial::createTevBlock(int block_type, bool noAlign) {
J2DTevBlock* block;
@@ -79,7 +71,6 @@ J2DTevBlock* J2DMaterial::createTevBlock(int block_type, bool noAlign) {
return block;
}
/* 802EA5C4-802EA79C 2E4F04 01D8+00 0/0 1/1 0/0 .text createIndBlock__11J2DMaterialFib */
J2DIndBlock* J2DMaterial::createIndBlock(int block_type, bool noAlign) {
J2DIndBlock* block;
@@ -100,8 +91,6 @@ J2DIndBlock* J2DMaterial::createIndBlock(int block_type, bool noAlign) {
return block;
}
/* 802EA79C-802EA84C 2E50DC 00B0+00 1/1 0/0 0/0 .text
* __ct__Q211J2DMaterial21J2DMaterialAnmPointerFv */
J2DMaterial::J2DMaterialAnmPointer::J2DMaterialAnmPointer() {
mColorAnm = NULL;
mColorIds = -1;
@@ -126,15 +115,12 @@ J2DMaterial::J2DMaterialAnmPointer::J2DMaterialAnmPointer() {
}
}
/* 802EA84C-802EA89C 2E518C 0050+00 4/4 0/0 0/0 .text makeAnmPointer__11J2DMaterialFv */
void J2DMaterial::makeAnmPointer() {
if (mAnmPointer == NULL) {
mAnmPointer = new J2DMaterialAnmPointer();
}
}
/* 802EA89C-802EA94C 2E51DC 00B0+00 0/0 4/4 0/0 .text setAnimation__11J2DMaterialFP11J2DAnmColor
*/
void J2DMaterial::setAnimation(J2DAnmColor* anm) {
if (anm != NULL || mAnmPointer != NULL) {
makeAnmPointer();
@@ -157,8 +143,6 @@ void J2DMaterial::setAnimation(J2DAnmColor* anm) {
}
}
/* 802EA94C-802EAA2C 2E528C 00E0+00 0/0 4/4 0/0 .text
* setAnimation__11J2DMaterialFP19J2DAnmTextureSRTKey */
void J2DMaterial::setAnimation(J2DAnmTextureSRTKey* anm) {
if (anm != NULL || mAnmPointer != NULL) {
makeAnmPointer();
@@ -184,8 +168,6 @@ void J2DMaterial::setAnimation(J2DAnmTextureSRTKey* anm) {
}
}
/* 802EAA2C-802EAB0C 2E536C 00E0+00 0/0 4/4 0/0 .text
* setAnimation__11J2DMaterialFP16J2DAnmTexPattern */
void J2DMaterial::setAnimation(J2DAnmTexPattern* anm) {
if (anm != NULL || mAnmPointer != NULL) {
makeAnmPointer();
@@ -211,8 +193,6 @@ void J2DMaterial::setAnimation(J2DAnmTexPattern* anm) {
}
}
/* 802EAB0C-802EAC78 2E544C 016C+00 0/0 4/4 0/0 .text
* setAnimation__11J2DMaterialFP15J2DAnmTevRegKey */
void J2DMaterial::setAnimation(J2DAnmTevRegKey* anm) {
if (anm != NULL || mAnmPointer != NULL) {
makeAnmPointer();
@@ -256,7 +236,6 @@ void J2DMaterial::setAnimation(J2DAnmTevRegKey* anm) {
}
}
/* 802EAC78-802EB0F4 2E55B8 047C+00 0/0 1/1 0/0 .text animation__11J2DMaterialFv */
void J2DMaterial::animation() {
if (!mAnmPointer) {
return;
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J2DMaterialFactory
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J2DGraph/J2DMaterialFactory.h"
@@ -13,8 +8,6 @@
#include "string.h"
#include "dolphin/types.h"
/* 802F2AD0-802F2C94 2ED410 01C4+00 0/0 1/1 0/0 .text
* __ct__18J2DMaterialFactoryFRC16J2DMaterialBlock */
J2DMaterialFactory::J2DMaterialFactory(J2DMaterialBlock const& param_0) {
field_0x0 = param_0.field_0x8;
field_0x4 = JSUConvertOffsetToPtr<J2DMaterialInitData>(&param_0, (void*)param_0.field_0xc);
@@ -46,7 +39,6 @@ J2DMaterialFactory::J2DMaterialFactory(J2DMaterialBlock const& param_0) {
field_0x58 = JSUConvertOffsetToPtr<u8>(&param_0, (void*)param_0.field_0x64);
}
/* 802F2C94-802F2D1C 2ED5D4 0088+00 1/1 0/0 0/0 .text countStages__18J2DMaterialFactoryCFi */
u32 J2DMaterialFactory::countStages(int param_0) const {
J2DMaterialInitData* iVar5 = &field_0x4[field_0x8[param_0]];
u32 uVar4 = 0;
@@ -193,7 +185,6 @@ J2DMaterial* J2DMaterialFactory::create(J2DMaterial* param_0, int index, u32 par
return param_0;
}
/* 802F362C-802F36CC 2EDF6C 00A0+00 1/1 0/0 0/0 .text newMatColor__18J2DMaterialFactoryCFii */
JUtility::TColor J2DMaterialFactory::newMatColor(int param_0, int param_1) const {
GXColor color = {0xff,0xff,0xff,0xff};
JUtility::TColor local_20 = GXColor(color);
@@ -204,7 +195,6 @@ JUtility::TColor J2DMaterialFactory::newMatColor(int param_0, int param_1) const
return local_20;
}
/* 802F36CC-802F3704 2EE00C 0038+00 1/1 0/0 0/0 .text newColorChanNum__18J2DMaterialFactoryCFi */
u8 J2DMaterialFactory::newColorChanNum(int param_0) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0x2 != 0xff) {
@@ -213,7 +203,6 @@ u8 J2DMaterialFactory::newColorChanNum(int param_0) const {
return 0;
}
/* 802F3704-802F3758 2EE044 0054+00 1/1 0/0 0/0 .text newColorChan__18J2DMaterialFactoryCFii */
J2DColorChan J2DMaterialFactory::newColorChan(int param_0, int param_1) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0xc[param_1] != 0xffff) {
@@ -222,7 +211,6 @@ J2DColorChan J2DMaterialFactory::newColorChan(int param_0, int param_1) const {
return J2DColorChan();
}
/* 802F3758-802F3790 2EE098 0038+00 1/1 0/0 0/0 .text newTexGenNum__18J2DMaterialFactoryCFi */
u32 J2DMaterialFactory::newTexGenNum(int param_0) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0x3 != 0xff) {
@@ -231,7 +219,6 @@ u32 J2DMaterialFactory::newTexGenNum(int param_0) const {
return 0;
}
/* 802F3790-802F3804 2EE0D0 0074+00 1/1 0/0 0/0 .text newTexCoord__18J2DMaterialFactoryCFii */
J2DTexCoord J2DMaterialFactory::newTexCoord(int param_0, int param_1) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0x14[param_1] != 0xffff) {
@@ -240,8 +227,6 @@ J2DTexCoord J2DMaterialFactory::newTexCoord(int param_0, int param_1) const {
return J2DTexCoord();
}
/* 802F3804-802F38E0 2EE144 00DC+00 1/1 0/0 0/0 .text newTexMtx__18J2DMaterialFactoryCFii
*/
J2DTexMtx* J2DMaterialFactory::newTexMtx(int param_0, int param_1) const {
J2DTexMtx* rv = NULL;
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
@@ -252,7 +237,6 @@ J2DTexMtx* J2DMaterialFactory::newTexMtx(int param_0, int param_1) const {
return rv;
}
/* 802F38E0-802F3920 2EE220 0040+00 1/1 0/0 0/0 .text newCullMode__18J2DMaterialFactoryCFi */
u8 J2DMaterialFactory::newCullMode(int param_0) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0x1 != 0xff) {
@@ -261,8 +245,6 @@ u8 J2DMaterialFactory::newCullMode(int param_0) const {
return 0xff;
}
/* 802F3920-802F3968 2EE260 0048+00 1/1 0/0 0/0 .text newTexNo__18J2DMaterialFactoryCFii
*/
u16 J2DMaterialFactory::newTexNo(int param_0, int param_1) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0x38[param_1] != 0xffff) {
@@ -271,8 +253,6 @@ u16 J2DMaterialFactory::newTexNo(int param_0, int param_1) const {
return 0x1FFFF;
}
/* 802F3968-802F39A8 2EE2A8 0040+00 1/1 0/0 0/0 .text newFontNo__18J2DMaterialFactoryCFi
*/
u16 J2DMaterialFactory::newFontNo(int param_0) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0x48 != 0xffff) {
@@ -281,7 +261,6 @@ u16 J2DMaterialFactory::newFontNo(int param_0) const {
return 0x1FFFF;
}
/* 802F39A8-802F3A1C 2EE2E8 0074+00 1/1 0/0 0/0 .text newTevOrder__18J2DMaterialFactoryCFii */
J2DTevOrder J2DMaterialFactory::newTevOrder(int param_0, int param_1) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0x72[param_1] != 0xffff) {
@@ -290,7 +269,6 @@ J2DTevOrder J2DMaterialFactory::newTevOrder(int param_0, int param_1) const {
return J2DTevOrder();
}
/* 802F3A1C-802F3AB4 2EE35C 0098+00 1/1 0/0 0/0 .text newTevColor__18J2DMaterialFactoryCFii */
J2DGXColorS10 J2DMaterialFactory::newTevColor(int param_0, int param_1) const {
// FAKEMATCH
#if DEBUG || VERSION == VERSION_WII_USA_R0 || VERSION == VERSION_WII_USA_R2
@@ -313,7 +291,6 @@ J2DGXColorS10 J2DMaterialFactory::newTevColor(int param_0, int param_1) const {
return rv;
}
/* 802F3AB4-802F3B54 2EE3F4 00A0+00 1/1 0/0 0/0 .text newTevKColor__18J2DMaterialFactoryCFii */
JUtility::TColor J2DMaterialFactory::newTevKColor(int param_0, int param_1) const {
JUtility::TColor local_20 = (GXColor){0xFF, 0xFF, 0xFF, 0xFF};
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
@@ -323,7 +300,6 @@ JUtility::TColor J2DMaterialFactory::newTevKColor(int param_0, int param_1) cons
return local_20;
}
/* 802F3B54-802F3B8C 2EE494 0038+00 1/1 0/0 0/0 .text newTevStageNum__18J2DMaterialFactoryCFi */
u8 J2DMaterialFactory::newTevStageNum(int param_0) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0x4 != 0xff) {
@@ -332,7 +308,6 @@ u8 J2DMaterialFactory::newTevStageNum(int param_0) const {
return 0xFF;
}
/* 802F3B8C-802F3BEC 2EE4CC 0060+00 1/1 0/0 0/0 .text newTevStage__18J2DMaterialFactoryCFii */
J2DTevStage J2DMaterialFactory::newTevStage(int param_0, int param_1) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0x9a[param_1] != 0xffff) {
@@ -341,8 +316,6 @@ J2DTevStage J2DMaterialFactory::newTevStage(int param_0, int param_1) const {
return J2DTevStage();
}
/* 802F3BEC-802F3C88 2EE52C 009C+00 1/1 0/0 0/0 .text
* newTevSwapModeTable__18J2DMaterialFactoryCFii */
J2DTevSwapModeTable J2DMaterialFactory::newTevSwapModeTable(int param_0, int param_1) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0xda[param_1] != 0xffff) {
@@ -351,8 +324,6 @@ J2DTevSwapModeTable J2DMaterialFactory::newTevSwapModeTable(int param_0, int par
return J2DTevSwapModeTable(j2dDefaultTevSwapModeTable);
}
/* 802F3C88-802F3CB8 2EE5C8 0030+00 1/1 0/0 0/0 .text newIndTexStageNum__18J2DMaterialFactoryCFi
*/
u8 J2DMaterialFactory::newIndTexStageNum(int param_0) const {
if (field_0xc != NULL) {
if (field_0xc[param_0].field_0x0 == 1) {
@@ -362,7 +333,6 @@ u8 J2DMaterialFactory::newIndTexStageNum(int param_0) const {
return 0;
}
/* 802F3CB8-802F3D20 2EE5F8 0068+00 1/1 0/0 0/0 .text newIndTexOrder__18J2DMaterialFactoryCFii */
J2DIndTexOrder J2DMaterialFactory::newIndTexOrder(int param_0, int param_1) const {
J2DIndTexOrder rv;
if (field_0xc != NULL) {
@@ -373,7 +343,6 @@ J2DIndTexOrder J2DMaterialFactory::newIndTexOrder(int param_0, int param_1) cons
return rv;
}
/* 802F3D20-802F3E24 2EE660 0104+00 1/1 0/0 0/0 .text newIndTexMtx__18J2DMaterialFactoryCFii */
J2DIndTexMtx J2DMaterialFactory::newIndTexMtx(int param_0, int param_1) const {
J2DIndTexMtx rv;
if (field_0xc != NULL) {
@@ -384,7 +353,6 @@ J2DIndTexMtx J2DMaterialFactory::newIndTexMtx(int param_0, int param_1) const {
return rv;
}
/* 802F3E24-802F3F78 2EE764 0154+00 1/1 0/0 0/0 .text newIndTevStage__18J2DMaterialFactoryCFii */
J2DIndTevStage J2DMaterialFactory::newIndTevStage(int param_0, int param_1) const {
J2DIndTevStage rv;
if (field_0xc != NULL) {
@@ -395,8 +363,6 @@ J2DIndTevStage J2DMaterialFactory::newIndTevStage(int param_0, int param_1) cons
return rv;
}
/* 802F3F78-802F3FE0 2EE8B8 0068+00 1/1 0/0 0/0 .text
* newIndTexCoordScale__18J2DMaterialFactoryCFii */
J2DIndTexCoordScale J2DMaterialFactory::newIndTexCoordScale(int param_0, int param_1) const {
J2DIndTexCoordScale rv;
if (field_0xc != NULL) {
@@ -407,7 +373,6 @@ J2DIndTexCoordScale J2DMaterialFactory::newIndTexCoordScale(int param_0, int par
return rv;
}
/* 802F3FE0-802F405C 2EE920 007C+00 1/1 0/0 0/0 .text newAlphaComp__18J2DMaterialFactoryCFi */
J2DAlphaComp J2DMaterialFactory::newAlphaComp(int param_0) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0xe2 != 0xffff) {
@@ -416,8 +381,6 @@ J2DAlphaComp J2DMaterialFactory::newAlphaComp(int param_0) const {
return J2DAlphaComp();
}
/* 802F405C-802F40D8 2EE99C 007C+00 1/1 0/0 0/0 .text newBlend__18J2DMaterialFactoryCFi
*/
J2DBlend J2DMaterialFactory::newBlend(int param_0) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0xe4 != 0xffff) {
@@ -426,8 +389,6 @@ J2DBlend J2DMaterialFactory::newBlend(int param_0) const {
return J2DBlend();
}
/* 802F40D8-802F4110 2EEA18 0038+00 1/1 0/0 0/0 .text newDither__18J2DMaterialFactoryCFi
*/
u8 J2DMaterialFactory::newDither(int param_0) const {
J2DMaterialInitData* iVar2 = &field_0x4[field_0x8[param_0]];
if (iVar2->field_0x5 != 0xff) {
@@ -436,7 +397,6 @@ u8 J2DMaterialFactory::newDither(int param_0) const {
return 0;
}
/* 802F4110-802F4170 2EEA50 0060+00 1/1 0/0 0/0 .text __ct__11J2DTevStageFRC15J2DTevStageInfo */
J2DTevStage::J2DTevStage(J2DTevStageInfo const& param_0) {
setTevStageInfo(param_0);
setTevSwapModeInfo(j2dDefaultTevSwapMode);
-15
View File
@@ -3,12 +3,10 @@
#include "JSystem/J2DGraph/J2DOrthoGraph.h"
#include "dolphin/gx.h"
/* 802E9670-802E96D0 2E3FB0 0060+00 3/3 1/1 0/0 .text __ct__13J2DOrthoGraphFv */
J2DOrthoGraph::J2DOrthoGraph() : J2DGrafContext(0, 0, 0, 0) {
this->setLookat();
}
/* 802E96D0-802E97B4 2E4010 00E4+00 0/0 7/7 0/0 .text __ct__13J2DOrthoGraphFffffff */
J2DOrthoGraph::J2DOrthoGraph(f32 x, f32 y, f32 width, f32 height, f32 far, f32 near)
: J2DGrafContext(x, y, width, height) {
mOrtho = JGeometry::TBox2<f32>(0, 0, width, height);
@@ -17,29 +15,23 @@ J2DOrthoGraph::J2DOrthoGraph(f32 x, f32 y, f32 width, f32 height, f32 far, f32 n
this->setLookat();
}
/* 802E97B4-802E980C 2E40F4 0058+00 1/0 6/6 0/0 .text setPort__13J2DOrthoGraphFv */
void J2DOrthoGraph::setPort() {
this->J2DGrafContext::setPort();
C_MTXOrtho(mMtx44, mOrtho.i.y, mOrtho.f.y, mOrtho.i.x, mOrtho.f.x, mNear, mFar);
GXSetProjection(mMtx44, GX_ORTHOGRAPHIC);
}
/* 802E980C-802E9840 2E414C 0034+00 0/0 5/5 0/0 .text
* setOrtho__13J2DOrthoGraphFRCQ29JGeometry8TBox2<f>ff */
void J2DOrthoGraph::setOrtho(JGeometry::TBox2<f32> const& bounds, f32 far, f32 near) {
mOrtho = bounds;
mNear = -near;
mFar = -far;
}
/* 802E9840-802E987C 2E4180 003C+00 1/0 0/0 0/0 .text setLookat__13J2DOrthoGraphFv */
void J2DOrthoGraph::setLookat() {
MTXIdentity(mPosMtx);
GXLoadPosMtxImm(mPosMtx, 0);
}
/* 802E987C-802E9998 2E41BC 011C+00 0/0 1/1 0/0 .text
* scissorBounds__13J2DOrthoGraphFPQ29JGeometry8TBox2<f>PCQ29JGeometry8TBox2<f> */
void J2DOrthoGraph::scissorBounds(JGeometry::TBox2<f32>* param_0,
JGeometry::TBox2<f32> const* param_1) {
f32 widthPower = this->getWidthPower();
@@ -54,7 +46,6 @@ void J2DOrthoGraph::scissorBounds(JGeometry::TBox2<f32>* param_0,
param_0->intersect(mScissorBounds);
}
/* 802E9998-802E9AC4 2E42D8 012C+00 0/0 6/6 0/0 .text J2DDrawLine__FffffQ28JUtility6TColori */
void J2DDrawLine(f32 x1, f32 y1, f32 x2, f32 y2, JUtility::TColor color,
int line_width) {
J2DOrthoGraph oGrph;
@@ -64,29 +55,23 @@ void J2DDrawLine(f32 x1, f32 y1, f32 x2, f32 y2, JUtility::TColor color,
oGrph.lineTo(x2, y2);
}
/* 802E9AC4-802E9B0C 2E4404 0048+00 0/0 10/10 0/0 .text J2DFillBox__FffffQ28JUtility6TColor */
void J2DFillBox(f32 x, f32 y, f32 width, f32 height, JUtility::TColor color) {
J2DFillBox(JGeometry::TBox2<f32>(x, y, x + width, y + height),
color);
}
/* 802E9B0C-802E9B9C 2E444C 0090+00 1/1 0/0 0/0 .text
* J2DFillBox__FRCQ29JGeometry8TBox2<f>Q28JUtility6TColor */
void J2DFillBox(JGeometry::TBox2<f32> const& box, JUtility::TColor color) {
J2DOrthoGraph oGrph;
oGrph.setColor(color);
oGrph.fillBox(box);
}
/* 802E9B9C-802E9BE8 2E44DC 004C+00 0/0 5/5 0/0 .text J2DDrawFrame__FffffQ28JUtility6TColorUc */
void J2DDrawFrame(f32 x, f32 y, f32 width, f32 height, JUtility::TColor color,
u8 line_width) {
J2DDrawFrame(JGeometry::TBox2<f32>(x, y, x + width, y + height),
color, line_width);
}
/* 802E9BE8-802E9C88 2E4528 00A0+00 1/1 0/0 0/0 .text
* J2DDrawFrame__FRCQ29JGeometry8TBox2<f>Q28JUtility6TColorUc */
void J2DDrawFrame(JGeometry::TBox2<f32> const& box, JUtility::TColor color, u8 line_width) {
J2DOrthoGraph oGrph;
oGrph.setColor(color);
-72
View File
@@ -7,7 +7,6 @@
#include "JSystem/JSupport/JSURandomInputStream.h"
#include "JSystem/JUtility/JUTResource.h"
/* 802F5BF8-802F5CB8 2F0538 00C0+00 0/0 10/10 0/0 .text __ct__7J2DPaneFv */
J2DPane::J2DPane() : mBounds(), mGlobalBounds(), mClipRect(), mPaneTree(this) {
mTransform = NULL;
mKind = 'PAN1';
@@ -20,7 +19,6 @@ J2DPane::J2DPane() : mBounds(), mGlobalBounds(), mClipRect(), mPaneTree(this) {
calcMtx();
}
/* 802F5CB8-802F5D40 2F05F8 0088+00 3/3 0/0 0/0 .text initiate__7J2DPaneFv */
void J2DPane::initiate() {
field_0x4 = -1;
mRotateOffsetY = mRotateOffsetX = mRotateZ = mRotateY = mRotateX = 0;
@@ -36,16 +34,12 @@ void J2DPane::initiate() {
calcMtx();
}
/* 802F5D40-802F5DD0 2F0680 0090+00 0/0 1/1 0/0 .text
* __ct__7J2DPaneFP7J2DPanebUxRCQ29JGeometry8TBox2<f> */
J2DPane::J2DPane(J2DPane* p_pane, bool visible, u64 tag, JGeometry::TBox2<f32> const& bounds)
: mBounds(), mGlobalBounds(), mClipRect(), mPaneTree(this) {
mTransform = NULL;
initialize(p_pane, visible, tag, bounds);
}
/* 802F5DD0-802F5E88 2F0710 00B8+00 1/1 0/0 0/0 .text
* initialize__7J2DPaneFP7J2DPanebUxRCQ29JGeometry8TBox2<f> */
void J2DPane::initialize(J2DPane* p_pane, bool visible, u64 infoTag,
JGeometry::TBox2<f32> const& bounds) {
mKind = 'PAN1';
@@ -62,15 +56,12 @@ void J2DPane::initialize(J2DPane* p_pane, bool visible, u64 infoTag,
calcMtx();
}
/* 802F5E88-802F5F08 2F07C8 0080+00 0/0 3/3 0/0 .text __ct__7J2DPaneFUxRCQ29JGeometry8TBox2<f> */
J2DPane::J2DPane(u64 infoTag, JGeometry::TBox2<f32> const& bounds)
: mBounds(), mGlobalBounds(), mClipRect(), mPaneTree(this) {
mTransform = NULL;
initialize(infoTag, bounds);
}
/* 802F5F08-802F5F9C 2F0848 0094+00 1/1 0/0 0/0 .text
* initialize__7J2DPaneFUxRCQ29JGeometry8TBox2<f> */
void J2DPane::initialize(u64 tag, const JGeometry::TBox2<f32>& bounds) {
mKind = 'PAN1';
mVisible = true;
@@ -82,8 +73,6 @@ void J2DPane::initialize(u64 tag, const JGeometry::TBox2<f32>& bounds) {
calcMtx();
}
/* 802F5F9C-802F60C4 2F08DC 0128+00 0/0 1/1 0/0 .text
* __ct__7J2DPaneFP7J2DPaneP20JSURandomInputStreamUc */
J2DPane::J2DPane(J2DPane* p_pane, JSURandomInputStream* p_stream, u8 isEx) : mPaneTree(this) {
mTransform = NULL;
if (!isEx) {
@@ -107,8 +96,6 @@ J2DPane::J2DPane(J2DPane* p_pane, JSURandomInputStream* p_stream, u8 isEx) : mPa
}
}
/* 802F60C4-802F63F8 2F0A04 0334+00 1/1 3/3 0/0 .text
* makePaneStream__7J2DPaneFP7J2DPaneP20JSURandomInputStream */
void J2DPane::makePaneStream(J2DPane* p_pane, JSURandomInputStream* p_stream) {
u8 unk;
p_stream->read(&unk, 1);
@@ -168,8 +155,6 @@ void J2DPane::makePaneStream(J2DPane* p_pane, JSURandomInputStream* p_stream) {
calcMtx();
}
/* 802F63F8-802F658C 2F0D38 0194+00 4/4 0/0 0/0 .text changeUseTrans__7J2DPaneFP7J2DPane
*/
void J2DPane::changeUseTrans(J2DPane* p_pane) {
f32 xOffset = 0;
f32 yOffset = 0;
@@ -214,7 +199,6 @@ void J2DPane::changeUseTrans(J2DPane* p_pane) {
}
}
/* 802F658C-802F666C 2F0ECC 00E0+00 1/0 4/4 0/0 .text __dt__7J2DPaneFv */
J2DPane::~J2DPane() {
JSUTreeIterator<J2DPane> iterator;
for (iterator = mPaneTree.getFirstChild(); iterator != mPaneTree.getEndChild();) {
@@ -223,7 +207,6 @@ J2DPane::~J2DPane() {
}
}
/* 802F666C-802F6714 2F0FAC 00A8+00 0/0 2/2 0/0 .text appendChild__7J2DPaneFP7J2DPane */
bool J2DPane::appendChild(J2DPane* p_child) {
if (p_child == NULL)
return false;
@@ -239,7 +222,6 @@ bool J2DPane::appendChild(J2DPane* p_child) {
return result;
}
/* 802F6714-802F67E0 2F1054 00CC+00 0/0 1/1 0/0 .text insertChild__7J2DPaneFP7J2DPaneP7J2DPane */
bool J2DPane::insertChild(J2DPane* p_prev, J2DPane* p_child) {
if (p_child == NULL)
return false;
@@ -257,7 +239,6 @@ bool J2DPane::insertChild(J2DPane* p_prev, J2DPane* p_child) {
return result;
}
/* 802F67E0-802F6D18 2F1120 0538+00 0/0 1/1 0/0 .text draw__7J2DPaneFffPC14J2DGrafContextbb */
void J2DPane::draw(f32 x, f32 y, J2DGrafContext const* p_grafCtx, bool isOrthoGraf, bool param_4) {
bool unkBool = param_4 && mVisible;
if (p_grafCtx->getGrafType() != 1) {
@@ -329,7 +310,6 @@ void J2DPane::draw(f32 x, f32 y, J2DGrafContext const* p_grafCtx, bool isOrthoGr
}
}
/* 802F6D18-802F6F60 2F1658 0248+00 2/2 4/4 0/0 .text place__7J2DPaneFRCQ29JGeometry8TBox2<f> */
void J2DPane::place(JGeometry::TBox2<f32> const& box) {
JGeometry::TBox2<f32> tmpBox;
@@ -380,21 +360,18 @@ void J2DPane::place(JGeometry::TBox2<f32> const& box) {
calcMtx();
}
/* 802F6F60-802F6FB4 2F18A0 0054+00 1/0 7/0 0/0 .text move__7J2DPaneFff */
void J2DPane::move(f32 x, f32 y) {
f32 width = getWidth();
f32 height = getHeight();
place(JGeometry::TBox2<f32>(x, y, x + width, y + height));
}
/* 802F6FB4-802F6FF8 2F18F4 0044+00 1/0 7/0 0/0 .text add__7J2DPaneFff */
void J2DPane::add(f32 x, f32 y) {
mTranslateX += x;
mTranslateY += y;
calcMtx();
}
/* 802F6FF8-802F7100 2F1938 0108+00 1/0 5/2 0/0 .text resize__7J2DPaneFff */
void J2DPane::resize(f32 x, f32 y) {
JGeometry::TBox2<f32> box = mBounds;
@@ -415,11 +392,8 @@ void J2DPane::resize(f32 x, f32 y) {
place(box);
}
/* ############################################################################################## */
/* 804349B0-804349C0 0616D0 0010+00 2/2 0/0 0/0 .bss static_mBounds__7J2DPane */
JGeometry::TBox2<f32> J2DPane::static_mBounds(0, 0, 0, 0);
/* 802F7100-802F71DC 2F1A40 00DC+00 0/0 25/25 1/1 .text getBounds__7J2DPaneFv */
JGeometry::TBox2<f32>& J2DPane::getBounds() {
static_mBounds = mBounds;
@@ -438,7 +412,6 @@ JGeometry::TBox2<f32>& J2DPane::getBounds() {
return static_mBounds;
}
/* 802F71DC-802F720C 2F1B1C 0030+00 0/0 12/12 0/0 .text rotate__7J2DPaneFff13J2DRotateAxisf */
void J2DPane::rotate(f32 offsetX, f32 offsetY, J2DRotateAxis axis, f32 angle) {
mRotateOffsetX = offsetX;
mRotateOffsetY = offsetY;
@@ -446,7 +419,6 @@ void J2DPane::rotate(f32 offsetX, f32 offsetY, J2DRotateAxis axis, f32 angle) {
rotate(angle);
}
/* 802F720C-802F7264 2F1B4C 0058+00 1/1 0/0 0/0 .text rotate__7J2DPaneFf */
void J2DPane::rotate(f32 angle) {
if (mRotAxis == ROTATE_X) {
mRotateX = angle;
@@ -459,7 +431,6 @@ void J2DPane::rotate(f32 angle) {
calcMtx();
}
/* 802F7264-802F72E0 2F1BA4 007C+00 0/0 2/2 0/0 .text clip__7J2DPaneFRCQ29JGeometry8TBox2<f> */
void J2DPane::clip(JGeometry::TBox2<f32> const& bounds) {
JGeometry::TBox2<f32> boxA(bounds);
JGeometry::TBox2<f32> boxB(mGlobalBounds);
@@ -467,7 +438,6 @@ void J2DPane::clip(JGeometry::TBox2<f32> const& bounds) {
mClipRect.intersect(boxA);
}
/* 802F72E0-802F7388 2F1C20 00A8+00 1/0 7/1 0/0 .text search__7J2DPaneFUx */
J2DPane* J2DPane::search(u64 tag) {
if (tag == mInfoTag) {
return this;
@@ -482,7 +452,6 @@ J2DPane* J2DPane::search(u64 tag) {
return NULL;
}
/* 802F7388-802F7430 2F1CC8 00A8+00 1/0 7/1 0/0 .text searchUserInfo__7J2DPaneFUx */
J2DPane* J2DPane::searchUserInfo(u64 tag) {
if (tag == mUserInfoTag) {
return this;
@@ -497,7 +466,6 @@ J2DPane* J2DPane::searchUserInfo(u64 tag) {
return NULL;
}
/* 802F7430-802F74B8 2F1D70 0088+00 1/0 7/7 0/0 .text isUsed__7J2DPaneFPC7ResTIMG */
bool J2DPane::isUsed(const ResTIMG* p_timg) {
JSUTreeIterator<J2DPane> iter;
for (iter = mPaneTree.getFirstChild(); iter != mPaneTree.getEndChild(); ++iter) {
@@ -507,7 +475,6 @@ bool J2DPane::isUsed(const ResTIMG* p_timg) {
return false;
}
/* 802F74B8-802F7540 2F1DF8 0088+00 1/0 7/7 0/0 .text isUsed__7J2DPaneFPC7ResFONT */
bool J2DPane::isUsed(const ResFONT* p_font) {
JSUTreeIterator<J2DPane> iter;
for (iter = mPaneTree.getFirstChild(); iter != mPaneTree.getEndChild(); ++iter) {
@@ -517,7 +484,6 @@ bool J2DPane::isUsed(const ResFONT* p_font) {
return false;
}
/* 802F7540-802F7680 2F1E80 0140+00 1/0 7/0 0/0 .text makeMatrix__7J2DPaneFffff */
void J2DPane::makeMatrix(f32 param_0, f32 param_1, f32 param_2, f32 param_3) {
f32 tmpX = mRotateOffsetX - param_2;
f32 tmpY = mRotateOffsetY - param_3;
@@ -533,8 +499,6 @@ void J2DPane::makeMatrix(f32 param_0, f32 param_1, f32 param_2, f32 param_3) {
MTXTransApply(tmp, mPositionMtx, param_0 + tmpX, param_1 + tmpY, 0);
}
/* 802F7680-802F76F8 2F1FC0 0078+00 1/0 7/3 0/0 .text setCullBack__7J2DPaneF11_GXCullMode
*/
void J2DPane::setCullBack(GXCullMode mode) {
mCullMode = mode;
@@ -544,8 +508,6 @@ void J2DPane::setCullBack(GXCullMode mode) {
}
}
/* 802F76F8-802F77D0 2F2038 00D8+00 0/0 8/8 0/0 .text setBasePosition__7J2DPaneF15J2DBasePosition
*/
void J2DPane::setBasePosition(J2DBasePosition position) {
mBasePosition = position;
mRotAxis = ROTATE_Z;
@@ -572,7 +534,6 @@ void J2DPane::setBasePosition(J2DBasePosition position) {
calcMtx();
}
/* 802F77D0-802F79A8 2F2110 01D8+00 0/0 1/1 0/0 .text setInfluencedAlpha__7J2DPaneFbb */
void J2DPane::setInfluencedAlpha(bool influencedAlpha, bool param_1) {
if (param_1 && mIsInfluencedAlpha != influencedAlpha) {
J2DPane* parent = getParentPane();
@@ -611,7 +572,6 @@ void J2DPane::setInfluencedAlpha(bool influencedAlpha, bool param_1) {
mIsInfluencedAlpha = influencedAlpha;
}
/* 802F79A8-802F7A8C 2F22E8 00E4+00 0/0 3/3 0/0 .text getGlbVtx__7J2DPaneCFUc */
Vec J2DPane::getGlbVtx(u8 param_0) const {
Vec out;
if (param_0 >= 4) {
@@ -640,7 +600,6 @@ Vec J2DPane::getGlbVtx(u8 param_0) const {
}
}
/* 802F7A8C-802F7AC4 2F23CC 0038+00 1/1 15/15 0/0 .text getFirstChildPane__7J2DPaneFv */
J2DPane* J2DPane::getFirstChildPane() {
if (!getFirstChild())
return NULL;
@@ -648,7 +607,6 @@ J2DPane* J2DPane::getFirstChildPane() {
return getFirstChild()->getObject();
}
/* 802F7AC4-802F7AFC 2F2404 0038+00 1/1 8/8 0/0 .text getNextChildPane__7J2DPaneFv */
J2DPane* J2DPane::getNextChildPane() {
if (getPaneTree()->getNextChild() == NULL)
return NULL;
@@ -656,7 +614,6 @@ J2DPane* J2DPane::getNextChildPane() {
return getPaneTree()->getNextChild()->getObject();
}
/* 802F7AFC-802F7B18 2F243C 001C+00 6/6 11/11 0/0 .text getParentPane__7J2DPaneFv */
J2DPane* J2DPane::getParentPane() {
if (getPaneTree()->getParent() == NULL)
return NULL;
@@ -685,8 +642,6 @@ struct J2DPaneInfo {
/* 0x40 */ f32 mTranslateY;
}; // Size: 0x48
/* 802F7B18-802F7D00 2F2458 01E8+00 1/1 6/6 0/0 .text
* makePaneExStream__7J2DPaneFP7J2DPaneP20JSURandomInputStream */
void J2DPane::makePaneExStream(J2DPane* p_parent, JSURandomInputStream* p_stream) {
p_stream->getPosition();
@@ -738,7 +693,6 @@ void J2DPane::makePaneExStream(J2DPane* p_parent, JSURandomInputStream* p_stream
calcMtx();
}
/* 802F7D00-802F7DB8 2F2640 00B8+00 0/0 1/1 0/0 .text J2DCast_F32_to_S16__7J2DPaneFfUc */
s16 J2DPane::J2DCast_F32_to_S16(f32 value, u8 arg2) {
if (arg2 >= 0xF) {
return 0;
@@ -763,8 +717,6 @@ s16 J2DPane::J2DCast_F32_to_S16(f32 value, u8 arg2) {
}
}
/* 802F7DB8-802F7EF4 2F26F8 013C+00 0/0 3/3 0/0 .text
* getPointer__7J2DPaneFP20JSURandomInputStreamUlP10JKRArchive */
void* J2DPane::getPointer(JSURandomInputStream* p_stream, u32 param_1, JKRArchive* p_archive) {
JUTResReference resRef;
@@ -798,7 +750,6 @@ void* J2DPane::getPointer(JSURandomInputStream* p_stream, u32 param_1, JKRArchiv
return pointer;
}
/* 802F7EF4-802F7FC4 2F2834 00D0+00 2/0 7/4 0/0 .text setAnimation__7J2DPaneFP10J2DAnmBase */
void J2DPane::setAnimation(J2DAnmBase* p_anm) {
if (p_anm != NULL) {
switch (p_anm->getKind()) {
@@ -829,18 +780,15 @@ void J2DPane::setAnimation(J2DAnmBase* p_anm) {
}
}
/* 802F7FC4-802F7FCC -00001 0008+00 0/0 0/0 0/0 .text setAnimation__7J2DPaneFP15J2DAnmTransform */
void J2DPane::setAnimation(J2DAnmTransform* p_anm) {
mTransform = p_anm;
}
/* 802F7FCC-802F8004 2F290C 0038+00 0/0 57/57 0/0 .text animationTransform__7J2DPaneFv */
void J2DPane::animationTransform() {
if (mTransform != NULL)
animationTransform(mTransform);
}
/* 802F8004-802F8080 2F2944 007C+00 1/0 7/1 0/0 .text clearAnmTransform__7J2DPaneFv */
void J2DPane::clearAnmTransform() {
J2DAnmTransform* none = NULL;
setAnimation(none);
@@ -851,8 +799,6 @@ void J2DPane::clearAnmTransform() {
}
}
/* 802F8080-802F8118 2F29C0 0098+00 1/0 7/0 0/0 .text
* animationTransform__7J2DPaneFPC15J2DAnmTransform */
const J2DAnmTransform* J2DPane::animationTransform(const J2DAnmTransform* p_transform) {
const J2DAnmTransform* p = p_transform;
if (mTransform != NULL)
@@ -867,8 +813,6 @@ const J2DAnmTransform* J2DPane::animationTransform(const J2DAnmTransform* p_tran
return p;
}
/* 802F8118-802F81A0 2F2A58 0088+00 1/0 8/1 0/0 .text
* setVisibileAnimation__7J2DPaneFP20J2DAnmVisibilityFull */
void J2DPane::setVisibileAnimation(J2DAnmVisibilityFull* p_visibility) {
setAnimationVF(p_visibility);
@@ -878,8 +822,6 @@ void J2DPane::setVisibileAnimation(J2DAnmVisibilityFull* p_visibility) {
}
}
/* 802F81A0-802F8228 2F2AE0 0088+00 1/0 8/1 0/0 .text
* setVtxColorAnimation__7J2DPaneFP14J2DAnmVtxColor */
void J2DPane::setVtxColorAnimation(J2DAnmVtxColor* p_vtxColor) {
setAnimationVC(p_vtxColor);
@@ -889,8 +831,6 @@ void J2DPane::setVtxColorAnimation(J2DAnmVtxColor* p_vtxColor) {
}
}
/* 802F8228-802F82C0 2F2B68 0098+00 1/0 7/3 0/0 .text animationPane__7J2DPaneFPC15J2DAnmTransform
*/
const J2DAnmTransform* J2DPane::animationPane(const J2DAnmTransform* p_transform) {
const J2DAnmTransform* p = p_transform;
if (mTransform != NULL)
@@ -905,8 +845,6 @@ const J2DAnmTransform* J2DPane::animationPane(const J2DAnmTransform* p_transform
return p;
}
/* 802F82C0-802F83C8 2F2C00 0108+00 2/2 0/0 0/0 .text
* updateTransform__7J2DPaneFPC15J2DAnmTransform */
void J2DPane::updateTransform(J2DAnmTransform const* p_anmTransform) {
if (field_0x4 != 0xFFFF && p_anmTransform != NULL) {
J3DTransformInfo info;
@@ -922,29 +860,22 @@ void J2DPane::updateTransform(J2DAnmTransform const* p_anmTransform) {
}
}
/* 802F83C8-802F83CC 2F2D08 0004+00 1/0 0/0 0/0 .text drawSelf__7J2DPaneFffPA3_A4_f */
void J2DPane::drawSelf(f32, f32, f32 (*)[3][4]) {
/* empty function */
}
/* 802F83CC-802F83D0 2F2D0C 0004+00 1/0 1/0 0/0 .text rewriteAlpha__7J2DPaneFv */
void J2DPane::rewriteAlpha() {
/* empty function */
}
/* 802F83D0-802F83FC 2F2D10 002C+00 1/0 6/0 0/0 .text
* setAnimationVF__7J2DPaneFP20J2DAnmVisibilityFull */
void J2DPane::setAnimationVF(J2DAnmVisibilityFull* p_visibility) {
setAnimation(p_visibility);
}
/* 802F83FC-802F8428 2F2D3C 002C+00 1/0 6/0 0/0 .text setAnimationVC__7J2DPaneFP14J2DAnmVtxColor
*/
void J2DPane::setAnimationVC(J2DAnmVtxColor* p_vtxColor) {
setAnimation(p_vtxColor);
}
/* 802F8428-802F8464 2F2D68 003C+00 1/0 4/0 0/0 .text setCullBack__7J2DPaneFb */
void J2DPane::setCullBack(bool cull) {
GXCullMode mode;
@@ -956,18 +887,15 @@ void J2DPane::setCullBack(bool cull) {
setCullBack(mode);
}
/* 802F8464-802F8474 2F2DA4 0010+00 1/0 5/0 0/0 .text setConnectParent__7J2DPaneFb */
bool J2DPane::setConnectParent(bool connected) {
mConnected = false;
return false;
}
/* 802F8474-802F8478 2F2DB4 0004+00 1/0 7/0 0/0 .text update__7J2DPaneFv */
void J2DPane::update() {
/* empty function */
}
/* 802F8478-802F847C 2F2DB8 0004+00 1/0 1/0 0/0 .text drawSelf__7J2DPaneFff */
void J2DPane::drawSelf(f32, f32) {
/* empty function */
}
-64
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J2DPicture
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J2DGraph/J2DPicture.h"
@@ -14,7 +9,6 @@
#include "JSystem/JSupport/JSURandomInputStream.h"
#include "dolphin/gx.h"
/* 802FC050-802FC118 2F6990 00C8+00 0/0 2/2 0/0 .text __ct__10J2DPictureFv */
J2DPicture::J2DPicture() : mPalette(NULL) {
for (int i = 0; i < 2; i++) {
mTexture[i] = NULL;
@@ -26,15 +20,11 @@ J2DPicture::J2DPicture() : mPalette(NULL) {
}
/* 802FC118-802FC1D4 2F6A58 00BC+00 0/0 1/1 0/0 .text
* __ct__10J2DPictureFP7J2DPaneP20JSURandomInputStreamP10JKRArchive */
J2DPicture::J2DPicture(J2DPane* p_pane, JSURandomInputStream* p_stream, JKRArchive* p_archive)
: mPalette(NULL) {
private_readStream(p_pane, p_stream, p_archive);
}
/* 802FC1D4-802FC708 2F6B14 0534+00 0/0 1/1 0/0 .text
* __ct__10J2DPictureFP7J2DPaneP20JSURandomInputStreamP11J2DMaterial */
J2DPicture::J2DPicture(J2DPane* p_pane, JSURandomInputStream* p_stream, J2DMaterial* p_material)
: mPalette(NULL) {
int position = p_stream->getPosition();
@@ -136,7 +126,6 @@ J2DPicture::J2DPicture(J2DPane* p_pane, JSURandomInputStream* p_stream, J2DMater
setBlendAlphaRatio(alpha.a, alpha.b);
}
/* 802FC708-802FC800 2F7048 00F8+00 0/0 20/20 1/1 .text __ct__10J2DPictureFPC7ResTIMG */
J2DPicture::J2DPicture(ResTIMG const* p_timg) {
for (int i = 0; i < 2; i++) {
mTexture[i] = NULL;
@@ -153,8 +142,6 @@ J2DPicture::J2DPicture(ResTIMG const* p_timg) {
}
/* 802FC800-802FC8E8 2F7140 00E8+00 0/0 5/5 0/0 .text
* __ct__10J2DPictureFUxRCQ29JGeometry8TBox2<f>PC7ResTIMGPC7ResTLUT */
J2DPicture::J2DPicture(u64 tag, JGeometry::TBox2<f32> const& bounds, ResTIMG const* p_timg,
ResTLUT const* p_tlut)
: J2DPane(tag, bounds), mPalette(NULL) {
@@ -169,8 +156,6 @@ J2DPicture::J2DPicture(u64 tag, JGeometry::TBox2<f32> const& bounds, ResTIMG con
initinfo();
}
/* 802FC8E8-802FCCDC 2F7228 03F4+00 1/1 0/0 0/0 .text
* private_readStream__10J2DPictureFP7J2DPaneP20JSURandomInputStreamP10JKRArchive */
void J2DPicture::private_readStream(J2DPane* parent, JSURandomInputStream* stream,
JKRArchive* archive) {
J2DScrnBlockHeader header;
@@ -245,8 +230,6 @@ void J2DPicture::private_readStream(J2DPane* parent, JSURandomInputStream* strea
setBlendRatio(1.0f, 1.0f);
}
/* 802FCCDC-802FCD70 2F761C 0094+00 1/0 0/0 0/0 .text initiate__10J2DPictureFPC7ResTIMGPC7ResTLUT
*/
void J2DPicture::initiate(const ResTIMG* img, const ResTLUT* lut) {
private_initiate(img, lut);
if (mTexture[0] == NULL) {
@@ -256,8 +239,6 @@ void J2DPicture::initiate(const ResTIMG* img, const ResTLUT* lut) {
place(JGeometry::TBox2<f32>(0.0f, 0.0f, mTexture[0]->getWidth(), mTexture[0]->getHeight()));
}
/* 802FCD70-802FCE9C 2F76B0 012C+00 2/2 0/0 0/0 .text
* private_initiate__10J2DPictureFPC7ResTIMGPC7ResTLUT */
void J2DPicture::private_initiate(const ResTIMG* timg, const ResTLUT* tlut) {
if (mTextureNum != 0) {
return;
@@ -286,7 +267,6 @@ void J2DPicture::private_initiate(const ResTIMG* timg, const ResTLUT* tlut) {
}
}
/* 802FCE9C-802FCFF0 2F77DC 0154+00 3/3 0/0 0/0 .text initinfo__10J2DPictureFv */
void J2DPicture::initinfo() {
mKind = 'PIC1';
setTexCoord(NULL, BIND15, MIRROR0, false);
@@ -298,7 +278,6 @@ void J2DPicture::initinfo() {
}
/* 802FCFF0-802FD098 2F7930 00A8+00 1/0 3/3 0/0 .text __dt__10J2DPictureFv */
J2DPicture::~J2DPicture() {
for (int i = 0; i < 2; i++) {
if ((int)(field_0x109 & 1 << i) != 0) {
@@ -309,7 +288,6 @@ J2DPicture::~J2DPicture() {
delete mPalette;
}
/* 802FD098-802FD168 2F79D8 00D0+00 1/0 0/0 0/0 .text prepareTexture__10J2DPictureFUc */
bool J2DPicture::prepareTexture(u8 param_0) {
for (u8 i = 0; i < param_0; i++) {
if (i >= 2) {
@@ -329,8 +307,6 @@ bool J2DPicture::prepareTexture(u8 param_0) {
return 1;
}
/* 802FD168-802FD4B4 2F7AA8 034C+00 1/0 0/0 0/0 .text
* insert__10J2DPictureFPC7ResTIMGP10JUTPaletteUcf */
bool J2DPicture::insert(ResTIMG const* img, JUTPalette* palette, u8 param_2, f32 param_3) {
if (img == NULL || mTextureNum >= 2 || param_2 >= 2 || param_2 > mTextureNum) {
return false;
@@ -405,13 +381,11 @@ bool J2DPicture::insert(ResTIMG const* img, JUTPalette* palette, u8 param_2, f32
}
/* 802FD4B4-802FD524 2F7DF4 0070+00 1/0 0/0 0/0 .text insert__10J2DPictureFPCcP10JUTPaletteUcf */
bool J2DPicture::insert(char const* resName, JUTPalette* palette, u8 param_2, f32 param_3) {
void* resource = J2DScreen::getNameResource(resName);
return insert((ResTIMG*)resource, palette, param_2, param_3);
}
/* 802FD524-802FD6F4 2F7E64 01D0+00 1/0 0/0 0/0 .text insert__10J2DPictureFP10JUTTextureUcf */
bool J2DPicture::insert(JUTTexture* texture, u8 param_1, f32 param_2) {
if (texture == NULL || mTextureNum >= 2 || param_1 >= 2 || param_1 > mTextureNum) {
return false;
@@ -448,7 +422,6 @@ bool J2DPicture::insert(JUTTexture* texture, u8 param_1, f32 param_2) {
}
/* 802FD6F4-802FD814 2F8034 0120+00 1/0 0/0 0/0 .text remove__10J2DPictureFUc */
bool J2DPicture::remove(u8 param_0) {
if (mTextureNum <= param_0 || mTextureNum == 1) {
return false;
@@ -474,8 +447,6 @@ bool J2DPicture::remove(u8 param_0) {
return true;
}
/* 802FD814-802FD874 2F8154 0060+00 1/0 0/0 0/0 .text remove__10J2DPictureFP10JUTTexture
*/
bool J2DPicture::remove(JUTTexture* param_0) {
u8 i = 0;
for (; i < mTextureNum; i++) {
@@ -486,7 +457,6 @@ bool J2DPicture::remove(JUTTexture* param_0) {
return remove(i);
}
/* 802FD874-802FD964 2F81B4 00F0+00 1/0 0/0 0/0 .text changeTexture__10J2DPictureFPC7ResTIMGUc */
const ResTIMG* J2DPicture::changeTexture(ResTIMG const* img, u8 texIndex) {
if (texIndex > mTextureNum || 2 <= texIndex || img == NULL) {
return NULL;
@@ -510,8 +480,6 @@ const ResTIMG* J2DPicture::changeTexture(ResTIMG const* img, u8 texIndex) {
}
/* 802FD964-802FD9BC 2F82A4 0058+00 1/0 0/0 0/0 .text changeTexture__10J2DPictureFPCcUc
*/
const ResTIMG* J2DPicture::changeTexture(char const* resName, u8 param_1) {
void* resource = J2DScreen::getNameResource(resName);
return changeTexture((ResTIMG*)resource, param_1);
@@ -522,8 +490,6 @@ static bool dummy_weak_order(JUTTexture* tex) {
return picture->append(tex, 1.0f);
}
/* 802FD9BC-802FDAC8 2F82FC 010C+00 1/0 0/0 0/0 .text
* changeTexture__10J2DPictureFPC7ResTIMGUcP10JUTPalette */
const ResTIMG* J2DPicture::changeTexture(ResTIMG const* img, u8 texIndex, JUTPalette* palette) {
if (texIndex > mTextureNum || 2 <= texIndex || img == NULL) {
return NULL;
@@ -547,14 +513,11 @@ const ResTIMG* J2DPicture::changeTexture(ResTIMG const* img, u8 texIndex, JUTPal
}
/* 802FDAC8-802FDB28 2F8408 0060+00 1/0 0/0 0/0 .text
* changeTexture__10J2DPictureFPCcUcP10JUTPalette */
const ResTIMG* J2DPicture::changeTexture(char const* param_0, u8 param_1, JUTPalette* param_2) {
void* resource = J2DScreen::getNameResource(param_0);
return changeTexture((ResTIMG*)resource, param_1, param_2);
}
/* 802FDB28-802FDB90 2F8468 0068+00 1/0 1/0 0/0 .text drawSelf__10J2DPictureFff */
void J2DPicture::drawSelf(f32 param_0, f32 param_1) {
Mtx tmp;
MTXIdentity(tmp);
@@ -562,8 +525,6 @@ void J2DPicture::drawSelf(f32 param_0, f32 param_1) {
drawSelf(param_0, param_1, &tmp);
}
/* 802FDB90-802FDBFC 2F84D0 006C+00 1/0 0/0 0/0 .text drawSelf__10J2DPictureFffPA3_A4_f
*/
void J2DPicture::drawSelf(f32 param_0, f32 param_1, Mtx* param_2) {
if (mTexture[0] != NULL && mTextureNum != 0) {
drawFullSet(mGlobalBounds.i.x + param_0, mGlobalBounds.i.y + param_1,
@@ -571,7 +532,6 @@ void J2DPicture::drawSelf(f32 param_0, f32 param_1, Mtx* param_2) {
}
}
/* 802FDBFC-802FDC70 2F853C 0074+00 1/0 0/0 0/0 .text drawFullSet__10J2DPictureFffffPA3_A4_f */
void J2DPicture::drawFullSet(f32 param_0, f32 param_1, f32 param_2, f32 param_3, Mtx* param_4) {
if (mTexture[0] != NULL && mTextureNum != 0) {
drawTexCoord(mBounds.i.x, mBounds.i.y, param_2, param_3, field_0x10a[0].x, field_0x10a[0].y,
@@ -580,7 +540,6 @@ void J2DPicture::drawFullSet(f32 param_0, f32 param_1, f32 param_2, f32 param_3,
}
}
/* 802FDC70-802FDF88 2F85B0 0318+00 1/0 1/1 0/0 .text draw__10J2DPictureFffffbbb */
void J2DPicture::draw(f32 x, f32 y, f32 width, f32 height, bool mirrorX, bool mirrorY,
bool rotate90) {
if (isVisible() && mTextureNum != 0 && mTexture[0] != NULL) {
@@ -641,8 +600,6 @@ void J2DPicture::draw(f32 x, f32 y, f32 width, f32 height, bool mirrorX, bool mi
}
/* 802FDF88-802FE380 2F88C8 03F8+00 1/0 0/0 0/0 .text
* drawOut__10J2DPictureFRCQ29JGeometry8TBox2<f>RCQ29JGeometry8TBox2<f> */
void J2DPicture::drawOut(JGeometry::TBox2<f32> const& posBox,
JGeometry::TBox2<f32> const& texRect) {
if (isVisible() && mTextureNum != 0 && mTexture[0] != NULL) {
@@ -701,8 +658,6 @@ void J2DPicture::drawOut(JGeometry::TBox2<f32> const& posBox,
}
/* 802FE380-802FE5D0 2F8CC0 0250+00 1/0 0/0 0/0 .text
* drawTexCoord__10J2DPictureFffffssssssssPA3_A4_f */
void J2DPicture::drawTexCoord(f32 param_0, f32 param_1, f32 param_2, f32 param_3, s16 param_4,
s16 param_5, s16 param_6, s16 param_7, s16 param_8, s16 param_9,
s16 param_10, s16 param_11, Mtx* param_12) {
@@ -757,7 +712,6 @@ void J2DPicture::drawTexCoord(f32 param_0, f32 param_1, f32 param_2, f32 param_3
}
/* 802FE5D0-802FEA60 2F8F10 0490+00 3/3 0/0 0/0 .text setTevMode__10J2DPictureFv */
void J2DPicture::setTevMode() {
u8 i;
for (i = 0; i < mTextureNum; i++) {
@@ -842,31 +796,24 @@ void J2DPicture::setTevMode() {
}
}
/* 802FEA60-802FEA74 2F93A0 0014+00 1/1 0/0 0/0 .text swap__10J2DPictureFRfRf */
void J2DPicture::swap(f32& lhs, f32& rhs) {
f32 tmp = lhs;
lhs = rhs;
rhs = tmp;
}
/* 802FEA74-802FEA9C 2F93B4 0028+00 1/0 0/0 0/0 .text setBlendColorRatio__10J2DPictureFff
*/
void J2DPicture::setBlendColorRatio(f32 param_0, f32 param_1) {
field_0x11c[0] = param_0;
field_0x11c[1] = param_1;
setBlendKonstColor();
}
/* 802FEA9C-802FEAC4 2F93DC 0028+00 1/0 0/0 0/0 .text setBlendAlphaRatio__10J2DPictureFff
*/
void J2DPicture::setBlendAlphaRatio(f32 param_0, f32 param_1) {
field_0x124[0] = param_0;
field_0x124[1] = param_1;
setBlendKonstAlpha();
}
/* 802FEAC4-802FEB94 2F9404 00D0+00 4/4 0/0 0/0 .text setBlendKonstColor__10J2DPictureFv
*/
void J2DPicture::setBlendKonstColor() {
int uvar3 = 0;
for (u8 i = 1; i < mTextureNum; i++) {
@@ -884,8 +831,6 @@ void J2DPicture::setBlendKonstColor() {
mBlendKonstColor = uvar3;
}
/* 802FEB94-802FEC64 2F94D4 00D0+00 4/4 0/0 0/0 .text setBlendKonstAlpha__10J2DPictureFv
*/
void J2DPicture::setBlendKonstAlpha() {
int uvar3 = 0;
for (u8 i = 1; i < mTextureNum; i++) {
@@ -903,8 +848,6 @@ void J2DPicture::setBlendKonstAlpha() {
mBlendKonstAlpha = uvar3;
}
/* 802FEC64-802FED44 2F95A4 00E0+00 3/3 0/0 0/0 .text
* getNewColor__10J2DPictureFPQ28JUtility6TColor */
void J2DPicture::getNewColor(JUtility::TColor* param_0) {
param_0[0] = mCornerColor[0];
param_0[1] = mCornerColor[1];
@@ -919,15 +862,11 @@ void J2DPicture::getNewColor(JUtility::TColor* param_0) {
}
}
/* 802FED44-802FED84 2F9684 0040+00 4/4 0/0 0/0 .text
* setTexCoord__10J2DPictureFPC10JUTTexture10J2DBinding9J2DMirrorb */
void J2DPicture::setTexCoord(JUTTexture const* param_0, J2DBinding param_1, J2DMirror param_2,
bool param_3) {
setTexCoord(&field_0x10a[0], param_0, param_1, param_2, param_3);
}
/* 802FED84-802FF09C 2F96C4 0318+00 2/2 0/0 0/0 .text
* setTexCoord__10J2DPictureFPQ29JGeometry8TVec2<s>PC10JUTTexture10J2DBinding9J2DMirrorb */
void J2DPicture::setTexCoord(JGeometry::TVec2<s16>* param_0, JUTTexture const* param_1,
J2DBinding binding, J2DMirror mirror, bool rotate90) {
bool bindLeft;
@@ -1042,7 +981,6 @@ void J2DPicture::setTexCoord(JGeometry::TVec2<s16>* param_0, JUTTexture const* p
}
/* 802FF09C-802FF100 2F99DC 0064+00 1/0 0/0 0/0 .text isUsed__10J2DPictureFPC7ResTIMG */
bool J2DPicture::isUsed(ResTIMG const* param_0) {
for (u8 i = 0; i < mTextureNum; i++) {
if (mTexture[i] != NULL && mTexture[i]->getTexInfo() == param_0) {
@@ -1053,7 +991,6 @@ bool J2DPicture::isUsed(ResTIMG const* param_0) {
return J2DPane::isUsed(param_0);
}
/* 802FF100-802FF1D0 2F9A40 00D0+00 1/0 0/0 0/0 .text getUsableTlut__10J2DPictureFUc */
u8 J2DPicture::getUsableTlut(u8 param_0) {
u8 var_r8 = 0;
@@ -1084,7 +1021,6 @@ u8 J2DPicture::getUsableTlut(u8 param_0) {
return var_r26;
}
/* 802FF1D0-802FF204 2F9B10 0034+00 1/1 1/1 0/0 .text getTlutID__10J2DPictureFPC7ResTIMGUc */
GXTlut J2DPicture::getTlutID(ResTIMG const* img, u8 param_1) {
if (img->numColors > 256) {
return (GXTlut)((param_1 % 4) + 0x10);
-115
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J2DPictureEx
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J2DGraph/J2DPictureEx.h"
@@ -12,8 +7,6 @@
#include "JSystem/JUtility/JUTTexture.h"
#include "dolphin/types.h"
/* 80303640-803036EC 2FDF80 00AC+00 1/0 0/0 0/0 .text
* initiate__12J2DPictureExFPC7ResTIMGPC7ResTLUT */
void J2DPictureEx::initiate(ResTIMG const* param_0, ResTLUT const* param_1) {
J2DTexGenBlock* this_00 = mMaterial->getTexGenBlock();
if (this_00->getTexGenNum() == 0 && append(param_0, 1.0f) && param_1 != NULL) {
@@ -23,8 +16,6 @@ void J2DPictureEx::initiate(ResTIMG const* param_0, ResTLUT const* param_1) {
}
}
/* 803036EC-8030393C 2FE02C 0250+00 0/0 1/1 0/0 .text
* __ct__12J2DPictureExFP7J2DPaneP20JSURandomInputStreamUlP11J2DMaterial */
J2DPictureEx::J2DPictureEx(J2DPane* param_0, JSURandomInputStream* param_1, u32 param_2,
J2DMaterial* param_3) {
field_0x194 = 0;
@@ -68,15 +59,12 @@ J2DPictureEx::J2DPictureEx(J2DPane* param_0, JSURandomInputStream* param_1, u32
}
}
/* 8030393C-803039CC 2FE27C 0090+00 1/0 0/0 0/0 .text __dt__12J2DPictureExFv */
J2DPictureEx::~J2DPictureEx() {
if (field_0x190) {
delete mMaterial;
}
}
/* 803039CC-80303AB4 2FE30C 00E8+00 1/0 0/0 0/0 .text prepareTexture__12J2DPictureExFUc
*/
bool J2DPictureEx::prepareTexture(u8 param_0) {
if (!mMaterial->getTevBlock()->prepareTexture(param_0)) {
return false;
@@ -89,8 +77,6 @@ bool J2DPictureEx::prepareTexture(u8 param_0) {
return true;
}
/* 80303AB4-80303B80 2FE3F4 00CC+00 1/0 0/0 0/0 .text drawSelf__12J2DPictureExFffPA3_A4_f
*/
void J2DPictureEx::drawSelf(f32 param_0, f32 param_1, f32 (*param_2)[3][4]) {
if (mMaterial != NULL) {
mMaterial->setGX();
@@ -102,7 +88,6 @@ void J2DPictureEx::drawSelf(f32 param_0, f32 param_1, f32 (*param_2)[3][4]) {
}
}
/* 80303B80-80303BDC 2FE4C0 005C+00 1/0 0/0 0/0 .text drawFullSet__12J2DPictureExFffffPA3_A4_f */
void J2DPictureEx::drawFullSet(f32 param_0, f32 param_1, f32 param_2, f32 param_3,
f32 (*param_4)[3][4]) {
drawTexCoord(mBounds.i.x, mBounds.i.y, param_2, param_3, field_0x10a[0].x, field_0x10a[0].y,
@@ -110,8 +95,6 @@ void J2DPictureEx::drawFullSet(f32 param_0, f32 param_1, f32 param_2, f32 param_
field_0x10a[3].x, field_0x10a[3].y, param_4);
}
/* 80303BDC-80303E5C 2FE51C 0280+00 1/0 0/0 0/0 .text
* drawTexCoord__12J2DPictureExFffffssssssssPA3_A4_f */
void J2DPictureEx::drawTexCoord(f32 param_0, f32 param_1, f32 param_2, f32 param_3, s16 param_4,
s16 param_5, s16 param_6, s16 param_7, s16 param_8, s16 param_9,
s16 param_10, s16 param_11, f32 (*param_12)[3][4]) {
@@ -159,8 +142,6 @@ void J2DPictureEx::drawTexCoord(f32 param_0, f32 param_1, f32 param_2, f32 param
}
/* 80303E5C-80303EA4 2FE79C 0048+00 1/0 0/0 0/0 .text
* append__12J2DPictureExFPC7ResTIMGP10JUTPalettef */
bool J2DPictureEx::append(ResTIMG const* param_0, JUTPalette* param_1, f32 param_2) {
if (mMaterial == NULL) {
return false;
@@ -169,7 +150,6 @@ bool J2DPictureEx::append(ResTIMG const* param_0, JUTPalette* param_1, f32 param
return insert(param_0, param_1, mMaterial->getTexGenBlock()->getTexGenNum(), param_2);
}
/* 80303EA4-80303EEC 2FE7E4 0048+00 1/0 0/0 0/0 .text append__12J2DPictureExFPCcP10JUTPalettef */
bool J2DPictureEx::append(char const* param_0, JUTPalette* param_1, f32 param_2) {
if (mMaterial == NULL) {
return false;
@@ -178,7 +158,6 @@ bool J2DPictureEx::append(char const* param_0, JUTPalette* param_1, f32 param_2)
return insert(param_0, param_1, mMaterial->getTexGenBlock()->getTexGenNum(), param_2);
}
/* 80303EEC-80303F34 2FE82C 0048+00 1/0 0/0 0/0 .text append__12J2DPictureExFP10JUTTexturef */
bool J2DPictureEx::append(JUTTexture* param_0, f32 param_1) {
if (mMaterial == NULL) {
return false;
@@ -187,8 +166,6 @@ bool J2DPictureEx::append(JUTTexture* param_0, f32 param_1) {
return insert(param_0, mMaterial->getTexGenBlock()->getTexGenNum(), param_1);
}
/* 80303F34-80303FD8 2FE874 00A4+00 1/0 0/0 0/0 .text
* insert__12J2DPictureExFPC7ResTIMGP10JUTPaletteUcf */
bool J2DPictureEx::insert(ResTIMG const* param_0, JUTPalette* param_1, u8 param_2,
f32 param_3) {
if (param_0 == NULL) {
@@ -204,14 +181,11 @@ bool J2DPictureEx::insert(ResTIMG const* param_0, JUTPalette* param_1, u8 param_
return true;
}
/* 80303FD8-80304048 2FE918 0070+00 1/0 0/0 0/0 .text insert__12J2DPictureExFPCcP10JUTPaletteUcf
*/
bool J2DPictureEx::insert(char const* param_0, JUTPalette* param_1, u8 param_2, f32 param_3) {
ResTIMG const* resource = (ResTIMG const*)J2DScreen::getNameResource(param_0);
return insert(resource, param_1, param_2, param_3);
}
/* 80304048-803040E4 2FE988 009C+00 1/0 0/0 0/0 .text insert__12J2DPictureExFP10JUTTextureUcf */
bool J2DPictureEx::insert(JUTTexture* param_0, u8 param_1, f32 param_2) {
if (param_0 == NULL) {
return false;
@@ -226,7 +200,6 @@ bool J2DPictureEx::insert(JUTTexture* param_0, u8 param_1, f32 param_2) {
return true;
}
/* 803040E4-8030437C 2FEA24 0298+00 2/2 0/0 0/0 .text insertCommon__12J2DPictureExFUcf */
void J2DPictureEx::insertCommon(u8 pos, f32 param_1) {
u8 new_tev_stage_num;
u8 tex_gen_num = mMaterial->getTexGenBlock()->getTexGenNum();
@@ -275,7 +248,6 @@ void J2DPictureEx::insertCommon(u8 pos, f32 param_1) {
setTevKAlphaSel(tex_gen_num);
}
/* 8030437C-8030446C 2FECBC 00F0+00 2/2 0/0 0/0 .text isInsert__12J2DPictureExCFUc */
bool J2DPictureEx::isInsert(u8 pos) const {
if (mMaterial == NULL) {
return false;
@@ -300,7 +272,6 @@ bool J2DPictureEx::isInsert(u8 pos) const {
return true;
}
/* 8030446C-80304608 2FEDAC 019C+00 1/0 0/0 0/0 .text remove__12J2DPictureExFUc */
bool J2DPictureEx::remove(u8 pos) {
if (!isRemove(pos)) {
return false;
@@ -332,7 +303,6 @@ bool J2DPictureEx::remove(u8 pos) {
return true;
}
/* 80304608-8030466C 2FEF48 0064+00 1/0 0/0 0/0 .text remove__12J2DPictureExFv */
bool J2DPictureEx::remove() {
if (mMaterial == NULL) {
return false;
@@ -346,7 +316,6 @@ bool J2DPictureEx::remove() {
return remove(texGenNum - 1);
}
/* 8030466C-80304728 2FEFAC 00BC+00 1/0 0/0 0/0 .text remove__12J2DPictureExFP10JUTTexture */
bool J2DPictureEx::remove(JUTTexture* param_0) {
if (mMaterial == NULL) {
return false;
@@ -365,7 +334,6 @@ bool J2DPictureEx::remove(JUTTexture* param_0) {
return remove(i);
}
/* 80304728-8030477C 2FF068 0054+00 1/1 0/0 0/0 .text isRemove__12J2DPictureExCFUc */
bool J2DPictureEx::isRemove(u8 param_0) const {
if (mMaterial == NULL) {
return false;
@@ -382,7 +350,6 @@ bool J2DPictureEx::isRemove(u8 param_0) const {
return true;
}
/* 8030477C-80304890 2FF0BC 0114+00 1/0 0/0 0/0 .text draw__12J2DPictureExFffUcbbb */
void J2DPictureEx::draw(f32 param_0, f32 param_1, u8 texNo, bool param_3, bool param_4,
bool param_5) {
if (mMaterial == NULL) {
@@ -408,7 +375,6 @@ void J2DPictureEx::draw(f32 param_0, f32 param_1, u8 texNo, bool param_3, bool p
}
}
/* 80304890-80304D88 2FF1D0 04F8+00 1/0 0/0 0/0 .text draw__12J2DPictureExFffffbbb */
void J2DPictureEx::draw(f32 param_0, f32 param_1, f32 width, f32 height, bool param_4,
bool param_5, bool param_6) {
if (!isVisible()) {
@@ -510,7 +476,6 @@ void J2DPictureEx::draw(f32 param_0, f32 param_1, f32 width, f32 height, bool pa
GXSetVtxDesc(GX_VA_TEX0, GX_NONE);
}
/* 80304D88-80304EF0 2FF6C8 0168+00 1/0 0/0 0/0 .text drawOut__12J2DPictureExFffffff */
void J2DPictureEx::drawOut(f32 param_0, f32 param_1, f32 param_2, f32 param_3, f32 param_4,
f32 param_5) {
if (mMaterial == NULL) {
@@ -533,8 +498,6 @@ void J2DPictureEx::drawOut(f32 param_0, f32 param_1, f32 param_2, f32 param_3, f
}
}
/* 80304EF0-80305264 2FF830 0374+00 1/0 0/0 0/0 .text
* drawOut__12J2DPictureExFRCQ29JGeometry8TBox2<f>RCQ29JGeometry8TBox2<f> */
void J2DPictureEx::drawOut(JGeometry::TBox2<f32> const& param_0,
JGeometry::TBox2<f32> const& param_1) {
if (mMaterial == NULL) {
@@ -610,7 +573,6 @@ void J2DPictureEx::drawOut(JGeometry::TBox2<f32> const& param_0,
GXSetVtxDesc(GX_VA_TEX0, GX_NONE);
}
/* 80305264-803052AC 2FFBA4 0048+00 1/0 0/0 0/0 .text load__12J2DPictureExF11_GXTexMapIDUc */
void J2DPictureEx::load(_GXTexMapID param_0, u8 param_1) {
if (mMaterial == NULL) {
return;
@@ -623,8 +585,6 @@ void J2DPictureEx::load(_GXTexMapID param_0, u8 param_1) {
mMaterial->getTevBlock()->loadTexture(param_0, param_1);
}
/* 803052AC-803053E0 2FFBEC 0134+00 3/3 0/0 0/0 .text setTevOrder__12J2DPictureExFUcUcb
*/
void J2DPictureEx::setTevOrder(u8 param_0, u8 param_1, bool param_2) {
u16 local_30[16];
if (param_0 == 1) {
@@ -655,8 +615,6 @@ void J2DPictureEx::setTevOrder(u8 param_0, u8 param_1, bool param_2) {
}
}
/* 803053E0-80305688 2FFD20 02A8+00 3/3 0/0 0/0 .text setTevStage__12J2DPictureExFUcUcb
*/
void J2DPictureEx::setTevStage(u8 param_0, u8 param_1, bool param_2) {
if (param_0 == 1) {
J2DTevStage* stage = mMaterial->getTevBlock()->getTevStage(0);
@@ -698,8 +656,6 @@ void J2DPictureEx::setTevStage(u8 param_0, u8 param_1, bool param_2) {
}
}
/* 80305688-80305928 2FFFC8 02A0+00 1/1 0/0 0/0 .text
* setStage__12J2DPictureExFP11J2DTevStageQ212J2DPictureEx10stage_enum */
void J2DPictureEx::setStage(J2DTevStage* stage, J2DPictureEx::stage_enum idx) {
s8 colorData[8][4] = {
{0x0F, 0x08, 0x0A, 0x0F},
@@ -739,7 +695,6 @@ void J2DPictureEx::setStage(J2DTevStage* stage, J2DPictureEx::stage_enum idx) {
stage->setTevAlphaOp(opData[idx][0], opData[idx][1], opData[idx][2], opData[idx][3], opData[idx][4]);
}
/* 80305928-80305C70 300268 0348+00 5/5 0/0 0/0 .text setTevKColor__12J2DPictureExFUc */
void J2DPictureEx::setTevKColor(u8 param_0) {
if (param_0 == 1) {
return;
@@ -793,8 +748,6 @@ void J2DPictureEx::setTevKColor(u8 param_0) {
}
}
/* 80305C70-80305D18 3005B0 00A8+00 3/3 0/0 0/0 .text setTevKColorSel__12J2DPictureExFUc
*/
void J2DPictureEx::setTevKColorSel(u8 param_0) {
for (u8 i = 0; i < param_0; i++) {
if (i < 4) {
@@ -805,8 +758,6 @@ void J2DPictureEx::setTevKColorSel(u8 param_0) {
}
}
/* 80305D18-80305DC0 300658 00A8+00 3/3 0/0 0/0 .text setTevKAlphaSel__12J2DPictureExFUc
*/
void J2DPictureEx::setTevKAlphaSel(u8 param_0) {
for (u8 i = 0; i < param_0; i++) {
if (i < 4) {
@@ -817,7 +768,6 @@ void J2DPictureEx::setTevKAlphaSel(u8 param_0) {
}
}
/* 80305DC0-80305ED4 300700 0114+00 2/2 0/0 0/0 .text shiftSetBlendRatio__12J2DPictureExFUcfbb */
void J2DPictureEx::shiftSetBlendRatio(u8 param_0, f32 param_1, bool param_2, bool param_3) {
f32* pJVar4 = param_2 != 0 ? field_0x11c : field_0x124;
f32* local_44 = param_2 != 0 ? field_0x160 : field_0x178;
@@ -850,7 +800,6 @@ void J2DPictureEx::shiftSetBlendRatio(u8 param_0, f32 param_1, bool param_2, boo
}
}
/* 80305ED4-80305F34 300814 0060+00 1/0 0/0 0/0 .text setBlendColorRatio__12J2DPictureExFff */
void J2DPictureEx::setBlendColorRatio(f32 param_0, f32 param_1) {
if (mMaterial == NULL) {
return;
@@ -867,7 +816,6 @@ void J2DPictureEx::setBlendColorRatio(f32 param_0, f32 param_1) {
}
/* 80305F34-80305F94 300874 0060+00 1/0 0/0 0/0 .text setBlendAlphaRatio__12J2DPictureExFff */
void J2DPictureEx::setBlendAlphaRatio(f32 param_0, f32 param_1) {
if (mMaterial == NULL) {
return;
@@ -884,8 +832,6 @@ void J2DPictureEx::setBlendAlphaRatio(f32 param_0, f32 param_1) {
}
/* 80305F94-803060DC 3008D4 0148+00 1/0 0/0 0/0 .text changeTexture__12J2DPictureExFPC7ResTIMGUc
*/
const ResTIMG* J2DPictureEx::changeTexture(ResTIMG const* img, u8 param_1) {
if (mMaterial == NULL || img == NULL) {
return NULL;
@@ -915,15 +861,11 @@ const ResTIMG* J2DPictureEx::changeTexture(ResTIMG const* img, u8 param_1) {
return NULL;
}
/* 803060DC-80306134 300A1C 0058+00 1/0 0/0 0/0 .text changeTexture__12J2DPictureExFPCcUc
*/
const ResTIMG* J2DPictureEx::changeTexture(char const* param_0, u8 param_1) {
ResTIMG const* resource = (ResTIMG const*)J2DScreen::getNameResource(param_0);
return changeTexture(resource, param_1);
}
/* 80306134-80306298 300A74 0164+00 1/0 0/0 0/0 .text
* changeTexture__12J2DPictureExFPC7ResTIMGUcP10JUTPalette */
const ResTIMG* J2DPictureEx::changeTexture(ResTIMG const* param_0, u8 param_1, JUTPalette* param_2) {
if (mMaterial == NULL || param_0 == NULL) {
return NULL;
@@ -951,14 +893,11 @@ const ResTIMG* J2DPictureEx::changeTexture(ResTIMG const* param_0, u8 param_1, J
return NULL;
}
/* 80306298-803062F8 300BD8 0060+00 1/0 0/0 0/0 .text
* changeTexture__12J2DPictureExFPCcUcP10JUTPalette */
const ResTIMG* J2DPictureEx::changeTexture(char const* param_0, u8 param_1, JUTPalette* param_2) {
ResTIMG const* resource = (ResTIMG const*)J2DScreen::getNameResource(param_0);
return changeTexture(resource, param_1, param_2);
}
/* 803062F8-80306350 300C38 0058+00 1/0 0/0 0/0 .text getTexture__12J2DPictureExCFUc */
JUTTexture* J2DPictureEx::getTexture(u8 param_0) const {
if (mMaterial == NULL) {
return NULL;
@@ -971,8 +910,6 @@ JUTTexture* J2DPictureEx::getTexture(u8 param_0) const {
return mMaterial->getTevBlock()->getTexture(param_0);
}
/* 80306350-80306370 300C90 0020+00 1/0 0/0 0/0 .text getTextureCount__12J2DPictureExCFv
*/
u8 J2DPictureEx::getTextureCount() const {
if (mMaterial == NULL) {
return NULL;
@@ -981,8 +918,6 @@ u8 J2DPictureEx::getTextureCount() const {
return mMaterial->getTexGenBlock()->getTexGenNum();
}
/* 80306370-803063F8 300CB0 0088+00 1/0 0/0 0/0 .text setBlack__12J2DPictureExFQ28JUtility6TColor
*/
bool J2DPictureEx::setBlack(JUtility::TColor param_0) {
JUtility::TColor black, white;
if (!getBlackWhite(&black, &white)) {
@@ -992,8 +927,6 @@ bool J2DPictureEx::setBlack(JUtility::TColor param_0) {
return setBlackWhite(param_0, white);
}
/* 803063F8-80306480 300D38 0088+00 1/0 0/0 0/0 .text setWhite__12J2DPictureExFQ28JUtility6TColor
*/
bool J2DPictureEx::setWhite(JUtility::TColor param_0) {
JUtility::TColor black, white;
if (!getBlackWhite(&black, &white)) {
@@ -1003,8 +936,6 @@ bool J2DPictureEx::setWhite(JUtility::TColor param_0) {
return setBlackWhite(black, param_0);
}
/* 80306480-80306664 300DC0 01E4+00 1/0 0/0 0/0 .text
* setBlackWhite__12J2DPictureExFQ28JUtility6TColorQ28JUtility6TColor */
bool J2DPictureEx::setBlackWhite(JUtility::TColor param_0, JUtility::TColor param_1) {
if (mMaterial == NULL) {
return false;
@@ -1052,8 +983,6 @@ bool J2DPictureEx::setBlackWhite(JUtility::TColor param_0, JUtility::TColor para
return true;
}
/* 80306664-80306824 300FA4 01C0+00 4/4 0/0 0/0 .text
* getBlackWhite__12J2DPictureExCFPQ28JUtility6TColorPQ28JUtility6TColor */
bool J2DPictureEx::getBlackWhite(JUtility::TColor* black, JUtility::TColor* white) const {
// FAKEMATCH
if (mMaterial == NULL) {
@@ -1092,8 +1021,6 @@ bool J2DPictureEx::getBlackWhite(JUtility::TColor* black, JUtility::TColor* whit
return true;
}
/* 80306824-803068F8 301164 00D4+00 1/1 0/0 0/0 .text
* isSetBlackWhite__12J2DPictureExCFQ28JUtility6TColorQ28JUtility6TColor */
bool J2DPictureEx::isSetBlackWhite(JUtility::TColor black, JUtility::TColor white) const {
if (black == 0x00000000 && white == 0xffffffff) {
return true;
@@ -1115,7 +1042,6 @@ bool J2DPictureEx::isSetBlackWhite(JUtility::TColor black, JUtility::TColor whit
return tmp <= max_tev_stage;
}
/* 803068F8-80306958 301238 0060+00 1/0 0/0 0/0 .text getBlack__12J2DPictureExCFv */
JUtility::TColor J2DPictureEx::getBlack() const {
JUtility::TColor black, white;
if (!getBlackWhite(&black, &white)) {
@@ -1125,7 +1051,6 @@ JUtility::TColor J2DPictureEx::getBlack() const {
}
}
/* 80306958-803069B8 301298 0060+00 1/0 0/0 0/0 .text getWhite__12J2DPictureExCFv */
JUtility::TColor J2DPictureEx::getWhite() const {
JUtility::TColor black, white;
if (!getBlackWhite(&black, &white)) {
@@ -1135,7 +1060,6 @@ JUtility::TColor J2DPictureEx::getWhite() const {
}
}
/* 803069B8-803069D8 3012F8 0020+00 1/0 0/0 0/0 .text setAlpha__12J2DPictureExFUc */
void J2DPictureEx::setAlpha(u8 alpha) {
mAlpha = alpha;
if (mMaterial != NULL && mMaterial->getColorBlock()->getMatColor(0) != NULL) {
@@ -1143,7 +1067,6 @@ void J2DPictureEx::setAlpha(u8 alpha) {
}
}
/* 803069D8-80306A0C 301318 0034+00 1/0 0/0 0/0 .text setCullBack__12J2DPictureExF11_GXCullMode */
void J2DPictureEx::setCullBack(GXCullMode cullMode) {
mCullMode = cullMode;
if (mMaterial != NULL) {
@@ -1152,15 +1075,12 @@ void J2DPictureEx::setCullBack(GXCullMode cullMode) {
J2DPane::setCullBack(cullMode);
}
/* 80306A0C-80306A24 30134C 0018+00 1/0 0/0 0/0 .text rewriteAlpha__12J2DPictureExFv */
void J2DPictureEx::rewriteAlpha() {
if (mMaterial != NULL) {
mAlpha = mMaterial->getColorBlock()->getMatColor(0)->a;
}
}
/* 80306A24-80306AC4 301364 00A0+00 1/0 0/0 0/0 .text isUsed__12J2DPictureExFPC7ResTIMG
*/
bool J2DPictureEx::isUsed(ResTIMG const* texInfo) {
if (mMaterial != NULL && mMaterial->getTevBlock() != NULL) {
for (u32 i = 0; i < 8; i++) {
@@ -1173,46 +1093,34 @@ bool J2DPictureEx::isUsed(ResTIMG const* texInfo) {
return J2DPane::isUsed(texInfo);
}
/* 80306AC4-80306AF0 301404 002C+00 1/0 0/0 0/0 .text setAnimation__12J2DPictureExFP11J2DAnmColor
*/
void J2DPictureEx::setAnimation(J2DAnmColor* anm) {
if (mMaterial != NULL) {
mMaterial->setAnimation(anm);
}
}
/* 80306AF0-80306B1C 301430 002C+00 1/0 0/0 0/0 .text
* setAnimation__12J2DPictureExFP19J2DAnmTextureSRTKey */
void J2DPictureEx::setAnimation(J2DAnmTextureSRTKey* anm) {
if (mMaterial != NULL) {
mMaterial->setAnimation(anm);
}
}
/* 80306B1C-80306B48 30145C 002C+00 1/0 0/0 0/0 .text
* setAnimation__12J2DPictureExFP16J2DAnmTexPattern */
void J2DPictureEx::setAnimation(J2DAnmTexPattern* anm) {
if (mMaterial != NULL) {
mMaterial->setAnimation(anm);
}
}
/* 80306B48-80306B74 301488 002C+00 1/0 0/0 0/0 .text
* setAnimation__12J2DPictureExFP15J2DAnmTevRegKey */
void J2DPictureEx::setAnimation(J2DAnmTevRegKey* anm) {
if (mMaterial != NULL) {
mMaterial->setAnimation(anm);
}
}
/* 80306B74-80306B7C -00001 0008+00 0/0 0/0 0/0 .text
* setAnimation__12J2DPictureExFP20J2DAnmVisibilityFull */
void J2DPictureEx::setAnimation(J2DAnmVisibilityFull* anm) {
field_0x194 = anm;
}
/* 80306B7C-80306C70 3014BC 00F4+00 1/0 0/0 0/0 .text
* setAnimation__12J2DPictureExFP14J2DAnmVtxColor */
void J2DPictureEx::setAnimation(J2DAnmVtxColor* anm) {
field_0x198 = anm;
field_0x19c = 0;
@@ -1248,8 +1156,6 @@ void J2DPictureEx::setAnimation(J2DAnmVtxColor* anm) {
}
}
/* 80306C70-80306DC8 3015B0 0158+00 1/0 0/0 0/0 .text
* animationPane__12J2DPictureExFPC15J2DAnmTransform */
const J2DAnmTransform* J2DPictureEx::animationPane(J2DAnmTransform const* anm) {
if (field_0x194 != NULL && field_0x154 != 0xffff) {
u8 tmp;
@@ -1283,7 +1189,6 @@ const J2DAnmTransform* J2DPictureEx::animationPane(J2DAnmTransform const* anm) {
return J2DPane::animationPane(anm);
}
/* 80306DC8-80306ED4 301708 010C+00 1/0 0/0 0/0 .text getUsableTlut__12J2DPictureExFUc */
u8 J2DPictureEx::getUsableTlut(u8 param_0) {
u32 tex_gen_num = mMaterial->getTexGenBlock()->getTexGenNum();
u8 usedTluts = 0;
@@ -1311,84 +1216,64 @@ u8 J2DPictureEx::getUsableTlut(u8 param_0) {
return 0;
}
/* 80306ED4-80306F04 301814 0030+00 1/0 0/0 0/0 .text append__12J2DPictureExFPC7ResTIMGf
*/
bool J2DPictureEx::append(ResTIMG const* param_0, f32 param_1) {
return append(param_0, NULL, param_1);
}
/* 80306F04-80306F34 301844 0030+00 1/0 0/0 0/0 .text append__12J2DPictureExFPCcf */
bool J2DPictureEx::append(char const* param_0, f32 param_1) {
return append(param_0, NULL, param_1);
}
/* 80306F34-80306F64 301874 0030+00 1/0 0/0 0/0 .text prepend__12J2DPictureExFP10JUTTexturef */
void J2DPictureEx::prepend(JUTTexture* param_0, f32 param_1) {
insert(param_0, 0, param_1);
}
/* 80306F64-80306F94 3018A4 0030+00 1/0 0/0 0/0 .text prepend__12J2DPictureExFPCcP10JUTPalettef */
void J2DPictureEx::prepend(char const* param_0, JUTPalette* param_1, f32 param_2) {
insert(param_0, param_1, 0, param_2);
}
/* 80306F94-80306FC4 3018D4 0030+00 1/0 0/0 0/0 .text prepend__12J2DPictureExFPCcf */
void J2DPictureEx::prepend(char const* param_0, f32 param_1) {
insert(param_0, 0, param_1);
}
/* 80306FC4-80306FF4 301904 0030+00 1/0 0/0 0/0 .text
* prepend__12J2DPictureExFPC7ResTIMGP10JUTPalettef */
void J2DPictureEx::prepend(ResTIMG const* param_0, JUTPalette* param_1, f32 param_2) {
insert(param_0, param_1, 0, param_2);
}
/* 80306FF4-80307024 301934 0030+00 1/0 0/0 0/0 .text prepend__12J2DPictureExFPC7ResTIMGf
*/
void J2DPictureEx::prepend(ResTIMG const* param_0, f32 param_1) {
insert(param_0, 0, param_1);
}
/* 80307024-80307058 301964 0034+00 1/0 0/0 0/0 .text insert__12J2DPictureExFPCcUcf */
bool J2DPictureEx::insert(char const* param_0, u8 param_1, f32 param_2) {
return insert(param_0, NULL, param_1, param_2);
}
/* 80307058-8030708C 301998 0034+00 1/0 0/0 0/0 .text insert__12J2DPictureExFPC7ResTIMGUcf */
bool J2DPictureEx::insert(ResTIMG const* param_0, u8 param_1, f32 param_2) {
return insert(param_0, NULL, param_1, param_2);
}
/* 8030708C-803070D0 3019CC 0044+00 1/0 0/0 0/0 .text draw__12J2DPictureExFffbbb */
void J2DPictureEx::draw(f32 param_0, f32 param_1, bool param_2, bool param_3, bool param_4) {
return draw(param_0, param_1, 0, param_2, param_3, param_4);
}
/* 803070D0-80307134 301A10 0064+00 1/0 0/0 0/0 .text drawOut__12J2DPictureExFffffffff */
void J2DPictureEx::drawOut(f32 param_0, f32 param_1, f32 param_2, f32 param_3, f32 param_4,
f32 param_5, f32 param_6, f32 param_7) {
drawOut(JGeometry::TBox2<f32>(param_0, param_1, param_0 + param_2, param_1 + param_3),
JGeometry::TBox2<f32>(param_4, param_5, param_4 + param_6, param_5 + param_7));
}
/* 80307134-80307168 301A74 0034+00 1/0 0/0 0/0 .text load__12J2DPictureExFUc */
void J2DPictureEx::load(u8 param_0) {
load((GXTexMapID)param_0, param_0);
}
/* 80307168-803071A4 301AA8 003C+00 1/0 0/0 0/0 .text setCullBack__12J2DPictureExFb */
void J2DPictureEx::setCullBack(bool param_0) {
setCullBack(param_0 ? GX_CULL_BACK : GX_CULL_NONE);
}
/* 803071A4-803071C4 301AE4 0020+00 1/0 0/0 0/0 .text isUsed__12J2DPictureExFPC7ResFONT
*/
bool J2DPictureEx::isUsed(ResFONT const* param_0) {
return J2DPane::isUsed(param_0);
}
/* 803071C4-803071E4 301B04 0020+00 1/0 0/0 0/0 .text setAnimation__12J2DPictureExFP10J2DAnmBase
*/
void J2DPictureEx::setAnimation(J2DAnmBase* param_0) {
J2DPane::setAnimation(param_0);
}
-19
View File
@@ -6,19 +6,14 @@
#include <stdio.h>
#include <stdlib.h>
/* 80451580-80451584 000A80 0004+00 3/3 0/0 0/0 .sbss mStrBuff__8J2DPrint */
char* J2DPrint::mStrBuff;
/* 80451584-80451588 000A84 0004+00 1/1 0/0 0/0 .sbss None */
static bool sStrBufInitialized;
/* 80451588-8045158C 000A88 0004+00 3/3 0/0 0/0 .sbss mStrBuffSize__8J2DPrint */
size_t J2DPrint::mStrBuffSize;
/* 8045158C-80451590 000A8C 0004+00 2/2 0/0 0/0 .sbss None */
static u8 data_8045158C[4];
/* 802F42F0-802F4394 2EEC30 00A4+00 1/1 0/0 0/0 .text J2DPrint_print_alpha_va */
f32 J2DPrint_print_alpha_va(J2DPrint* pPrint, u8 alpha, const char* fmt, va_list args) {
pPrint->initchar();
s32 length = vsnprintf(J2DPrint::mStrBuff, J2DPrint::mStrBuffSize, fmt, args);
@@ -47,7 +42,6 @@ J2DPrint::J2DPrint(JUTFont* pFont, f32 charSpacing, f32 lineSpacing, JUtility::T
private_initiate(pFont, charSpacing, lineSpacing, charColor, gradColor, blackColor, whiteColor, false);
}
/* 802F4420-802F4468 2EED60 0048+00 1/0 6/6 0/0 .text __dt__8J2DPrintFv */
J2DPrint::~J2DPrint() {}
void J2DPrint::initiate() {
@@ -96,7 +90,6 @@ void J2DPrint::private_initiate(JUTFont* pFont, f32 charSpacing, f32 lineSpacing
initchar();
}
/* 802F4658-802F46C4 2EEF98 006C+00 1/1 1/1 0/0 .text setBuffer__8J2DPrintFUl */
u8* J2DPrint::setBuffer(size_t size) {
JUT_ASSERT(335, size > 0);
@@ -111,7 +104,6 @@ u8* J2DPrint::setBuffer(size_t size) {
return u8Buff;
}
/* 802F46C4-802F475C 2EF004 0098+00 1/1 0/0 0/0 .text setFontSize__8J2DPrintFv */
void J2DPrint::setFontSize() {
if (mFont != NULL) {
mFontSizeX = mFont->getCellWidth();
@@ -119,7 +111,6 @@ void J2DPrint::setFontSize() {
}
}
/* 802F475C-802F4778 2EF09C 001C+00 2/2 2/2 0/0 .text locate__8J2DPrintFff */
void J2DPrint::locate(f32 cursorH, f32 cursorV) {
field_0x24 = cursorH;
field_0x28 = cursorV;
@@ -128,7 +119,6 @@ void J2DPrint::locate(f32 cursorH, f32 cursorV) {
field_0x34 = 0.0f;
}
/* 802F4778-802F4828 2EF0B8 00B0+00 0/0 2/2 0/0 .text print__8J2DPrintFffUcPCce */
f32 J2DPrint::print(f32 cursorH, f32 cursorV, u8 alpha, char const* fmt, ...) {
locate(cursorH, cursorV);
@@ -140,8 +130,6 @@ f32 J2DPrint::print(f32 cursorH, f32 cursorV, u8 alpha, char const* fmt, ...) {
return var_f31;
}
/* 802F4828-802F4B4C 2EF168 0324+00 0/0 4/4 0/0 .text
* printReturn__8J2DPrintFPCcff18J2DTextBoxHBinding18J2DTextBoxVBindingffUc */
void J2DPrint::printReturn(char const* pString, f32 param_1, f32 param_2,
J2DTextBoxHBinding hBind, J2DTextBoxVBinding vBind, f32 param_5,
f32 param_6, u8 alpha) {
@@ -200,8 +188,6 @@ void J2DPrint::printReturn(char const* pString, f32 param_1, f32 param_2,
}
}
/* 802F4B4C-802F52E8 2EF48C 079C+00 2/2 0/0 0/0 .text
* parse__8J2DPrintFPCUciiPUsRQ28J2DPrint5TSizeUcb */
f32 J2DPrint::parse(const u8* pString, int length, int param_2, u16* param_3,
TSize& size, u8 alpha, bool param_6) {
if (mFont == NULL) {
@@ -387,7 +373,6 @@ f32 J2DPrint::parse(const u8* pString, int length, int param_2, u16* param_3,
return local_a8 - prevCursorV;
}
/* 802F52E8-802F5410 2EFC28 0128+00 2/1 0/0 0/0 .text doCtrlCode__8J2DPrintFi */
void J2DPrint::doCtrlCode(int iCharacter) {
switch (iCharacter) {
case '\b':
@@ -424,7 +409,6 @@ void J2DPrint::doCtrlCode(int iCharacter) {
}
}
/* 802F5410-802F594C 2EFD50 053C+00 1/1 0/0 0/0 .text doEscapeCode__8J2DPrintFPPCUcUc */
u16 J2DPrint::doEscapeCode(const u8** ppu8String, u8 alpha) {
const u8* pStringStart = *ppu8String;
u16 code = 0;
@@ -534,7 +518,6 @@ u16 J2DPrint::doEscapeCode(const u8** ppu8String, u8 alpha) {
return code;
}
/* 802F594C-802F59C0 2F028C 0074+00 3/3 0/0 0/0 .text initchar__8J2DPrintFv */
void J2DPrint::initchar() {
field_0x8 = mCharColor;
field_0xc = mGradColor;
@@ -546,7 +529,6 @@ void J2DPrint::initchar() {
mScaleY = mFontSizeY;
}
/* 802F59C0-802F5AC4 2F0300 0104+00 1/1 0/0 0/0 .text getNumberS32__8J2DPrintFPPCUclli */
s32 J2DPrint::getNumberS32(const u8** ppu8String, s32 defaultValue, s32 errorValue, int base) {
const u8* pStringStart = *ppu8String;
if (**ppu8String != '[') {
@@ -586,7 +568,6 @@ s32 J2DPrint::getNumberS32(const u8** ppu8String, s32 defaultValue, s32 errorVal
return number;
}
/* 802F5AC4-802F5BF8 2F0404 0134+00 1/1 0/0 0/0 .text getNumberF32__8J2DPrintFPPCUcffi */
f32 J2DPrint::getNumberF32(const u8** ppu8String, f32 defaultValue, f32 errorValue, int base) {
const u8* pStringStart = *ppu8String;
if (**ppu8String != '[') {
-56
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J2DScreen
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J2DGraph/J2DScreen.h"
@@ -16,7 +11,6 @@
#include "JSystem/JSupport/JSUMemoryStream.h"
#include "dolphin/types.h"
/* 802F8498-802F8540 2F2DD8 00A8+00 0/0 59/59 4/4 .text __ct__9J2DScreenFv */
J2DScreen::J2DScreen()
: J2DPane(NULL, true, 'root', JGeometry::TBox2<f32>(JGeometry::TVec2<f32>(0, 0), JGeometry::TVec2<f32>(640, 480))), mColor() {
field_0x4 = -1;
@@ -28,12 +22,10 @@ J2DScreen::J2DScreen()
mNameTable = NULL;
}
/* 802F8540-802F85A8 2F2E80 0068+00 1/0 0/0 0/0 .text __dt__9J2DScreenFv */
J2DScreen::~J2DScreen() {
clean();
}
/* 802F85A8-802F8648 2F2EE8 00A0+00 3/3 0/0 0/0 .text clean__9J2DScreenFv */
void J2DScreen::clean() {
delete[] mMaterials;
mMaterialNum = 0;
@@ -52,8 +44,6 @@ void J2DScreen::clean() {
}
}
/* 802F8648-802F8748 2F2F88 0100+00 0/0 58/58 4/4 .text setPriority__9J2DScreenFPCcUlP10JKRArchive
*/
bool J2DScreen::setPriority(char const* resName, u32 param_1, JKRArchive* p_archive) {
if (p_archive == NULL) {
return false;
@@ -68,8 +58,6 @@ bool J2DScreen::setPriority(char const* resName, u32 param_1, JKRArchive* p_arch
return false;
}
/* 802F8748-802F8778 2F3088 0030+00 1/1 1/1 0/0 .text
* setPriority__9J2DScreenFP20JSURandomInputStreamUlP10JKRArchive */
bool J2DScreen::setPriority(JSURandomInputStream* p_stream, u32 param_1, JKRArchive* p_archive) {
if (p_archive == NULL) {
return false;
@@ -78,8 +66,6 @@ bool J2DScreen::setPriority(JSURandomInputStream* p_stream, u32 param_1, JKRArch
}
}
/* 802F8778-802F8834 2F30B8 00BC+00 1/1 0/0 0/0 .text
* private_set__9J2DScreenFP20JSURandomInputStreamUlP10JKRArchive */
bool J2DScreen::private_set(JSURandomInputStream* p_stream, u32 param_1, JKRArchive* p_archive) {
if (!checkSignature(p_stream)) {
return false;
@@ -98,8 +84,6 @@ bool J2DScreen::private_set(JSURandomInputStream* p_stream, u32 param_1, JKRArch
return make_end ? p_stream->isGood() : false;
}
/* 802F8834-802F8894 2F3174 0060+00 1/1 0/0 0/0 .text
* checkSignature__9J2DScreenFP20JSURandomInputStream */
bool J2DScreen::checkSignature(JSURandomInputStream* p_stream) {
J2DScrnHeader header;
p_stream->read(&header, sizeof(J2DScrnHeader));
@@ -112,8 +96,6 @@ bool J2DScreen::checkSignature(JSURandomInputStream* p_stream) {
}
}
/* 802F8894-802F8990 2F31D4 00FC+00 1/1 0/0 0/0 .text
* getScreenInformation__9J2DScreenFP20JSURandomInputStream */
bool J2DScreen::getScreenInformation(JSURandomInputStream* p_stream) {
J2DScrnInfoHeader info;
p_stream->read(&info, sizeof(J2DScrnInfoHeader));
@@ -134,8 +116,6 @@ bool J2DScreen::getScreenInformation(JSURandomInputStream* p_stream) {
return true;
}
/* 802F8990-802F8B98 2F32D0 0208+00 1/1 0/0 0/0 .text
* makeHierarchyPanes__9J2DScreenFP7J2DPaneP20JSURandomInputStreamUlP10JKRArchive */
s32 J2DScreen::makeHierarchyPanes(J2DPane* p_basePane, JSURandomInputStream* p_stream, u32 param_2,
JKRArchive* p_archive) {
J2DPane* next_pane = p_basePane;
@@ -190,8 +170,6 @@ s32 J2DScreen::makeHierarchyPanes(J2DPane* p_basePane, JSURandomInputStream* p_s
}
}
/* 802F8B98-802F8ED4 2F34D8 033C+00 1/0 0/0 0/0 .text
* createPane__9J2DScreenFRC18J2DScrnBlockHeaderP20JSURandomInputStreamP7J2DPaneUlP10JKRArchive */
J2DPane* J2DScreen::createPane(J2DScrnBlockHeader const& header, JSURandomInputStream* p_stream,
J2DPane* p_basePane, u32 param_3, JKRArchive* p_archive) {
J2DPane* newPane;
@@ -246,7 +224,6 @@ J2DPane* J2DScreen::createPane(J2DScrnBlockHeader const& header, JSURandomInputS
return newPane;
}
/* 802F8ED4-802F90A0 2F3814 01CC+00 0/0 51/51 4/4 .text draw__9J2DScreenFffPC14J2DGrafContext */
void J2DScreen::draw(f32 x, f32 y, J2DGrafContext const* grafCtx) {
u32 l_x, l_y, width, height;
@@ -283,7 +260,6 @@ void J2DScreen::draw(f32 x, f32 y, J2DGrafContext const* grafCtx) {
}
}
/* 802F90A0-802F90E0 2F39E0 0040+00 1/0 0/0 0/0 .text search__9J2DScreenFUx */
J2DPane* J2DScreen::search(u64 tag) {
if (tag == 0) {
return NULL;
@@ -292,7 +268,6 @@ J2DPane* J2DScreen::search(u64 tag) {
return J2DPane::search(tag);
}
/* 802F90E0-802F9120 2F3A20 0040+00 1/0 0/0 0/0 .text searchUserInfo__9J2DScreenFUx */
J2DPane* J2DScreen::searchUserInfo(u64 tag) {
if (tag == 0) {
return NULL;
@@ -301,7 +276,6 @@ J2DPane* J2DScreen::searchUserInfo(u64 tag) {
return J2DPane::searchUserInfo(tag);
}
/* 802F9120-802F9280 2F3A60 0160+00 1/0 0/0 0/0 .text drawSelf__9J2DScreenFffPA3_A4_f */
void J2DScreen::drawSelf(f32 param_0, f32 param_1, Mtx* param_2) {
JUtility::TColor color(mColor);
u8 alpha = (color.a * mAlpha) / 255;
@@ -331,8 +305,6 @@ void J2DScreen::drawSelf(f32 param_0, f32 param_1, Mtx* param_2) {
}
}
/* 802F9280-802F937C 2F3BC0 00FC+00 1/1 0/0 0/0 .text
* getResReference__9J2DScreenFP20JSURandomInputStreamUl */
J2DResReference* J2DScreen::getResReference(JSURandomInputStream* p_stream, u32 param_1) {
s32 position = p_stream->getPosition();
p_stream->skip(4);
@@ -359,8 +331,6 @@ J2DResReference* J2DScreen::getResReference(JSURandomInputStream* p_stream, u32
return (J2DResReference*)buffer;
}
/* 802F937C-802F9600 2F3CBC 0284+00 1/1 0/0 0/0 .text
* createMaterial__9J2DScreenFP20JSURandomInputStreamUlP10JKRArchive */
bool J2DScreen::createMaterial(JSURandomInputStream* p_stream, u32 param_1, JKRArchive* p_archive) {
s32 position = p_stream->getPosition();
@@ -426,21 +396,16 @@ failure:
return false;
}
/* 802F9600-802F9620 2F3F40 0020+00 1/0 0/0 0/0 .text isUsed__9J2DScreenFPC7ResTIMG */
bool J2DScreen::isUsed(ResTIMG const* p_timg) {
return J2DPane::isUsed(p_timg);
}
/* 802F9620-802F9640 2F3F60 0020+00 1/0 0/0 0/0 .text isUsed__9J2DScreenFPC7ResFONT */
bool J2DScreen::isUsed(ResFONT const* p_font) {
return J2DPane::isUsed(p_font);
}
/* ############################################################################################## */
/* 80451590-80451598 000A90 0004+04 1/1 3/3 0/0 .sbss mDataManage__9J2DScreen */
J2DDataManage* J2DScreen::mDataManage;
/* 802F9640-802F9690 2F3F80 0050+00 0/0 6/6 0/0 .text getNameResource__9J2DScreenFPCc */
void* J2DScreen::getNameResource(char const* resName) {
void* res = JKRFileLoader::getGlbResource(resName, NULL);
@@ -451,7 +416,6 @@ void* J2DScreen::getNameResource(char const* resName) {
return res;
}
/* 802F9690-802F9704 2F3FD0 0074+00 0/0 30/30 3/3 .text animation__9J2DScreenFv */
void J2DScreen::animation() {
animationPane(mTransform);
@@ -460,7 +424,6 @@ void J2DScreen::animation() {
}
}
/* 802F9704-802F9798 2F4044 0094+00 1/0 0/0 0/0 .text setAnimation__9J2DScreenFP11J2DAnmColor */
void J2DScreen::setAnimation(J2DAnmColor* p_anmColor) {
p_anmColor->searchUpdateMaterialID(this);
u16 matNum = p_anmColor->getUpdateMaterialNum();
@@ -473,8 +436,6 @@ void J2DScreen::setAnimation(J2DAnmColor* p_anmColor) {
}
}
/* 802F9798-802F9838 2F40D8 00A0+00 1/0 0/0 0/0 .text
* setAnimation__9J2DScreenFP19J2DAnmTextureSRTKey */
void J2DScreen::setAnimation(J2DAnmTextureSRTKey* p_anmSRTKey) {
p_anmSRTKey->searchUpdateMaterialID(this);
u16 matNum = p_anmSRTKey->getUpdateMaterialNum();
@@ -487,8 +448,6 @@ void J2DScreen::setAnimation(J2DAnmTextureSRTKey* p_anmSRTKey) {
}
}
/* 802F9838-802F98CC 2F4178 0094+00 1/0 0/0 0/0 .text setAnimation__9J2DScreenFP16J2DAnmTexPattern
*/
void J2DScreen::setAnimation(J2DAnmTexPattern* p_anmPattern) {
p_anmPattern->searchUpdateMaterialID(this);
u16 matNum = p_anmPattern->getUpdateMaterialNum();
@@ -501,8 +460,6 @@ void J2DScreen::setAnimation(J2DAnmTexPattern* p_anmPattern) {
}
}
/* 802F98CC-802F99A8 2F420C 00DC+00 1/0 0/0 0/0 .text setAnimation__9J2DScreenFP15J2DAnmTevRegKey
*/
void J2DScreen::setAnimation(J2DAnmTevRegKey* p_anmRegKey) {
p_anmRegKey->searchUpdateMaterialID(this);
@@ -523,48 +480,35 @@ void J2DScreen::setAnimation(J2DAnmTevRegKey* p_anmRegKey) {
}
}
/* 802F99A8-802F99C8 2F42E8 0020+00 1/0 0/0 0/0 .text setAnimation__9J2DScreenFP14J2DAnmVtxColor
*/
void J2DScreen::setAnimation(J2DAnmVtxColor* p_anmVtxColor) {
J2DPane::setVtxColorAnimation(p_anmVtxColor);
}
/* 802F99C8-802F99E8 2F4308 0020+00 1/0 0/0 0/0 .text
* setAnimation__9J2DScreenFP20J2DAnmVisibilityFull */
void J2DScreen::setAnimation(J2DAnmVisibilityFull* p_anmVisibility) {
J2DPane::setVisibileAnimation(p_anmVisibility);
}
/* 802F99E8-802F9A18 2F4328 0030+00 1/0 0/0 0/0 .text
* createPane__9J2DScreenFRC18J2DScrnBlockHeaderP20JSURandomInputStreamP7J2DPaneUl */
J2DPane* J2DScreen::createPane(J2DScrnBlockHeader const& header, JSURandomInputStream* p_stream,
J2DPane* p_basePane, u32 param_3) {
return createPane(header, p_stream, p_basePane, param_3, NULL);
}
/* 802F9A18-802F9A20 2F4358 0008+00 1/0 0/0 0/0 .text getTypeID__9J2DScreenCFv */
u16 J2DScreen::getTypeID() const {
return 8;
}
/* 802F9A20-802F9A54 2F4360 0034+00 1/0 0/0 0/0 .text calcMtx__9J2DScreenFv */
void J2DScreen::calcMtx() {
makeMatrix(mTranslateX, mTranslateY);
}
/* 802F9A54-802F9A74 2F4394 0020+00 1/0 0/0 0/0 .text setAnimation__9J2DScreenFP10J2DAnmBase */
void J2DScreen::setAnimation(J2DAnmBase* p_anm) {
J2DPane::setAnimation(p_anm);
}
/* 802F9A74-802F9A78 2F43B4 0004+00 1/0 0/0 0/0 .text
* setAnimationVF__9J2DScreenFP20J2DAnmVisibilityFull */
void J2DScreen::setAnimationVF(J2DAnmVisibilityFull*) {
/* empty function */
}
/* 802F9A78-802F9A7C 2F43B8 0004+00 1/0 0/0 0/0 .text setAnimationVC__9J2DScreenFP14J2DAnmVtxColor
*/
void J2DScreen::setAnimationVC(J2DAnmVtxColor*) {
/* empty function */
}
-29
View File
@@ -9,12 +9,10 @@
#include "math.h"
#include "dolphin/gx.h"
/* 802E9C90-802E9CC4 2E45D0 0034+00 0/0 1/1 0/0 .text load__9J2DTexMtxFUl */
void J2DTexMtx::load(u32 mtxIdx) {
GXLoadTexMtxImm(mTexMtx, mtxIdx * 3 + GX_TEXMTX0, mInfo.getTexMtxType());
}
/* 802E9CC4-802E9D2C 2E4604 0068+00 0/0 2/2 0/0 .text calc__9J2DTexMtxFv */
void J2DTexMtx::calc() {
if (mInfo.mTexMtxDCC == J2DTexMtxInfo::DCC_NONE) {
getTextureMtx(mInfo.mTexSRTInfo, mInfo.mCenter, mTexMtx);
@@ -23,8 +21,6 @@ void J2DTexMtx::calc() {
}
}
/* 802E9D2C-802E9EBC 2E466C 0190+00 1/1 0/0 0/0 .text
* getTextureMtx__9J2DTexMtxFRC17J2DTextureSRTInfo3VecPA4_f */
void J2DTexMtx::getTextureMtx(J2DTextureSRTInfo const& param_0, Vec param_1, Mtx param_2) {
float f31 = (param_0.mRotationDeg * M_PI) / 180.0f;
param_2[0][0] = param_0.mScaleX * i_cosf(f31);
@@ -43,8 +39,6 @@ void J2DTexMtx::getTextureMtx(J2DTextureSRTInfo const& param_0, Vec param_1, Mtx
param_2[2][3] = 0.0f;
}
/* 802E9EBC-802EA044 2E47FC 0188+00 1/1 0/0 0/0 .text
* getTextureMtxMaya__9J2DTexMtxFRC17J2DTextureSRTInfoPA4_f */
void J2DTexMtx::getTextureMtxMaya(J2DTextureSRTInfo const& param_0, Mtx param_1) {
float f31 = (param_0.mRotationDeg * M_PI) / 180.0f;
param_1[0][0] = param_0.mScaleX * i_cosf(f31);
@@ -63,24 +57,20 @@ void J2DTexMtx::getTextureMtxMaya(J2DTextureSRTInfo const& param_0, Mtx param_1)
param_1[2][3] = 0.0f;
}
/* 802EA044-802EA098 2E4984 0054+00 0/0 5/5 0/0 .text load__14J2DIndTevStageFUc */
void J2DIndTevStage::load(u8 tevStage) {
GXSetTevIndirect((GXTevStageID)tevStage, getIndStage(), getIndFormat(), getBiasSel(),
getMtxSel(), getWrapS(), getWrapT(), getPrev(), getLod(), getAlphaSel());
}
/* 802EA098-802EA0CC 2E49D8 0034+00 0/0 1/1 0/0 .text load__12J2DIndTexMtxFUc */
void J2DIndTexMtx::load(u8 indTexMtx) {
GXSetIndTexMtx((GXIndTexMtxID)(GX_ITM_0 + indTexMtx), mIndTexMtxInfo.mMtx,
mIndTexMtxInfo.mScaleExp);
}
/* 802EA0CC-802EA0FC 2E4A0C 0030+00 0/0 1/1 0/0 .text load__19J2DIndTexCoordScaleFUc */
void J2DIndTexCoordScale::load(u8 indTexStage) {
GXSetIndTexCoordScale((GXIndTexStageID)indTexStage, mInfo.getScaleS(), mInfo.getScaleT());
}
/* 802EA0FC-802EA12C 2E4A3C 0030+00 0/0 1/1 0/0 .text load__14J2DIndTexOrderFUc */
void J2DIndTexOrder::load(u8 indTexStage) {
GXSetIndTexOrder((GXIndTexStageID)indTexStage, mInfo.getTexCoordID(), mInfo.getTexMapID());
}
@@ -105,8 +95,6 @@ static void dummyVirtual(J2DTevBlock* block, J2DIndBlock* indBlock) {
block->getTevSwapModeTable(0);
}
/* ############################################################################################## */
/* 803A1B80-803A1BA0 02E1E0 0020+00 0/0 3/3 0/0 .rodata j2dDefaultTexCoordInfo */
J2DTexCoordInfo const j2dDefaultTexCoordInfo[8] = {
{GX_TG_MTX2x4, GX_TG_TEX0, GX_IDENTITY, 0}, {GX_TG_MTX2x4, GX_TG_TEX1, GX_IDENTITY, 0},
{GX_TG_MTX2x4, GX_TG_TEX2, GX_IDENTITY, 0}, {GX_TG_MTX2x4, GX_TG_TEX3, GX_IDENTITY, 0},
@@ -114,70 +102,53 @@ J2DTexCoordInfo const j2dDefaultTexCoordInfo[8] = {
{GX_TG_MTX2x4, GX_TG_TEX6, GX_IDENTITY, 0}, {GX_TG_MTX2x4, GX_TG_TEX7, GX_IDENTITY, 0},
};
/* 803A1BA0-803A1BC4 02E200 0024+00 0/0 3/3 0/0 .rodata j2dDefaultTexMtxInfo */
J2DTexMtxInfo const j2dDefaultTexMtxInfo = {1, 1, 255, 255, 0.5f, 0.5f,
0.0f, 1.0f, 1.0f, 0.0f, 0.0f, 0.0f};
/* 803A1BC4-803A1BE0 02E224 001C+00 0/0 3/3 0/0 .rodata j2dDefaultIndTexMtxInfo */
J2DIndTexMtxInfo const j2dDefaultIndTexMtxInfo = {{0.5f, 0.0f, 0.0f, 0.0f, 0.5f, 0.0f}, 1};
/* 803A1BE0-803A1BF4 02E240 0014+00 0/0 1/1 0/0 .rodata j2dDefaultTevStageInfo */
extern J2DTevStageInfo const j2dDefaultTevStageInfo = {
4, GX_CC_RASC, GX_CC_ZERO, GX_CC_ZERO, GX_CC_CPREV, GX_TEV_ADD,
GX_TB_ZERO, GX_CS_SCALE_1, 1, GX_TEVPREV, GX_CA_RASA, GX_CA_ZERO,
GX_CA_ZERO, GX_CA_APREV, GX_TEV_ADD, GX_TB_ZERO, GX_CS_SCALE_1, 1,
GX_TEVPREV};
/* 803A1BF4-803A1C00 02E254 000C+00 0/0 7/7 0/0 .rodata j2dDefaultIndTevStageInfo */
extern const J2DIndTevStageInfo j2dDefaultIndTevStageInfo = {
GX_INDTEXSTAGE0, GX_ITB_NONE, GX_ITB_NONE, GX_ITM_OFF, GX_ITW_OFF,
GX_ITW_OFF, 0, 0, GX_ITBA_OFF,
};
/* 8045617C-80456180 00477C 0004+00 0/0 1/1 0/0 .sdata2 j2dDefaultColInfo */
extern const GXColor j2dDefaultColInfo = {255, 255, 255, 255};
/* 80456180-80456184 004780 0004+00 0/0 7/7 0/0 .sdata2 j2dDefaultTevOrderInfoNull */
extern const J2DTevOrderInfo j2dDefaultTevOrderInfoNull = {
GX_TEXCOORD_NULL, GX_TEXMAP_NULL, GX_COLOR_NULL, 0};
/* 80456184-80456188 004784 0002+02 0/0 3/3 0/0 .sdata2 j2dDefaultIndTexOrderNull */
extern const J2DIndTexOrderInfo j2dDefaultIndTexOrderNull = {
GX_TEXCOORD_NULL,
GX_TEXMAP_NULL,
};
/* 80456188-80456190 004788 0008+00 0/0 5/5 0/0 .sdata2 j2dDefaultTevColor */
extern const GXColorS10 j2dDefaultTevColor = {255, 255, 255, 255};
/* 80456190-80456194 004790 0002+02 0/0 3/3 0/0 .sdata2 j2dDefaultIndTexCoordScaleInfo */
extern const J2DIndTexCoordScaleInfo j2dDefaultIndTexCoordScaleInfo = {
GX_ITS_1,
GX_ITS_1,
};
/* 80456194-80456198 004794 0004+00 0/0 5/5 0/0 .sdata2 j2dDefaultTevKColor */
extern const GXColor j2dDefaultTevKColor = {255, 255, 255, 255};
/* 80456198-8045619C 004798 0004+00 0/0 2/2 0/0 .sdata2 j2dDefaultTevSwapMode */
extern const J2DTevSwapModeInfo j2dDefaultTevSwapMode = {GX_TEV_SWAP0, GX_TEV_SWAP0, 0, 0};
/* 8045619C-804561A0 00479C 0004+00 0/0 6/6 0/0 .sdata2 j2dDefaultTevSwapModeTable */
extern const J2DTevSwapModeTableInfo j2dDefaultTevSwapModeTable = {
GX_CH_RED, GX_CH_GREEN, GX_CH_BLUE, GX_CH_ALPHA};
/* 804561A0-804561A4 0047A0 0004+00 0/0 3/3 0/0 .sdata2 j2dDefaultBlendInfo */
extern const J2DBlendInfo j2dDefaultBlendInfo = {GX_BM_BLEND, GX_BL_SRCALPHA, GX_BL_INVSRCALPHA,
GX_LO_NOOP};
/* 804561A4-804561A8 0047A4 0004+00 0/0 1/1 0/0 .sdata2 None */
extern const u8 j2dDefaultPEBlockDither = 0;
/* 804561A8-804561AC 0047A8 0004+00 0/0 3/3 0/0 .sdata2 j2dDefaultColorChanInfo */
extern const J2DColorChanInfo j2dDefaultColorChanInfo = {0, 3, 0, 0};
/* 804561AC-804561AE 0047AC 0002+00 0/0 1/1 0/0 .sdata2 None */
extern const u8 data_804561AC = 0x1B;
/* 804561AE-804561B0 0047AE 0002+00 0/0 3/3 0/0 .sdata2 j2dDefaultAlphaCmp */
extern const u16 j2dDefaultAlphaCmp = 0x00E7;
-31
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J2DTextBox
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J2DGraph/J2DTextBox.h"
@@ -10,21 +5,16 @@
#include "JSystem/JSupport/JSURandomInputStream.h"
#include "JSystem/JUtility/JUTResFont.h"
/* 802FF660-802FF6D8 2F9FA0 0078+00 0/0 1/1 0/0 .text __ct__10J2DTextBoxFv */
J2DTextBox::J2DTextBox()
: mFont(NULL), mCharColor(), mGradientColor(), mStringPtr(NULL), mWhiteColor(), mBlackColor() {
initiate(NULL, NULL, 0, HBIND_LEFT, VBIND_TOP);
}
/* 802FF6D8-802FF75C 2FA018 0084+00 0/0 1/1 0/0 .text
* __ct__10J2DTextBoxFP7J2DPaneP20JSURandomInputStreamP10JKRArchive */
J2DTextBox::J2DTextBox(J2DPane* p_pane, JSURandomInputStream* p_stream, JKRArchive* p_archive)
: mFont(NULL), mCharColor(), mGradientColor(), mStringPtr(NULL), mWhiteColor(), mBlackColor() {
private_readStream(p_pane, p_stream, p_archive);
}
/* 802FF75C-802FFBC4 2FA09C 0468+00 0/0 1/1 0/0 .text
* __ct__10J2DTextBoxFP7J2DPaneP20JSURandomInputStreamUlP11J2DMaterial */
J2DTextBox::J2DTextBox(J2DPane* p_pane, JSURandomInputStream* p_stream, u32 param_2,
J2DMaterial* p_material)
: mFont(NULL), mCharColor(), mGradientColor(), mStringPtr(NULL), mWhiteColor(), mBlackColor() {
@@ -142,8 +132,6 @@ J2DTextBox::J2DTextBox(u64 tag, JGeometry::TBox2<f32> const& bounds, ResFONT con
initiate(p_font, string, strLength, hBind, vBind);
}
/* 802FFC58-802FFE88 2FA598 0230+00 2/2 1/0 0/0 .text
* initiate__10J2DTextBoxFPC7ResFONTPCcs18J2DTextBoxHBinding18J2DTextBoxVBinding */
void J2DTextBox::initiate(ResFONT const* p_font, char const* string, s16 length,
J2DTextBoxHBinding hBind, J2DTextBoxVBinding vBind) {
if (p_font != NULL) {
@@ -197,8 +185,6 @@ void J2DTextBox::initiate(ResFONT const* p_font, char const* string, s16 length,
mTextFontOwned = true;
}
/* 802FFE88-803001E0 2FA7C8 0358+00 1/1 0/0 0/0 .text
* private_readStream__10J2DTextBoxFP7J2DPaneP20JSURandomInputStreamP10JKRArchive */
void J2DTextBox::private_readStream(J2DPane* p_pane, JSURandomInputStream* p_stream,
JKRArchive* p_archive) {
int position = p_stream->getPosition();
@@ -263,7 +249,6 @@ void J2DTextBox::private_readStream(J2DPane* p_pane, JSURandomInputStream* p_str
mTextFontOwned = true;
}
/* 803001E0-80300278 2FAB20 0098+00 1/0 2/2 0/0 .text __dt__10J2DTextBoxFv */
J2DTextBox::~J2DTextBox() {
if (mTextFontOwned) {
delete mFont;
@@ -272,7 +257,6 @@ J2DTextBox::~J2DTextBox() {
delete[] mStringPtr;
}
/* 80300278-803002E8 2FABB8 0070+00 1/0 0/0 0/0 .text setFont__10J2DTextBoxFP7JUTFont */
void J2DTextBox::setFont(JUTFont* p_font) {
if (p_font) {
if (mTextFontOwned) {
@@ -283,7 +267,6 @@ void J2DTextBox::setFont(JUTFont* p_font) {
}
}
/* 803002E8-80300490 2FAC28 01A8+00 1/0 0/0 0/0 .text draw__10J2DTextBoxFff */
void J2DTextBox::draw(f32 posX, f32 posY) {
Mtx m;
@@ -310,8 +293,6 @@ void J2DTextBox::draw(f32 posX, f32 posY) {
}
}
/* 80300490-80300658 2FADD0 01C8+00 1/0 1/1 0/0 .text draw__10J2DTextBoxFfff18J2DTextBoxHBinding
*/
void J2DTextBox::draw(f32 posX, f32 posY, f32 param_2, J2DTextBoxHBinding hBind) {
Mtx m;
@@ -339,12 +320,10 @@ void J2DTextBox::draw(f32 posX, f32 posY, f32 param_2, J2DTextBoxHBinding hBind)
}
}
/* 80300658-80300660 2FAF98 0008+00 0/0 62/62 2/2 .text getStringPtr__10J2DTextBoxCFv */
char* J2DTextBox::getStringPtr() const {
return mStringPtr;
}
/* 80300660-8030074C 2FAFA0 00EC+00 0/0 6/6 0/0 .text setString__10J2DTextBoxFPCce */
s32 J2DTextBox::setString(char const* string, ...) {
va_list args;
va_start(args, string);
@@ -370,7 +349,6 @@ s32 J2DTextBox::setString(char const* string, ...) {
return len;
}
/* 8030074C-80300870 2FB08C 0124+00 0/0 41/41 2/2 .text setString__10J2DTextBoxFsPCce */
s32 J2DTextBox::setString(s16 length, char const* string, ...) {
va_list args;
va_start(args, string);
@@ -404,7 +382,6 @@ s32 J2DTextBox::setString(s16 length, char const* string, ...) {
return len;
}
/* 80300870-803008E8 2FB1B0 0078+00 1/0 1/0 0/0 .text setConnectParent__10J2DTextBoxFb */
bool J2DTextBox::setConnectParent(bool connected) {
if (getPaneTree()->getParent() == NULL) {
return false;
@@ -418,7 +395,6 @@ bool J2DTextBox::setConnectParent(bool connected) {
return connected;
}
/* 803008E8-80300950 2FB228 0068+00 1/0 1/0 0/0 .text drawSelf__10J2DTextBoxFff */
void J2DTextBox::drawSelf(f32 param_0, f32 param_1) {
Mtx identity;
MTXIdentity(identity);
@@ -426,8 +402,6 @@ void J2DTextBox::drawSelf(f32 param_0, f32 param_1) {
drawSelf(param_0, param_1, &identity);
}
/* 80300950-80300AF8 2FB290 01A8+00 1/0 0/0 0/0 .text drawSelf__10J2DTextBoxFffPA3_A4_f
*/
void J2DTextBox::drawSelf(f32 param_0, f32 param_1, Mtx* p_mtx) {
Mtx m;
@@ -451,7 +425,6 @@ void J2DTextBox::drawSelf(f32 param_0, f32 param_1, Mtx* p_mtx) {
}
}
/* 80300AF8-80300BFC 2FB438 0104+00 1/0 1/0 0/0 .text resize__10J2DTextBoxFff */
void J2DTextBox::resize(f32 x, f32 y) {
if (mConnected && getPaneTree() != NULL && getPaneTree()->getParent() != NULL) {
J2DPane* obj = getPaneTree()->getParent()->getObject();
@@ -467,7 +440,6 @@ void J2DTextBox::resize(f32 x, f32 y) {
J2DPane::resize(x, y);
}
/* 80300BFC-80300C68 2FB53C 006C+00 1/0 0/0 0/0 .text isUsed__10J2DTextBoxFPC7ResFONT */
bool J2DTextBox::isUsed(ResFONT const* p_font) {
if (mFont != NULL && mFont->getResFont() == p_font) {
return true;
@@ -476,17 +448,14 @@ bool J2DTextBox::isUsed(ResFONT const* p_font) {
return J2DPane::isUsed(p_font);
}
/* 80300C68-80300C70 2FB5A8 0008+00 1/0 1/0 0/0 .text getTypeID__10J2DTextBoxCFv */
u16 J2DTextBox::getTypeID() const {
return 19;
}
/* 80300C70-80300C90 2FB5B0 0020+00 1/0 0/0 0/0 .text isUsed__10J2DTextBoxFPC7ResTIMG */
bool J2DTextBox::isUsed(ResTIMG const* p_timg) {
return J2DPane::isUsed(p_timg);
}
/* 80300C90-80300C94 2FB5D0 0004+00 1/0 0/0 0/0 .text rewriteAlpha__10J2DTextBoxFv */
void J2DTextBox::rewriteAlpha() {
/* empty function */
}
-51
View File
@@ -9,8 +9,6 @@
#include "JSystem/JSupport/JSURandomInputStream.h"
#include "JSystem/JUtility/JUTResFont.h"
/* 803071E4-8030751C 301B24 0338+00 0/0 1/1 0/0 .text
* __ct__12J2DTextBoxExFP7J2DPaneP20JSURandomInputStreamUlP11J2DMaterial */
J2DTextBoxEx::J2DTextBoxEx(J2DPane* p_pane, JSURandomInputStream* p_stream, u32 param_2,
J2DMaterial* p_material) {
J2DTextBoxInfo info;
@@ -92,15 +90,12 @@ J2DTextBoxEx::J2DTextBoxEx(J2DPane* p_pane, JSURandomInputStream* p_stream, u32
field_0x140 = 0;
}
/* 8030751C-803075AC 301E5C 0090+00 1/0 0/0 0/0 .text __dt__12J2DTextBoxExFv */
J2DTextBoxEx::~J2DTextBoxEx() {
if (field_0x140 != 0) {
delete mMaterial;
}
}
/* 803075AC-803078AC 301EEC 0300+00 1/0 0/0 0/0 .text drawSelf__12J2DTextBoxExFffPA3_A4_f
*/
void J2DTextBoxEx::drawSelf(f32 param_0, f32 param_1, Mtx* p_mtx) {
Mtx m;
@@ -142,7 +137,6 @@ void J2DTextBoxEx::drawSelf(f32 param_0, f32 param_1, Mtx* p_mtx) {
}
}
/* 803078AC-80307AF0 3021EC 0244+00 1/0 0/0 0/0 .text draw__12J2DTextBoxExFff */
void J2DTextBoxEx::draw(f32 posX, f32 posY) {
Mtx m;
@@ -198,8 +192,6 @@ void J2DTextBoxEx::draw(f32 posX, f32 posY) {
}
}
/* 80307AF0-80307D5C 302430 026C+00 1/0 0/0 0/0 .text draw__12J2DTextBoxExFfff18J2DTextBoxHBinding
*/
void J2DTextBoxEx::draw(f32 posX, f32 posY, f32 param_2, J2DTextBoxHBinding hBind) {
Mtx m;
@@ -256,8 +248,6 @@ void J2DTextBoxEx::draw(f32 posX, f32 posY, f32 param_2, J2DTextBoxHBinding hBin
}
}
/* 80307D5C-80307DC0 30269C 0064+00 1/0 0/0 0/0 .text setFont__12J2DTextBoxExFP7JUTFont
*/
void J2DTextBoxEx::setFont(JUTFont* p_font) {
if (p_font != NULL && mMaterial != NULL && mMaterial->getTevBlock() != NULL) {
mMaterial->getTevBlock()->setFont(p_font);
@@ -265,7 +255,6 @@ void J2DTextBoxEx::setFont(JUTFont* p_font) {
}
}
/* 80307DC0-80307E0C 302700 004C+00 1/0 0/0 0/0 .text getFont__12J2DTextBoxExCFv */
JUTFont* J2DTextBoxEx::getFont() const {
if (mMaterial != NULL && mMaterial->getTevBlock() != NULL) {
return mMaterial->getTevBlock()->getFont();
@@ -274,7 +263,6 @@ JUTFont* J2DTextBoxEx::getFont() const {
return NULL;
}
/* 80307E0C-80307EF0 30274C 00E4+00 1/1 0/0 0/0 .text setTevOrder__12J2DTextBoxExFb */
void J2DTextBoxEx::setTevOrder(bool param_0) {
u16 local_18[2];
if (!param_0) {
@@ -296,7 +284,6 @@ void J2DTextBoxEx::setTevOrder(bool param_0) {
}
}
/* 80307EF0-80307F94 302830 00A4+00 1/1 0/0 0/0 .text setTevStage__12J2DTextBoxExFb */
void J2DTextBoxEx::setTevStage(bool param_0) {
J2DTevStage* stage = mMaterial->getTevBlock()->getTevStage(0);
@@ -308,8 +295,6 @@ void J2DTextBoxEx::setTevStage(bool param_0) {
}
}
/* 80307F94-8030823C 3028D4 02A8+00 1/1 0/0 0/0 .text
* setStage__12J2DTextBoxExFP11J2DTevStageQ212J2DTextBoxEx10stage_enum */
void J2DTextBoxEx::setStage(J2DTevStage* param_0, J2DTextBoxEx::stage_enum param_1) {
const u8 tevColors[3][4] = {
{0x0F, 0x08, 0x0A, 0x0F}, {0x02, 0x04, 0x08, 0x0F}, {0x0F, 0x0A, 0x00, 0x0F},
@@ -340,8 +325,6 @@ void J2DTextBoxEx::setStage(J2DTevStage* param_0, J2DTextBoxEx::stage_enum param
tevAlphaOps[param_1][0], tevAlphaOps[param_1][1], tevAlphaOps[param_1][2], tevAlphaOps[param_1][3], tevAlphaOps[param_1][4]);
}
/* 8030823C-803082C4 302B7C 0088+00 1/0 0/0 0/0 .text setBlack__12J2DTextBoxExFQ28JUtility6TColor
*/
bool J2DTextBoxEx::setBlack(JUtility::TColor black) {
JUtility::TColor tevBlack;
JUtility::TColor tevWhite;
@@ -353,8 +336,6 @@ bool J2DTextBoxEx::setBlack(JUtility::TColor black) {
}
}
/* 803082C4-8030834C 302C04 0088+00 1/0 0/0 0/0 .text setWhite__12J2DTextBoxExFQ28JUtility6TColor
*/
bool J2DTextBoxEx::setWhite(JUtility::TColor white) {
JUtility::TColor tevBlack;
JUtility::TColor tevWhite;
@@ -366,8 +347,6 @@ bool J2DTextBoxEx::setWhite(JUtility::TColor white) {
}
}
/* 8030834C-803084CC 302C8C 0180+00 1/0 0/0 0/0 .text
* setBlackWhite__12J2DTextBoxExFQ28JUtility6TColorQ28JUtility6TColor */
bool J2DTextBoxEx::setBlackWhite(JUtility::TColor param_0, JUtility::TColor param_1) {
if (mMaterial == NULL) {
return false;
@@ -408,8 +387,6 @@ bool J2DTextBoxEx::setBlackWhite(JUtility::TColor param_0, JUtility::TColor para
return true;
}
/* 803084CC-80308668 302E0C 019C+00 4/4 0/0 0/0 .text
* getBlackWhite__12J2DTextBoxExCFPQ28JUtility6TColorPQ28JUtility6TColor */
bool J2DTextBoxEx::getBlackWhite(JUtility::TColor* param_0, JUtility::TColor* param_1) const {
if (mMaterial == NULL) {
return false;
@@ -443,8 +420,6 @@ bool J2DTextBoxEx::getBlackWhite(JUtility::TColor* param_0, JUtility::TColor* pa
return true;
}
/* 80308668-803086FC 302FA8 0094+00 1/1 0/0 0/0 .text
* isSetBlackWhite__12J2DTextBoxExCFQ28JUtility6TColorQ28JUtility6TColor */
bool J2DTextBoxEx::isSetBlackWhite(JUtility::TColor param_0, JUtility::TColor param_1) const {
if ((u32)param_0 == 0 && (u32)param_1 == 0xffffffff) {
return 1;
@@ -456,7 +431,6 @@ bool J2DTextBoxEx::isSetBlackWhite(JUtility::TColor param_0, JUtility::TColor pa
return 1;
}
/* 803086FC-8030875C 30303C 0060+00 1/0 0/0 0/0 .text getBlack__12J2DTextBoxExCFv */
JUtility::TColor J2DTextBoxEx::getBlack() const {
JUtility::TColor black;
JUtility::TColor white;
@@ -466,7 +440,6 @@ JUtility::TColor J2DTextBoxEx::getBlack() const {
return black;
}
/* 8030875C-803087BC 30309C 0060+00 1/0 0/0 0/0 .text getWhite__12J2DTextBoxExCFv */
JUtility::TColor J2DTextBoxEx::getWhite() const {
JUtility::TColor black;
JUtility::TColor white;
@@ -476,7 +449,6 @@ JUtility::TColor J2DTextBoxEx::getWhite() const {
return white;
}
/* 803087BC-803087DC 3030FC 0020+00 1/0 0/0 0/0 .text setAlpha__12J2DTextBoxExFUc */
void J2DTextBoxEx::setAlpha(u8 alpha) {
mAlpha = alpha;
@@ -491,7 +463,6 @@ void J2DTextBoxEx::setAlpha(u8 alpha) {
mMaterial->getColorBlock()->getMatColor(0)->a = alpha;
}
/* 803087DC-80308810 30311C 0034+00 1/0 0/0 0/0 .text setCullBack__12J2DTextBoxExF11_GXCullMode */
void J2DTextBoxEx::setCullBack(GXCullMode mode) {
mCullMode = mode;
@@ -502,7 +473,6 @@ void J2DTextBoxEx::setCullBack(GXCullMode mode) {
J2DPane::setCullBack(mode);
}
/* 80308810-80308828 303150 0018+00 1/0 0/0 0/0 .text rewriteAlpha__12J2DTextBoxExFv */
void J2DTextBoxEx::rewriteAlpha() {
if (mMaterial == NULL) {
return;
@@ -511,8 +481,6 @@ void J2DTextBoxEx::rewriteAlpha() {
mAlpha = mMaterial->getColorBlock()->getMatColor(0)->a;
}
/* 80308828-803088B4 303168 008C+00 1/0 0/0 0/0 .text isUsed__12J2DTextBoxExFPC7ResFONT
*/
bool J2DTextBoxEx::isUsed(ResFONT const* p_font) {
if (getFont() != NULL && getFont()->getResFont() == p_font) {
return true;
@@ -521,46 +489,34 @@ bool J2DTextBoxEx::isUsed(ResFONT const* p_font) {
return J2DPane::isUsed(p_font);
}
/* 803088B4-803088E0 3031F4 002C+00 1/0 0/0 0/0 .text setAnimation__12J2DTextBoxExFP11J2DAnmColor
*/
void J2DTextBoxEx::setAnimation(J2DAnmColor* anm) {
if (mMaterial != NULL) {
mMaterial->setAnimation(anm);
}
}
/* 803088E0-8030890C 303220 002C+00 1/0 0/0 0/0 .text
* setAnimation__12J2DTextBoxExFP19J2DAnmTextureSRTKey */
void J2DTextBoxEx::setAnimation(J2DAnmTextureSRTKey* anm) {
if (mMaterial != NULL) {
mMaterial->setAnimation(anm);
}
}
/* 8030890C-80308938 30324C 002C+00 1/0 0/0 0/0 .text
* setAnimation__12J2DTextBoxExFP16J2DAnmTexPattern */
void J2DTextBoxEx::setAnimation(J2DAnmTexPattern* anm) {
if (mMaterial != NULL) {
mMaterial->setAnimation(anm);
}
}
/* 80308938-80308964 303278 002C+00 1/0 0/0 0/0 .text
* setAnimation__12J2DTextBoxExFP15J2DAnmTevRegKey */
void J2DTextBoxEx::setAnimation(J2DAnmTevRegKey* anm) {
if (mMaterial != NULL) {
mMaterial->setAnimation(anm);
}
}
/* 80308964-8030896C -00001 0008+00 0/0 0/0 0/0 .text
* setAnimation__12J2DTextBoxExFP20J2DAnmVisibilityFull */
void J2DTextBoxEx::setAnimation(J2DAnmVisibilityFull* anm) {
mVisibilityAnm = anm;
}
/* 8030896C-803089EC 3032AC 0080+00 1/0 0/0 0/0 .text
* animationPane__12J2DTextBoxExFPC15J2DAnmTransform */
const J2DAnmTransform* J2DTextBoxEx::animationPane(J2DAnmTransform const* param_0) {
if (mVisibilityAnm != NULL && field_0x13c != 0xffff) {
u8 visibility;
@@ -574,25 +530,18 @@ const J2DAnmTransform* J2DTextBoxEx::animationPane(J2DAnmTransform const* param_
return J2DPane::animationPane(param_0);
}
/* 803089EC-80308A28 30332C 003C+00 1/0 0/0 0/0 .text setCullBack__12J2DTextBoxExFb */
void J2DTextBoxEx::setCullBack(bool param_0) {
setCullBack(param_0 ? GX_CULL_BACK : GX_CULL_NONE);
}
/* 80308A28-80308A48 303368 0020+00 1/0 0/0 0/0 .text isUsed__12J2DTextBoxExFPC7ResTIMG
*/
bool J2DTextBoxEx::isUsed(ResTIMG const* p_timg) {
return J2DPane::isUsed(p_timg);
}
/* 80308A48-80308A4C 303388 0004+00 1/0 0/0 0/0 .text
* setAnimation__12J2DTextBoxExFP14J2DAnmVtxColor */
void J2DTextBoxEx::setAnimation(J2DAnmVtxColor* param_0) {
/* empty function */
}
/* 80308A4C-80308A6C 30338C 0020+00 1/0 0/0 0/0 .text setAnimation__12J2DTextBoxExFP10J2DAnmBase
*/
void J2DTextBoxEx::setAnimation(J2DAnmBase* anm) {
J2DPane::setAnimation(anm);
}
-40
View File
@@ -6,7 +6,6 @@
#include "JSystem/JUtility/JUTResource.h"
#include "JSystem/JUtility/JUTTexture.h"
/* 802F9A7C-802F9B74 2F43BC 00F8+00 0/0 1/1 0/0 .text __ct__9J2DWindowFv */
J2DWindow::J2DWindow()
: field_0x100(NULL), field_0x104(NULL), field_0x108(NULL), field_0x10c(NULL), field_0x110(NULL),
mPalette(NULL) {
@@ -16,8 +15,6 @@ J2DWindow::J2DWindow()
mWhite = JUtility::TColor(0xffffffff);
}
/* 802F9B74-802F9C10 2F44B4 009C+00 0/0 1/1 0/0 .text
* __ct__9J2DWindowFP7J2DPaneP20JSURandomInputStreamP10JKRArchive */
J2DWindow::J2DWindow(J2DPane* param_0, JSURandomInputStream* param_1, JKRArchive* param_2)
: field_0x100(NULL), field_0x104(NULL), field_0x108(NULL), field_0x10c(NULL), field_0x110(NULL),
mPalette(NULL) {
@@ -39,8 +36,6 @@ struct J2DWindowData {
u32 field_0x30[4];
};
/* 802F9C10-802FA118 2F4550 0508+00 0/0 1/1 0/0 .text
* __ct__9J2DWindowFP7J2DPaneP20JSURandomInputStreamP11J2DMaterial */
J2DWindow::J2DWindow(J2DPane* param_0, JSURandomInputStream* param_1, J2DMaterial* param_2) :
field_0x100(NULL),
field_0x104(NULL),
@@ -149,8 +144,6 @@ J2DWindow::J2DWindow(J2DPane* param_0, JSURandomInputStream* param_1, J2DMateria
initinfo2();
}
/* 802FA118-802FA604 2F4A58 04EC+00 1/1 0/0 0/0 .text
* private_readStream__9J2DWindowFP7J2DPaneP20JSURandomInputStreamP10JKRArchive */
void J2DWindow::private_readStream(J2DPane* param_0, JSURandomInputStream* param_1,
JKRArchive* param_2) {
s32 local_188 = param_1->getPosition();
@@ -212,7 +205,6 @@ void J2DWindow::private_readStream(J2DPane* param_0, JSURandomInputStream* param
initinfo2();
}
/* 802FA604-802FA880 2F4F44 027C+00 2/2 0/0 0/0 .text initinfo2__9J2DWindowFv */
void J2DWindow::initinfo2() {
if (field_0x100 && field_0x104 && field_0x108 && field_0x10c) {
field_0x140 = field_0x100->getWidth() + field_0x104->getWidth();
@@ -237,7 +229,6 @@ void J2DWindow::initinfo2() {
}
}
/* 802FA880-802FA928 2F51C0 00A8+00 1/0 1/1 0/0 .text __dt__9J2DWindowFv */
J2DWindow::~J2DWindow() {
delete field_0x100;
delete field_0x104;
@@ -247,7 +238,6 @@ J2DWindow::~J2DWindow() {
delete field_0x110;
}
/* 802FA928-802FAA5C 2F5268 0134+00 1/0 0/0 0/0 .text draw__9J2DWindowFRCQ29JGeometry8TBox2<f> */
void J2DWindow::draw(JGeometry::TBox2<f32> const& param_0) {
JGeometry::TBox2<f32> stack_58;
if (field_0x100 && field_0x104 && field_0x108 && field_0x10c) {
@@ -260,8 +250,6 @@ void J2DWindow::draw(JGeometry::TBox2<f32> const& param_0) {
draw(param_0, stack_58);
}
/* 802FAA5C-802FAED0 2F539C 0474+00 2/2 0/0 0/0 .text
* draw_private__9J2DWindowFRCQ29JGeometry8TBox2<f>RCQ29JGeometry8TBox2<f> */
void J2DWindow::draw_private(JGeometry::TBox2<f32> const& param_0,
JGeometry::TBox2<f32> const& param_1) {
JGeometry::TBox2<f32> stack_a0(param_1);
@@ -355,8 +343,6 @@ void J2DWindow::draw_private(JGeometry::TBox2<f32> const& param_0,
GXSetVtxDesc(GX_VA_TEX0, GX_NONE);
}
/* 802FAED0-802FB000 2F5810 0130+00 1/0 0/0 0/0 .text
* draw__9J2DWindowFRCQ29JGeometry8TBox2<f>RCQ29JGeometry8TBox2<f> */
void J2DWindow::draw(JGeometry::TBox2<f32> const& param_0, JGeometry::TBox2<f32> const& param_1) {
if (param_0.getWidth() >= field_0x140 && param_0.getHeight() >= field_0x142 && isVisible()) {
makeMatrix(param_0.i.x, param_0.i.y, 0, 0);
@@ -371,7 +357,6 @@ void J2DWindow::draw(JGeometry::TBox2<f32> const& param_0, JGeometry::TBox2<f32>
}
}
/* 802FB000-802FB12C 2F5940 012C+00 1/0 1/0 0/0 .text resize__9J2DWindowFff */
void J2DWindow::resize(f32 param_0, f32 param_1) {
f32 f31 = getWidth();
f32 f30 = getHeight();
@@ -398,14 +383,12 @@ void J2DWindow::setContentsColor(JUtility::TColor param_0, JUtility::TColor para
field_0x134.set(param_3);
}
/* 802FB1D8-802FB240 2F5B18 0068+00 1/0 1/0 0/0 .text drawSelf__9J2DWindowFff */
void J2DWindow::drawSelf(f32 param_0, f32 param_1) {
Mtx stack_38;
MTXIdentity(stack_38);
drawSelf(param_0, param_1, &stack_38);
}
/* 802FB240-802FB338 2F5B80 00F8+00 1/0 0/0 0/0 .text drawSelf__9J2DWindowFffPA3_A4_f */
void J2DWindow::drawSelf(f32 param_0, f32 param_1, Mtx* param_2) {
JGeometry::TBox2<f32> stack_50(mBounds);
stack_50.addPos(JGeometry::TVec2<f32>(param_0, param_1));
@@ -418,8 +401,6 @@ void J2DWindow::drawSelf(f32 param_0, f32 param_1, Mtx* param_2) {
clip(field_0x114);
}
/* 802FB338-802FB634 2F5C78 02FC+00 1/0 0/0 0/0 .text
* drawContents__9J2DWindowFRCQ29JGeometry8TBox2<f> */
void J2DWindow::drawContents(JGeometry::TBox2<f32> const& param_0) {
if (param_0.isValid()) {
GXSetNumChans(1);
@@ -477,8 +458,6 @@ void J2DWindow::drawContents(JGeometry::TBox2<f32> const& param_0) {
}
}
/* 802FB634-802FB7C8 2F5F74 0194+00 2/2 0/0 0/0 .text
* drawFrameTexture__9J2DWindowFP10JUTTextureffffUsUsUsUsb */
void J2DWindow::drawFrameTexture(JUTTexture* param_0, f32 param_1, f32 param_2, f32 param_3,
f32 param_4, u16 param_5, u16 param_6, u16 param_7, u16 param_8,
bool param_9) {
@@ -507,8 +486,6 @@ void J2DWindow::drawFrameTexture(JUTTexture* param_0, f32 param_1, f32 param_2,
GXSetVtxAttrFmt(GX_VTXFMT0, GX_VA_POS, GX_POS_XYZ, GX_S16, 0);
}
/* 802FB7C8-802FB868 2F6108 00A0+00 1/1 0/0 0/0 .text
* drawFrameTexture__9J2DWindowFP10JUTTextureffbbb */
void J2DWindow::drawFrameTexture(JUTTexture* param_0, f32 param_1, f32 param_2, bool param_3,
bool param_4, bool param_5) {
u16 r31 = param_4 ? u16(0x8000) : u16(0);
@@ -519,7 +496,6 @@ void J2DWindow::drawFrameTexture(JUTTexture* param_0, f32 param_1, f32 param_2,
r30, r31, param_5);
}
/* 802FB868-802FBB90 2F61A8 0328+00 1/1 0/0 0/0 .text drawContentsTexture__9J2DWindowFffff */
void J2DWindow::drawContentsTexture(f32 param_0, f32 param_1, f32 param_2, f32 param_3) {
f32 f29 = param_0 + param_2;
f32 f28 = param_1 + param_3;
@@ -559,8 +535,6 @@ void J2DWindow::drawContentsTexture(f32 param_0, f32 param_1, f32 param_2, f32 p
GXSetVtxAttrFmt(GX_VTXFMT0, GX_VA_POS, GX_POS_XYZ, GX_S16, 0);
}
/* 802FBB90-802FBE60 2F64D0 02D0+00 2/2 0/0 0/0 .text
* setTevMode__9J2DWindowFP10JUTTextureQ28JUtility6TColorQ28JUtility6TColor */
void J2DWindow::setTevMode(JUTTexture* param_0, JUtility::TColor param_1,
JUtility::TColor param_2) {
if (param_1 == 0 && param_2 == 0xffffffff) {
@@ -600,8 +574,6 @@ void J2DWindow::setTevMode(JUTTexture* param_0, JUtility::TColor param_1,
GXSetBlendMode(GX_BM_BLEND, GX_BL_SRCALPHA, GX_BL_INVSRCALPHA, GX_LO_SET);
}
/* 802FBE60-802FBEDC 2F67A0 007C+00 1/0 0/0 0/0 .text getFrameTexture__9J2DWindowCFUcUc
*/
JUTTexture* J2DWindow::getFrameTexture(u8 param_0, u8 param_1) const {
JUTTexture* tmp[4] = {NULL, NULL, NULL, NULL};
tmp[0] = field_0x100;
@@ -614,7 +586,6 @@ JUTTexture* J2DWindow::getFrameTexture(u8 param_0, u8 param_1) const {
return tmp[param_0];
}
/* 802FBEDC-802FBF98 2F681C 00BC+00 1/0 0/0 0/0 .text isUsed__9J2DWindowFPC7ResTIMG */
bool J2DWindow::isUsed(ResTIMG const* param_0) {
JUTTexture* tmp[5] = {NULL, NULL, NULL, NULL, NULL};
tmp[0] = field_0x100;
@@ -630,18 +601,14 @@ bool J2DWindow::isUsed(ResTIMG const* param_0) {
return J2DPane::isUsed(param_0);
}
/* 802FBF98-802FBFA0 2F68D8 0008+00 1/0 1/0 0/0 .text getTypeID__9J2DWindowCFv */
u16 J2DWindow::getTypeID() const {
return 17;
}
/* 802FBFA0-802FBFE8 2F68E0 0048+00 1/0 0/0 0/0 .text draw__9J2DWindowFffff */
void J2DWindow::draw(f32 param_0, f32 param_1, f32 param_2, f32 param_3) {
draw(JGeometry::TBox2<f32>(param_0, param_1, param_0 + param_2, param_1 + param_3));
}
/* 802FBFE8-802FC000 2F6928 0018+00 1/0 0/0 0/0 .text getContentsTexture__9J2DWindowCFUc
*/
JUTTexture* J2DWindow::getContentsTexture(u8 param_0) const {
if (param_0 != 0) {
return NULL;
@@ -649,8 +616,6 @@ JUTTexture* J2DWindow::getContentsTexture(u8 param_0) const {
return field_0x110;
}
/* 802FC000-802FC01C 2F6940 001C+00 1/0 0/0 0/0 .text
* getMaterial__9J2DWindowCFRQ29J2DWindow9TMaterial */
void J2DWindow::getMaterial(J2DWindow::TMaterial& param_0) const {
param_0.field_0x0 = NULL;
param_0.field_0x4 = NULL;
@@ -659,23 +624,18 @@ void J2DWindow::getMaterial(J2DWindow::TMaterial& param_0) const {
param_0.field_0x10 = NULL;
}
/* 802FC01C-802FC024 2F695C 0008+00 1/0 0/0 0/0 .text getFrameMaterial__9J2DWindowCFUc */
J2DMaterial* J2DWindow::getFrameMaterial(u8 param_0) const {
return NULL;
}
/* 802FC024-802FC02C 2F6964 0008+00 1/0 0/0 0/0 .text getContentsMaterial__9J2DWindowCFv
*/
J2DMaterial* J2DWindow::getContentsMaterial() const {
return NULL;
}
/* 802FC02C-802FC04C 2F696C 0020+00 1/0 0/0 0/0 .text isUsed__9J2DWindowFPC7ResFONT */
bool J2DWindow::isUsed(ResFONT const* param_0) {
return J2DPane::isUsed(param_0);
}
/* 802FC04C-802FC050 2F698C 0004+00 1/0 0/0 0/0 .text rewriteAlpha__9J2DWindowFv */
void J2DWindow::rewriteAlpha() {
/* empty function */
}
-74
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J2DWindowEx
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J2DGraph/J2DWindowEx.h"
@@ -27,8 +22,6 @@ struct J2DWindowExDef {
STATIC_ASSERT(sizeof(J2DWindowExDef) == 0x40);
/* 80300C94-80300F80 2FB5D4 02EC+00 0/0 1/1 0/0 .text
* __ct__11J2DWindowExFP7J2DPaneP20JSURandomInputStreamUlP11J2DMaterial */
J2DWindowEx::J2DWindowEx(J2DPane* param_0, JSURandomInputStream* param_1, u32 param_2,
J2DMaterial* param_3) : J2DWindow() {
mAnmVisibilityFull = NULL;
@@ -87,7 +80,6 @@ J2DWindowEx::J2DWindowEx(J2DPane* param_0, JSURandomInputStream* param_1, u32 pa
setMinSize();
}
/* 80300F80-80301144 2FB8C0 01C4+00 1/1 0/0 0/0 .text setMinSize__11J2DWindowExFv */
void J2DWindowEx::setMinSize() {
field_0x140 = 1;
field_0x142 = 1;
@@ -111,7 +103,6 @@ void J2DWindowEx::setMinSize() {
+ mFrameMaterial[2]->getTevBlock()->getTexture(0)->getHeight();
}
/* 80301144-8030122C 2FBA84 00E8+00 1/0 0/0 0/0 .text __dt__11J2DWindowExFv */
J2DWindowEx::~J2DWindowEx() {
for (u8 i = 0; i < 4; i++) {
if (field_0x170 & (1 << i)) {
@@ -124,8 +115,6 @@ J2DWindowEx::~J2DWindowEx() {
}
}
/* 8030122C-803012CC 2FBB6C 00A0+00 1/0 0/0 0/0 .text drawSelf__11J2DWindowExFffPA3_A4_f
*/
void J2DWindowEx::drawSelf(f32 param_0, f32 param_1, f32 (*param_2)[3][4]) {
JGeometry::TBox2<f32> aTStack_50(mBounds);
Mtx auStack_40;
@@ -136,8 +125,6 @@ void J2DWindowEx::drawSelf(f32 param_0, f32 param_1, f32 (*param_2)[3][4]) {
clip(field_0x114);
}
/* 803012CC-80301994 2FBC0C 06C8+00 2/2 0/0 0/0 .text
* draw_private__11J2DWindowExFRCQ29JGeometry8TBox2<f>RCQ29JGeometry8TBox2<f> */
void J2DWindowEx::draw_private(JGeometry::TBox2<f32> const& param_0,
JGeometry::TBox2<f32> const& param_1) {
if (param_0.getWidth() >= field_0x140 && param_0.getHeight() >= field_0x142) {
@@ -318,8 +305,6 @@ static f32 dummy_literal() {
return 0.0f;
}
/* 80301994-80301D74 2FC2D4 03E0+00 1/0 0/0 0/0 .text
* drawContents__11J2DWindowExFRCQ29JGeometry8TBox2<f> */
void J2DWindowEx::drawContents(JGeometry::TBox2<f32> const& param_1) {
if (!param_1.isValid() || mContentsMaterial == NULL) {
return;
@@ -398,8 +383,6 @@ void J2DWindowEx::drawContents(JGeometry::TBox2<f32> const& param_1) {
}
/* 80301D74-80301FC8 2FC6B4 0254+00 1/1 0/0 0/0 .text
* drawFrameTexture__11J2DWindowExFffffUsUsUsUsP11J2DMaterialb */
void J2DWindowEx::drawFrameTexture(f32 param_1, f32 param_2, f32 param_3, f32 param_4, u16 param_5,
u16 param_6, u16 param_7, u16 param_8, J2DMaterial* param_9,
bool param_10) {
@@ -446,8 +429,6 @@ void J2DWindowEx::drawFrameTexture(f32 param_1, f32 param_2, f32 param_3, f32 pa
}
}
/* 80301FC8-80302164 2FC908 019C+00 1/0 0/0 0/0 .text draw__11J2DWindowExFRCQ29JGeometry8TBox2<f>
*/
void J2DWindowEx::draw(JGeometry::TBox2<f32> const& param_1) {
bool isMissingTexture = false;
JUTTexture* local_68[4];
@@ -474,8 +455,6 @@ void J2DWindowEx::draw(JGeometry::TBox2<f32> const& param_1) {
draw(param_1, aTStack_78);
}
/* 80302164-80302284 2FCAA4 0120+00 1/0 0/0 0/0 .text
* draw__11J2DWindowExFRCQ29JGeometry8TBox2<f>RCQ29JGeometry8TBox2<f> */
void J2DWindowEx::draw(JGeometry::TBox2<f32> const& param_1, JGeometry::TBox2<f32> const& param_2) {
rewriteAlpha();
mColorAlpha = mAlpha;
@@ -496,7 +475,6 @@ void J2DWindowEx::draw(JGeometry::TBox2<f32> const& param_1, JGeometry::TBox2<f3
GXLoadPosMtxImm(auStack_60, 0);
}
/* 80302284-80302388 2FCBC4 0104+00 1/1 0/0 0/0 .text setTevOrder__11J2DWindowExFb */
void J2DWindowEx::setTevOrder(bool param_0) {
u16 local_28[2];
if (!param_0) {
@@ -521,7 +499,6 @@ void J2DWindowEx::setTevOrder(bool param_0) {
}
}
/* 80302388-803024B4 2FCCC8 012C+00 1/1 0/0 0/0 .text setTevStage__11J2DWindowExFb */
void J2DWindowEx::setTevStage(bool param_1) {
for (int i = 0; i < 4; i++) {
J2DTevStage* pJVar3 = mFrameMaterial[i]->getTevBlock()->getTevStage(0);
@@ -547,50 +524,40 @@ void J2DWindowEx::setTevStage(bool param_1) {
}
}
/* 803A1C70-803A1C80 02E2D0 0010+00 0/0 0/0 0/0 .rodata @1557 */
static u8 const lit_1557[16] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
/* 803A1C80-803A1C90 02E2E0 0010+00 0/0 0/0 0/0 .rodata @1566 */
static u8 const lit_1566[16] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
/* 803A1C90-803A1CA0 02E2F0 0010+00 0/0 0/0 0/0 .rodata @1575 */
static u8 const lit_1575[16] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
/* 803A1CA0-803A1CB0 02E300 0010+00 0/0 0/0 0/0 .rodata @1581 */
static u8 const lit_1581[16] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
/* 803A1CB0-803A1CC0 02E310 0010+00 0/0 0/0 0/0 .rodata @1587 */
static u8 const lit_1587[16] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
/* 803A1CC0-803A1CD0 02E320 0010+00 0/0 0/0 0/0 .rodata @1596 */
static u8 const lit_1596[16] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
/* 803A1CD0-803A1CE0 02E330 0010+00 0/0 0/0 0/0 .rodata @1605 */
static u8 const lit_1605[16] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
/* 803A1CE0-803A1CF0 02E340 0010+00 0/0 0/0 0/0 .rodata @1612 */
static u8 const lit_1612[16] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
/* 803024B4-80302764 2FCDF4 02B0+00 1/1 0/0 0/0 .text
* setStage__11J2DWindowExFP11J2DTevStageQ211J2DWindowEx10stage_enum */
void J2DWindowEx::setStage(J2DTevStage* param_0, J2DWindowEx::stage_enum param_1) {
s8 local_30[6][4] = {
{0x0f, 0x08, 0x0a, 0x0f}, {0x0f, 0x08, 0x0a, 0x0f}, {0x0f, 0x0a, 0x00, 0x0f},
@@ -616,8 +583,6 @@ void J2DWindowEx::setStage(J2DTevStage* param_0, J2DWindowEx::stage_enum param_1
}
/* 80302764-803027EC 2FD0A4 0088+00 1/0 0/0 0/0 .text setBlack__11J2DWindowExFQ28JUtility6TColor
*/
bool J2DWindowEx::setBlack(JUtility::TColor black) {
JUtility::TColor dummy,white;
@@ -628,8 +593,6 @@ bool J2DWindowEx::setBlack(JUtility::TColor black) {
return setBlackWhite(black, white);
}
/* 803027EC-80302874 2FD12C 0088+00 1/0 0/0 0/0 .text setWhite__11J2DWindowExFQ28JUtility6TColor
*/
bool J2DWindowEx::setWhite(JUtility::TColor white) {
JUtility::TColor black,dummy;
@@ -640,8 +603,6 @@ bool J2DWindowEx::setWhite(JUtility::TColor white) {
return setBlackWhite(black, white);
}
/* 80302874-80302A4C 2FD1B4 01D8+00 1/0 0/0 0/0 .text
* setBlackWhite__11J2DWindowExFQ28JUtility6TColorQ28JUtility6TColor */
// NONMATCHING - J2DGXColorS10 issue
bool J2DWindowEx::setBlackWhite(JUtility::TColor black, JUtility::TColor white) {
for (int i = 0; i < 4; i++) {
@@ -684,7 +645,6 @@ bool J2DWindowEx::setBlackWhite(JUtility::TColor black, JUtility::TColor white)
return true;
}
/* 80302A4C-80302BE8 2FD38C 019C+00 4/4 0/0 0/0 .text getBlackWhite__11J2DWindowExCFPQ28JUtility6TColorPQ28JUtility6TColor */
bool J2DWindowEx::getBlackWhite(JUtility::TColor* param_0, JUtility::TColor* param_1) const {
if (mFrameMaterial[0] == NULL) {
return false;
@@ -718,8 +678,6 @@ bool J2DWindowEx::getBlackWhite(JUtility::TColor* param_0, JUtility::TColor* par
return true;
}
/* 80302BE8-80302C88 2FD528 00A0+00 1/1 0/0 0/0 .text
* isSetBlackWhite__11J2DWindowExCFQ28JUtility6TColorQ28JUtility6TColor */
bool J2DWindowEx::isSetBlackWhite(JUtility::TColor param_0, JUtility::TColor param_1) const {
if ((u32)param_0 == 0 && (u32)param_1 == 0xffffffff) {
return true;
@@ -732,7 +690,6 @@ bool J2DWindowEx::isSetBlackWhite(JUtility::TColor param_0, JUtility::TColor par
return true;
}
/* 80302C88-80302CE8 2FD5C8 0060+00 1/0 0/0 0/0 .text getBlack__11J2DWindowExCFv */
JUtility::TColor J2DWindowEx::getBlack() const {
JUtility::TColor black, white;
if (!getBlackWhite(&black, &white)) {
@@ -742,7 +699,6 @@ JUtility::TColor J2DWindowEx::getBlack() const {
return black;
}
/* 80302CE8-80302D48 2FD628 0060+00 1/0 0/0 0/0 .text getWhite__11J2DWindowExCFv */
JUtility::TColor J2DWindowEx::getWhite() const {
JUtility::TColor black, white;
if (!getBlackWhite(&black, &white)) {
@@ -752,7 +708,6 @@ JUtility::TColor J2DWindowEx::getWhite() const {
return white;
}
/* 80302D48-80302D98 2FD688 0050+00 1/0 0/0 0/0 .text setAlpha__11J2DWindowExFUc */
void J2DWindowEx::setAlpha(u8 param_0) {
mAlpha = param_0;
@@ -771,7 +726,6 @@ void J2DWindowEx::setAlpha(u8 param_0) {
}
}
/* 80302D98-80302DF4 2FD6D8 005C+00 1/0 0/0 0/0 .text setCullBack__11J2DWindowExF11_GXCullMode */
void J2DWindowEx::setCullBack(_GXCullMode param_0) {
mCullMode = param_0;
@@ -787,14 +741,12 @@ void J2DWindowEx::setCullBack(_GXCullMode param_0) {
J2DPane::setCullBack(param_0);
}
/* 80302DF4-80302E0C 2FD734 0018+00 1/0 0/0 0/0 .text rewriteAlpha__11J2DWindowExFv */
void J2DWindowEx::rewriteAlpha() {
if (mContentsMaterial != NULL) {
mAlpha = mContentsMaterial->getColorBlock()->getMatColor(0)->a;
}
}
/* 80302E0C-80302E74 2FD74C 0068+00 1/0 0/0 0/0 .text getFrameTexture__11J2DWindowExCFUcUc */
JUTTexture* J2DWindowEx::getFrameTexture(u8 param_0, u8 param_1) const {
J2DMaterial* frameMaterial = getFrameMaterial(param_0);
if (frameMaterial != NULL && frameMaterial->getTevBlock() != NULL) {
@@ -803,7 +755,6 @@ JUTTexture* J2DWindowEx::getFrameTexture(u8 param_0, u8 param_1) const {
return NULL;
}
/* 80302E74-80302EDC 2FD7B4 0068+00 1/0 0/0 0/0 .text getContentsTexture__11J2DWindowExCFUc */
JUTTexture* J2DWindowEx::getContentsTexture(u8 param_0) const {
J2DMaterial* frameMaterial = getContentsMaterial();
if (frameMaterial != NULL && frameMaterial->getTevBlock() != NULL) {
@@ -812,7 +763,6 @@ JUTTexture* J2DWindowEx::getContentsTexture(u8 param_0) const {
return NULL;
}
/* 80302EDC-80302FFC 2FD81C 0120+00 1/0 0/0 0/0 .text isUsed__11J2DWindowExFPC7ResTIMG */
bool J2DWindowEx::isUsed(ResTIMG const* timg) {
for (u8 i = 0; i < 4; i++) {
if (mFrameMaterial[i] != NULL && mFrameMaterial[i]->getTevBlock() != NULL) {
@@ -837,8 +787,6 @@ bool J2DWindowEx::isUsed(ResTIMG const* timg) {
return J2DPane::isUsed(timg);
}
/* 80302FFC-80303084 2FD93C 0088+00 1/0 0/0 0/0 .text setAnimation__11J2DWindowExFP11J2DAnmColor
*/
void J2DWindowEx::setAnimation(J2DAnmColor* anmColor) {
for (u8 i = 0; i < 4; i++) {
if (isNeedSetAnm(i)) {
@@ -850,8 +798,6 @@ void J2DWindowEx::setAnimation(J2DAnmColor* anmColor) {
}
}
/* 80303084-8030310C 2FD9C4 0088+00 1/0 0/0 0/0 .text
* setAnimation__11J2DWindowExFP19J2DAnmTextureSRTKey */
void J2DWindowEx::setAnimation(J2DAnmTextureSRTKey* param_0) {
for (u8 i = 0; i < 4; i++) {
if (isNeedSetAnm(i)) {
@@ -863,8 +809,6 @@ void J2DWindowEx::setAnimation(J2DAnmTextureSRTKey* param_0) {
}
}
/* 8030310C-80303194 2FDA4C 0088+00 1/0 0/0 0/0 .text
* setAnimation__11J2DWindowExFP16J2DAnmTexPattern */
void J2DWindowEx::setAnimation(J2DAnmTexPattern* param_0) {
for (u8 i = 0; i < 4; i++) {
if (isNeedSetAnm(i)) {
@@ -876,8 +820,6 @@ void J2DWindowEx::setAnimation(J2DAnmTexPattern* param_0) {
}
}
/* 80303194-8030321C 2FDAD4 0088+00 1/0 0/0 0/0 .text
* setAnimation__11J2DWindowExFP15J2DAnmTevRegKey */
void J2DWindowEx::setAnimation(J2DAnmTevRegKey* param_0) {
for (u8 i = 0; i < 4; i++) {
if (isNeedSetAnm(i)) {
@@ -889,7 +831,6 @@ void J2DWindowEx::setAnimation(J2DAnmTevRegKey* param_0) {
}
}
/* 8030321C-80303274 2FDB5C 0058+00 4/4 0/0 0/0 .text isNeedSetAnm__11J2DWindowExFUc */
bool J2DWindowEx::isNeedSetAnm(u8 param_0) {
for (u8 i = 0; i < param_0; i++) {
if (mFrameMaterial[i] == mFrameMaterial[param_0]) {
@@ -899,14 +840,10 @@ bool J2DWindowEx::isNeedSetAnm(u8 param_0) {
return mFrameMaterial[param_0] != NULL;
}
/* 80303274-8030327C -00001 0008+00 0/0 0/0 0/0 .text
* setAnimation__11J2DWindowExFP20J2DAnmVisibilityFull */
void J2DWindowEx::setAnimation(J2DAnmVisibilityFull* param_0) {
mAnmVisibilityFull = param_0;
}
/* 8030327C-80303370 2FDBBC 00F4+00 1/0 0/0 0/0 .text
* setAnimation__11J2DWindowExFP14J2DAnmVtxColor */
void J2DWindowEx::setAnimation(J2DAnmVtxColor* param_0) {
mAnmVtxColor = param_0;
field_0x17c = 0;
@@ -936,8 +873,6 @@ void J2DWindowEx::setAnimation(J2DAnmVtxColor* param_0) {
}
}
/* 80303370-80303510 2FDCB0 01A0+00 1/0 0/0 0/0 .text
* animationPane__11J2DWindowExFPC15J2DAnmTransform */
const J2DAnmTransform* J2DWindowEx::animationPane(J2DAnmTransform const* param_0) {
if (mAnmVisibilityFull != 0 && field_0x166 != 0xffff) {
u8 visibility;
@@ -976,8 +911,6 @@ const J2DAnmTransform* J2DWindowEx::animationPane(J2DAnmTransform const* param_0
return J2DPane::animationPane(param_0);
}
/* 80303510-80303534 2FDE50 0024+00 1/0 0/0 0/0 .text getFrameMaterial__11J2DWindowExCFUc
*/
J2DMaterial* J2DWindowEx::getFrameMaterial(u8 index) const {
if (index >= 4) {
return NULL;
@@ -986,13 +919,10 @@ J2DMaterial* J2DWindowEx::getFrameMaterial(u8 index) const {
return mFrameMaterial[index];
}
/* 80303534-8030353C 2FDE74 0008+00 1/0 0/0 0/0 .text getContentsMaterial__11J2DWindowExCFv */
J2DMaterial* J2DWindowEx::getContentsMaterial() const {
return mContentsMaterial;
}
/* 8030353C-80303568 2FDE7C 002C+00 1/0 0/0 0/0 .text
* getMaterial__11J2DWindowExCFRQ29J2DWindow9TMaterial */
void J2DWindowEx::getMaterial(J2DWindow::TMaterial& param_0) const {
param_0.field_0x0 = mFrameMaterial[0];
param_0.field_0x4 = mFrameMaterial[1];
@@ -1001,13 +931,11 @@ void J2DWindowEx::getMaterial(J2DWindow::TMaterial& param_0) const {
param_0.field_0x10 = mContentsMaterial;
}
/* 80303568-803035C0 2FDEA8 0058+00 1/0 0/0 0/0 .text draw__11J2DWindowExFffff */
void J2DWindowEx::draw(f32 param_0, f32 param_1, f32 param_2, f32 param_3) {
draw(JGeometry::TBox2<f32>(JGeometry::TVec2<f32>(param_0, param_1),
JGeometry::TVec2<f32>(param_0 + param_2, param_1 + param_3)));
}
/* 803035C0-803035FC 2FDF00 003C+00 1/0 0/0 0/0 .text setCullBack__11J2DWindowExFb */
void J2DWindowEx::setCullBack(bool param_0) {
_GXCullMode mode;
if (param_0) {
@@ -1018,12 +946,10 @@ void J2DWindowEx::setCullBack(bool param_0) {
setCullBack(mode);
}
/* 803035FC-8030361C 2FDF3C 0020+00 1/0 0/0 0/0 .text isUsed__11J2DWindowExFPC7ResFONT */
bool J2DWindowEx::isUsed(ResFONT const* param_0) {
return J2DPane::isUsed(param_0);
}
/* 8030361C-8030363C 2FDF5C 0020+00 1/0 0/0 0/0 .text setAnimation__11J2DWindowExFP10J2DAnmBase */
void J2DWindowEx::setAnimation(J2DAnmBase* param_0) {
J2DPane::setAnimation(param_0);
}
+2 -51
View File
@@ -4,7 +4,6 @@
#include "JSystem/J3DGraphBase/J3DStruct.h"
#include "JSystem/JMath/JMath.h"
/* 803283FC-8032842C 322D3C 0030+00 0/0 25/25 285/285 .text init__12J3DFrameCtrlFs */
void J3DFrameCtrl::init(s16 endFrame) {
mAttribute = EMode_LOOP;
mState = 0;
@@ -15,8 +14,6 @@ void J3DFrameCtrl::init(s16 endFrame) {
mFrame = 0.0f;
}
/* 8032842C-803289CC 322D6C 05A0+00 0/0 92/92 382/382 .text checkPass__12J3DFrameCtrlFf
*/
int J3DFrameCtrl::checkPass(f32 passFrame) {
f32 next_frame = mFrame + mRate;
@@ -135,7 +132,6 @@ int J3DFrameCtrl::checkPass(f32 passFrame) {
}
/* 803289CC-80328E40 32330C 0474+00 0/0 3/3 0/0 .text update__12J3DFrameCtrlFv */
void J3DFrameCtrl::update() {
mState = 0;
mFrame += mRate;
@@ -206,7 +202,6 @@ void J3DFrameCtrl::update() {
}
}
/* 80328E40-80328E90 323780 0050+00 0/0 3/3 0/0 .text __ct__15J3DAnmTransformFsPfPsPf */
J3DAnmTransform::J3DAnmTransform(s16 frameMax, f32* pScaleData, s16* pRotData, f32* pTransData)
: J3DAnmBase(frameMax) {
mScaleData = pScaleData;
@@ -218,8 +213,6 @@ J3DAnmTransform::J3DAnmTransform(s16 frameMax, f32* pScaleData, s16* pRotData, f
field_0x1e = 0;
}
/* 80328E90-803291F0 3237D0 0360+00 1/0 0/0 0/0 .text
* getTransform__19J3DAnmTransformFullCFUsP16J3DTransformInfo */
void J3DAnmTransformFull::getTransform(u16 jointNo, J3DTransformInfo* pTransform) const {
J3D_ASSERT_RANGE(317, jointNo >= 0 && jointNo < field_0x1e);
J3D_ASSERT_NULLPTR(318, pTransform != NULL);
@@ -310,8 +303,6 @@ void J3DAnmTransformFull::getTransform(u16 jointNo, J3DTransformInfo* pTransform
}
}
/* 803291F0-80329A34 323B30 0844+00 1/0 0/0 0/0 .text
* getTransform__27J3DAnmTransformFullWithLerpCFUsP16J3DTransformInfo */
void J3DAnmTransformFullWithLerp::getTransform(u16 jointNo, J3DTransformInfo* pTransform) const {
J3D_ASSERT_RANGE(421, jointNo >= 0 && jointNo < field_0x1e);
J3D_ASSERT_NULLPTR(422, pTransform != NULL);
@@ -520,6 +511,7 @@ inline f32 J3DHermiteInterpolation(register f32 pp1, register s16 const* pp2,
register s16 const* pp3, register s16 const* pp4,
register s16 const* pp5, register s16 const* pp6,
register s16 const* pp7) {
#ifdef __MWERKS__
register f32 p1 = pp1;
register f32 ff8;
register f32 ff7;
@@ -561,6 +553,7 @@ inline f32 J3DHermiteInterpolation(register f32 pp1, register s16 const* pp2,
}
// clang-format on
return fout;
#endif
}
template<typename T>
@@ -614,8 +607,6 @@ f32 J3DGetKeyFrameInterpolation(f32 frame, J3DAnmKeyTableBase* pKeyTable, T* pDa
}
}
/* 80329A34-80329E5C 324374 0428+00 0/0 1/1 0/0 .text
* calcTransform__18J3DAnmTransformKeyCFfUsP16J3DTransformInfo */
void J3DAnmTransformKey::calcTransform(f32 frame, u16 jointNo, J3DTransformInfo* pTransform) const {
J3D_ASSERT_RANGE(829, jointNo >= 0 && jointNo < field_0x1e);
J3D_ASSERT_NULLPTR(830, pTransform != NULL);
@@ -734,7 +725,6 @@ void J3DAnmTransformKey::calcTransform(f32 frame, u16 jointNo, J3DTransformInfo*
}
}
/* 80329E5C-80329F14 32479C 00B8+00 0/0 2/2 0/0 .text __ct__19J3DAnmTextureSRTKeyFv */
J3DAnmTextureSRTKey::J3DAnmTextureSRTKey() {
mDecShift = 0;
mTrackNum = mScaleNum = mRotNum = mTransNum = 0;
@@ -748,8 +738,6 @@ J3DAnmTextureSRTKey::J3DAnmTextureSRTKey() {
mTexMtxCalcType = 0;
}
/* 80329F14-8032A184 324854 0270+00 0/0 1/1 0/0 .text
* calcTransform__19J3DAnmTextureSRTKeyCFfUsP17J3DTextureSRTInfo */
void J3DAnmTextureSRTKey::calcTransform(f32 frame, u16 jointNo, J3DTextureSRTInfo* pTexSRTInfo) const {
J3D_ASSERT_RANGE(992, jointNo >= 0 && jointNo < mTrackNum);
J3D_ASSERT_NULLPTR(993, pTexSRTInfo != NULL);
@@ -820,8 +808,6 @@ void J3DAnmTextureSRTKey::calcTransform(f32 frame, u16 jointNo, J3DTextureSRTInf
}
}
/* 8032A184-8032A218 324AC4 0094+00 1/0 0/0 0/0 .text getWeight__17J3DAnmClusterFullCFUs
*/
f32 J3DAnmClusterFull::getWeight(u16 index) const {
int maxFrame = mAnmTable[index].mMaxFrame;
int frame = (int)(mFrame + 0.5f);
@@ -835,8 +821,6 @@ f32 J3DAnmClusterFull::getWeight(u16 index) const {
}
}
/* 8032A218-8032A29C 324B58 0084+00 1/0 0/0 0/0 .text getWeight__16J3DAnmClusterKeyCFUs
*/
f32 J3DAnmClusterKey::getWeight(u16 index) const {
int maxFrame = (u16)mAnmTable[index].mWeightTable.mMaxFrame;
switch (maxFrame) {
@@ -850,7 +834,6 @@ f32 J3DAnmClusterKey::getWeight(u16 index) const {
}
}
/* 8032A29C-8032A30C 324BDC 0070+00 2/2 0/0 0/0 .text __ct__14J3DAnmVtxColorFv */
J3DAnmVtxColor::J3DAnmVtxColor() {
for (int i = 0; i < 2; i++) {
mAnmTableNum[i] = 0;
@@ -860,15 +843,12 @@ J3DAnmVtxColor::J3DAnmVtxColor() {
}
}
/* 8032A30C-8032A368 324C4C 005C+00 0/0 1/1 0/0 .text __ct__18J3DAnmVtxColorFullFv */
J3DAnmVtxColorFull::J3DAnmVtxColorFull() {
for (int i = 0; i < 2; i++) {
mpTable[i] = NULL;
}
}
/* 8032A368-8032A4E0 324CA8 0178+00 1/0 0/0 0/0 .text
* getColor__18J3DAnmVtxColorFullCFUcUsP8_GXColor */
void J3DAnmVtxColorFull::getColor(u8 tableNo, u16 index, GXColor* pColor) const {
J3D_ASSERT_NULLPTR(1254, pColor != NULL);
J3DAnmColorFullTable* entry = &mpTable[tableNo][index];
@@ -912,15 +892,12 @@ void J3DAnmVtxColorFull::getColor(u8 tableNo, u16 index, GXColor* pColor) const
}
}
/* 8032A4E0-8032A53C 324E20 005C+00 0/0 1/1 0/0 .text __ct__17J3DAnmVtxColorKeyFv */
J3DAnmVtxColorKey::J3DAnmVtxColorKey() {
for (int i = 0; i < 2; i++) {
mpTable[i] = 0;
}
}
/* 8032A53C-8032A828 324E7C 02EC+00 1/0 0/0 0/0 .text
* getColor__17J3DAnmVtxColorKeyCFUcUsP8_GXColor */
void J3DAnmVtxColorKey::getColor(u8 tableNo, u16 index, GXColor* pColor) const {
J3D_ASSERT_NULLPTR(1338, pColor != NULL);
J3DAnmColorKeyTable* entry = &mpTable[tableNo][index];
@@ -1003,13 +980,10 @@ void J3DAnmVtxColorKey::getColor(u8 tableNo, u16 index, GXColor* pColor) const {
}
}
/* 8032A828-8032A8A4 325168 007C+00 2/2 0/0 0/0 .text __ct__11J3DAnmColorFv */
J3DAnmColor::J3DAnmColor() : field_0xc(0), field_0xe(0), field_0x10(0),
field_0x12(0), mUpdateMaterialNum(0), mUpdateMaterialID(NULL) {}
/* 8032A8A4-8032A93C 3251E4 0098+00 0/0 1/1 0/0 .text
* searchUpdateMaterialID__11J3DAnmColorFP16J3DMaterialTable */
void J3DAnmColor::searchUpdateMaterialID(J3DMaterialTable* pMatTable) {
for (u16 i = 0; i < mUpdateMaterialNum; i++) {
int index = pMatTable->getMaterialName()->getIndex(mUpdateMaterialName.getName(i));
@@ -1021,7 +995,6 @@ void J3DAnmColor::searchUpdateMaterialID(J3DMaterialTable* pMatTable) {
}
}
/* 8032A93C-8032A990 32527C 0054+00 0/0 1/1 0/0 .text __ct__15J3DAnmColorFullFv */
J3DAnmColorFull::J3DAnmColorFull() {
mColorR = NULL;
mColorG = NULL;
@@ -1030,7 +1003,6 @@ J3DAnmColorFull::J3DAnmColorFull() {
mAnmTable = NULL;
}
/* 8032A990-8032AB00 3252D0 0170+00 1/0 0/0 0/0 .text getColor__15J3DAnmColorFullCFUsP8_GXColor */
void J3DAnmColorFull::getColor(u16 index, GXColor* pColor) const {
J3D_ASSERT_RANGE(1537, index >= 0 && index < mUpdateMaterialNum);
J3D_ASSERT_NULLPTR(1538, pColor != NULL);
@@ -1075,7 +1047,6 @@ void J3DAnmColorFull::getColor(u16 index, GXColor* pColor) const {
}
}
/* 8032AB00-8032AB54 325440 0054+00 0/0 1/1 0/0 .text __ct__14J3DAnmColorKeyFv */
J3DAnmColorKey::J3DAnmColorKey() {
mColorR = NULL;
mColorG = NULL;
@@ -1084,7 +1055,6 @@ J3DAnmColorKey::J3DAnmColorKey() {
mAnmTable = NULL;
}
/* 8032AB54-8032AE18 325494 02C4+00 1/0 0/0 0/0 .text getColor__14J3DAnmColorKeyCFUsP8_GXColor */
void J3DAnmColorKey::getColor(u16 index, GXColor* pColor) const {
J3D_ASSERT_RANGE(1614, index >= 0 && index < mUpdateMaterialNum);
J3D_ASSERT_NULLPTR(1615, pColor != NULL);
@@ -1168,7 +1138,6 @@ void J3DAnmColorKey::getColor(u16 index, GXColor* pColor) const {
}
}
/* 8032AE18-8032AED8 325758 00C0+00 0/0 1/1 0/0 .text __ct__15J3DAnmTevRegKeyFv */
J3DAnmTevRegKey::J3DAnmTevRegKey() {
mCRegUpdateMaterialNum = mKRegUpdateMaterialNum = 0;
@@ -1196,11 +1165,9 @@ J3DAnmTevRegKey::J3DAnmTevRegKey() {
}
/* 8032AED8-8032AF50 325818 0078+00 0/0 2/2 0/0 .text __ct__16J3DAnmTexPatternFv */
J3DAnmTexPattern::J3DAnmTexPattern() : mTextureIndex(NULL), mAnmTable(NULL),
field_0x14(0), mUpdateMaterialNum(0), mUpdateMaterialID(NULL) {}
/* 8032AF50-8032B004 325890 00B4+00 0/0 1/1 72/72 .text getTexNo__16J3DAnmTexPatternCFUsPUs */
void J3DAnmTexPattern::getTexNo(u16 index, u16* pTexNo) const {
u32 maxFrame = mAnmTable[index].mMaxFrame;
J3D_ASSERT_RANGE(1743, index >= 0 && index < mUpdateMaterialNum);
@@ -1215,8 +1182,6 @@ void J3DAnmTexPattern::getTexNo(u16 index, u16* pTexNo) const {
}
}
/* 8032B004-8032B09C 325944 0098+00 1/1 1/1 0/0 .text
* searchUpdateMaterialID__16J3DAnmTexPatternFP16J3DMaterialTable */
void J3DAnmTexPattern::searchUpdateMaterialID(J3DMaterialTable* pMatTable) {
J3D_ASSERT_NULLPTR(1790, pMatTable != NULL);
@@ -1230,15 +1195,11 @@ void J3DAnmTexPattern::searchUpdateMaterialID(J3DMaterialTable* pMatTable) {
}
}
/* 8032B09C-8032B0C0 3259DC 0024+00 0/0 4/4 1/1 .text
* searchUpdateMaterialID__16J3DAnmTexPatternFP12J3DModelData */
void J3DAnmTexPattern::searchUpdateMaterialID(J3DModelData* pModelData) {
J3D_ASSERT_NULLPTR(1813, pModelData != NULL);
searchUpdateMaterialID(&pModelData->getMaterialTable());
}
/* 8032B0C0-8032B1D4 325A00 0114+00 1/1 1/1 0/0 .text
* searchUpdateMaterialID__19J3DAnmTextureSRTKeyFP16J3DMaterialTable */
void J3DAnmTextureSRTKey::searchUpdateMaterialID(J3DMaterialTable* pMatTable) {
J3D_ASSERT_NULLPTR(1832, pMatTable != NULL);
@@ -1261,15 +1222,11 @@ void J3DAnmTextureSRTKey::searchUpdateMaterialID(J3DMaterialTable* pMatTable) {
}
}
/* 8032B1D4-8032B1F8 325B14 0024+00 0/0 8/8 6/6 .text
* searchUpdateMaterialID__19J3DAnmTextureSRTKeyFP12J3DModelData */
void J3DAnmTextureSRTKey::searchUpdateMaterialID(J3DModelData* pModelData) {
J3D_ASSERT_NULLPTR(1871, pModelData != NULL);
searchUpdateMaterialID(&pModelData->getMaterialTable());
}
/* 8032B1F8-8032B4BC 325B38 02C4+00 0/0 2/2 1/1 .text
* getTevColorReg__15J3DAnmTevRegKeyCFUsP11_GXColorS10 */
void J3DAnmTevRegKey::getTevColorReg(u16 index, GXColorS10* pColor) const {
J3D_ASSERT_RANGE(1887, index >= 0 && index < mCRegUpdateMaterialNum);
J3D_ASSERT_NULLPTR(1888, pColor != NULL);
@@ -1353,8 +1310,6 @@ void J3DAnmTevRegKey::getTevColorReg(u16 index, GXColorS10* pColor) const {
}
}
/* 8032B4BC-8032B780 325DFC 02C4+00 0/0 1/1 1/1 .text
* getTevKonstReg__15J3DAnmTevRegKeyCFUsP8_GXColor */
void J3DAnmTevRegKey::getTevKonstReg(u16 index, GXColor* pColor) const {
J3D_ASSERT_RANGE(1989, index >= 0 && index < mKRegUpdateMaterialNum);
J3D_ASSERT_NULLPTR(1990, pColor != NULL);
@@ -1438,8 +1393,6 @@ void J3DAnmTevRegKey::getTevKonstReg(u16 index, GXColor* pColor) const {
}
}
/* 8032B780-8032B87C 3260C0 00FC+00 1/1 1/1 0/0 .text
* searchUpdateMaterialID__15J3DAnmTevRegKeyFP16J3DMaterialTable */
void J3DAnmTevRegKey::searchUpdateMaterialID(J3DMaterialTable* pMatTable) {
J3D_ASSERT_NULLPTR(2083, pMatTable != NULL);
@@ -1462,8 +1415,6 @@ void J3DAnmTevRegKey::searchUpdateMaterialID(J3DMaterialTable* pMatTable) {
}
}
/* 8032B87C-8032B8A0 3261BC 0024+00 0/0 9/9 4/4 .text
* searchUpdateMaterialID__15J3DAnmTevRegKeyFP12J3DModelData */
void J3DAnmTevRegKey::searchUpdateMaterialID(J3DModelData* pModelData) {
J3D_ASSERT_NULLPTR(2119, pModelData != NULL);
searchUpdateMaterialID(&pModelData->getMaterialTable());
@@ -6,7 +6,6 @@
#include "JSystem/JMath/JMATrigonometric.h"
#include "dolphin/base/PPCArch.h"
/* 8032E1F8-8032E230 328B38 0038+00 0/0 1/1 0/0 .text __ct__13J3DDeformDataFv */
J3DDeformData::J3DDeformData() {
mClusterNum = 0;
mClusterKeyNum = 0;
@@ -22,23 +21,18 @@ J3DDeformData::J3DDeformData() {
mClusterKeyName = NULL;
}
/* 8032E230-8032E274 328B70 0044+00 0/0 1/1 0/0 .text offAllFlag__13J3DDeformDataFUl */
void J3DDeformData::offAllFlag(u32 i_flag) {
for (u16 i = 0; i < mClusterNum; i++) {
mClusterPointer[i].getDeformer()->offFlag(i_flag);
}
}
/* 8032E274-8032E298 328BB4 0024+00 0/0 1/1 0/0 .text deform__13J3DDeformDataFP8J3DModel
*/
void J3DDeformData::deform(J3DModel* model) {
J3D_ASSERT_NULLPTR(110, model);
deform(model->getVertexBuffer());
}
/* 8032E298-8032E364 328BD8 00CC+00 1/1 0/0 0/0 .text deform__13J3DDeformDataFP15J3DVertexBuffer
*/
void J3DDeformData::deform(J3DVertexBuffer* buffer) {
J3D_ASSERT_NULLPTR(141, buffer);
@@ -59,14 +53,12 @@ void J3DDeformData::deform(J3DVertexBuffer* buffer) {
buffer->setCurrentVtxNrm(buffer->getVtxNrmArrayPointer(0));
}
/* 8032E364-8032E39C 328CA4 0038+00 0/0 1/1 0/0 .text setAnm__13J3DDeformDataFP13J3DAnmCluster */
void J3DDeformData::setAnm(J3DAnmCluster* anm) {
for (u16 i = 0; i < mClusterNum; i++) {
mClusterPointer[i].getDeformer()->setAnmCluster(anm);
}
}
/* 8032E39C-8032E3BC 328CDC 0020+00 0/0 1/1 0/0 .text __ct__11J3DDeformerFP13J3DDeformData */
J3DDeformer::J3DDeformer(J3DDeformData* data) {
mDeformData = data;
mAnmCluster = NULL;
@@ -75,8 +67,6 @@ J3DDeformer::J3DDeformer(J3DDeformData* data) {
mFlags = 3;
}
/* 8032E3BC-8032E4A4 328CFC 00E8+00 1/1 0/0 0/0 .text deform__11J3DDeformerFP15J3DVertexBufferUs
*/
void J3DDeformer::deform(J3DVertexBuffer* buffer, u16 param_1) {
J3D_ASSERT_NULLPTR(222, buffer);
@@ -95,8 +85,6 @@ void J3DDeformer::deform(J3DVertexBuffer* buffer, u16 param_1) {
}
}
/* 8032E4A4-8032E60C 328DE4 0168+00 1/1 0/0 0/0 .text
* deform_VtxPosF32__11J3DDeformerFP15J3DVertexBufferP10J3DClusterP13J3DClusterKeyPf */
void J3DDeformer::deform_VtxPosF32(J3DVertexBuffer* i_buffer, J3DCluster* i_cluster,
J3DClusterKey* i_key, f32* i_weights) {
J3DClusterKey* key;
@@ -137,8 +125,6 @@ void J3DDeformer::deform_VtxPosF32(J3DVertexBuffer* i_buffer, J3DCluster* i_clus
}
}
/* 8032E60C-8032EAB4 328F4C 04A8+00 1/1 0/0 0/0 .text
* deform_VtxNrmF32__11J3DDeformerFP15J3DVertexBufferP10J3DClusterP13J3DClusterKeyPf */
// NONMATCHING one missing mr
void J3DDeformer::deform_VtxNrmF32(J3DVertexBuffer* i_buffer, J3DCluster* i_cluster,
J3DClusterKey* i_key, f32* i_weights) {
@@ -238,8 +224,6 @@ void J3DDeformer::deform_VtxNrmF32(J3DVertexBuffer* i_buffer, J3DCluster* i_clus
}
}
/* 8032EAB4-8032EBCC 3293F4 0118+00 1/1 0/0 0/0 .text deform__11J3DDeformerFP15J3DVertexBufferUsPf
*/
void J3DDeformer::deform(J3DVertexBuffer* i_buffer, u16 param_1, f32* i_weights) {
J3D_ASSERT_NULLPTR(505, i_buffer != NULL);
@@ -268,8 +252,6 @@ void J3DDeformer::deform(J3DVertexBuffer* i_buffer, u16 param_1, f32* i_weights)
}
}
/* 8032EBCC-8032EC28 32950C 005C+00 1/1 0/0 0/0 .text normalizeWeight__11J3DDeformerFiPf
*/
void J3DDeformer::normalizeWeight(int i_keyNum, f32* i_weights) {
f32 totalWeight = 0.0f;
for (u16 i = 0; i < i_keyNum; i++) {
-18
View File
@@ -8,8 +8,6 @@
#include "JSystem/JMath/JMath.h"
#include "m_Do/m_Do_mtx.h"
/* 8032EC28-8032ECAC 329568 0084+00 0/0 1/1 0/0 .text
* init__25J3DMtxCalcJ3DSysInitBasicFRC3VecRA3_A4_Cf */
void J3DMtxCalcJ3DSysInitBasic::init(Vec const& scale, Mtx const& mtx) {
J3DSys::mCurrentS = scale;
J3DSys::mParentS = (Vec){1.0f, 1.0f, 1.0f};
@@ -17,8 +15,6 @@ void J3DMtxCalcJ3DSysInitBasic::init(Vec const& scale, Mtx const& mtx) {
J3DSys::mCurrentS.z);
}
/* 8032ECAC-8032ED30 3295EC 0084+00 0/0 2/2 2/2 .text
* init__24J3DMtxCalcJ3DSysInitMayaFRC3VecRA3_A4_Cf */
void J3DMtxCalcJ3DSysInitMaya::init(Vec const& scale, Mtx const& mtx) {
J3DSys::mParentS = (Vec){1.0f, 1.0f, 1.0f};
J3DSys::mCurrentS = scale;
@@ -26,10 +22,8 @@ void J3DMtxCalcJ3DSysInitMaya::init(Vec const& scale, Mtx const& mtx) {
J3DSys::mCurrentS.z);
}
/* 804515F0-804515F4 000AF0 0004+00 3/3 1/1 0/0 .sbss mMtxBuffer__10J3DMtxCalc */
J3DMtxBuffer* J3DMtxCalc::mMtxBuffer;
/* 804515F4-804515F8 000AF4 0004+00 4/4 9/9 2/2 .sbss mJoint__10J3DMtxCalc */
J3DJoint* J3DMtxCalc::mJoint;
inline s32 checkScaleOne(const Vec& param_0) {
@@ -40,8 +34,6 @@ inline s32 checkScaleOne(const Vec& param_0) {
}
}
/* 8032ED30-8032EE50 329670 0120+00 0/0 1/1 0/0 .text
* calcTransform__28J3DMtxCalcCalcTransformBasicFRC16J3DTransformInfo */
void J3DMtxCalcCalcTransformBasic::calcTransform(J3DTransformInfo const& transInfo) {
J3DMtxBuffer* mtxBuf = J3DMtxCalc::getMtxBuffer();
u16 jntNo = J3DMtxCalc::getJoint()->getJntNo();
@@ -65,8 +57,6 @@ void J3DMtxCalcCalcTransformBasic::calcTransform(J3DTransformInfo const& transIn
MTXCopy(J3DSys::mCurrentMtx, anmMtx);
}
/* 8032EE50-8032EFBC 329790 016C+00 0/0 1/1 0/0 .text
* calcTransform__32J3DMtxCalcCalcTransformSoftimageFRC16J3DTransformInfo */
void J3DMtxCalcCalcTransformSoftimage::calcTransform(J3DTransformInfo const& transInfo) {
J3DMtxBuffer* mtxBuf = J3DMtxCalc::getMtxBuffer();
u16 jntNo = J3DMtxCalc::getJoint()->getJntNo();
@@ -96,8 +86,6 @@ void J3DMtxCalcCalcTransformSoftimage::calcTransform(J3DTransformInfo const& tra
}
}
/* 8032EFBC-8032F13C 3298FC 0180+00 0/0 6/6 2/2 .text
* calcTransform__27J3DMtxCalcCalcTransformMayaFRC16J3DTransformInfo */
void J3DMtxCalcCalcTransformMaya::calcTransform(J3DTransformInfo const& transInfo) {
J3DJoint* joint = J3DMtxCalc::getJoint();
J3DMtxBuffer* mtxBuf = J3DMtxCalc::getMtxBuffer();
@@ -140,8 +128,6 @@ void J3DMtxCalcCalcTransformMaya::calcTransform(J3DTransformInfo const& transInf
J3DSys::mParentS.z = transInfo.mScale.z;
}
/* 8032F13C-8032F170 329A7C 0034+00 0/0 1/1 0/0 .text appendChild__8J3DJointFP8J3DJoint
*/
void J3DJoint::appendChild(J3DJoint* pChild) {
if (mChild == NULL) {
mChild = pChild;
@@ -154,7 +140,6 @@ void J3DJoint::appendChild(J3DJoint* pChild) {
}
}
/* 8032F170-8032F254 329AB0 00E4+00 0/0 1/1 0/0 .text __ct__8J3DJointFv */
J3DJoint::J3DJoint() {
mCallBackUserData = NULL;
mCallBack = NULL;
@@ -175,7 +160,6 @@ J3DJoint::J3DJoint() {
mMax = init2;
}
/* 8032F254-8032F3F8 329B94 01A4+00 0/0 1/1 0/0 .text entryIn__8J3DJointFv */
void J3DJoint::entryIn() {
MtxP anmMtx = j3dSys.getModel()->getAnmMtx(mJntNo);
j3dSys.getDrawBuffer(0)->setZMtx(anmMtx);
@@ -208,10 +192,8 @@ void J3DJoint::entryIn() {
}
}
/* 804515F8-80451600 000AF8 0004+04 1/1 1/1 0/0 .sbss mCurrentMtxCalc__8J3DJoint */
J3DMtxCalc* J3DJoint::mCurrentMtxCalc;
/* 8032F3F8-8032F5A8 329D38 01B0+00 0/0 1/1 0/0 .text recursiveCalc__8J3DJointFv */
void J3DJoint::recursiveCalc() {
J3DMtxCalc* prevMtxCalc = NULL;
Mtx prevCurrentMtx;
@@ -14,7 +14,6 @@ enum {
kTypeShape = 0x12,
};
/* 80325A18-80325A9C 320358 0084+00 0/0 1/1 0/0 .text __ct__12J3DJointTreeFv */
J3DJointTree::J3DJointTree()
: mHierarchy(NULL), mFlags(0), mModelDataType(0), mRootNode(NULL), mBasicMtxCalc(NULL),
mJointNodePointer(NULL), mJointNum(0), mWEvlpMtxNum(0), mWEvlpMixMtxNum(0),
@@ -72,7 +71,6 @@ void J3DJointTree::makeHierarchy(J3DJoint* pJoint, const J3DModelHierarchy** pHi
}
}
/* 80325C00-80325CAC 320540 00AC+00 0/0 2/2 0/0 .text findImportantMtxIndex__12J3DJointTreeFv */
void J3DJointTree::findImportantMtxIndex() {
s32 wEvlpMtxNum = getWEvlpMtxNum();
u32 tableIdx = 0;
@@ -102,8 +100,6 @@ void J3DJointTree::findImportantMtxIndex() {
}
}
/* 80325CAC-80325D1C 3205EC 0070+00 1/0 0/0 0/0 .text
* calc__12J3DJointTreeFP12J3DMtxBufferRC3VecRA3_A4_Cf */
void J3DJointTree::calc(J3DMtxBuffer* pMtxBuffer, Vec const& scale, f32 const (&mtx)[3][4]) {
J3D_ASSERT_NULLPTR(217, pMtxBuffer != NULL);
getBasicMtxCalc()->init(scale, mtx);
@@ -117,8 +113,6 @@ void J3DJointTree::calc(J3DMtxBuffer* pMtxBuffer, Vec const& scale, f32 const (&
root->recursiveCalc();
}
/* 80325D1C-80325D24 32065C 0008+00 1/1 0/0 0/0 .text setMtxBuffer__10J3DMtxCalcFP12J3DMtxBuffer
*/
void J3DMtxCalc::setMtxBuffer(J3DMtxBuffer* mtxBuffer) {
J3DMtxCalc::mMtxBuffer = mtxBuffer;
}
@@ -5,7 +5,6 @@
#include "JSystem/J3DGraphBase/J3DMaterial.h"
#include "JSystem/JUtility/JUTAssert.h"
/* 8032F5A8-8032F5D0 329EE8 0028+00 0/0 1/1 0/0 .text clear__16J3DMaterialTableFv */
void J3DMaterialTable::clear() {
mMaterialNum = 0;
mUniqueMatNum = 0;
@@ -17,7 +16,6 @@ void J3DMaterialTable::clear() {
field_0x1c = 0;
}
/* 8032F5D0-8032F604 329F10 0034+00 0/0 2/2 0/0 .text __ct__16J3DMaterialTableFv */
J3DMaterialTable::J3DMaterialTable() {
mMaterialNum = 0;
mUniqueMatNum = 0;
@@ -29,11 +27,8 @@ J3DMaterialTable::J3DMaterialTable() {
field_0x1c = 0;
}
/* 8032F604-8032F64C 329F44 0048+00 1/0 1/1 0/0 .text __dt__16J3DMaterialTableFv */
J3DMaterialTable::~J3DMaterialTable() {}
/* 8032F64C-8032F6F8 329F8C 00AC+00 0/0 1/1 5/5 .text
* removeMatColorAnimator__16J3DMaterialTableFP11J3DAnmColor */
int J3DMaterialTable::removeMatColorAnimator(J3DAnmColor* pAnmColor) {
J3D_ASSERT_NULLPTR(208, pAnmColor != NULL);
int ret = false;
@@ -54,8 +49,6 @@ int J3DMaterialTable::removeMatColorAnimator(J3DAnmColor* pAnmColor) {
return ret;
}
/* 8032F6F8-8032F7B4 32A038 00BC+00 0/0 5/5 10/10 .text
* removeTexNoAnimator__16J3DMaterialTableFP16J3DAnmTexPattern */
int J3DMaterialTable::removeTexNoAnimator(J3DAnmTexPattern* pAnmTexPattern) {
J3D_ASSERT_NULLPTR(242, pAnmTexPattern != NULL);
int ret = 0;
@@ -78,8 +71,6 @@ int J3DMaterialTable::removeTexNoAnimator(J3DAnmTexPattern* pAnmTexPattern) {
return ret;
}
/* 8032F7B4-8032F880 32A0F4 00CC+00 0/0 4/4 26/26 .text
* removeTexMtxAnimator__16J3DMaterialTableFP19J3DAnmTextureSRTKey */
int J3DMaterialTable::removeTexMtxAnimator(J3DAnmTextureSRTKey* pAnmTexSRTKey) {
J3D_ASSERT_NULLPTR(278, pAnmTexSRTKey != NULL);
s32 ret = 0;
@@ -105,8 +96,6 @@ int J3DMaterialTable::removeTexMtxAnimator(J3DAnmTextureSRTKey* pAnmTexSRTKey) {
return ret;
}
/* 8032F880-8032F9C0 32A1C0 0140+00 0/0 7/7 24/24 .text
* removeTevRegAnimator__16J3DMaterialTableFP15J3DAnmTevRegKey */
int J3DMaterialTable::removeTevRegAnimator(J3DAnmTevRegKey* pAnmTevRegKey) {
J3D_ASSERT_NULLPTR(320, pAnmTevRegKey != NULL);
s32 ret = 0;
@@ -144,8 +133,6 @@ int J3DMaterialTable::removeTevRegAnimator(J3DAnmTevRegKey* pAnmTevRegKey) {
return ret;
}
/* 8032F9C0-8032FAF4 32A300 0134+00 1/1 0/0 0/0 .text
* createTexMtxForAnimator__16J3DMaterialTableFP19J3DAnmTextureSRTKey */
int J3DMaterialTable::createTexMtxForAnimator(J3DAnmTextureSRTKey* pTexSRTKey) {
J3D_ASSERT_NULLPTR(382, pTexSRTKey != NULL);
int rv = 0;
@@ -178,8 +165,6 @@ int J3DMaterialTable::createTexMtxForAnimator(J3DAnmTextureSRTKey* pTexSRTKey) {
return rv;
}
/* 8032FAF4-8032FBC8 32A434 00D4+00 0/0 1/1 0/0 .text
* entryMatColorAnimator__16J3DMaterialTableFP11J3DAnmColor */
int J3DMaterialTable::entryMatColorAnimator(J3DAnmColor* pAnmColor) {
J3D_ASSERT_NULLPTR(450, pAnmColor != NULL);
int rv = 0;
@@ -205,8 +190,6 @@ int J3DMaterialTable::entryMatColorAnimator(J3DAnmColor* pAnmColor) {
return rv;
}
/* 8032FBC8-8032FCC4 32A508 00FC+00 0/0 7/7 1/1 .text
* entryTexNoAnimator__16J3DMaterialTableFP16J3DAnmTexPattern */
int J3DMaterialTable::entryTexNoAnimator(J3DAnmTexPattern* pAnmTexPattern) {
J3D_ASSERT_NULLPTR(489, pAnmTexPattern != NULL);
int rv = 0;
@@ -234,8 +217,6 @@ int J3DMaterialTable::entryTexNoAnimator(J3DAnmTexPattern* pAnmTexPattern) {
return rv;
}
/* 8032FCC4-8032FE70 32A604 01AC+00 0/0 14/14 6/6 .text
* entryTexMtxAnimator__16J3DMaterialTableFP19J3DAnmTextureSRTKey */
int J3DMaterialTable::entryTexMtxAnimator(J3DAnmTextureSRTKey* pAnmTexSRTKey) {
J3D_ASSERT_NULLPTR(532, pAnmTexSRTKey != NULL);
int rv = 0;
@@ -278,8 +259,6 @@ int J3DMaterialTable::entryTexMtxAnimator(J3DAnmTextureSRTKey* pAnmTexSRTKey) {
return rv;
}
/* 8032FE70-8032FFEC 32A7B0 017C+00 0/0 10/10 4/4 .text
* entryTevRegAnimator__16J3DMaterialTableFP15J3DAnmTevRegKey */
int J3DMaterialTable::entryTevRegAnimator(J3DAnmTevRegKey* pAnmTevRegKey) {
J3D_ASSERT_NULLPTR(599, pAnmTevRegKey != NULL);
int rv = 0;
-28
View File
@@ -8,7 +8,6 @@
#define J3D_ASSERTMSG(LINE, COND, MSG) JUT_ASSERT_MSG(LINE, (COND) != 0, MSG)
#define J3D_WARN1(LINE, MSG, ARG1) JUT_WARN(LINE, MSG, ARG1)
/* 80327100-80327184 321A40 0084+00 0/0 3/3 0/0 .text initialize__8J3DModelFv */
void J3DModel::initialize() {
mModelData = NULL;
mFlags = 0;
@@ -33,8 +32,6 @@ void J3DModel::initialize() {
mUnkCalc2 = NULL;
}
/* 80327184-80327300 321AC4 017C+00 0/0 3/3 0/0 .text
* entryModelData__8J3DModelFP12J3DModelDataUlUl */
s32 J3DModel::entryModelData(J3DModelData* pModelData, u32 mdlFlags, u32 mtxNum) {
J3D_ASSERTMSG(83, pModelData != NULL, "Error : null pointer.");
J3D_ASSERTMSG(84, mtxNum != 0, "Error : non-zero argument is specified 0.");
@@ -95,8 +92,6 @@ s32 J3DModel::entryModelData(J3DModelData* pModelData, u32 mdlFlags, u32 mtxNum)
return kJ3DError_Success;
}
/* 80327300-803273CC 321C40 00CC+00 1/1 0/0 0/0 .text createShapePacket__8J3DModelFP12J3DModelData
*/
s32 J3DModel::createShapePacket(J3DModelData* pModelData) {
J3D_ASSERTMSG(173, pModelData != NULL, "Error : null pointer.");
@@ -116,8 +111,6 @@ s32 J3DModel::createShapePacket(J3DModelData* pModelData) {
return kJ3DError_Success;
}
/* 803273CC-803275FC 321D0C 0230+00 1/1 0/0 0/0 .text createMatPacket__8J3DModelFP12J3DModelDataUl
*/
s32 J3DModel::createMatPacket(J3DModelData* pModelData, u32 mdlFlags) {
J3D_ASSERTMSG(207, pModelData != NULL, "Error : null pointer.");
s32 ret = 0;
@@ -200,7 +193,6 @@ s32 J3DModel::createMatPacket(J3DModelData* pModelData, u32 mdlFlags) {
return kJ3DError_Success;
}
/* 803275FC-8032767C 321F3C 0080+00 0/0 1/1 0/0 .text newDifferedDisplayList__8J3DModelFUl */
s32 J3DModel::newDifferedDisplayList(u32 diffFlags) {
mDiffFlag = diffFlags;
@@ -232,7 +224,6 @@ void J3DModel::ptrToIndex() {
}
}
/* 8032767C-803276B4 321FBC 0038+00 0/0 4/4 0/0 .text lock__8J3DModelFv */
void J3DModel::lock() {
int matNum = mModelData->getMaterialNum();
for (int i = 0; i < matNum; i++) {
@@ -240,7 +231,6 @@ void J3DModel::lock() {
}
}
/* 803276B4-803276EC 321FF4 0038+00 0/0 2/2 0/0 .text unlock__8J3DModelFv */
void J3DModel::unlock() {
int matNum = mModelData->getMaterialNum();
for (int i = 0; i < matNum; i++) {
@@ -259,7 +249,6 @@ void J3DModel::makeDL() {
}
}
/* 803276EC-80327858 32202C 016C+00 1/0 0/0 0/0 .text calcMaterial__8J3DModelFv */
void J3DModel::calcMaterial() {
j3dSys.setModel(this);
@@ -291,7 +280,6 @@ void J3DModel::calcMaterial() {
}
}
/* 80327858-803279A0 322198 0148+00 1/0 0/0 0/0 .text calcDiffTexMtx__8J3DModelFv */
void J3DModel::calcDiffTexMtx() {
j3dSys.setModel(this);
@@ -317,7 +305,6 @@ void J3DModel::calcDiffTexMtx() {
}
}
/* 803279A0-80327A2C 3222E0 008C+00 0/0 2/2 0/0 .text diff__8J3DModelFv */
void J3DModel::diff() {
u16 matNum = mModelData->getMaterialNum();
for (u16 i = 0; i < matNum; i++) {
@@ -326,8 +313,6 @@ void J3DModel::diff() {
}
}
/* 80327A2C-80327AA0 32236C 0074+00 0/0 1/1 2/2 .text setDeformData__8J3DModelFP13J3DDeformDataUl
*/
s32 J3DModel::setDeformData(J3DDeformData* p_deformData, u32 param_1) {
mDeformData = p_deformData;
@@ -347,8 +332,6 @@ s32 J3DModel::setDeformData(J3DDeformData* p_deformData, u32 param_1) {
return kJ3DError_Success;
}
/* 80327AA0-80327BD4 3223E0 0134+00 0/0 0/0 2/2 .text setSkinDeform__8J3DModelFP13J3DSkinDeformUl
*/
s32 J3DModel::setSkinDeform(J3DSkinDeform* p_skinDeform, u32 flags) {
mSkinDeform = p_skinDeform;
@@ -394,7 +377,6 @@ s32 J3DModel::setSkinDeform(J3DSkinDeform* p_skinDeform, u32 flags) {
return ret;
}
/* 80327BD4-80327C58 322514 0084+00 1/1 0/0 2/2 .text calcAnmMtx__8J3DModelFv */
void J3DModel::calcAnmMtx() {
j3dSys.setModel(this);
@@ -405,8 +387,6 @@ void J3DModel::calcAnmMtx() {
}
}
/* 80327C58-80327CA4 322598 004C+00 1/1 1/1 1/1 .text calcWeightEnvelopeMtx__8J3DModelFv
*/
void J3DModel::calcWeightEnvelopeMtx() {
if (getModelData()->getWEvlpMtxNum() != 0 && !checkFlag(J3DMdlFlag_EnableLOD)) {
if (!getModelData()->checkFlag(0x100)) {
@@ -415,13 +395,11 @@ void J3DModel::calcWeightEnvelopeMtx() {
}
}
/* 80327CA4-80327CF0 3225E4 004C+00 1/0 0/0 0/0 .text update__8J3DModelFv */
void J3DModel::update() {
calc();
entry();
}
/* 80327CF0-80327E4C 322630 015C+00 1/0 0/0 0/0 .text calc__8J3DModelFv */
void J3DModel::calc() {
j3dSys.setModel(this);
@@ -468,7 +446,6 @@ void J3DModel::calc() {
}
}
/* 80327E4C-80327F40 32278C 00F4+00 1/0 0/0 0/0 .text entry__8J3DModelFv */
void J3DModel::entry() {
j3dSys.setModel(this);
@@ -495,7 +472,6 @@ void J3DModel::entry() {
}
}
/* 80327F40-80328190 322880 0250+00 1/0 0/0 0/0 .text viewCalc__8J3DModelFv */
void J3DModel::viewCalc() {
mMtxBuffer->swapDrawMtx();
mMtxBuffer->swapNrmMtx();
@@ -532,12 +508,10 @@ void J3DModel::viewCalc() {
prepareShapePackets();
}
/* 80328190-803281B4 322AD0 0024+00 1/1 0/0 0/0 .text calcNrmMtx__8J3DModelFv */
void J3DModel::calcNrmMtx() {
mMtxBuffer->calcNrmMtx();
}
/* 803281B4-803282B8 322AF4 0104+00 1/1 0/0 0/0 .text calcBumpMtx__8J3DModelFv */
void J3DModel::calcBumpMtx() {
if (getModelData()->checkBumpFlag()) {
u32 bumpMtxIdx = 0;
@@ -555,14 +529,12 @@ void J3DModel::calcBumpMtx() {
}
}
/* 803282B8-803282EC 322BF8 0034+00 1/1 0/0 0/0 .text calcBBoardMtx__8J3DModelFv */
void J3DModel::calcBBoardMtx() {
if (getModelData()->checkBBoardFlag()) {
mMtxBuffer->calcBBoardMtx();
}
}
/* 803282EC-80328350 322C2C 0064+00 2/2 0/0 0/0 .text prepareShapePackets__8J3DModelFv */
void J3DModel::prepareShapePackets() {
u16 shapeNum = mModelData->getShapeNum();
@@ -9,7 +9,6 @@
#include "JSystem/J3DGraphBase/J3DMaterial.h"
#include "JSystem/J3DGraphAnimator/J3DModel.h"
/* 80325D88-80325DA0 3206C8 0018+00 1/1 2/2 0/0 .text clear__12J3DModelDataFv */
void J3DModelData::clear() {
mpRawData = 0;
mFlags = 0;
@@ -17,12 +16,10 @@ void J3DModelData::clear() {
mbHasBillboard = 0;
}
/* 80325DA0-80325E14 3206E0 0074+00 0/0 2/2 0/0 .text __ct__12J3DModelDataFv */
J3DModelData::J3DModelData() {
clear();
}
/* 80325E14-80325EC8 320754 00B4+00 0/0 2/2 0/0 .text newSharedDisplayList__12J3DModelDataFUl */
s32 J3DModelData::newSharedDisplayList(u32 mdlFlags) {
u16 matNum = getMaterialNum();
@@ -42,7 +39,6 @@ s32 J3DModelData::newSharedDisplayList(u32 mdlFlags) {
return kJ3DError_Success;
}
/* 80325EC8-80325F94 320808 00CC+00 0/0 1/1 0/0 .text indexToPtr__12J3DModelDataFv */
void J3DModelData::indexToPtr() {
j3dSys.setTexture(getTexture());
@@ -65,7 +61,6 @@ void J3DModelData::indexToPtr() {
OSRestoreInterrupts(sInterruptFlag);
}
/* 80325F94-8032600C 3208D4 0078+00 0/0 2/2 0/0 .text makeSharedDL__12J3DModelDataFv */
void J3DModelData::makeSharedDL() {
j3dSys.setTexture(getTexture());
@@ -75,8 +70,6 @@ void J3DModelData::makeSharedDL() {
}
}
/* 8032600C-803260CC 32094C 00C0+00 0/0 3/3 7/7 .text simpleCalcMaterial__12J3DModelDataFUsPA4_f
*/
void J3DModelData::simpleCalcMaterial(u16 idx, Mtx param_1) {
syncJ3DSysFlags();
@@ -90,7 +83,6 @@ void J3DModelData::simpleCalcMaterial(u16 idx, Mtx param_1) {
}
}
/* 803260CC-803260F8 320A0C 002C+00 0/0 1/1 0/0 .text syncJ3DSysPointers__12J3DModelDataCFv */
void J3DModelData::syncJ3DSysPointers() const {
j3dSys.setTexture(getTexture());
j3dSys.setVtxPos(getVtxPosArray());
@@ -98,8 +90,6 @@ void J3DModelData::syncJ3DSysPointers() const {
j3dSys.setVtxCol(getVtxColorArray(0));
}
/* 803260F8-80326134 320A38 003C+00 1/1 5/5 0/0 .text syncJ3DSysFlags__12J3DModelDataCFv
*/
void J3DModelData::syncJ3DSysFlags() const {
if (checkFlag(0x20)) {
j3dSys.onFlag(J3DSysFlag_PostTexMtx);
@@ -5,16 +5,12 @@
#include "JSystem/J3DGraphLoader/J3DModelLoader.h"
#include "JSystem/JKernel/JKRHeap.h"
/* 804371C0-804371F0 063EE0 0030+00 1/0 0/0 0/0 .bss sNoUseDrawMtx__12J3DMtxBuffer */
Mtx J3DMtxBuffer::sNoUseDrawMtx;
/* 804371F0-80437218 063F10 0024+04 1/0 0/0 0/0 .bss sNoUseNrmMtx__12J3DMtxBuffer */
Mtx33 J3DMtxBuffer::sNoUseNrmMtx;
/* 80450970-80450974 -00001 0004+00 1/1 0/0 0/0 .sdata sNoUseDrawMtxPtr__12J3DMtxBuffer */
Mtx* J3DMtxBuffer::sNoUseDrawMtxPtr = &J3DMtxBuffer::sNoUseDrawMtx;
/* 80450974-80450978 -00001 0004+00 1/1 0/0 0/0 .sdata sNoUseNrmMtxPtr__12J3DMtxBuffer */
Mtx33* J3DMtxBuffer::sNoUseNrmMtxPtr = &J3DMtxBuffer::sNoUseNrmMtx;
// force .sdata2 order
@@ -26,7 +22,6 @@ f32 dummy0() {
return 0.0f;
}
/* 80326214-80326258 320B54 0044+00 0/0 1/1 0/0 .text initialize__12J3DMtxBufferFv */
void J3DMtxBuffer::initialize() {
mJointTree = NULL;
mpScaleFlagArr = NULL;
@@ -44,7 +39,6 @@ void J3DMtxBuffer::initialize() {
mpUserAnmMtx = NULL;
}
/* 80326258-80326364 320B98 010C+00 0/0 1/1 0/0 .text create__12J3DMtxBufferFP12J3DModelDataUl */
enum {
J3DMdlDataFlag_ConcatView = 0x10,
J3DMdlDataFlag_NoAnimation = 0x100,
@@ -96,8 +90,6 @@ s32 J3DMtxBuffer::create(J3DModelData* pModelData, u32 mtxNum) {
return ret;
}
/* 80326364-803263F0 320CA4 008C+00 1/1 0/0 0/0 .text createAnmMtx__12J3DMtxBufferFP12J3DModelData
*/
J3DError J3DMtxBuffer::createAnmMtx(J3DModelData* pModelData) {
if (pModelData->getJointNum() != 0) {
mpScaleFlagArr = new u8[pModelData->getJointNum()];
@@ -115,8 +107,6 @@ J3DError J3DMtxBuffer::createAnmMtx(J3DModelData* pModelData) {
return kJ3DError_Success;
}
/* 803263F0-8032648C 320D30 009C+00 1/1 0/0 0/0 .text
* createWeightEnvelopeMtx__12J3DMtxBufferFP12J3DModelData */
s32 J3DMtxBuffer::createWeightEnvelopeMtx(J3DModelData* pModelData) {
if (pModelData->getWEvlpMtxNum() != 0) {
mpEvlpScaleFlagArr = new u8[pModelData->getWEvlpMtxNum()];
@@ -131,8 +121,6 @@ s32 J3DMtxBuffer::createWeightEnvelopeMtx(J3DModelData* pModelData) {
return kJ3DError_Success;
}
/* 8032648C-803264B8 320DCC 002C+00 1/1 0/0 0/0 .text setNoUseDrawMtx__12J3DMtxBufferFv
*/
s32 J3DMtxBuffer::setNoUseDrawMtx() {
mpDrawMtxArr[0] = mpDrawMtxArr[1] = &sNoUseDrawMtxPtr;
mpNrmMtxArr[0] = mpNrmMtxArr[1] = &sNoUseNrmMtxPtr;
@@ -140,8 +128,6 @@ s32 J3DMtxBuffer::setNoUseDrawMtx() {
return kJ3DError_Success;
}
/* 803264B8-80326664 320DF8 01AC+00 1/1 0/0 0/0 .text
* createDoubleDrawMtx__12J3DMtxBufferFP12J3DModelDataUl */
s32 J3DMtxBuffer::createDoubleDrawMtx(J3DModelData* pModelData, u32 mtxNum) {
if (mtxNum != 0) {
for (s32 i = 0; i < 2; i++) {
@@ -183,8 +169,6 @@ s32 J3DMtxBuffer::createDoubleDrawMtx(J3DModelData* pModelData, u32 mtxNum) {
return kJ3DError_Success;
}
/* 80326664-803268D4 320FA4 0270+00 1/1 0/0 0/0 .text
* createBumpMtxArray__12J3DMtxBufferFP12J3DModelDataUl */
s32 J3DMtxBuffer::createBumpMtxArray(J3DModelData* i_modelData, u32 mtxNum) {
J3D_ASSERT_NULLPTR(295, i_modelData != NULL);
@@ -250,10 +234,8 @@ s32 J3DMtxBuffer::createBumpMtxArray(J3DModelData* i_modelData, u32 mtxNum) {
return kJ3DError_Success;
}
/* 80450978-80450980 0003F8 0008+00 1/1 0/0 0/0 .sdata J3DUnit01 */
static f32 J3DUnit01[] = { 0.0f, 1.0f };
/* 803268D4-80326ACC 321214 01F8+00 0/0 1/1 0/0 .text calcWeightEnvelopeMtx__12J3DMtxBufferFv */
void J3DMtxBuffer::calcWeightEnvelopeMtx() {
register MtxP weightAnmMtx;
register Mtx* worldMtx;
@@ -418,8 +400,6 @@ void J3DMtxBuffer::calcWeightEnvelopeMtx() {
}
}
/* 80326ACC-80326D3C 32140C 0270+00 0/0 1/1 0/0 .text
* calcDrawMtx__12J3DMtxBufferFUlRC3VecRA3_A4_Cf */
void J3DMtxBuffer::calcDrawMtx(u32 mdlFlag, Vec const& param_1, Mtx const& param_2) {
Mtx* sp24, *sp20;
int sp1C = 0;
@@ -469,7 +449,6 @@ void J3DMtxBuffer::calcDrawMtx(u32 mdlFlag, Vec const& param_1, Mtx const& param
}
}
/* 80326D3C-80326EF0 32167C 01B4+00 0/0 1/1 0/0 .text calcNrmMtx__12J3DMtxBufferFv */
void J3DMtxBuffer::calcNrmMtx() {
u16 drawMtxNum = mJointTree->getDrawMtxNum();
for (u16 i = 0; i < drawMtxNum; i++) {
@@ -489,7 +468,6 @@ void J3DMtxBuffer::calcNrmMtx() {
}
}
/* 80326EF0-80327048 321830 0158+00 0/0 1/1 0/0 .text calcBBoardMtx__12J3DMtxBufferFv */
void J3DMtxBuffer::calcBBoardMtx() {
u16 drawMtxNum = mJointTree->getDrawMtxNum();
for (u16 i = 0; i < drawMtxNum; i++) {
@@ -519,8 +497,6 @@ void J3DMtxBuffer::calcBBoardMtx() {
}
}
/* 80327048-80327100 321988 00B8+00 1/1 1/1 0/0 .text
* J3DCalcViewBaseMtx__FPA4_fRC3VecRA3_A4_CfPA4_f */
void J3DCalcViewBaseMtx(Mtx view, Vec const& scale, const Mtx& base, Mtx dst) {
Mtx m;
+44 -92
View File
@@ -5,7 +5,6 @@
#include "JSystem/JKernel/JKRHeap.h"
#include <string.h>
/* 8032C6E4-8032C704 327024 0020+00 1/1 0/0 0/0 .text __ct__12J3DSkinNListFv */
J3DSkinNList::J3DSkinNList() {
field_0x0 = NULL;
field_0x4 = NULL;
@@ -15,7 +14,6 @@ J3DSkinNList::J3DSkinNList() {
field_0x12 = 0;
}
/* 8032C704-8032C7BC 327044 00B8+00 1/1 0/0 0/0 .text J3DPSWeightMTXMultVec__FPA4_ffP3VecP3Vec */
static void J3DPSWeightMTXMultVec(f32 (*param_0)[4], f32 param_1, Vec* param_2, Vec* param_3) {
f32 f4 = param_0[0][3] + param_0[0][0] * param_2->x;
f32 f5 = param_0[1][3] + param_0[1][0] * param_2->x;
@@ -31,8 +29,6 @@ static void J3DPSWeightMTXMultVec(f32 (*param_0)[4], f32 param_1, Vec* param_2,
param_3->z += f3 * param_1;
}
/* 8032C7BC-8032C85C 3270FC 00A0+00 1/1 0/0 0/0 .text J3DPSWeightMTXMultVecSR__FPA4_ffP3VecP3Vec
*/
static void J3DPSWeightMTXMultVecSR(f32 (*param_0)[4], f32 param_1, Vec* param_2,
Vec* param_3) {
f32 f4 = param_0[0][0] * param_2->x;
@@ -49,8 +45,6 @@ static void J3DPSWeightMTXMultVecSR(f32 (*param_0)[4], f32 param_1, Vec* param_2
param_3->z += f3 * param_1;
}
/* 8032C85C-8032C8E4 32719C 0088+00 1/1 0/0 0/0 .text calcSkin_VtxPosF32__12J3DSkinNListFPA4_fPvPv
*/
void J3DSkinNList::calcSkin_VtxPosF32(f32 (*param_0)[4], void* param_1, void* param_2) {
int r29 = field_0x10;
for (int i = 0; i < r29; i++) {
@@ -61,8 +55,6 @@ void J3DSkinNList::calcSkin_VtxPosF32(f32 (*param_0)[4], void* param_1, void* pa
}
}
/* 8032C8E4-8032C96C 327224 0088+00 1/1 0/0 0/0 .text calcSkin_VtxNrmF32__12J3DSkinNListFPA4_fPvPv
*/
void J3DSkinNList::calcSkin_VtxNrmF32(f32 (*param_0)[4], void* param_1, void* param_2) {
int r29 = field_0x12;
for (int i = 0; i < r29; i++) {
@@ -73,7 +65,6 @@ void J3DSkinNList::calcSkin_VtxNrmF32(f32 (*param_0)[4], void* param_1, void* pa
}
}
/* 8032C96C-8032C9B0 3272AC 0044+00 0/0 0/0 2/2 .text __ct__13J3DSkinDeformFv */
J3DSkinDeform::J3DSkinDeform() {
mPosData = NULL;
mNrmData = NULL;
@@ -87,14 +78,10 @@ J3DSkinDeform::J3DSkinDeform() {
mSkinNList = NULL;
}
/* 80437218-80438218 063F38 1000+00 1/1 0/0 0/0 .bss sWorkArea_WEvlpMixMtx__13J3DSkinDeform */
u16* J3DSkinDeform::sWorkArea_WEvlpMixMtx[1024];
/* 80438218-80439218 064F38 1000+00 1/1 0/0 0/0 .bss sWorkArea_WEvlpMixWeight__13J3DSkinDeform */
f32* J3DSkinDeform::sWorkArea_WEvlpMixWeight[1024];
/* 8032C9B0-8032CF44 3272F0 0594+00 0/0 1/1 0/0 .text
* initSkinInfo__13J3DSkinDeformFP12J3DModelData */
void J3DSkinDeform::initSkinInfo(J3DModelData* pModelData) {
J3D_ASSERT_NULLPTR(322, pModelData != NULL);
@@ -206,13 +193,8 @@ void J3DSkinDeform::initSkinInfo(J3DModelData* pModelData) {
}
}
/* 80439218-80439A20 065F38 0800+08 1/1 0/0 0/0 .bss sWorkArea_MtxReg__13J3DSkinDeform
*/
u16 J3DSkinDeform::sWorkArea_MtxReg[1024];
/* 8032CF44-8032D378 327884 0434+00 0/0 1/1 0/0 .text
* initMtxIndexArray__13J3DSkinDeformFP12J3DModelData */
// NONMATCHING - matches debug, not retail
int J3DSkinDeform::initMtxIndexArray(J3DModelData* pModelData) {
J3D_ASSERT_NULLPTR(507, pModelData != NULL);
if (mPosData != NULL && mNrmData != NULL) {
@@ -365,82 +347,79 @@ int J3DSkinDeform::initMtxIndexArray(J3DModelData* pModelData) {
return kJ3DError_Success;
}
/* 8032D378-8032D5C4 327CB8 024C+00 0/0 1/1 0/0 .text
* changeFastSkinDL__13J3DSkinDeformFP12J3DModelData */
// NONMATCHING - regalloc, display list access issues
// NONMATCHING - instruction ordering/optimization issue, matches debug
// the compiler needs to delay adding +3 to dl until the end of the while loop for the function to match
// but instead it puts the +3 at the start of the for loop and reworks the other instructions
// can get a 99.93% match on retail by moving where dl is incremented, but it seems fake as it breaks debug, and introduces an operand swap on src
void J3DSkinDeform::changeFastSkinDL(J3DModelData* pModelData) {
J3D_ASSERT_NULLPTR(740, pModelData != NULL);
for (u16 i = 0; i < pModelData->getShapeNum(); i++) {
u32 kSize[4] = {0,1,1,2};
int local_30 = -1;
int local_34 = 0;
int pnmtxIdxOffs = -1;
int vtxSize = 0;
J3DShape* pShapeNode = pModelData->getShapeNodePointer(i);
for (GXVtxDescList* vtxDesc = pShapeNode->getVtxDesc(); vtxDesc->attr != GX_VA_NULL; vtxDesc++) {
if (vtxDesc->attr == GX_VA_PNMTXIDX) {
local_30 = local_34;
pnmtxIdxOffs = vtxSize;
}
local_34 += kSize[vtxDesc->type];
vtxSize += kSize[vtxDesc->type];
}
if (local_30 != -1) {
if (pnmtxIdxOffs != -1) {
for (u16 j = 0; j < (u16)pShapeNode->getMtxGroupNum(); j++) {
u8* pDList = pShapeNode->getShapeDraw(j)->getDisplayList();
u8* local_44 = pDList;
u8* puVar10 = pDList;
while (local_44 - pDList < pShapeNode->getShapeDraw(j)->getDisplayListSize()) {
u8 command = *local_44;
local_44++;
*puVar10++ = command;
if (command != GX_TRIANGLEFAN && command != GX_TRIANGLESTRIP)
u8* displayListStart = pShapeNode->getShapeDraw(j)->getDisplayList();
u8* dl = displayListStart;
u8* dst = displayListStart;
while ((dl - displayListStart) < pShapeNode->getShapeDraw(j)->getDisplayListSize()) {
u8 cmd = *dl;
dl++;
*dst++ = cmd;
if (cmd != GX_TRIANGLEFAN && cmd != GX_TRIANGLESTRIP)
break;
int uVar9 = *(u16*)local_44;
local_44 += 2;
*(u16*)puVar10 = uVar9;
puVar10 += 2;
for (int local_4c = 0; local_4c < uVar9; local_4c++) {
u8* dst = &local_44[local_34 * local_4c];
memcpy(puVar10, dst + 1, local_34 - 1);
// FAKEMATCH
#if DEBUG || VERSION == VERSION_WII_USA_R0 || VERSION == VERSION_WII_USA_R2
puVar10 += local_34 - 1;
#else
puVar10 = (local_34 + puVar10) - 1;
#endif
int vtxCount = *(u16*)dl;
dl += 2;
*(u16*)dst = vtxCount;
dst += 2;
for (int k = 0; k < vtxCount; k++) {
u8* src = &dl[vtxSize * k];
memcpy(dst, src + 1, (int)(vtxSize - 1)); // The -1 is to remove GX_VA_PNMTXIDX
dst += (int)(vtxSize - 1);
}
local_44 += local_34 * uVar9;
dl += vtxSize * vtxCount;
}
int dlistSize = ((int)puVar10 - (int)pDList + 0x1f) & ~0x1f;
while ((int)puVar10 - (int)pDList < pShapeNode->getShapeDraw(j)->getDisplayListSize()) {
*puVar10++ = 0;
int dlistSize = ((int)dst - (int)displayListStart + 0x1f) & ~0x1f;
while ((int)dst - (int)displayListStart < pShapeNode->getShapeDraw(j)->getDisplayListSize()) {
*dst++ = 0;
}
pShapeNode->getShapeDraw(j)->setDisplayListSize(dlistSize);
DCStoreRange(pDList, pShapeNode->getShapeDraw(j)->getDisplayListSize());
DCStoreRange(displayListStart, pShapeNode->getShapeDraw(j)->getDisplayListSize());
}
}
}
for (u16 i = 0; i < pModelData->getShapeNum(); i++) {
J3DShape* pShape = pModelData->getShapeNodePointer(i);
GXVtxDescList* local_5c = pShape->getVtxDesc();
GXVtxDescList* local_60 = local_5c;
for (; local_5c->attr != GX_VA_NULL; local_5c++) {
if (local_5c->attr != GX_VA_PNMTXIDX) {
local_60->attr = local_5c->attr;
local_60->type = local_5c->type;
local_60++;
J3DShape* shape = pModelData->getShapeNodePointer(i);
GXVtxDescList* desc = shape->getVtxDesc();
GXVtxDescList* descDst = desc;
for (; desc->attr != GX_VA_NULL; desc++) {
if (desc->attr != GX_VA_PNMTXIDX) {
descDst->attr = desc->attr;
descDst->type = desc->type;
descDst++;
}
}
local_60->attr = GX_VA_NULL;
local_60->type = GX_NONE;
pShape->makeVcdVatCmd();
descDst->attr = GX_VA_NULL;
descDst->type = GX_NONE;
shape->makeVcdVatCmd();
}
}
/* 8032D5C4-8032D738 327F04 0174+00 1/1 0/0 0/0 .text calcNrmMtx__13J3DSkinDeformFP12J3DMtxBuffer
*/
void J3DSkinDeform::calcNrmMtx(J3DMtxBuffer* pMtxBuffer) {
J3DJointTree* jointTree = pMtxBuffer->getJointTree();
u16 drawMtxNum = jointTree->getDrawMtxNum();
@@ -461,8 +440,6 @@ void J3DSkinDeform::calcNrmMtx(J3DMtxBuffer* pMtxBuffer) {
}
}
/* 8032D738-8032D87C 328078 0144+00 0/0 1/1 0/0 .text
* transformVtxPosNrm__13J3DSkinDeformFP12J3DModelData */
void J3DSkinDeform::transformVtxPosNrm(J3DModelData* pModelData) {
if (pModelData->getWEvlpMtxNum() != 0 && field_0x19 == 0) {
int vtmNum = pModelData->getVtxNum();
@@ -494,8 +471,6 @@ void J3DSkinDeform::transformVtxPosNrm(J3DModelData* pModelData) {
}
}
/* 8032D87C-8032D8F4 3281BC 0078+00 1/1 0/0 0/0 .text
* calcAnmInvJointMtx__13J3DSkinDeformFP12J3DMtxBuffer */
void J3DSkinDeform::calcAnmInvJointMtx(J3DMtxBuffer* pMtxBuffer) {
J3D_ASSERT_NULLPTR(978, pMtxBuffer != NULL);
@@ -510,8 +485,6 @@ void J3DSkinDeform::calcAnmInvJointMtx(J3DMtxBuffer* pMtxBuffer) {
}
}
/* 8032D8F4-8032DA1C 328234 0128+00 1/1 0/0 0/0 .text
* deformFastVtxPos_F32__13J3DSkinDeformCFP15J3DVertexBufferP12J3DMtxBuffer */
void J3DSkinDeform::deformFastVtxPos_F32(J3DVertexBuffer* pVtxBuffer, J3DMtxBuffer* pMtxBuffer) const {
pVtxBuffer->swapTransformedVtxPos();
J3DJointTree* jointTree = pMtxBuffer->getJointTree();
@@ -540,8 +513,6 @@ void J3DSkinDeform::deformFastVtxPos_F32(J3DVertexBuffer* pVtxBuffer, J3DMtxBuff
pVtxBuffer->setCurrentVtxPos(transformedVtxPos);
}
/* 8032DA1C-8032DB50 32835C 0134+00 1/1 0/0 0/0 .text
* deformFastVtxNrm_F32__13J3DSkinDeformCFP15J3DVertexBufferP12J3DMtxBuffer */
void J3DSkinDeform::deformFastVtxNrm_F32(J3DVertexBuffer* pVtxBuffer, J3DMtxBuffer* pMtxBuffer) const {
pVtxBuffer->swapTransformedVtxNrm();
J3DJointTree* jointTree = pMtxBuffer->getJointTree();
@@ -574,9 +545,6 @@ void J3DSkinDeform::deformFastVtxNrm_F32(J3DVertexBuffer* pVtxBuffer, J3DMtxBuff
pVtxBuffer->setCurrentVtxNrm(transformedVtxNrm);
}
/* 8032DB50-8032DC74 328490 0124+00 1/1 0/0 0/0 .text
* deformVtxPos_F32__13J3DSkinDeformCFP15J3DVertexBufferP12J3DMtxBuffer */
// NONMATCHING - J3DPSMulMtxVec regalloc
void J3DSkinDeform::deformVtxPos_F32(J3DVertexBuffer* pVtxBuffer, J3DMtxBuffer* pMtxBuffer) const {
Mtx* anmMtx = NULL;
Mtx* anmMtxs[2];
@@ -599,9 +567,6 @@ void J3DSkinDeform::deformVtxPos_F32(J3DVertexBuffer* pVtxBuffer, J3DMtxBuffer*
pVtxBuffer->setCurrentVtxPos(transformedVtxPos);
}
/* 8032DC74-8032DDB8 3285B4 0144+00 1/1 0/0 0/0 .text
* deformVtxPos_S16__13J3DSkinDeformCFP15J3DVertexBufferP12J3DMtxBuffer */
// NONMATCHING - J3DPSMulMtxVec regalloc
void J3DSkinDeform::deformVtxPos_S16(J3DVertexBuffer* pVtxBuffer, J3DMtxBuffer* pMtxBuffer) const {
Mtx* anmMtx = NULL;
Mtx* anmMtxs[2];
@@ -626,9 +591,6 @@ void J3DSkinDeform::deformVtxPos_S16(J3DVertexBuffer* pVtxBuffer, J3DMtxBuffer*
pVtxBuffer->setCurrentVtxPos(transformedVtxPos);
}
/* 8032DDB8-8032DEBC 3286F8 0104+00 1/1 0/0 0/0 .text
* deformVtxNrm_F32__13J3DSkinDeformCFP15J3DVertexBuffer */
// NONMATCHING - J3DPSMulMtxVec regalloc
void J3DSkinDeform::deformVtxNrm_F32(J3DVertexBuffer* pVtxBuffer) const {
pVtxBuffer->swapTransformedVtxNrm();
int nrmNum = pVtxBuffer->getVertexData()->getNrmNum();
@@ -643,9 +605,6 @@ void J3DSkinDeform::deformVtxNrm_F32(J3DVertexBuffer* pVtxBuffer) const {
pVtxBuffer->setCurrentVtxNrm(transformedVtxNrm);
}
/* 8032DEBC-8032DFDC 3287FC 0120+00 1/1 0/0 0/0 .text
* deformVtxNrm_S16__13J3DSkinDeformCFP15J3DVertexBuffer */
// NONMATCHING - J3DPSMulMtxVec regalloc
void J3DSkinDeform::deformVtxNrm_S16(J3DVertexBuffer* pVtxBuffer) const {
int vtxNrmFrac = pVtxBuffer->getVertexData()->getVtxNrmFrac();
J3DGQRSetup7(vtxNrmFrac, 7, vtxNrmFrac, 7);
@@ -663,8 +622,6 @@ void J3DSkinDeform::deformVtxNrm_S16(J3DVertexBuffer* pVtxBuffer) const {
pVtxBuffer->setCurrentVtxNrm(transformedVtxNrm);
}
/* 8032DFDC-8032E064 32891C 0088+00 0/0 1/1 0/0 .text deform__13J3DSkinDeformFP8J3DModel
*/
void J3DSkinDeform::deform(J3DModel* pModel) {
J3D_ASSERT_NULLPTR(1270, pModel != NULL);
@@ -683,8 +640,6 @@ void J3DSkinDeform::deform(J3DModel* pModel) {
deform(pModel->getVertexBuffer(), pModel->getMtxBuffer());
}
/* 8032E064-8032E180 3289A4 011C+00 1/0 0/0 0/0 .text
* deform__13J3DSkinDeformFP15J3DVertexBufferP12J3DMtxBuffer */
void J3DSkinDeform::deform(J3DVertexBuffer* pVtxBuffer, J3DMtxBuffer* pMtxBuffer) {
J3D_ASSERT_NULLPTR(1299, pVtxBuffer != NULL);
J3D_ASSERT_NULLPTR(1300, pMtxBuffer != NULL);
@@ -719,12 +674,9 @@ void J3DSkinDeform::deform(J3DVertexBuffer* pVtxBuffer, J3DMtxBuffer* pMtxBuffer
}
}
/* 8032E180-8032E1B0 328AC0 0030+00 0/0 1/1 0/0 .text calc__15J3DVtxColorCalcFP8J3DModel
*/
void J3DVtxColorCalc::calc(J3DModel* pModel) {
J3D_ASSERT_NULLPTR(1351, pModel != NULL);
calc(pModel->getVertexBuffer());
}
/* 8032E1B0-8032E1F8 328AF0 0048+00 1/0 0/0 0/0 .text __dt__13J3DSkinDeformFv */
J3DSkinDeform::~J3DSkinDeform() {}
@@ -43,7 +43,6 @@ J3DDrawBuffer::~J3DDrawBuffer() {
mpBuffer = NULL;
}
/* 80325068-8032509C 31F9A8 0034+00 2/2 1/1 0/0 .text frameInit__13J3DDrawBufferFv */
void J3DDrawBuffer::frameInit() {
u32 bufSize = mEntryTableSize;
for (u32 i = 0; i < bufSize; i++)
@@ -52,8 +51,6 @@ void J3DDrawBuffer::frameInit() {
mpCallBackPacket = NULL;
}
/* 8032509C-803251E4 31F9DC 0148+00 2/1 0/0 0/0 .text
* entryMatSort__13J3DDrawBufferFP12J3DMatPacket */
int J3DDrawBuffer::entryMatSort(J3DMatPacket* pMatPacket) {
J3D_ASSERT_NULLPTR(122, pMatPacket != NULL);
@@ -97,8 +94,6 @@ int J3DDrawBuffer::entryMatSort(J3DMatPacket* pMatPacket) {
return 1;
}
/* 803251E4-8032529C 31FB24 00B8+00 1/0 0/0 0/0 .text
* entryMatAnmSort__13J3DDrawBufferFP12J3DMatPacket */
int J3DDrawBuffer::entryMatAnmSort(J3DMatPacket* pMatPacket) {
J3D_ASSERT_NULLPTR(199, pMatPacket != NULL);
@@ -131,8 +126,6 @@ int J3DDrawBuffer::entryMatAnmSort(J3DMatPacket* pMatPacket) {
return 1;
}
/* 8032529C-803253B4 31FBDC 0118+00 1/0 0/0 0/0 .text entryZSort__13J3DDrawBufferFP12J3DMatPacket
*/
int J3DDrawBuffer::entryZSort(J3DMatPacket* pMatPacket) {
J3D_ASSERT_NULLPTR(257, pMatPacket != NULL);
@@ -163,8 +156,6 @@ int J3DDrawBuffer::entryZSort(J3DMatPacket* pMatPacket) {
return 1;
}
/* 803253B4-80325404 31FCF4 0050+00 1/0 0/0 0/0 .text
* entryModelSort__13J3DDrawBufferFP12J3DMatPacket */
int J3DDrawBuffer::entryModelSort(J3DMatPacket* pMatPacket) {
J3D_ASSERT_NULLPTR(316, pMatPacket != NULL);
@@ -179,8 +170,6 @@ int J3DDrawBuffer::entryModelSort(J3DMatPacket* pMatPacket) {
return 0;
}
/* 80325404-80325458 31FD44 0054+00 1/0 0/0 0/0 .text
* entryInvalidSort__13J3DDrawBufferFP12J3DMatPacket */
int J3DDrawBuffer::entryInvalidSort(J3DMatPacket* pMatPacket) {
J3D_ASSERT_NULLPTR(343, pMatPacket != NULL);
@@ -215,22 +204,18 @@ int J3DDrawBuffer::entryImm(J3DPacket* pPacket, u16 index) {
return 1;
}
/* 803CEC30-803CEC78 02BD50 0048+00 0/1 1/1 0/0 .data sortFuncTable__13J3DDrawBuffer */
J3DDrawBuffer::sortFunc J3DDrawBuffer::sortFuncTable[6] = {
&J3DDrawBuffer::entryMatSort, &J3DDrawBuffer::entryMatAnmSort, &J3DDrawBuffer::entryZSort,
&J3DDrawBuffer::entryModelSort, &J3DDrawBuffer::entryInvalidSort, &J3DDrawBuffer::entryNonSort,
};
/* 803CEC90-803CECA8 02BDB0 0018+00 1/2 0/0 0/0 .data drawFuncTable__13J3DDrawBuffer */
J3DDrawBuffer::drawFunc J3DDrawBuffer::drawFuncTable[2] = {
&J3DDrawBuffer::drawHead,
&J3DDrawBuffer::drawTail,
};
/* 804515E0-804515E8 000AE0 0004+04 0/0 1/1 0/0 .sbss entryNum__13J3DDrawBuffer */
int J3DDrawBuffer::entryNum;
/* 803254AC-80325500 31FDEC 0054+00 0/0 2/2 0/0 .text draw__13J3DDrawBufferCFv */
void J3DDrawBuffer::draw() const {
J3D_ASSERT_RANGE(411, mDrawMode < J3DDrawBufDrawMode_MAX);
@@ -238,7 +223,6 @@ void J3DDrawBuffer::draw() const {
(this->*func)();
}
/* 80325500-80325578 31FE40 0078+00 1/0 0/0 0/0 .text drawHead__13J3DDrawBufferCFv */
void J3DDrawBuffer::drawHead() const {
u32 size = mEntryTableSize;
J3DPacket** buf = mpBuffer;
@@ -250,7 +234,6 @@ void J3DDrawBuffer::drawHead() const {
}
}
/* 80325578-803255F0 31FEB8 0078+00 1/0 0/0 0/0 .text drawTail__13J3DDrawBufferCFv */
void J3DDrawBuffer::drawTail() const {
for (int i = mEntryTableSize - 1; i >= 0; i--) {
for (J3DPacket* packet = mpBuffer[i]; packet != NULL; packet = packet->getNextPacket()) {
-50
View File
@@ -7,7 +7,6 @@
#include "JSystem/J3DGraphBase/J3DGD.h"
#include "JSystem/J3DGraphBase/J3DFifo.h"
/* 8030D098-8030D210 3079D8 0178+00 0/0 1/1 0/0 .text J3DGDSetGenMode__FUcUcUcUc11_GXCullMode */
void J3DGDSetGenMode(u8 nTexGens, u8 nChans, u8 nTevs, u8 nInds,
GXCullMode cm) {
static u8 cm2hw[4] = {0, 2, 1, 3};
@@ -17,14 +16,12 @@ void J3DGDSetGenMode(u8 nTexGens, u8 nChans, u8 nTevs, u8 nInds,
J3DGDWriteBPCmd(BP_GEN_MODE(nTexGens, nChans, nTevs - 1, cm2hw[cm], nInds));
}
/* 8030D210-8030D364 307B50 0154+00 0/0 1/1 0/0 .text J3DGDSetGenMode_3Param__FUcUcUc */
void J3DGDSetGenMode_3Param(u8 nTexGens, u8 nTevs, u8 nInds) {
GDOverflowCheck(10);
J3DGDWriteBPCmd(0xFE073C0F);
J3DGDWriteBPCmd(BP_GEN_MODE(nTexGens, 0, nTevs - 1, 0, nInds));
}
/* 8030D364-8030D65C 307CA4 02F8+00 0/0 1/1 0/0 .text J3DGDSetLightAttn__F10_GXLightIDffffff */
void J3DGDSetLightAttn(GXLightID light, f32 a0, f32 a1, f32 a2, f32 k0, f32 k1, f32 k2) {
J3DGDWriteXFCmdHdr(XF_LIGHT_ATTN_ID + __GDLightID2Offset(light), 6);
J3DGDWrite_f32(a0);
@@ -35,15 +32,11 @@ void J3DGDSetLightAttn(GXLightID light, f32 a0, f32 a1, f32 a2, f32 k0, f32 k1,
J3DGDWrite_f32(k2);
}
/* 8030D65C-8030D76C 307F9C 0110+00 0/0 1/1 0/0 .text J3DGDSetLightColor__F10_GXLightID8_GXColor
*/
void J3DGDSetLightColor(GXLightID light, GXColor color) {
J3DGDWriteXFCmd(XF_LIGHT_COLOR_ID + __GDLightID2Offset(light),
(color.r << 24) | (color.g << 16) | (color.b << 8) | (color.a << 0));
}
/* 8030D76C-8030D938 3080AC 01CC+00 0/0 1/1 0/0 .text J3DGDSetLightPos__F10_GXLightIDfff
*/
void J3DGDSetLightPos(GXLightID light, f32 x, f32 y, f32 z) {
J3DGDWriteXFCmdHdr(XF_LIGHT_POS_ID + __GDLightID2Offset(light), 3);
J3DGDWrite_f32(x);
@@ -51,8 +44,6 @@ void J3DGDSetLightPos(GXLightID light, f32 x, f32 y, f32 z) {
J3DGDWrite_f32(z);
}
/* 8030D938-8030DB04 308278 01CC+00 0/0 1/1 0/0 .text J3DGDSetLightDir__F10_GXLightIDfff
*/
void J3DGDSetLightDir(GXLightID light, f32 nx, f32 ny, f32 nz) {
J3DGDWriteXFCmdHdr(XF_LIGHT_DIR_ID + __GDLightID2Offset(light), 3);
J3DGDWrite_f32(nx);
@@ -60,8 +51,6 @@ void J3DGDSetLightDir(GXLightID light, f32 nx, f32 ny, f32 nz) {
J3DGDWrite_f32(nz);
}
/* 8030DB04-8030E064 308444 0560+00 1/0 1/1 0/0 .text
* J3DGDSetVtxAttrFmtv__F9_GXVtxFmtPC17_GXVtxAttrFmtListb */
void J3DGDSetVtxAttrFmtv(GXVtxFmt vtxfmt, const GXVtxAttrFmtList* list, bool param_2) {
u32 posCnt = GX_POS_XYZ;
u32 posType = GX_F32;
@@ -192,8 +181,6 @@ void J3DGDSetVtxAttrFmtv(GXVtxFmt vtxfmt, const GXVtxAttrFmtList* list, bool par
J3DGDWriteCPCmd(vtxfmt + CP_REG_VAT_GRP2_ID, CP_REG_VAT_GRP2(tx4Frac, tx5Cnt, tx5Type, tx5Frac, tx6Cnt, tx6Type, tx6Frac, tx7Cnt, tx7Type, tx7Frac));
}
/* 8030E064-8030E234 3089A4 01D0+00 1/0 1/1 0/0 .text
* J3DGDSetTexCoordGen__F13_GXTexGenType12_GXTexGenSrc */
void J3DGDSetTexCoordGen(GXTexGenType func, GXTexGenSrc src_param) {
u32 tgType;
u32 form;
@@ -316,8 +303,6 @@ void J3DGDSetTexCoordGen(GXTexGenType func, GXTexGenSrc src_param) {
J3DGDWrite_u32(XF_REG_TEX(proj, form, tgType, row, embossRow, embossLit));
}
/* 8030E234-8030E438 308B74 0204+00 0/0 16/16 0/0 .text
* J3DGDSetTexCoordScale2__F13_GXTexCoordIDUsUcUcUsUcUc */
void J3DGDSetTexCoordScale2(GXTexCoordID coord, u16 s_scale, u8 s_bias,
u8 s_wrap, u16 t_scale, u8 t_bias, u8 t_wrap) {
GDOverflowCheck(15);
@@ -326,32 +311,26 @@ void J3DGDSetTexCoordScale2(GXTexCoordID coord, u16 s_scale, u8 s_bias,
J3DGDWriteBPCmd(BP_TEXCOORD_T_SCALE(t_scale - 1, t_bias, t_wrap, coord * 2 + 0x31));
}
/* 8045090C-80450914 00038C 0008+00 1/1 0/0 0/0 .sdata J3DGDTexMode0Ids */
static u8 J3DGDTexMode0Ids[8] = {
0x80, 0x81, 0x82, 0x83, 0xA0, 0xA1, 0xA2, 0xA3,
};
/* 80450914-8045091C 000394 0008+00 1/1 0/0 0/0 .sdata J3DGDTexMode1Ids */
static u8 J3DGDTexMode1Ids[8] = {
0x84, 0x85, 0x86, 0x87, 0xA4, 0xA5, 0xA6, 0xA7,
};
/* 8045091C-80450924 00039C 0008+00 1/1 0/0 0/0 .sdata J3DGDTexImage0Ids */
static u8 J3DGDTexImage0Ids[8] = {
0x88, 0x89, 0x8A, 0x8B, 0xA8, 0xA9, 0xAA, 0xAB,
};
/* 80450924-8045092C 0003A4 0008+00 2/2 0/0 0/0 .sdata J3DGDTexImage3Ids */
static u8 J3DGDTexImage3Ids[8] = {
0x94, 0x95, 0x96, 0x97, 0xB4, 0xB5, 0xB6, 0xB7,
};
/* 8045092C-80450934 0003AC 0008+00 1/1 0/0 0/0 .sdata J3DGDTexTlutIds */
static u8 J3DGDTexTlutIds[8] = {
0x98, 0x99, 0x9A, 0x9B, 0xB8, 0xB9, 0xBA, 0xBB,
};
/* 80450934-8045093C 0003B4 0006+02 1/1 0/0 0/0 .sdata GX2HWFiltConv */
static u8 GX2HWFiltConv[6] = {
0x00, 0x04, 0x01, 0x05, 0x02, 0x06,
};
@@ -368,32 +347,23 @@ void J3DGDSetTexLookupMode(GXTexMapID id, GXTexWrapMode wrap_s,
J3DGDWriteBPCmd(BP_TEX_MODE1((u8)(16.0f * min_lod), (u8)(16.0f * max_lod), J3DGDTexMode1Ids[id]));
}
/* 8030E5D4-8030E67C 308F14 00A8+00 0/0 1/1 0/0 .text
* J3DGDSetTexImgAttr__F11_GXTexMapIDUsUs9_GXTexFmt */
void J3DGDSetTexImgAttr(GXTexMapID id, u16 width, u16 height, GXTexFmt format) {
J3DGDWriteBPCmd(BP_IMAGE_ATTR(width - 1, height - 1, format, J3DGDTexImage0Ids[id]));
}
/* 8030E67C-8030E70C 308FBC 0090+00 0/0 1/1 0/0 .text J3DGDSetTexImgPtr__F11_GXTexMapIDPv
*/
void J3DGDSetTexImgPtr(GXTexMapID id, void* image_ptr) {
J3DGDWriteBPCmd(BP_IMAGE_PTR(OSCachedToPhysical(image_ptr) >> 5, J3DGDTexImage3Ids[id]));
}
/* 8030E70C-8030E7E0 30904C 00D4+00 0/0 1/1 0/0 .text J3DGDSetTexImgPtrRaw__F11_GXTexMapIDUl */
void J3DGDSetTexImgPtrRaw(GXTexMapID id, u32 image_ptr_raw) {
GDOverflowCheck(5);
J3DGDWriteBPCmd(BP_IMAGE_PTR(image_ptr_raw, J3DGDTexImage3Ids[id]));
}
/* 8030E7E0-8030E878 309120 0098+00 0/0 1/1 0/0 .text
* J3DGDSetTexTlut__F11_GXTexMapIDUl10_GXTlutFmt */
void J3DGDSetTexTlut(GXTexMapID id, u32 tmem_addr, GXTlutFmt format) {
J3DGDWriteBPCmd(BP_TEX_TLUT((tmem_addr - 0x80000) >> 9, format, J3DGDTexTlutIds[id]));
}
/* 8030E878-8030EB30 3091B8 02B8+00 0/0 1/1 0/0 .text J3DGDLoadTlut__FPvUl11_GXTlutSize
*/
void J3DGDLoadTlut(void* tlut_ptr, u32 tmem_addr, GXTlutSize size) {
ASSERTMSGLINE(735, !(tmem_addr & 0x1ff), "GDLoadTlut: invalid TMEM pointer");
ASSERTMSGLINE(736, size <= 0x400, "GDLoadTlut: invalid TLUT size");
@@ -406,8 +376,6 @@ void J3DGDLoadTlut(void* tlut_ptr, u32 tmem_addr, GXTlutSize size) {
J3DGDWriteBPCmd(0xF000000);
}
/* 8030EB30-8030EE10 309470 02E0+00 0/0 2/2 0/0 .text J3DGDSetIndTexMtx__F14_GXIndTexMtxIDPA3_fSc
*/
void J3DGDSetIndTexMtx(GXIndTexMtxID mtx_id, f32 offset[2][3], s8 scale_exp) {
s32 offsetS32[6];
u32 id_offset;
@@ -548,8 +516,6 @@ void J3DGDSetTevOrder(GXTevStageID evenStage, GXTexCoordID coord0, GXTexMapID ma
));
}
/* 8030F294-8030F3FC 309BD4 0168+00 0/0 11/11 0/0 .text
* J3DGDSetTevKColor__F14_GXTevKColorID8_GXColor */
void J3DGDSetTevKColor(GXTevKColorID reg, GXColor color) {
u32 regRA;
u32 regBG;
@@ -562,8 +528,6 @@ void J3DGDSetTevKColor(GXTevKColorID reg, GXColor color) {
J3DGDWriteBPCmd(regBG);
}
/* 8030F3FC-8030F630 309D3C 0234+00 0/0 11/11 0/0 .text
* J3DGDSetTevColorS10__F11_GXTevRegID11_GXColorS10 */
void J3DGDSetTevColorS10(GXTevRegID reg, GXColorS10 color) {
u32 regRA;
u32 regBG;
@@ -578,7 +542,6 @@ void J3DGDSetTevColorS10(GXTevRegID reg, GXColorS10 color) {
J3DGDWriteBPCmd(regBG);
}
/* 8030F630-8030F994 309F70 0364+00 0/0 3/3 0/0 .text J3DGDSetFog__F10_GXFogTypeffff8_GXColor */
void J3DGDSetFog(GXFogType type, f32 startz, f32 endz, f32 nearz, f32 farz, GXColor color) {
f32 A;
f32 B;
@@ -644,8 +607,6 @@ void J3DGDSetFog(GXFogType type, f32 startz, f32 endz, f32 nearz, f32 farz, GXCo
(u32)(arg1) << 10 \
)
/* 8030F994-8030FAE0 30A2D4 014C+00 0/0 3/3 0/0 .text J3DGDSetFogRangeAdj__FUcUsP14_GXFogAdjTable
*/
void J3DGDSetFogRangeAdj(GXBool enable, u16 center, GXFogAdjTable* table) {
if (enable) {
for (int i = 0; i < 10; i += 2) {
@@ -658,7 +619,6 @@ void J3DGDSetFogRangeAdj(GXBool enable, u16 center, GXFogAdjTable* table) {
J3DGDWriteBPCmd(range_c);
}
/* 8030FAE0-8030FB60 30A420 0080+00 0/0 10/10 0/0 .text J3DFifoLoadPosMtxImm__FPA4_fUl */
void J3DFifoLoadPosMtxImm(MtxP mtx, u32 id) {
J3DFifoWriteXFCmdHdr(4 * id, 12);
J3DGXCmd1f32ptr(&mtx[0][0]);
@@ -675,7 +635,6 @@ void J3DFifoLoadPosMtxImm(MtxP mtx, u32 id) {
J3DGXCmd1f32ptr(&mtx[2][3]);
}
/* 8030FB60-8030FBCC 30A4A0 006C+00 0/0 9/9 0/0 .text J3DFifoLoadNrmMtxImm__FPA4_fUl */
void J3DFifoLoadNrmMtxImm(MtxP mtx, u32 id) {
J3DFifoWriteXFCmdHdr(id * 3 + 0x400, 9);
J3DGXCmd1f32ptr(&mtx[0][0]);
@@ -689,8 +648,6 @@ void J3DFifoLoadNrmMtxImm(MtxP mtx, u32 id) {
J3DGXCmd1f32ptr(&mtx[2][2]);
}
/* 8030FBCC-8030FC38 30A50C 006C+00 0/0 3/3 0/0 .text J3DFifoLoadNrmMtxImm3x3__FPA3_fUl
*/
void J3DFifoLoadNrmMtxImm3x3(Mtx3P mtx, u32 id) {
J3DFifoWriteXFCmdHdr(id * 3 + 0x400, 9);
J3DGXCmd1f32ptr(&mtx[0][0]);
@@ -704,8 +661,6 @@ void J3DFifoLoadNrmMtxImm3x3(Mtx3P mtx, u32 id) {
J3DGXCmd1f32ptr(&mtx[2][2]);
}
/* 8030FC38-8030FCD0 30A578 0098+00 0/0 4/4 0/0 .text J3DFifoLoadNrmMtxToTexMtx__FPA4_fUl
*/
void J3DFifoLoadNrmMtxToTexMtx(MtxP mtx, u32 id) {
J3DFifoWriteXFCmdHdr(4 * id, 12);
J3DGXCmd1f32ptr(&mtx[0][0]);
@@ -722,7 +677,6 @@ void J3DFifoLoadNrmMtxToTexMtx(MtxP mtx, u32 id) {
J3DGXCmd1f32(0.0f);
}
/* 8030FCD0-8030FD68 30A610 0098+00 0/0 2/2 0/0 .text J3DFifoLoadNrmMtxToTexMtx3x3__FPA3_fUl */
void J3DFifoLoadNrmMtxToTexMtx3x3(Mtx3P mtx, u32 id) {
J3DFifoWriteXFCmdHdr(4 * id, 0xc);
J3DGXCmd1f32ptr(&mtx[0][0]);
@@ -739,18 +693,14 @@ void J3DFifoLoadNrmMtxToTexMtx3x3(Mtx3P mtx, u32 id) {
J3DGXCmd1f32(0.0f);
}
/* 8045093C-80450944 0003BC 0008+00 1/1 0/0 0/0 .sdata J3DTexImage1Ids */
static u8 J3DTexImage1Ids[8] = {
0x8C, 0x8D, 0x8E, 0x8F, 0xAC, 0xAD, 0xAE, 0xAF,
};
/* 80450944-8045094C 0003C4 0008+00 1/1 0/0 0/0 .sdata J3DTexImage2Ids */
static u8 J3DTexImage2Ids[8] = {
0x90, 0x91, 0x92, 0x93, 0xB0, 0xB1, 0xB2, 0xB3,
};
/* 8030FD68-8030FDE8 30A6A8 0080+00 0/0 1/1 0/0 .text
* J3DFifoLoadTexCached__F11_GXTexMapIDUl15_GXTexCacheSizeUl15_GXTexCacheSize */
void J3DFifoLoadTexCached(GXTexMapID id, u32 tmem_even, GXTexCacheSize size_even,
u32 tmem_odd, GXTexCacheSize size_odd) {
J3DFifoLoadBPCmd(BP_TEX_CACHE_EVEN(tmem_even >> 5, size_even + 3, size_even + 3, 0, J3DTexImage1Ids[id]));
-174
View File
@@ -31,7 +31,6 @@ inline void loadTevKColor(u32 reg, const J3DGXColor& color) {
J3DGDSetTevKColor(GXTevKColorID(reg), color);
}
/* 8031747C-803174DC 311DBC 0060+00 0/0 1/1 0/0 .text initialize__21J3DColorBlockLightOffFv */
void J3DColorBlockLightOff::initialize() {
mColorChanNum = 0;
for (int i = 0; i < ARRAY_SIZE(mMatColor); i++) {
@@ -41,7 +40,6 @@ void J3DColorBlockLightOff::initialize() {
mColorChanOffset = 0;
}
/* 803174DC-80317580 311E1C 00A4+00 0/0 1/1 0/0 .text initialize__22J3DColorBlockAmbientOnFv */
void J3DColorBlockAmbientOn::initialize() {
mColorChanNum = 0;
for (int i = 0; i < ARRAY_SIZE(mMatColor); i++) {
@@ -54,7 +52,6 @@ void J3DColorBlockAmbientOn::initialize() {
mColorChanOffset = 0;
}
/* 80317580-80317644 311EC0 00C4+00 0/0 1/1 0/0 .text initialize__20J3DColorBlockLightOnFv */
void J3DColorBlockLightOn::initialize() {
mColorChanNum = 0;
for (int i = 0; i < ARRAY_SIZE(mMatColor); i++) {
@@ -70,7 +67,6 @@ void J3DColorBlockLightOn::initialize() {
mColorChanOffset = 0;
}
/* 80317644-80317674 311F84 0030+00 0/0 2/2 0/0 .text initialize__21J3DTexGenBlockPatchedFv */
void J3DTexGenBlockPatched::initialize() {
mTexGenNum = 0;
for (int i = 0; i < 8; i++)
@@ -78,7 +74,6 @@ void J3DTexGenBlockPatched::initialize() {
mTexMtxOffset = 0;
}
/* 80317674-803176A4 311FB4 0030+00 0/0 1/1 0/0 .text initialize__15J3DTexGenBlock4Fv */
void J3DTexGenBlock4::initialize() {
mTexGenNum = 0;
for (int i = 0; i < 4; i++)
@@ -86,8 +81,6 @@ void J3DTexGenBlock4::initialize() {
mTexMtxOffset = 0;
}
/* 803176A4-803176D4 311FE4 0030+00 0/0 1/1 0/0 .text initialize__19J3DTexGenBlockBasicFv
*/
void J3DTexGenBlockBasic::initialize() {
mTexGenNum = 0;
for (int i = 0; i < 8; i++)
@@ -95,13 +88,10 @@ void J3DTexGenBlockBasic::initialize() {
mTexMtxOffset = 0;
}
/* 803176D4-803176E0 312014 000C+00 0/0 1/1 0/0 .text initialize__15J3DTevBlockNullFv */
void J3DTevBlockNull::initialize() {
mTexNoOffset = 0;
}
/* 803176E0-803177E8 312020 0108+00 0/0 1/1 0/0 .text initialize__18J3DTevBlockPatchedFv
*/
void J3DTevBlockPatched::initialize() {
for (int i = 0; i < ARRAY_SIZE(mTexNo); i++) {
mTexNo[i] = 0xFFFF;
@@ -124,14 +114,12 @@ void J3DTevBlockPatched::initialize() {
mTevRegOffset = 0;
}
/* 803177E8-80317810 312128 0028+00 0/0 1/1 0/0 .text initialize__12J3DTevBlock1Fv */
void J3DTevBlock1::initialize() {
mTexNo[0] = 0xFFFF;
mTevStage[0].setStageNo(0);
mTexNoOffset = 0;
}
/* 80317810-803178EC 312150 00DC+00 0/0 1/1 0/0 .text initialize__12J3DTevBlock2Fv */
void J3DTevBlock2::initialize() {
mTexNo[0] = 0xFFFF;
mTexNo[1] = 0xFFFF;
@@ -155,7 +143,6 @@ void J3DTevBlock2::initialize() {
mTevRegOffset = 0;
}
/* 803178EC-80317A00 31222C 0114+00 0/0 1/1 0/0 .text initialize__12J3DTevBlock4Fv */
void J3DTevBlock4::initialize() {
mTexNo[0] = 0xFFFF;
mTexNo[1] = 0xFFFF;
@@ -188,7 +175,6 @@ void J3DTevBlock4::initialize() {
mTevRegOffset = 0;
}
/* 80317A00-80317B28 312340 0128+00 0/0 1/1 0/0 .text initialize__13J3DTevBlock16Fv */
void J3DTevBlock16::initialize() {
for (int i = 0; i < ARRAY_SIZE(mTexNo); i++) {
mTexNo[i] = 0xFFFF;
@@ -216,12 +202,10 @@ void J3DTevBlock16::initialize() {
mTevRegOffset = 0;
}
/* 80317B28-80317B34 312468 000C+00 0/0 1/1 0/0 .text initialize__15J3DIndBlockFullFv */
void J3DIndBlockFull::initialize() {
mIndTexStageNum = 0;
}
/* 80317B34-80317B58 312474 0024+00 0/0 1/1 0/0 .text initialize__16J3DPEBlockFogOffFv */
void J3DPEBlockFogOff::initialize() {
mAlphaComp = 0xFFFF;
mZMode = 0xFFFF;
@@ -229,7 +213,6 @@ void J3DPEBlockFogOff::initialize() {
mDither = 1;
}
/* 80317B58-80317B84 312498 002C+00 0/0 1/1 0/0 .text initialize__14J3DPEBlockFullFv */
void J3DPEBlockFull::initialize() {
mAlphaComp = 0xFFFF;
mZMode = 0xFFFF;
@@ -238,109 +221,84 @@ void J3DPEBlockFull::initialize() {
mFogOffset = 0;
}
/* 80317B84-80317B8C 3124C4 0008+00 1/0 0/0 0/0 .text countDLSize__21J3DColorBlockLightOffFv */
s32 J3DColorBlockLightOff::countDLSize() {
return 34;
}
/* 80317B8C-80317B94 3124CC 0008+00 1/0 0/0 0/0 .text countDLSize__22J3DColorBlockAmbientOnFv */
s32 J3DColorBlockAmbientOn::countDLSize() {
return 47;
}
/* 80317B94-80317B9C 3124D4 0008+00 1/0 0/0 0/0 .text countDLSize__20J3DColorBlockLightOnFv */
s32 J3DColorBlockLightOn::countDLSize() {
return 623;
}
/* 80317B9C-80317BA4 3124DC 0008+00 1/0 0/0 0/0 .text countDLSize__21J3DTexGenBlockPatchedFv */
s32 J3DTexGenBlockPatched::countDLSize() {
return 424;
}
/* 80317BA4-80317BAC 3124E4 0008+00 1/0 0/0 0/0 .text countDLSize__15J3DTexGenBlock4Fv */
s32 J3DTexGenBlock4::countDLSize() {
return 254;
}
/* 80317BAC-80317BB4 3124EC 0008+00 1/0 0/0 0/0 .text countDLSize__19J3DTexGenBlockBasicFv */
s32 J3DTexGenBlockBasic::countDLSize() {
return 498;
}
/* 80317BB4-80317BBC 3124F4 0008+00 1/0 0/0 0/0 .text countDLSize__18J3DTevBlockPatchedFv
*/
s32 J3DTevBlockPatched::countDLSize() {
return 560;
}
/* 80317BBC-80317BC4 3124FC 0008+00 1/0 0/0 0/0 .text countDLSize__12J3DTevBlock1Fv */
s32 J3DTevBlock1::countDLSize() {
return 105;
}
/* 80317BC4-80317BCC 312504 0008+00 1/0 0/0 0/0 .text countDLSize__12J3DTevBlock2Fv */
s32 J3DTevBlock2::countDLSize() {
return 335;
}
/* 80317BCC-80317BD4 31250C 0008+00 1/0 0/0 0/0 .text countDLSize__12J3DTevBlock4Fv */
s32 J3DTevBlock4::countDLSize() {
return 580;
}
/* 80317BD4-80317BDC 312514 0008+00 1/0 0/0 0/0 .text countDLSize__13J3DTevBlock16Fv */
s32 J3DTevBlock16::countDLSize() {
return 1000;
}
/* 80317BDC-80317BE4 31251C 0008+00 1/0 0/0 0/0 .text countDLSize__15J3DIndBlockFullFv */
s32 J3DIndBlockFull::countDLSize() {
return 140;
}
/* 80317BE4-80317BEC 312524 0008+00 1/0 0/0 0/0 .text countDLSize__13J3DPEBlockOpaFv */
s32 J3DPEBlockOpa::countDLSize() {
return 30;
}
/* 80317BEC-80317BF4 31252C 0008+00 1/0 0/0 0/0 .text countDLSize__17J3DPEBlockTexEdgeFv
*/
s32 J3DPEBlockTexEdge::countDLSize() {
return 30;
}
/* 80317BF4-80317BFC 312534 0008+00 1/0 0/0 0/0 .text countDLSize__13J3DPEBlockXluFv */
s32 J3DPEBlockXlu::countDLSize() {
return 30;
}
/* 80317BFC-80317C04 31253C 0008+00 1/0 0/0 0/0 .text countDLSize__16J3DPEBlockFogOffFv
*/
s32 J3DPEBlockFogOff::countDLSize() {
return 30;
}
/* 80317C04-80317C0C 312544 0008+00 1/0 0/0 0/0 .text countDLSize__14J3DPEBlockFullFv */
s32 J3DPEBlockFull::countDLSize() {
return 85;
}
/* 80450960-80450964 0003E0 0004+00 5/5 0/0 0/0 .sdata SizeOfLoadMatColors */
static u32 SizeOfLoadMatColors = 13;
/* 80450964-80450968 0003E4 0004+00 2/2 0/0 0/0 .sdata SizeOfLoadAmbColors */
static u32 SizeOfLoadAmbColors = 13;
/* 80450968-80450970 0003E8 0004+04 5/5 0/0 0/0 .sdata SizeOfLoadColorChans */
static u32 SizeOfLoadColorChans = 21;
static u8 sdata_padding[4] = {};
/* 804515D8-804515DC 000AD8 0004+00 2/2 0/0 0/0 .sbss SizeOfJ3DColorBlockLightOffLoad */
static u32 SizeOfJ3DColorBlockLightOffLoad = SizeOfLoadMatColors + SizeOfLoadColorChans;
/* 80317C0C-8031816C 31254C 0560+00 1/0 0/0 0/0 .text load__21J3DColorBlockLightOffFv */
void J3DColorBlockLightOff::load() {
GDOverflowCheck(SizeOfJ3DColorBlockLightOffLoad);
mMatColorOffset = GDGetCurrOffset();
@@ -354,10 +312,8 @@ void J3DColorBlockLightOff::load() {
mColorChan[3].load();
}
/* 804515DC-804515E0 000ADC 0004+00 3/3 0/0 0/0 .sbss SizeOfJ3DColorBlockAmbientOnLoad */
static u32 SizeOfJ3DColorBlockAmbientOnLoad = SizeOfLoadMatColors + SizeOfLoadAmbColors + SizeOfLoadColorChans;
/* 8031816C-803187F4 312AAC 0688+00 1/0 0/0 0/0 .text load__22J3DColorBlockAmbientOnFv */
void J3DColorBlockAmbientOn::load() {
GDOverflowCheck(SizeOfJ3DColorBlockAmbientOnLoad);
mMatColorOffset = GDGetCurrOffset();
@@ -372,7 +328,6 @@ void J3DColorBlockAmbientOn::load() {
mColorChan[3].load();
}
/* 803187F4-80318EB4 313134 06C0+00 1/0 0/0 0/0 .text load__20J3DColorBlockLightOnFv */
void J3DColorBlockLightOn::load() {
GDOverflowCheck(SizeOfJ3DColorBlockAmbientOnLoad);
mMatColorOffset = GDGetCurrOffset();
@@ -393,13 +348,11 @@ void J3DColorBlockLightOn::load() {
}
}
/* 80318EB4-80318F00 3137F4 004C+00 2/0 0/0 0/0 .text patch__21J3DColorBlockLightOffFv */
void J3DColorBlockLightOff::patch() {
patchMatColor();
patchLight();
}
/* 80318F00-803190AC 313840 01AC+00 2/0 0/0 0/0 .text patchMatColor__21J3DColorBlockLightOffFv */
void J3DColorBlockLightOff::patchMatColor() {
GDSetCurrOffset(mMatColorOffset);
void* start = GDGetCurrPointer();
@@ -409,7 +362,6 @@ void J3DColorBlockLightOff::patchMatColor() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 803190AC-803194E8 3139EC 043C+00 2/0 0/0 0/0 .text patchLight__21J3DColorBlockLightOffFv */
void J3DColorBlockLightOff::patchLight() {
GDSetCurrOffset(mColorChanOffset);
void* start = GDGetCurrPointer();
@@ -425,13 +377,11 @@ void J3DColorBlockLightOff::patchLight() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 803194E8-80319534 313E28 004C+00 1/0 0/0 0/0 .text patch__20J3DColorBlockLightOnFv */
void J3DColorBlockLightOn::patch() {
patchMatColor();
patchLight();
}
/* 80319534-803196E0 313E74 01AC+00 1/0 0/0 0/0 .text patchMatColor__20J3DColorBlockLightOnFv */
void J3DColorBlockLightOn::patchMatColor() {
GDSetCurrOffset(mMatColorOffset);
void* start = GDGetCurrPointer();
@@ -441,7 +391,6 @@ void J3DColorBlockLightOn::patchMatColor() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 803196E0-80319B4C 314020 046C+00 1/0 0/0 0/0 .text patchLight__20J3DColorBlockLightOnFv */
void J3DColorBlockLightOn::patchLight() {
GDSetCurrOffset(mColorChanOffset);
void* start = GDGetCurrPointer();
@@ -463,7 +412,6 @@ void J3DColorBlockLightOn::patchLight() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 80319B4C-80319BB4 31448C 0068+00 2/0 0/0 0/0 .text diff__21J3DColorBlockLightOffFUl */
void J3DColorBlockLightOff::diff(u32 diffFlags) {
if (diffFlags & J3DDiffFlag_MatColor)
diffMatColor();
@@ -472,13 +420,11 @@ void J3DColorBlockLightOff::diff(u32 diffFlags) {
diffColorChan();
}
/* 80319BB4-80319D30 3144F4 017C+00 2/0 0/0 0/0 .text diffMatColor__21J3DColorBlockLightOffFv */
void J3DColorBlockLightOff::diffMatColor() {
GDOverflowCheck(SizeOfLoadMatColors);
loadMatColors(mMatColor);
}
/* 80319D30-8031A13C 314670 040C+00 2/0 0/0 0/0 .text diffColorChan__21J3DColorBlockLightOffFv */
void J3DColorBlockLightOff::diffColorChan() {
GDOverflowCheck(SizeOfLoadColorChans);
J3DGDWriteXFCmdHdr(XF_REG_COLOR0CNTRL_ID, 4);
@@ -488,7 +434,6 @@ void J3DColorBlockLightOff::diffColorChan() {
mColorChan[3].load();
}
/* 8031A13C-8031A1DC 314A7C 00A0+00 1/0 0/0 0/0 .text diff__20J3DColorBlockLightOnFUl */
void J3DColorBlockLightOn::diff(u32 diffFlags) {
if (diffFlags & J3DDiffFlag_AmbColor)
diffAmbColor();
@@ -504,19 +449,16 @@ void J3DColorBlockLightOn::diff(u32 diffFlags) {
diffLightObj(lightObjNum);
}
/* 8031A1DC-8031A358 314B1C 017C+00 1/0 0/0 0/0 .text diffAmbColor__20J3DColorBlockLightOnFv */
void J3DColorBlockLightOn::diffAmbColor() {
GDOverflowCheck(SizeOfLoadAmbColors);
loadAmbColors(mAmbColor);
}
/* 8031A358-8031A4D4 314C98 017C+00 1/0 0/0 0/0 .text diffMatColor__20J3DColorBlockLightOnFv */
void J3DColorBlockLightOn::diffMatColor() {
GDOverflowCheck(SizeOfLoadMatColors);
loadMatColors(mMatColor);
}
/* 8031A4D4-8031A8E0 314E14 040C+00 1/0 0/0 0/0 .text diffColorChan__20J3DColorBlockLightOnFv */
void J3DColorBlockLightOn::diffColorChan() {
GDOverflowCheck(SizeOfLoadColorChans);
J3DGDWriteXFCmdHdr(XF_REG_COLOR0CNTRL_ID, 4);
@@ -526,7 +468,6 @@ void J3DColorBlockLightOn::diffColorChan() {
mColorChan[3].load();
}
/* 8031A8E0-8031A948 315220 0068+00 1/0 0/0 0/0 .text diffLightObj__20J3DColorBlockLightOnFUl */
void J3DColorBlockLightOn::diffLightObj(u32 lightObjNum) {
for (u32 i = 0; i < lightObjNum; i ++) {
if (mLight[i] != NULL) {
@@ -535,7 +476,6 @@ void J3DColorBlockLightOn::diffLightObj(u32 lightObjNum) {
}
}
/* 8031A948-8031A9E8 315288 00A0+00 1/0 0/0 0/0 .text load__15J3DTexGenBlock4Fv */
void J3DTexGenBlock4::load() {
mTexMtxOffset = GDGetCurrOffset();
for (u32 i = 0; i < 4; i++) {
@@ -549,7 +489,6 @@ void J3DTexGenBlock4::load() {
}
}
/* 8031A9E8-8031AA88 315328 00A0+00 1/0 0/0 0/0 .text load__19J3DTexGenBlockBasicFv */
void J3DTexGenBlockBasic::load() {
mTexMtxOffset = GDGetCurrOffset();
for (u32 i = 0; i < 8; i++) {
@@ -563,7 +502,6 @@ void J3DTexGenBlockBasic::load() {
}
}
/* 8031AA88-8031AB18 3153C8 0090+00 1/0 0/0 0/0 .text patch__21J3DTexGenBlockPatchedFv */
void J3DTexGenBlockPatched::patch() {
GDSetCurrOffset(mTexMtxOffset);
void* start = GDGetCurrPointer();
@@ -578,7 +516,6 @@ void J3DTexGenBlockPatched::patch() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031AB18-8031ABC0 315458 00A8+00 1/0 0/0 0/0 .text patch__15J3DTexGenBlock4Fv */
void J3DTexGenBlock4::patch() {
GDSetCurrOffset(mTexMtxOffset);
void* start = GDGetCurrPointer();
@@ -593,7 +530,6 @@ void J3DTexGenBlock4::patch() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031ABC0-8031AC68 315500 00A8+00 1/0 0/0 0/0 .text patch__19J3DTexGenBlockBasicFv */
void J3DTexGenBlockBasic::patch() {
GDSetCurrOffset(mTexMtxOffset);
void* start = GDGetCurrPointer();
@@ -608,7 +544,6 @@ void J3DTexGenBlockBasic::patch() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031AC68-8031ACD0 3155A8 0068+00 3/0 0/0 0/0 .text diff__21J3DTexGenBlockPatchedFUl */
void J3DTexGenBlockPatched::diff(u32 diffFlags) {
if (getDiffFlag_TexGenNum(diffFlags)) {
diffTexMtx();
@@ -619,7 +554,6 @@ void J3DTexGenBlockPatched::diff(u32 diffFlags) {
}
}
/* 8031ACD0-8031AD30 315610 0060+00 3/0 0/0 0/0 .text diffTexMtx__21J3DTexGenBlockPatchedFv */
void J3DTexGenBlockPatched::diffTexMtx() {
for (u32 i = 0; i < ARRAY_SIZEU(mTexMtx); ++i) {
if (mTexMtx[i] != NULL) {
@@ -628,14 +562,12 @@ void J3DTexGenBlockPatched::diffTexMtx() {
}
}
/* 8031AD30-8031AD64 315670 0034+00 3/0 0/0 0/0 .text diffTexGen__21J3DTexGenBlockPatchedFv */
void J3DTexGenBlockPatched::diffTexGen() {
if (mTexGenNum > 0) {
loadTexCoordGens(mTexGenNum, mTexCoord);
}
}
/* 8031AD64-8031AFA4 3156A4 0240+00 1/0 0/0 0/0 .text load__12J3DTevBlock1Fv */
void J3DTevBlock1::load() {
mTexNoOffset = GDGetCurrOffset();
GDOverflowCheck(0x69);
@@ -663,7 +595,6 @@ void J3DTevBlock1::load() {
mIndTevStage[0].load(0);
}
/* 8031AFA4-8031B4C0 3158E4 051C+00 1/0 0/0 0/0 .text load__12J3DTevBlock2Fv */
void J3DTevBlock2::load() {
u32 tevStageNum = mTevStageNum;
mTexNoOffset = GDGetCurrOffset();
@@ -730,7 +661,6 @@ void J3DTevBlock2::load() {
}
}
/* 8031B4C0-8031BA04 315E00 0544+00 1/0 0/0 0/0 .text load__12J3DTevBlock4Fv */
void J3DTevBlock4::load() {
u32 tevStageNum = mTevStageNum;
mTexNoOffset = GDGetCurrOffset();
@@ -799,7 +729,6 @@ void J3DTevBlock4::load() {
}
}
/* 8031BA04-8031BF4C 316344 0548+00 1/0 0/0 0/0 .text load__13J3DTevBlock16Fv */
void J3DTevBlock16::load() {
u32 tevStageNum = mTevStageNum;
mTexNoOffset = GDGetCurrOffset();
@@ -869,8 +798,6 @@ void J3DTevBlock16::load() {
}
/* 8031BF4C-8031BFE0 31688C 0094+00 1/0 0/0 0/0 .text patchTexNo__18J3DTevBlockPatchedFv
*/
void J3DTevBlockPatched::patchTexNo() {
GDSetCurrOffset(mTexNoOffset);
void* start = GDGetCurrPointer();
@@ -885,8 +812,6 @@ void J3DTevBlockPatched::patchTexNo() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031BFE0-8031C0AC 316920 00CC+00 1/0 0/0 0/0 .text patchTevReg__18J3DTevBlockPatchedFv
*/
void J3DTevBlockPatched::patchTevReg() {
GDSetCurrOffset(mTevRegOffset);
void* start = GDGetCurrPointer();
@@ -902,8 +827,6 @@ void J3DTevBlockPatched::patchTevReg() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031C0AC-8031C228 3169EC 017C+00 1/0 0/0 0/0 .text
* patchTexNoAndTexCoordScale__18J3DTevBlockPatchedFv */
void J3DTevBlockPatched::patchTexNoAndTexCoordScale() {
GDSetCurrOffset(mTexNoOffset);
void* start = GDGetCurrPointer();
@@ -941,13 +864,11 @@ void J3DTevBlockPatched::patchTexNoAndTexCoordScale() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031C228-8031C274 316B68 004C+00 1/0 0/0 0/0 .text patch__18J3DTevBlockPatchedFv */
void J3DTevBlockPatched::patch() {
patchTexNo();
patchTevReg();
}
/* 8031C274-8031C2E4 316BB4 0070+00 1/0 0/0 0/0 .text patchTexNo__12J3DTevBlock1Fv */
void J3DTevBlock1::patchTexNo() {
GDSetCurrOffset(mTexNoOffset);
void* start = GDGetCurrPointer();
@@ -960,11 +881,8 @@ void J3DTevBlock1::patchTexNo() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031C2E4-8031C2E8 316C24 0004+00 1/0 0/0 0/0 .text patchTevReg__12J3DTevBlock1Fv */
void J3DTevBlock1::patchTevReg() {}
/* 8031C2E8-8031C3CC 316C28 00E4+00 1/0 0/0 0/0 .text patchTexNoAndTexCoordScale__12J3DTevBlock1Fv
*/
void J3DTevBlock1::patchTexNoAndTexCoordScale() {
GDSetCurrOffset(mTexNoOffset);
void* start = GDGetCurrPointer();
@@ -992,12 +910,10 @@ void J3DTevBlock1::patchTexNoAndTexCoordScale() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031C3CC-8031C3F8 316D0C 002C+00 1/0 0/0 0/0 .text patch__12J3DTevBlock1Fv */
void J3DTevBlock1::patch() {
patchTexNo();
}
/* 8031C3F8-8031C48C 316D38 0094+00 1/0 0/0 0/0 .text patchTexNo__12J3DTevBlock2Fv */
void J3DTevBlock2::patchTexNo() {
GDSetCurrOffset(mTexNoOffset);
void* start = GDGetCurrPointer();
@@ -1012,7 +928,6 @@ void J3DTevBlock2::patchTexNo() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031C48C-8031C558 316DCC 00CC+00 1/0 0/0 0/0 .text patchTevReg__12J3DTevBlock2Fv */
void J3DTevBlock2::patchTevReg() {
GDSetCurrOffset(mTevRegOffset);
void* start = GDGetCurrPointer();
@@ -1028,8 +943,6 @@ void J3DTevBlock2::patchTevReg() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031C558-8031C6A8 316E98 0150+00 1/0 0/0 0/0 .text patchTexNoAndTexCoordScale__12J3DTevBlock2Fv
*/
void J3DTevBlock2::patchTexNoAndTexCoordScale() {
GDSetCurrOffset(mTexNoOffset);
void* start = GDGetCurrPointer();
@@ -1064,13 +977,11 @@ void J3DTevBlock2::patchTexNoAndTexCoordScale() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031C6A8-8031C6F4 316FE8 004C+00 1/0 0/0 0/0 .text patch__12J3DTevBlock2Fv */
void J3DTevBlock2::patch() {
patchTexNo();
patchTevReg();
}
/* 8031C6F4-8031C788 317034 0094+00 1/0 0/0 0/0 .text patchTexNo__12J3DTevBlock4Fv */
void J3DTevBlock4::patchTexNo() {
GDSetCurrOffset(mTexNoOffset);
void* start = GDGetCurrPointer();
@@ -1085,7 +996,6 @@ void J3DTevBlock4::patchTexNo() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031C788-8031C854 3170C8 00CC+00 1/0 0/0 0/0 .text patchTevReg__12J3DTevBlock4Fv */
void J3DTevBlock4::patchTevReg() {
GDSetCurrOffset(mTevRegOffset);
void* start = GDGetCurrPointer();
@@ -1101,8 +1011,6 @@ void J3DTevBlock4::patchTevReg() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031C854-8031C9D0 317194 017C+00 1/0 0/0 0/0 .text patchTexNoAndTexCoordScale__12J3DTevBlock4Fv
*/
void J3DTevBlock4::patchTexNoAndTexCoordScale() {
GDSetCurrOffset(mTexNoOffset);
void* start = GDGetCurrPointer();
@@ -1139,13 +1047,11 @@ void J3DTevBlock4::patchTexNoAndTexCoordScale() {
void* end = GDGetCurrPointer();
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031C9D0-8031CA1C 317310 004C+00 1/0 0/0 0/0 .text patch__12J3DTevBlock4Fv */
void J3DTevBlock4::patch() {
patchTexNo();
patchTevReg();
}
/* 8031CA1C-8031CAB0 31735C 0094+00 1/0 0/0 0/0 .text patchTexNo__13J3DTevBlock16Fv */
void J3DTevBlock16::patchTexNo() {
GDSetCurrOffset(mTexNoOffset);
void* start = GDGetCurrPointer();
@@ -1160,7 +1066,6 @@ void J3DTevBlock16::patchTexNo() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031CAB0-8031CB7C 3173F0 00CC+00 1/0 0/0 0/0 .text patchTevReg__13J3DTevBlock16Fv */
void J3DTevBlock16::patchTevReg() {
GDSetCurrOffset(mTevRegOffset);
void* start = GDGetCurrPointer();
@@ -1176,8 +1081,6 @@ void J3DTevBlock16::patchTevReg() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031CB7C-8031CCF8 3174BC 017C+00 1/0 0/0 0/0 .text
* patchTexNoAndTexCoordScale__13J3DTevBlock16Fv */
void J3DTevBlock16::patchTexNoAndTexCoordScale() {
GDSetCurrOffset(mTexNoOffset);
void* start = GDGetCurrPointer();
@@ -1215,13 +1118,11 @@ void J3DTevBlock16::patchTexNoAndTexCoordScale() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031CCF8-8031CD44 317638 004C+00 1/0 0/0 0/0 .text patch__13J3DTevBlock16Fv */
void J3DTevBlock16::patch() {
patchTexNo();
patchTevReg();
}
/* 8031CD44-8031CE00 317684 00BC+00 6/0 1/0 0/0 .text diff__11J3DTevBlockFUl */
void J3DTevBlock::diff(u32 diffFlags) {
if (getDiffFlag_TexNoNum(diffFlags)) {
diffTexNo();
@@ -1244,8 +1145,6 @@ void J3DTevBlock::diff(u32 diffFlags) {
}
}
/* 8031CE00-8031CE64 317740 0064+00 1/0 0/0 0/0 .text diffTexNo__18J3DTevBlockPatchedFv
*/
void J3DTevBlockPatched::diffTexNo() {
for (u32 i = 0; i < ARRAY_SIZEU(mTexNo); i++) {
if (mTexNo[i] != 0xFFFF) {
@@ -1254,7 +1153,6 @@ void J3DTevBlockPatched::diffTexNo() {
}
}
/* 8031CE64-8031CF78 3177A4 0114+00 1/0 0/0 0/0 .text diffTevStage__18J3DTevBlockPatchedFv */
void J3DTevBlockPatched::diffTevStage() {
u32 tevStageNum = mTevStageNum;
for (u32 i = 0; i < tevStageNum; i++) {
@@ -1262,8 +1160,6 @@ void J3DTevBlockPatched::diffTevStage() {
}
}
/* 8031CF78-8031D028 3178B8 00B0+00 1/0 0/0 0/0 .text diffTevStageIndirect__18J3DTevBlockPatchedFv
*/
void J3DTevBlockPatched::diffTevStageIndirect() {
u32 tevStageNum = mTevStageNum;
for (u32 i = 0; i < tevStageNum; i++) {
@@ -1271,8 +1167,6 @@ void J3DTevBlockPatched::diffTevStageIndirect() {
}
}
/* 8031D028-8031D0C4 317968 009C+00 1/0 0/0 0/0 .text diffTevReg__18J3DTevBlockPatchedFv
*/
void J3DTevBlockPatched::diffTevReg() {
for (u32 i = 0; i < ARRAY_SIZEU(mTevColor) - 1; i++) {
loadTevColor(i, mTevColor[i]);
@@ -1282,7 +1176,6 @@ void J3DTevBlockPatched::diffTevReg() {
}
}
/* 8031D0C4-8031D1BC 317A04 00F8+00 1/0 0/0 0/0 .text diffTexCoordScale__18J3DTevBlockPatchedFv */
void J3DTevBlockPatched::diffTexCoordScale() {
u32 tevStageNum = mTevStageNum;
for (u32 i = 0; i < tevStageNum; i += 2) {
@@ -1297,28 +1190,22 @@ void J3DTevBlockPatched::diffTexCoordScale() {
}
}
/* 8031D1BC-8031D1F4 317AFC 0038+00 1/0 0/0 0/0 .text diffTexNo__12J3DTevBlock1Fv */
void J3DTevBlock1::diffTexNo() {
if (mTexNo[0] != 0xFFFF) {
loadTexNo(0, mTexNo[0]);
}
}
/* 8031D1F4-8031D1F8 317B34 0004+00 1/0 0/0 0/0 .text diffTevReg__12J3DTevBlock1Fv */
void J3DTevBlock1::diffTevReg() {}
/* 8031D1F8-8031D2E8 317B38 00F0+00 1/0 0/0 0/0 .text diffTevStage__12J3DTevBlock1Fv */
void J3DTevBlock1::diffTevStage() {
mTevStage[0].load(0);
}
/* 8031D2E8-8031D368 317C28 0080+00 1/0 0/0 0/0 .text diffTevStageIndirect__12J3DTevBlock1Fv */
void J3DTevBlock1::diffTevStageIndirect() {
mIndTevStage[0].load(0);
}
/* 8031D368-8031D3D0 317CA8 0068+00 1/0 0/0 0/0 .text diffTexCoordScale__12J3DTevBlock1Fv
*/
void J3DTevBlock1::diffTexCoordScale() {
loadTexCoordScale(
GXTexCoordID(mTevOrder[0].getTevOrderInfo().mTexCoord),
@@ -1326,7 +1213,6 @@ void J3DTevBlock1::diffTexCoordScale() {
);
}
/* 8031D3D0-8031D434 317D10 0064+00 1/0 0/0 0/0 .text diffTexNo__12J3DTevBlock2Fv */
void J3DTevBlock2::diffTexNo() {
for (u32 i = 0; i < ARRAY_SIZEU(mTexNo); i++) {
if (mTexNo[i] != 0xFFFF) {
@@ -1335,7 +1221,6 @@ void J3DTevBlock2::diffTexNo() {
}
}
/* 8031D434-8031D4D0 317D74 009C+00 1/0 0/0 0/0 .text diffTevReg__12J3DTevBlock2Fv */
void J3DTevBlock2::diffTevReg() {
for (u32 i = 0; i < ARRAY_SIZEU(mTevColor) - 1; i++) {
loadTevColor(i, mTevColor[i]);
@@ -1345,7 +1230,6 @@ void J3DTevBlock2::diffTevReg() {
}
}
/* 8031D4D0-8031D5E4 317E10 0114+00 1/0 0/0 0/0 .text diffTevStage__12J3DTevBlock2Fv */
void J3DTevBlock2::diffTevStage() {
u32 tevStageNum = mTevStageNum;
for (u32 i = 0; i < tevStageNum; i++) {
@@ -1353,7 +1237,6 @@ void J3DTevBlock2::diffTevStage() {
}
}
/* 8031D5E4-8031D694 317F24 00B0+00 1/0 0/0 0/0 .text diffTevStageIndirect__12J3DTevBlock2Fv */
void J3DTevBlock2::diffTevStageIndirect() {
u32 tevStageNum = mTevStageNum;
for (u32 i = 0; i < tevStageNum; i++) {
@@ -1361,8 +1244,6 @@ void J3DTevBlock2::diffTevStageIndirect() {
}
}
/* 8031D694-8031D758 317FD4 00C4+00 1/0 0/0 0/0 .text diffTexCoordScale__12J3DTevBlock2Fv
*/
void J3DTevBlock2::diffTexCoordScale() {
loadTexCoordScale(
GXTexCoordID(mTevOrder[0].getTevOrderInfo().mTexCoord),
@@ -1374,7 +1255,6 @@ void J3DTevBlock2::diffTexCoordScale() {
);
}
/* 8031D758-8031D7BC 318098 0064+00 1/0 0/0 0/0 .text diffTexNo__12J3DTevBlock4Fv */
void J3DTevBlock4::diffTexNo() {
for (u32 i = 0; i < ARRAY_SIZEU(mTexNo); i++) {
if (mTexNo[i] != 0xFFFF) {
@@ -1383,7 +1263,6 @@ void J3DTevBlock4::diffTexNo() {
}
}
/* 8031D7BC-8031D858 3180FC 009C+00 1/0 0/0 0/0 .text diffTevReg__12J3DTevBlock4Fv */
void J3DTevBlock4::diffTevReg() {
for (u32 i = 0; i < ARRAY_SIZEU(mTevColor) - 1; i++) {
loadTevColor(i, mTevColor[i]);
@@ -1393,7 +1272,6 @@ void J3DTevBlock4::diffTevReg() {
}
}
/* 8031D858-8031D96C 318198 0114+00 1/0 0/0 0/0 .text diffTevStage__12J3DTevBlock4Fv */
void J3DTevBlock4::diffTevStage() {
u32 tevStageNum = mTevStageNum;
for (u32 i = 0; i < tevStageNum; i++) {
@@ -1401,7 +1279,6 @@ void J3DTevBlock4::diffTevStage() {
}
}
/* 8031D96C-8031DA1C 3182AC 00B0+00 1/0 0/0 0/0 .text diffTevStageIndirect__12J3DTevBlock4Fv */
void J3DTevBlock4::diffTevStageIndirect() {
u32 tevStageNum = mTevStageNum;
for (u32 i = 0; i < tevStageNum; i++) {
@@ -1409,8 +1286,6 @@ void J3DTevBlock4::diffTevStageIndirect() {
}
}
/* 8031DA1C-8031DB14 31835C 00F8+00 1/0 0/0 0/0 .text diffTexCoordScale__12J3DTevBlock4Fv
*/
void J3DTevBlock4::diffTexCoordScale() {
u32 tevStageNum = mTevStageNum;
for (u32 i = 0; i < tevStageNum; i += 2) {
@@ -1424,7 +1299,6 @@ void J3DTevBlock4::diffTexCoordScale() {
);
}
}
/* 8031DB14-8031DB78 318454 0064+00 1/0 0/0 0/0 .text diffTexNo__13J3DTevBlock16Fv */
void J3DTevBlock16::diffTexNo() {
for (u32 i = 0; i < ARRAY_SIZEU(mTexNo); i++) {
if (mTexNo[i] != 0xFFFF) {
@@ -1433,7 +1307,6 @@ void J3DTevBlock16::diffTexNo() {
}
}
/* 8031DB78-8031DC14 3184B8 009C+00 1/0 0/0 0/0 .text diffTevReg__13J3DTevBlock16Fv */
void J3DTevBlock16::diffTevReg() {
for (u32 i = 0; i < ARRAY_SIZEU(mTevColor) - 1; i++) {
loadTevColor(i, mTevColor[i]);
@@ -1443,7 +1316,6 @@ void J3DTevBlock16::diffTevReg() {
}
}
/* 8031DC14-8031DD28 318554 0114+00 1/0 0/0 0/0 .text diffTevStage__13J3DTevBlock16Fv */
void J3DTevBlock16::diffTevStage() {
u32 tevStageNum = mTevStageNum;
for (u32 i = 0; i < tevStageNum; i++) {
@@ -1451,7 +1323,6 @@ void J3DTevBlock16::diffTevStage() {
}
}
/* 8031DD28-8031DDD8 318668 00B0+00 1/0 0/0 0/0 .text diffTevStageIndirect__13J3DTevBlock16Fv */
void J3DTevBlock16::diffTevStageIndirect() {
u32 tevStageNum = mTevStageNum;
for (u32 i = 0; i < tevStageNum; i++) {
@@ -1459,7 +1330,6 @@ void J3DTevBlock16::diffTevStageIndirect() {
}
}
/* 8031DDD8-8031DED0 318718 00F8+00 1/0 0/0 0/0 .text diffTexCoordScale__13J3DTevBlock16Fv */
void J3DTevBlock16::diffTexCoordScale() {
u32 tevStageNum = mTevStageNum;
for (u32 i = 0; i < tevStageNum; i += 2) {
@@ -1474,7 +1344,6 @@ void J3DTevBlock16::diffTexCoordScale() {
}
}
/* 8031DED0-8031DFB4 318810 00E4+00 1/0 0/0 0/0 .text ptrToIndex__13J3DTevBlock16Fv */
void J3DTevBlock16::ptrToIndex() {
GDSetCurrOffset(mTexNoOffset);
void* start = GDGetCurrPointer();
@@ -1499,8 +1368,6 @@ void J3DTevBlock16::ptrToIndex() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031DFB4-8031E098 3188F4 00E4+00 1/0 0/0 0/0 .text ptrToIndex__18J3DTevBlockPatchedFv
*/
void J3DTevBlockPatched::ptrToIndex() {
GDSetCurrOffset(mTexNoOffset);
void* start = GDGetCurrPointer();
@@ -1525,7 +1392,6 @@ void J3DTevBlockPatched::ptrToIndex() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031E098-8031E12C 3189D8 0094+00 5/5 1/1 0/0 .text indexToPtr_private__11J3DTevBlockFUl */
void J3DTevBlock::indexToPtr_private(u32 offs) {
GDSetCurrOffset(offs);
void* start = GDGetCurrPointer();
@@ -1544,7 +1410,6 @@ void J3DTevBlock::indexToPtr_private(u32 offs) {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031E12C-8031E328 318A6C 01FC+00 1/0 0/0 0/0 .text load__15J3DIndBlockFullFv */
void J3DIndBlockFull::load() {
int indTexStageNum = mIndTexStageNum;
for (u32 i = 0; i < indTexStageNum; i++) {
@@ -1579,7 +1444,6 @@ void J3DIndBlockFull::load() {
);
}
/* 8031E328-8031E408 318C68 00E0+00 1/0 0/0 0/0 .text diff__15J3DIndBlockFullFUl */
void J3DIndBlockFull::diff(u32 diffFlags) {
if (diffFlags & J3DDiffFlag_TevStageIndirect) {
u32 indTexStageNum = mIndTexStageNum;
@@ -1609,7 +1473,6 @@ void J3DIndBlockFull::diff(u32 diffFlags) {
}
}
/* 8031E408-8031E6C8 318D48 02C0+00 1/0 0/0 0/0 .text load__13J3DPEBlockOpaFv */
void J3DPEBlockOpa::load() {
GDOverflowCheck(0x1e);
J3DGDSetAlphaCompare(GX_ALWAYS, 0, GX_AOP_AND, GX_ALWAYS, 0);
@@ -1618,7 +1481,6 @@ void J3DPEBlockOpa::load() {
J3DGDSetZCompLoc(1);
}
/* 8031E6C8-8031E98C 319008 02C4+00 1/0 0/0 0/0 .text load__17J3DPEBlockTexEdgeFv */
void J3DPEBlockTexEdge::load() {
GDOverflowCheck(0x1e);
J3DGDSetAlphaCompare(GX_GEQUAL, 0x80, GX_AOP_AND, GX_LEQUAL, 0xff);
@@ -1627,7 +1489,6 @@ void J3DPEBlockTexEdge::load() {
J3DGDSetZCompLoc(0);
}
/* 8031E98C-8031EC50 3192CC 02C4+00 1/0 0/0 0/0 .text load__13J3DPEBlockXluFv */
void J3DPEBlockXlu::load() {
GDOverflowCheck(0x1e);
J3DGDSetAlphaCompare(GX_ALWAYS, 0, GX_AOP_AND,GX_ALWAYS, 0);
@@ -1640,7 +1501,6 @@ inline void loadZCompLoc(u8 compLoc) {
J3DGDSetZCompLoc(compLoc);
}
/* 8031EC50-8031F0D8 319590 0488+00 1/0 0/0 0/0 .text load__16J3DPEBlockFogOffFv */
void J3DPEBlockFogOff::load() {
GDOverflowCheck(0x1e);
mAlphaComp.load();
@@ -1649,14 +1509,12 @@ void J3DPEBlockFogOff::load() {
loadZCompLoc(mZCompLoc);
}
/* 8031F0D8-8031F3C0 319A18 02E8+00 1/0 0/0 0/0 .text diffBlend__16J3DPEBlockFogOffFv */
void J3DPEBlockFogOff::diffBlend() {
GDOverflowCheck(0xf);
mBlend.load(mDither);
mZMode.load();
}
/* 8031F3C0-8031F890 319D00 04D0+00 1/0 0/0 0/0 .text load__14J3DPEBlockFullFv */
void J3DPEBlockFull::load() {
mFogOffset = GDGetCurrOffset();
GDOverflowCheck(0x55);
@@ -1667,7 +1525,6 @@ void J3DPEBlockFull::load() {
loadZCompLoc(mZCompLoc);
}
/* 8031F890-8031F940 31A1D0 00B0+00 1/0 0/0 0/0 .text patch__14J3DPEBlockFullFv */
void J3DPEBlockFull::patch() {
GDSetCurrOffset(mFogOffset);
GDOverflowCheck(0x37);
@@ -1677,20 +1534,17 @@ void J3DPEBlockFull::patch() {
DCStoreRange(start, (uintptr_t)end - (uintptr_t)start);
}
/* 8031F940-8031F9B8 31A280 0078+00 1/0 0/0 0/0 .text diffFog__14J3DPEBlockFullFv */
void J3DPEBlockFull::diffFog() {
GDOverflowCheck(0x37);
mFog.load();
}
/* 8031F9B8-8031FCA0 31A2F8 02E8+00 1/0 0/0 0/0 .text diffBlend__14J3DPEBlockFullFv */
void J3DPEBlockFull::diffBlend() {
GDOverflowCheck(0xf);
mBlend.load(mDither);
mZMode.load();
}
/* 8031FCA0-8031FD08 31A5E0 0068+00 1/0 0/0 0/0 .text diff__14J3DPEBlockFullFUl */
void J3DPEBlockFull::diff(u32 diffFlags) {
if ((diffFlags & J3DDiffFlag_Fog)) {
diffFog();
@@ -1701,8 +1555,6 @@ void J3DPEBlockFull::diff(u32 diffFlags) {
}
}
/* 8031FD08-8031FDE4 31A648 00DC+00 1/0 0/0 0/0 .text
* reset__21J3DColorBlockLightOffFP13J3DColorBlock */
void J3DColorBlockLightOff::reset(J3DColorBlock* pBlock) {
J3D_ASSERT_NULLPTR(2434, pBlock != NULL);
mColorChanNum = pBlock->getColorChanNum();
@@ -1715,8 +1567,6 @@ void J3DColorBlockLightOff::reset(J3DColorBlock* pBlock) {
}
}
/* 8031FDE4-8031FF34 31A724 0150+00 1/0 0/0 0/0 .text
* reset__22J3DColorBlockAmbientOnFP13J3DColorBlock */
void J3DColorBlockAmbientOn::reset(J3DColorBlock* pBlock) {
J3D_ASSERT_NULLPTR(2451, pBlock != NULL);
mColorChanNum = pBlock->getColorChanNum();
@@ -1734,8 +1584,6 @@ void J3DColorBlockAmbientOn::reset(J3DColorBlock* pBlock) {
}
}
/* 8031FF34-80320084 31A874 0150+00 1/0 0/0 0/0 .text
* reset__20J3DColorBlockLightOnFP13J3DColorBlock */
void J3DColorBlockLightOn::reset(J3DColorBlock* pBlock) {
J3D_ASSERT_NULLPTR(2476, pBlock != NULL);
mColorChanNum = pBlock->getColorChanNum();
@@ -1753,8 +1601,6 @@ void J3DColorBlockLightOn::reset(J3DColorBlock* pBlock) {
}
}
/* 80320084-803201A0 31A9C4 011C+00 1/0 0/0 0/0 .text
* reset__21J3DTexGenBlockPatchedFP14J3DTexGenBlock */
void J3DTexGenBlockPatched::reset(J3DTexGenBlock* pBlock) {
J3D_ASSERT_NULLPTR(2504, pBlock != NULL);
@@ -1775,8 +1621,6 @@ void J3DTexGenBlockPatched::reset(J3DTexGenBlock* pBlock) {
}
}
/* 803201A0-803202DC 31AAE0 013C+00 1/0 0/0 0/0 .text reset__15J3DTexGenBlock4FP14J3DTexGenBlock
*/
void J3DTexGenBlock4::reset(J3DTexGenBlock* pBlock) {
J3D_ASSERT_NULLPTR(2537, pBlock != NULL);
@@ -1799,8 +1643,6 @@ void J3DTexGenBlock4::reset(J3DTexGenBlock* pBlock) {
mNBTScale = *pBlock->getNBTScale();
}
/* 803202DC-80320418 31AC1C 013C+00 1/0 0/0 0/0 .text
* reset__19J3DTexGenBlockBasicFP14J3DTexGenBlock */
void J3DTexGenBlockBasic::reset(J3DTexGenBlock* pBlock) {
J3D_ASSERT_NULLPTR(2572, pBlock != NULL);
@@ -1823,8 +1665,6 @@ void J3DTexGenBlockBasic::reset(J3DTexGenBlock* pBlock) {
mNBTScale = *pBlock->getNBTScale();
}
/* 80320418-803205D4 31AD58 01BC+00 1/0 0/0 0/0 .text reset__18J3DTevBlockPatchedFP11J3DTevBlock
*/
void J3DTevBlockPatched::reset(J3DTevBlock* pBlock) {
J3D_ASSERT_NULLPTR(2608, pBlock != NULL);
@@ -1844,7 +1684,6 @@ void J3DTevBlockPatched::reset(J3DTevBlock* pBlock) {
}
}
/* 803205D4-803206AC 31AF14 00D8+00 1/0 0/0 0/0 .text reset__12J3DTevBlock1FP11J3DTevBlock */
void J3DTevBlock1::reset(J3DTevBlock* pBlock) {
J3D_ASSERT_NULLPTR(2633, pBlock != NULL);
@@ -1854,7 +1693,6 @@ void J3DTevBlock1::reset(J3DTevBlock* pBlock) {
mIndTevStage[0] = *pBlock->getIndTevStage(0);
}
/* 803206AC-8032098C 31AFEC 02E0+00 1/0 0/0 0/0 .text reset__12J3DTevBlock2FP11J3DTevBlock */
void J3DTevBlock2::reset(J3DTevBlock* pBlock) {
J3D_ASSERT_NULLPTR(2649, pBlock != NULL);
@@ -1883,7 +1721,6 @@ void J3DTevBlock2::reset(J3DTevBlock* pBlock) {
}
}
/* 8032098C-80320E24 31B2CC 0498+00 1/0 0/0 0/0 .text reset__12J3DTevBlock4FP11J3DTevBlock */
void J3DTevBlock4::reset(J3DTevBlock* pBlock) {
J3D_ASSERT_NULLPTR(2682, pBlock != NULL);
@@ -1921,7 +1758,6 @@ void J3DTevBlock4::reset(J3DTevBlock* pBlock) {
mTevSwapModeTable[i] = *pBlock->getTevSwapModeTable(i);
}
/* 80320E24-803210B0 31B764 028C+00 1/0 0/0 0/0 .text reset__13J3DTevBlock16FP11J3DTevBlock */
void J3DTevBlock16::reset(J3DTevBlock* pBlock) {
J3D_ASSERT_NULLPTR(2728, pBlock != NULL);
@@ -1953,7 +1789,6 @@ void J3DTevBlock16::reset(J3DTevBlock* pBlock) {
}
}
/* 803210B0-803211B4 31B9F0 0104+00 1/0 0/0 0/0 .text reset__15J3DIndBlockFullFP11J3DIndBlock */
void J3DIndBlockFull::reset(J3DIndBlock* pBlock) {
J3D_ASSERT_NULLPTR(2762, pBlock != NULL);
@@ -1969,7 +1804,6 @@ void J3DIndBlockFull::reset(J3DIndBlock* pBlock) {
}
}
/* 803211B4-8032129C 31BAF4 00E8+00 1/0 0/0 0/0 .text reset__16J3DPEBlockFogOffFP10J3DPEBlock */
void J3DPEBlockFogOff::reset(J3DPEBlock* pBlock) {
J3D_ASSERT_NULLPTR(2783, pBlock != NULL);
@@ -1984,7 +1818,6 @@ void J3DPEBlockFogOff::reset(J3DPEBlock* pBlock) {
}
}
/* 8032129C-803213C0 31BBDC 0124+00 1/0 0/0 0/0 .text reset__14J3DPEBlockFullFP10J3DPEBlock */
void J3DPEBlockFull::reset(J3DPEBlock* pBlock) {
J3D_ASSERT_NULLPTR(2807, pBlock != NULL);
@@ -2003,7 +1836,6 @@ void J3DPEBlockFull::reset(J3DPEBlock* pBlock) {
}
}
/* 803213C0-80321584 31BD00 01C4+00 4/0 0/0 0/0 .text calc__21J3DTexGenBlockPatchedFPA4_Cf */
void J3DTexGenBlockPatched::calc(const Mtx modelMtx) {
Mtx viewMtx;
for (int i = 0; i < 8; i++) {
@@ -2063,8 +1895,6 @@ void J3DTexGenBlockPatched::calc(const Mtx modelMtx) {
}
}
/* 80321584-803216D8 31BEC4 0154+00 4/0 0/0 0/0 .text
* calcWithoutViewMtx__21J3DTexGenBlockPatchedFPA4_Cf */
void J3DTexGenBlockPatched::calcWithoutViewMtx(const Mtx modelMtx) {
Mtx mtx;
for (int i = 0; i < 8; i++) {
@@ -2110,8 +1940,6 @@ void J3DTexGenBlockPatched::calcWithoutViewMtx(const Mtx modelMtx) {
}
}
/* 803216D8-8032181C 31C018 0144+00 4/0 0/0 0/0 .text
* calcPostTexMtx__21J3DTexGenBlockPatchedFPA4_Cf */
void J3DTexGenBlockPatched::calcPostTexMtx(const Mtx modelMtx) {
Mtx mtx1, mtx2;
for (int i = 0; i < 8; i++) {
@@ -2155,8 +1983,6 @@ void J3DTexGenBlockPatched::calcPostTexMtx(const Mtx modelMtx) {
}
}
/* 8032181C-80321938 31C15C 011C+00 4/0 0/0 0/0 .text
* calcPostTexMtxWithoutViewMtx__21J3DTexGenBlockPatchedFPA4_Cf */
void J3DTexGenBlockPatched::calcPostTexMtxWithoutViewMtx(f32 const (*param_0)[4]) {
for (int i = 0; i < 8; i++) {
if (mTexMtx[i] != NULL) {
-59
View File
@@ -3,8 +3,6 @@
#include "JSystem/J3DGraphBase/J3DMaterial.h"
#include "JSystem/J3DGraphBase/J3DGD.h"
/* 803157A0-803159A0 3100E0 0200+00 0/0 3/3 0/0 .text createColorBlock__11J3DMaterialFUl
*/
J3DColorBlock* J3DMaterial::createColorBlock(u32 flags) {
J3DColorBlock* rv = NULL;
switch (flags) {
@@ -23,8 +21,6 @@ J3DColorBlock* J3DMaterial::createColorBlock(u32 flags) {
return rv;
}
/* 803159A0-80315B04 3102E0 0164+00 0/0 2/2 0/0 .text createTexGenBlock__11J3DMaterialFUl
*/
J3DTexGenBlock* J3DMaterial::createTexGenBlock(u32 flags) {
J3DTexGenBlock* rv = NULL;
switch (flags) {
@@ -40,7 +36,6 @@ J3DTexGenBlock* J3DMaterial::createTexGenBlock(u32 flags) {
return rv;
}
/* 80315B04-80315E78 310444 0374+00 0/0 2/2 0/0 .text createTevBlock__11J3DMaterialFi */
J3DTevBlock* J3DMaterial::createTevBlock(int tevStageNum) {
J3DTevBlock* rv = NULL;
if (tevStageNum <= 1) {
@@ -57,7 +52,6 @@ J3DTevBlock* J3DMaterial::createTevBlock(int tevStageNum) {
return rv;
}
/* 80315E78-80315F60 3107B8 00E8+00 0/0 3/3 0/0 .text createIndBlock__11J3DMaterialFi */
J3DIndBlock* J3DMaterial::createIndBlock(int flags) {
J3DIndBlock* rv = NULL;
if (flags != 0) {
@@ -70,8 +64,6 @@ J3DIndBlock* J3DMaterial::createIndBlock(int flags) {
return rv;
}
/* 80315F60-80316100 3108A0 01A0+00 0/0 3/3 0/0 .text createPEBlock__11J3DMaterialFUlUl
*/
J3DPEBlock* J3DMaterial::createPEBlock(u32 flags, u32 materialMode) {
J3DPEBlock* rv = NULL;
if (flags == 0) {
@@ -100,7 +92,6 @@ J3DPEBlock* J3DMaterial::createPEBlock(u32 flags, u32 materialMode) {
return rv;
}
/* 80316100-80316150 310A40 0050+00 0/0 2/2 0/0 .text calcSizeColorBlock__11J3DMaterialFUl */
u32 J3DMaterial::calcSizeColorBlock(u32 flags) {
u32 rv = 0;
switch (flags) {
@@ -118,7 +109,6 @@ u32 J3DMaterial::calcSizeColorBlock(u32 flags) {
return rv;
}
/* 80316150-8031617C 310A90 002C+00 0/0 1/1 0/0 .text calcSizeTexGenBlock__11J3DMaterialFUl */
u32 J3DMaterial::calcSizeTexGenBlock(u32 flags) {
u32 rv = 0;
switch (flags) {
@@ -133,8 +123,6 @@ u32 J3DMaterial::calcSizeTexGenBlock(u32 flags) {
return rv;
}
/* 8031617C-803161C4 310ABC 0048+00 0/0 1/1 0/0 .text calcSizeTevBlock__11J3DMaterialFi
*/
u32 J3DMaterial::calcSizeTevBlock(int tevStageNum) {
u32 rv = 0;
if (tevStageNum <= 1) {
@@ -150,8 +138,6 @@ u32 J3DMaterial::calcSizeTevBlock(int tevStageNum) {
return rv;
}
/* 803161C4-803161D8 310B04 0014+00 0/0 2/2 0/0 .text calcSizeIndBlock__11J3DMaterialFi
*/
u32 J3DMaterial::calcSizeIndBlock(int flags) {
u32 rv = 0;
if (flags != 0) {
@@ -163,8 +149,6 @@ u32 J3DMaterial::calcSizeIndBlock(int flags) {
return rv;
}
/* 803161D8-80316240 310B18 0068+00 0/0 2/2 0/0 .text calcSizePEBlock__11J3DMaterialFUlUl
*/
u32 J3DMaterial::calcSizePEBlock(u32 flags, u32 materialMode) {
u32 rv = 0;
if (flags == 0) {
@@ -184,7 +168,6 @@ u32 J3DMaterial::calcSizePEBlock(u32 flags, u32 materialMode) {
return rv;
}
/* 80316240-80316290 310B80 0050+00 2/2 5/5 0/0 .text initialize__11J3DMaterialFv */
void J3DMaterial::initialize() {
mShape = NULL;
mNext = NULL;
@@ -203,14 +186,11 @@ void J3DMaterial::initialize() {
mSharedDLObj = NULL;
}
/* 80316290-80316344 310BD0 00B4+00 0/0 2/2 0/0 .text countDLSize__11J3DMaterialFv */
u32 J3DMaterial::countDLSize() {
return (mColorBlock->countDLSize() + mTexGenBlock->countDLSize() + mTevBlock->countDLSize() +
mIndBlock->countDLSize() + mPEBlock->countDLSize() + 31) & ~0x1f;
}
/* 80316344-80316620 310C84 02DC+00 2/2 0/0 0/0 .text
* makeDisplayList_private__11J3DMaterialFP17J3DDisplayListObj */
void J3DMaterial::makeDisplayList_private(J3DDisplayListObj* pDLObj) {
pDLObj->beginDL();
mTevBlock->load();
@@ -224,7 +204,6 @@ void J3DMaterial::makeDisplayList_private(J3DDisplayListObj* pDLObj) {
pDLObj->endDL();
}
/* 80316620-80316668 310F60 0048+00 1/0 0/0 0/0 .text makeDisplayList__11J3DMaterialFv */
void J3DMaterial::makeDisplayList() {
if (!j3dSys.getMatPacket()->isLocked()) {
j3dSys.getMatPacket()->mDiffFlag = mDiffFlag;
@@ -232,12 +211,10 @@ void J3DMaterial::makeDisplayList() {
}
}
/* 80316668-8031668C 310FA8 0024+00 1/0 0/0 0/0 .text makeSharedDisplayList__11J3DMaterialFv */
void J3DMaterial::makeSharedDisplayList() {
makeDisplayList_private(mSharedDLObj);
}
/* 8031668C-803166DC 310FCC 0050+00 1/0 0/0 0/0 .text load__11J3DMaterialFv */
void J3DMaterial::load() {
j3dSys.setMaterialMode(mMaterialMode);
if (!j3dSys.checkFlag(2)) {
@@ -245,7 +222,6 @@ void J3DMaterial::load() {
}
}
/* 803166DC-80316740 31101C 0064+00 1/0 0/0 0/0 .text loadSharedDL__11J3DMaterialFv */
void J3DMaterial::loadSharedDL() {
j3dSys.setMaterialMode(mMaterialMode);
if (!j3dSys.checkFlag(2)) {
@@ -254,7 +230,6 @@ void J3DMaterial::loadSharedDL() {
}
}
/* 80316740-803167D8 311080 0098+00 2/0 0/0 0/0 .text patch__11J3DMaterialFv */
void J3DMaterial::patch() {
j3dSys.getMatPacket()->mDiffFlag = mDiffFlag;
j3dSys.getMatPacket()->beginPatch();
@@ -264,7 +239,6 @@ void J3DMaterial::patch() {
j3dSys.getMatPacket()->endPatch();
}
/* 803167D8-803169DC 311118 0204+00 2/0 0/0 0/0 .text diff__11J3DMaterialFUl */
void J3DMaterial::diff(u32 diffFlags) {
if (j3dSys.getMatPacket()->isEnabled_Diff()) {
j3dSys.getMatPacket()->beginDiff();
@@ -283,7 +257,6 @@ void J3DMaterial::diff(u32 diffFlags) {
}
}
/* 803169DC-80316A54 31131C 0078+00 2/0 0/0 0/0 .text calc__11J3DMaterialFPA4_Cf */
void J3DMaterial::calc(f32 const (*param_0)[4]) {
if (j3dSys.checkFlag(0x40000000)) {
mTexGenBlock->calcPostTexMtx(param_0);
@@ -295,7 +268,6 @@ void J3DMaterial::calc(f32 const (*param_0)[4]) {
setCurrentMtx();
}
/* 80316A54-80316AB0 311394 005C+00 3/0 0/0 0/0 .text calcDiffTexMtx__11J3DMaterialFPA4_Cf */
void J3DMaterial::calcDiffTexMtx(f32 const (*param_0)[4]) {
if (j3dSys.checkFlag(0x40000000)) {
mTexGenBlock->calcPostTexMtxWithoutViewMtx(param_0);
@@ -304,12 +276,10 @@ void J3DMaterial::calcDiffTexMtx(f32 const (*param_0)[4]) {
}
}
/* 80316AB0-80316AC8 3113F0 0018+00 1/1 1/1 0/0 .text setCurrentMtx__11J3DMaterialFv */
void J3DMaterial::setCurrentMtx() {
mShape->setCurrentMtx(mCurrentMtx);
}
/* 80316AC8-80316D68 311408 02A0+00 1/1 0/0 0/0 .text calcCurrentMtx__11J3DMaterialFv */
void J3DMaterial::calcCurrentMtx() {
if (!j3dSys.checkFlag(0x40000000)) {
mCurrentMtx.setCurrentTexMtx(
@@ -336,8 +306,6 @@ void J3DMaterial::calcCurrentMtx() {
}
}
/* 80316D68-80316E14 3116A8 00AC+00 1/1 0/0 0/0 .text copy__11J3DMaterialFP11J3DMaterial
*/
void J3DMaterial::copy(J3DMaterial* pOther) {
J3D_ASSERT_NULLPTR(620, pOther != NULL);
mColorBlock->reset(pOther->mColorBlock);
@@ -347,7 +315,6 @@ void J3DMaterial::copy(J3DMaterial* pOther) {
mPEBlock->reset(pOther->mPEBlock);
}
/* 80316E14-80316E70 311754 005C+00 1/0 0/0 0/0 .text reset__11J3DMaterialFv */
void J3DMaterial::reset() {
if ((~mDiffFlag & J3DDiffFlag_Changed) == 0) {
mDiffFlag &= ~J3DDiffFlag_Changed;
@@ -358,7 +325,6 @@ void J3DMaterial::reset() {
}
}
/* 80316E70-80316E90 3117B0 0020+00 1/0 0/0 0/0 .text change__11J3DMaterialFv */
void J3DMaterial::change() {
if ((mDiffFlag & (J3DDiffFlag_Changed | J3DDiffFlag_Unk40000000)) == 0) {
mDiffFlag |= J3DDiffFlag_Changed;
@@ -366,7 +332,6 @@ void J3DMaterial::change() {
}
}
/* 80316E90-80316F24 3117D0 0094+00 0/0 2/2 0/0 .text newSharedDisplayList__11J3DMaterialFUl */
s32 J3DMaterial::newSharedDisplayList(u32 dlSize) {
if (mSharedDLObj == NULL) {
mSharedDLObj = new J3DDisplayListObj();
@@ -383,8 +348,6 @@ s32 J3DMaterial::newSharedDisplayList(u32 dlSize) {
return kJ3DError_Success;
}
/* 80316F24-80316FB8 311864 0094+00 0/0 2/2 0/0 .text newSingleSharedDisplayList__11J3DMaterialFUl
*/
s32 J3DMaterial::newSingleSharedDisplayList(u32 dlSize) {
if (mSharedDLObj == NULL) {
mSharedDLObj = new J3DDisplayListObj();
@@ -401,20 +364,14 @@ s32 J3DMaterial::newSingleSharedDisplayList(u32 dlSize) {
return kJ3DError_Success;
}
/* 80316FB8-80316FD8 3118F8 0020+00 0/0 1/1 0/0 .text initialize__18J3DPatchedMaterialFv
*/
void J3DPatchedMaterial::initialize() {
J3DMaterial::initialize();
}
/* 80316FD8-80316FDC 311918 0004+00 1/0 0/0 0/0 .text makeDisplayList__18J3DPatchedMaterialFv */
void J3DPatchedMaterial::makeDisplayList() {}
/* 80316FDC-80316FE0 31191C 0004+00 1/0 0/0 0/0 .text
* makeSharedDisplayList__18J3DPatchedMaterialFv */
void J3DPatchedMaterial::makeSharedDisplayList() {}
/* 80316FE0-80316FFC 311920 001C+00 1/0 0/0 0/0 .text load__18J3DPatchedMaterialFv */
void J3DPatchedMaterial::load() {
j3dSys.setMaterialMode(mMaterialMode);
if (j3dSys.checkFlag(2)) {
@@ -422,33 +379,24 @@ void J3DPatchedMaterial::load() {
}
}
/* 80316FFC-8031703C 31193C 0040+00 1/0 0/0 0/0 .text loadSharedDL__18J3DPatchedMaterialFv */
void J3DPatchedMaterial::loadSharedDL() {
j3dSys.setMaterialMode(mMaterialMode);
if (!j3dSys.checkFlag(0x02))
mSharedDLObj->callDL();
}
/* 8031703C-80317040 31197C 0004+00 1/0 0/0 0/0 .text reset__18J3DPatchedMaterialFv */
void J3DPatchedMaterial::reset() {}
/* 80317040-80317044 311980 0004+00 1/0 0/0 0/0 .text change__18J3DPatchedMaterialFv */
void J3DPatchedMaterial::change() {}
/* 80317044-80317064 311984 0020+00 0/0 1/1 0/0 .text initialize__17J3DLockedMaterialFv
*/
void J3DLockedMaterial::initialize() {
J3DMaterial::initialize();
}
/* 80317064-80317068 3119A4 0004+00 1/0 0/0 0/0 .text makeDisplayList__17J3DLockedMaterialFv */
void J3DLockedMaterial::makeDisplayList() {}
/* 80317068-8031706C 3119A8 0004+00 1/0 0/0 0/0 .text makeSharedDisplayList__17J3DLockedMaterialFv
*/
void J3DLockedMaterial::makeSharedDisplayList() {}
/* 8031706C-80317088 3119AC 001C+00 1/0 0/0 0/0 .text load__17J3DLockedMaterialFv */
void J3DLockedMaterial::load() {
j3dSys.setMaterialMode(mMaterialMode);
if (j3dSys.checkFlag(2)) {
@@ -456,25 +404,18 @@ void J3DLockedMaterial::load() {
}
}
/* 80317088-803170C8 3119C8 0040+00 1/0 0/0 0/0 .text loadSharedDL__17J3DLockedMaterialFv
*/
void J3DLockedMaterial::loadSharedDL() {
j3dSys.setMaterialMode(mMaterialMode);
if (!j3dSys.checkFlag(0x02))
mSharedDLObj->callDL();
}
/* 803170C8-803170CC 311A08 0004+00 1/0 0/0 0/0 .text patch__17J3DLockedMaterialFv */
void J3DLockedMaterial::patch() {}
/* 803170CC-803170D0 311A0C 0004+00 1/0 0/0 0/0 .text diff__17J3DLockedMaterialFUl */
void J3DLockedMaterial::diff(u32 diffFlags) {}
/* 803170D0-803170D4 311A10 0004+00 1/0 0/0 0/0 .text calc__17J3DLockedMaterialFPA4_Cf */
void J3DLockedMaterial::calc(const Mtx param_0) {}
/* 803170D4-803170D8 311A14 0004+00 1/0 0/0 0/0 .text reset__17J3DLockedMaterialFv */
void J3DLockedMaterial::reset() {}
/* 803170D8-803170DC 311A18 0004+00 1/0 0/0 0/0 .text change__17J3DLockedMaterialFv */
void J3DLockedMaterial::change() {}
-32
View File
@@ -34,7 +34,6 @@ J3DError J3DDisplayListObj::newSingleDisplayList(u32 maxSize) {
return kJ3DError_Success;
}
/* 8031256C-803125E4 30CEAC 0078+00 0/0 1/1 0/0 .text single_To_Double__17J3DDisplayListObjFv */
int J3DDisplayListObj::single_To_Double() {
if (mpDisplayList[0] == mpDisplayList[1]) {
mpDisplayList[1] = new (0x20) char[mMaxSize];
@@ -68,14 +67,10 @@ void J3DDisplayListObj::callDL() const {
GXCallDisplayList(mpDisplayList[0], mSize);
}
/* 80434C70-80434C80 061990 0010+00 2/2 3/3 0/0 .bss sGDLObj__17J3DDisplayListObj */
GDLObj J3DDisplayListObj::sGDLObj;
/* 804515A0-804515A8 000AA0 0004+04 3/3 0/0 0/0 .sbss sInterruptFlag__17J3DDisplayListObj
*/
s32 J3DDisplayListObj::sInterruptFlag;
/* 80312644-80312698 30CF84 0054+00 2/2 1/1 0/0 .text beginDL__17J3DDisplayListObjFv */
void J3DDisplayListObj::beginDL() {
swapBuffer();
sInterruptFlag = OSDisableInterrupts();
@@ -83,7 +78,6 @@ void J3DDisplayListObj::beginDL() {
GDSetCurrent(&sGDLObj);
}
/* 80312698-803126F4 30CFD8 005C+00 1/1 1/1 0/0 .text endDL__17J3DDisplayListObjFv */
u32 J3DDisplayListObj::endDL() {
GDPadCurr32();
OSRestoreInterrupts(sInterruptFlag);
@@ -93,20 +87,16 @@ u32 J3DDisplayListObj::endDL() {
return mSize;
}
/* 803126F4-80312714 30D034 0020+00 0/0 1/1 0/0 .text beginPatch__17J3DDisplayListObjFv
*/
void J3DDisplayListObj::beginPatch() {
beginDL();
}
/* 80312714-80312750 30D054 003C+00 0/0 1/1 0/0 .text endPatch__17J3DDisplayListObjFv */
u32 J3DDisplayListObj::endPatch() {
OSRestoreInterrupts(sInterruptFlag);
GDSetCurrent(NULL);
return mSize;
}
/* 80312750-80312758 30D090 0008+00 3/0 16/0 10/0 .text entry__9J3DPacketFP13J3DDrawBuffer */
int J3DPacket::entry(J3DDrawBuffer* pBuffer) {
J3D_ASSERT_NULLPTR(290, pBuffer != NULL);
return 1;
@@ -123,7 +113,6 @@ void J3DPacket::addChildPacket(J3DPacket* pPacket) {
}
}
/* 803CD900-803CD920 02AA20 0020+00 1/1 0/0 0/0 .data sDifferedRegister */
static u32 sDifferedRegister[8] = {
J3DDiffFlag_AmbColor,
J3DDiffFlag_MatColor,
@@ -135,7 +124,6 @@ static u32 sDifferedRegister[8] = {
J3DDiffFlag_TevStageIndirect,
};
/* 803CD920-803CD940 02AA40 0020+00 1/1 0/0 0/0 .data sSizeOfDiffered */
static s32 sSizeOfDiffered[8] = {
13,
13,
@@ -147,18 +135,14 @@ static s32 sSizeOfDiffered[8] = {
45,
};
/* 80312778-803127B0 30D0B8 0038+00 2/2 0/0 0/0 .text __ct__13J3DDrawPacketFv */
J3DDrawPacket::J3DDrawPacket() {
mFlags = 0;
mpDisplayListObj = NULL;
mpTexMtxObj = NULL;
}
/* 803127B0-8031280C 30D0F0 005C+00 3/2 0/0 0/0 .text __dt__13J3DDrawPacketFv */
J3DDrawPacket::~J3DDrawPacket() {}
/* 8031280C-80312898 30D14C 008C+00 1/1 1/1 0/0 .text newDisplayList__13J3DDrawPacketFUl
*/
J3DError J3DDrawPacket::newDisplayList(u32 size) {
mpDisplayListObj = new J3DDisplayListObj();
@@ -172,7 +156,6 @@ J3DError J3DDrawPacket::newDisplayList(u32 size) {
return kJ3DError_Success;
}
/* 80312898-80312924 30D1D8 008C+00 0/0 1/1 0/0 .text newSingleDisplayList__13J3DDrawPacketFUl */
J3DError J3DDrawPacket::newSingleDisplayList(u32 size) {
mpDisplayListObj = new J3DDisplayListObj();
@@ -190,7 +173,6 @@ void J3DDrawPacket::draw() {
callDL();
}
/* 80312948-803129A4 30D288 005C+00 0/0 1/1 0/0 .text __ct__12J3DMatPacketFv */
J3DMatPacket::J3DMatPacket() {
mpInitShapePacket = NULL;
mpShapePacket = NULL;
@@ -200,7 +182,6 @@ J3DMatPacket::J3DMatPacket() {
mpMaterialAnm = NULL;
}
/* 803129A4-80312A04 30D2E4 0060+00 1/0 1/1 0/0 .text __dt__12J3DMatPacketFv */
J3DMatPacket::~J3DMatPacket() {}
void J3DMatPacket::addShapePacket(J3DShapePacket* pShape) {
@@ -220,13 +201,11 @@ void J3DMatPacket::endDiff() {
mpInitShapePacket->endDL();
}
/* 80312A74-80312A9C 30D3B4 0028+00 0/0 1/1 0/0 .text isSame__12J3DMatPacketCFP12J3DMatPacket */
bool J3DMatPacket::isSame(J3DMatPacket* pOther) const {
J3D_ASSERT_NULLPTR(521, pOther != NULL);
return mDiffFlag == pOther->mDiffFlag && (mDiffFlag >> 31) == 0;
}
/* 80312A9C-80312B20 30D3DC 0084+00 1/0 0/0 0/0 .text draw__12J3DMatPacketFv */
void J3DMatPacket::draw() {
mpMaterial->load();
callDL();
@@ -246,7 +225,6 @@ void J3DMatPacket::draw() {
J3DShape::resetVcdVatCache();
}
/* 80312B20-80312B74 30D460 0054+00 0/0 1/1 0/0 .text __ct__14J3DShapePacketFv */
J3DShapePacket::J3DShapePacket() {
mpShape = NULL;
mpMtxBuffer = NULL;
@@ -255,11 +233,8 @@ J3DShapePacket::J3DShapePacket() {
mpModel = NULL;
}
/* 80312B74-80312BD4 30D4B4 0060+00 1/0 1/1 0/0 .text __dt__14J3DShapePacketFv */
J3DShapePacket::~J3DShapePacket() {}
/* 80312BD4-80312DBC 30D514 01E8+00 1/1 0/0 0/0 .text calcDifferedBufferSize__14J3DShapePacketFUl
*/
u32 J3DShapePacket::calcDifferedBufferSize(u32 diffFlags) {
u32 bufferSize = 0;
@@ -324,8 +299,6 @@ u32 J3DShapePacket::calcDifferedBufferSize(u32 diffFlags) {
return OSRoundUp32B(bufferSize);
}
/* 80312DBC-80312E08 30D6FC 004C+00 0/0 1/1 0/0 .text newDifferedDisplayList__14J3DShapePacketFUl
*/
int J3DShapePacket::newDifferedDisplayList(u32 diffFlags) {
mDiffFlag = diffFlags;
@@ -340,7 +313,6 @@ int J3DShapePacket::newDifferedDisplayList(u32 diffFlags) {
return kJ3DError_Success;
}
/* 80312E08-80312F24 30D748 011C+00 2/2 0/0 0/0 .text prepareDraw__14J3DShapePacketCFv */
void J3DShapePacket::prepareDraw() const {
mpModel->getVertexBuffer()->setArray();
j3dSys.setModel(mpModel);
@@ -375,7 +347,6 @@ void J3DShapePacket::prepareDraw() const {
mpModel->getModelData()->syncJ3DSysFlags();
}
/* 80312F24-80312FBC 30D864 0098+00 1/0 0/0 0/0 .text draw__14J3DShapePacketFv */
void J3DShapePacket::draw() {
if (!checkFlag(J3DShpFlag_Hidden) && mpShape != NULL) {
prepareDraw();
@@ -395,7 +366,6 @@ void J3DShapePacket::draw() {
}
}
/* 80312FBC-80313044 30D8FC 0088+00 1/1 2/2 1/1 .text drawFast__14J3DShapePacketFv */
void J3DShapePacket::drawFast() {
if (!checkFlag(J3DShpFlag_Hidden) && mpShape != NULL) {
prepareDraw();
@@ -411,10 +381,8 @@ void J3DShapePacket::drawFast() {
}
}
/* 80313044-80313048 30D984 0004+00 1/0 0/0 0/0 .text draw__9J3DPacketFv */
void J3DPacket::draw() {}
/* 80313048-803130A8 30D988 0060+00 1/0 0/0 0/0 .text entry__12J3DMatPacketFP13J3DDrawBuffer */
int J3DMatPacket::entry(J3DDrawBuffer* pBuffer) {
J3DDrawBuffer::sortFunc func = J3DDrawBuffer::sortFuncTable[pBuffer->getSortMode()];
return (pBuffer->*func)(this);
-19
View File
@@ -35,7 +35,6 @@ void J3DShape::initialize() {
mHasPNMTXIdx = false;
}
/* 80314BB8-80314CBC 30F4F8 0104+00 0/0 1/1 0/0 .text addTexMtxIndexInDL__8J3DShapeF7_GXAttrUl */
void J3DShape::addTexMtxIndexInDL(GXAttr attr, u32 valueBase) {
u32 kSize[] = {0, 1, 1, 2};
@@ -63,7 +62,6 @@ void J3DShape::addTexMtxIndexInDL(GXAttr attr, u32 valueBase) {
getShapeDraw(i)->addTexMtxIndexInDL(stride, attrOffs, (s32)valueBase);
}
/* 80314CBC-80314DA8 30F5FC 00EC+00 0/0 1/1 0/0 .text addTexMtxIndexInVcd__8J3DShapeF7_GXAttr */
void J3DShape::addTexMtxIndexInVcd(GXAttr attr) {
u32 kSize[] = {0, 1, 1, 2}; // stripped data
@@ -108,14 +106,11 @@ void J3DShape::addTexMtxIndexInVcd(GXAttr attr) {
makeVcdVatCmd();
}
/* 80314DA8-80314E28 30F6E8 0080+00 0/0 1/1 0/0 .text
* calcNBTScale__8J3DShapeFRC3VecPA3_A3_fPA3_A3_f */
void J3DShape::calcNBTScale(const Vec& param_0, f32 (*param_1)[3][3], f32 (*param_2)[3][3]) {
for (u16 i = 0; i < mMtxGroupNum; i++)
mShapeMtx[i]->calcNBTScale(param_0, param_1, param_2);
}
/* 80314E28-80314E98 30F768 0070+00 0/0 1/1 0/0 .text countBumpMtxNum__8J3DShapeCFv */
u16 J3DShape::countBumpMtxNum() const {
u16 num = 0;
for (u16 i = 0; i < mMtxGroupNum; i++)
@@ -124,20 +119,17 @@ u16 J3DShape::countBumpMtxNum() const {
return num;
}
/* 80314E98-80314EB0 30F7D8 0018+00 1/1 0/0 0/0 .text J3DLoadCPCmd__FUcUl */
void J3DLoadCPCmd(u8 addr, u32 val) {
GXCmd1u8(GX_LOAD_CP_REG);
GXCmd1u8(addr);
GXCmd1u32(val);
}
/* 80314EB0-80314EEC 30F7F0 003C+00 1/1 0/0 0/0 .text J3DLoadArrayBasePtr__F7_GXAttrPv */
static void J3DLoadArrayBasePtr(GXAttr attr, void* data) {
u32 idx = (attr == GX_VA_NBT) ? 1 : (attr - GX_VA_POS);
J3DLoadCPCmd(0xA0 + idx, ((uintptr_t)data & 0x7FFFFFFF));
}
/* 80314EEC-80314F5C 30F82C 0070+00 3/3 0/0 0/0 .text loadVtxArray__8J3DShapeCFv */
void J3DShape::loadVtxArray() const {
J3DLoadArrayBasePtr(GX_VA_POS, j3dSys.getVtxPos());
@@ -148,7 +140,6 @@ void J3DShape::loadVtxArray() const {
J3DLoadArrayBasePtr(GX_VA_CLR0, j3dSys.getVtxCol());
}
/* 80314F5C-80314F98 30F89C 003C+00 0/0 1/1 0/0 .text isSameVcdVatCmd__8J3DShapeFP8J3DShape */
bool J3DShape::isSameVcdVatCmd(J3DShape* other) {
u8* a = (u8*)other->getVcdVatCmd();
u8* b = mVcdVatCmd;
@@ -159,7 +150,6 @@ bool J3DShape::isSameVcdVatCmd(J3DShape* other) {
return true;
}
/* 80314F98-80315260 30F8D8 02C8+00 1/1 0/0 0/0 .text makeVtxArrayCmd__8J3DShapeFv */
void J3DShape::makeVtxArrayCmd() {
GXVtxAttrFmtList* vtxAttr = mVertexData->getVtxAttrFmtList();
@@ -237,7 +227,6 @@ void J3DShape::makeVtxArrayCmd() {
}
}
/* 80315260-80315300 30FBA0 00A0+00 1/1 2/2 0/0 .text makeVcdVatCmd__8J3DShapeFv */
void J3DShape::makeVcdVatCmd() {
static BOOL sInterruptFlag = OSDisableInterrupts();
OSDisableScheduler();
@@ -255,14 +244,12 @@ void J3DShape::makeVcdVatCmd() {
OSRestoreInterrupts(sInterruptFlag);
}
/* 804515D0-804515D4 000AD0 0004+00 5/5 25/25 9/9 .sbss sOldVcdVatCmd__8J3DShape */
void* J3DShape::sOldVcdVatCmd;
void J3DShape::loadCurrentMtx() const {
mCurrentMtx.load();
}
/* 80315300-80315398 30FC40 0098+00 2/2 6/6 3/3 .text loadPreDrawSetting__8J3DShapeCFv */
void J3DShape::loadPreDrawSetting() const {
if (sOldVcdVatCmd != mVcdVatCmd) {
GXCallDisplayList(mVcdVatCmd, kVcdVatDLSize);
@@ -272,10 +259,8 @@ void J3DShape::loadPreDrawSetting() const {
mCurrentMtx.load();
}
/* 804515D4-804515D8 000AD4 0004+00 3/3 0/0 0/0 .sbss None */
bool J3DShape::sEnvelopeFlag;
/* 80315398-8031544C 30FCD8 00B4+00 1/1 0/0 0/0 .text setArrayAndBindPipeline__8J3DShapeCFv */
void J3DShape::setArrayAndBindPipeline() const {
J3DShapeMtx::setCurrentPipeline((mFlags & 0x1C) >> 2);
loadVtxArray();
@@ -287,7 +272,6 @@ void J3DShape::setArrayAndBindPipeline() const {
J3DShapeMtx::sTexMtxLoadType = getTexMtxLoadType();
}
/* 8031544C-803155E0 30FD8C 0194+00 1/0 0/0 0/0 .text drawFast__8J3DShapeCFv */
void J3DShape::drawFast() const {
if (sOldVcdVatCmd != mVcdVatCmd) {
GXCallDisplayList(mVcdVatCmd, kVcdVatDLSize);
@@ -317,14 +301,12 @@ void J3DShape::drawFast() const {
}
}
/* 803155E0-80315628 30FF20 0048+00 1/0 0/0 0/0 .text draw__8J3DShapeCFv */
void J3DShape::draw() const {
resetVcdVatCache();
loadPreDrawSetting();
drawFast();
}
/* 80315628-803156AC 30FF68 0084+00 1/0 0/0 0/0 .text simpleDraw__8J3DShapeCFv */
void J3DShape::simpleDraw() const {
resetVcdVatCache();
loadPreDrawSetting();
@@ -337,7 +319,6 @@ void J3DShape::simpleDraw() const {
}
}
/* 803156AC-803157A0 30FFEC 00F4+00 1/0 0/0 0/0 .text simpleDrawCache__8J3DShapeCFv */
void J3DShape::simpleDrawCache() const {
if (sOldVcdVatCmd != mVcdVatCmd) {
GXCallDisplayList(mVcdVatCmd, kVcdVatDLSize);
@@ -6,7 +6,6 @@
#include <stdint.h>
#include <dolphin/gx.h>
/* 80314924-80314974 30F264 0050+00 1/1 0/0 0/0 .text countVertex__12J3DShapeDrawFUl */
u32 J3DShapeDraw::countVertex(u32 stride) {
u32 count = 0;
uintptr_t dlStart = (uintptr_t)getDisplayList();
@@ -23,7 +22,6 @@ u32 J3DShapeDraw::countVertex(u32 stride) {
return count;
}
/* 80314974-80314ABC 30F2B4 0148+00 0/0 1/1 0/0 .text addTexMtxIndexInDL__12J3DShapeDrawFUlUlUl */
// NONMATCHING regalloc
void J3DShapeDraw::addTexMtxIndexInDL(u32 stride, u32 attrOffs, u32 valueBase) {
u32 byteNum = countVertex(stride);
@@ -70,16 +68,13 @@ void J3DShapeDraw::addTexMtxIndexInDL(u32 stride, u32 attrOffs, u32 valueBase) {
DCStoreRange(newDLStart, mDisplayListSize);
}
/* 80314ABC-80314AD4 30F3FC 0018+00 0/0 1/1 0/0 .text __ct__12J3DShapeDrawFPCUcUl */
J3DShapeDraw::J3DShapeDraw(const u8* displayList, u32 displayListSize) {
mDisplayList = (void*)displayList;
mDisplayListSize = displayListSize;
}
/* 80314AD4-80314B00 30F414 002C+00 0/0 3/3 0/0 .text draw__12J3DShapeDrawCFv */
void J3DShapeDraw::draw() const {
GXCallDisplayList(mDisplayList, mDisplayListSize);
}
/* 80314B00-80314B48 30F440 0048+00 1/0 0/0 0/0 .text __dt__12J3DShapeDrawFv */
J3DShapeDraw::~J3DShapeDraw() {}
-44
View File
@@ -6,11 +6,8 @@
#include "JSystem/J3DGraphBase/J3DMatBlock.h"
#include "JSystem/J3DGraphBase/J3DTexture.h"
/* 80434C80-80434C98 0619A0 0014+04 2/2 0/0 0/0 .bss sMtxLoadCache__11J3DShapeMtx */
u16 J3DShapeMtx::sMtxLoadCache[10];
/* 803130A8-803130E4 30D9E8 003C+00 0/0 1/1 0/0 .text resetMtxLoadCache__11J3DShapeMtxFv
*/
void J3DShapeMtx::resetMtxLoadCache() {
sMtxLoadCache[0] =
sMtxLoadCache[1] =
@@ -24,32 +21,27 @@ void J3DShapeMtx::resetMtxLoadCache() {
sMtxLoadCache[9] = 0xFFFF;
}
/* 803130E4-80313128 30DA24 0044+00 1/0 0/0 0/0 .text loadMtxIndx_PNGP__11J3DShapeMtxCFiUs */
void J3DShapeMtx::loadMtxIndx_PNGP(int slot, u16 indx) const {
// J3DFifoLoadPosMtxIndx(indx, slot * 3); // matches debug, but not retail
J3DFifoLoadIndx(GX_LOAD_INDX_A, indx, 0xB000 | ((u16)(slot * 0x0C)));
J3DFifoLoadNrmMtxIndx3x3(indx, slot * 3);
}
/* 80313128-80313188 30DA68 0060+00 1/0 0/0 0/0 .text loadMtxIndx_PCPU__11J3DShapeMtxCFiUs */
void J3DShapeMtx::loadMtxIndx_PCPU(int slot, u16 indx) const {
J3DFifoLoadPosMtxImm(*j3dSys.getShapePacket()->getBaseMtxPtr(), slot * 3);
j3dSys.loadNrmMtxIndx(slot, indx);
}
/* 80313188-803131D4 30DAC8 004C+00 1/0 0/0 0/0 .text loadMtxIndx_NCPU__11J3DShapeMtxCFiUs */
void J3DShapeMtx::loadMtxIndx_NCPU(int slot, u16 indx) const {
j3dSys.loadPosMtxIndx(slot, indx);
J3DFifoLoadNrmMtxImm(*j3dSys.getShapePacket()->getBaseMtxPtr(), slot * 3);
}
/* 803131D4-8031322C 30DB14 0058+00 1/0 0/0 0/0 .text loadMtxIndx_PNCPU__11J3DShapeMtxCFiUs */
void J3DShapeMtx::loadMtxIndx_PNCPU(int slot, u16 indx) const {
J3DFifoLoadPosMtxImm(*j3dSys.getShapePacket()->getBaseMtxPtr(), slot * 3);
J3DFifoLoadNrmMtxImm(*j3dSys.getShapePacket()->getBaseMtxPtr(), slot * 3);
}
/* 803CD9C0-803CD9F0 02AAE0 0030+00 2/3 0/0 0/0 .data sMtxLoadPipeline__11J3DShapeMtx */
J3DShapeMtx_LoadFunc J3DShapeMtx::sMtxLoadPipeline[4] = {
&J3DShapeMtx::loadMtxIndx_PNGP,
&J3DShapeMtx::loadMtxIndx_PCPU,
@@ -57,7 +49,6 @@ J3DShapeMtx_LoadFunc J3DShapeMtx::sMtxLoadPipeline[4] = {
&J3DShapeMtx::loadMtxIndx_PNCPU,
};
/* 803CDA20-803CDA50 02AB40 0030+00 2/3 0/0 0/0 .data sMtxLoadPipeline__21J3DShapeMtxConcatView */
J3DShapeMtxConcatView_LoadFunc J3DShapeMtxConcatView::sMtxLoadPipeline[4] = {
&J3DShapeMtxConcatView::loadMtxConcatView_PNGP,
&J3DShapeMtxConcatView::loadMtxConcatView_PCPU,
@@ -65,8 +56,6 @@ J3DShapeMtxConcatView_LoadFunc J3DShapeMtxConcatView::sMtxLoadPipeline[4] = {
&J3DShapeMtxConcatView::loadMtxConcatView_PNCPU,
};
/* 803CDA80-803CDAB0 02ABA0 0030+00 1/2 0/0 0/0 .data sMtxLoadLODPipeline__21J3DShapeMtxConcatView
*/
J3DShapeMtxConcatView_LoadFunc J3DShapeMtxConcatView::sMtxLoadLODPipeline[4] = {
&J3DShapeMtxConcatView::loadMtxConcatView_PNGP_LOD,
&J3DShapeMtxConcatView::loadMtxConcatView_PCPU,
@@ -74,10 +63,8 @@ J3DShapeMtxConcatView_LoadFunc J3DShapeMtxConcatView::sMtxLoadLODPipeline[4] = {
&J3DShapeMtxConcatView::loadMtxConcatView_PNCPU,
};
/* 804515A8-804515AC 000AA8 0004+00 4/4 2/2 0/0 .sbss sCurrentPipeline__11J3DShapeMtx */
u32 J3DShapeMtx::sCurrentPipeline;
/* 804515AC-804515B0 000AAC 0004+00 3/3 1/1 0/0 .sbss sCurrentScaleFlag__11J3DShapeMtx */
u8* J3DShapeMtx::sCurrentScaleFlag;
// This below is technically part of J3DScaleFlag.
@@ -87,21 +74,14 @@ bool J3DShapeMtx::sNBTFlag;
/* 804515B1 0003+00 data_804515B1 None */
bool J3DShapeMtx::sLODFlag;
/* 804515B4-804515B8 000AB4 0004+00 4/4 1/1 0/0 .sbss sTexMtxLoadType__11J3DShapeMtx */
u32 J3DShapeMtx::sTexMtxLoadType;
/* 804515B8-804515C0 000AB8 0008+00 2/2 0/0 0/0 .sbss sMtxPtrTbl__21J3DShapeMtxConcatView
*/
MtxP J3DShapeMtxConcatView::sMtxPtrTbl[2];
/* 804515C0-804515C4 000AC0 0004+00 6/6 2/2 0/0 .sbss sTexGenBlock__17J3DDifferedTexMtx
*/
J3DTexGenBlock* J3DDifferedTexMtx::sTexGenBlock;
/* 804515C4-804515C8 000AC4 0004+00 1/1 2/2 0/0 .sbss sTexMtxObj__17J3DDifferedTexMtx */
J3DTexMtxObj* J3DDifferedTexMtx::sTexMtxObj;
/* 8031322C-80313828 30DB6C 05FC+00 7/5 0/0 0/0 .text loadExecute__17J3DDifferedTexMtxFPA4_Cf */
void J3DDifferedTexMtx::loadExecute(f32 const (*param_0)[4]) {
static Mtx qMtx = {
{0.5f, 0.0f, 0.5f, 0.0f},
@@ -312,8 +292,6 @@ void J3DDifferedTexMtx::loadExecute(f32 const (*param_0)[4]) {
}
}
/* 80313828-803138C8 30E168 00A0+00 1/0 0/0 0/0 .text
* loadMtxConcatView_PNGP__21J3DShapeMtxConcatViewCFiUs */
void J3DShapeMtxConcatView::loadMtxConcatView_PNGP(int slot, u16 drw) const {
Mtx m;
MTXConcat(*j3dSys.getShapePacket()->getBaseMtxPtr(), j3dSys.getModelDrawMtx(drw), m);
@@ -322,8 +300,6 @@ void J3DShapeMtxConcatView::loadMtxConcatView_PNGP(int slot, u16 drw) const {
loadNrmMtx(slot, drw, m);
}
/* 803138C8-8031396C 30E208 00A4+00 2/0 0/0 0/0 .text
* loadMtxConcatView_PCPU__21J3DShapeMtxConcatViewCFiUs */
void J3DShapeMtxConcatView::loadMtxConcatView_PCPU(int slot, u16 drw) const {
Mtx m;
MTXConcat(*j3dSys.getShapePacket()->getBaseMtxPtr(), j3dSys.getModelDrawMtx(drw), m);
@@ -332,8 +308,6 @@ void J3DShapeMtxConcatView::loadMtxConcatView_PCPU(int slot, u16 drw) const {
loadNrmMtx(slot, drw, m);
}
/* 8031396C-80313A14 30E2AC 00A8+00 2/0 0/0 0/0 .text
* loadMtxConcatView_NCPU__21J3DShapeMtxConcatViewCFiUs */
void J3DShapeMtxConcatView::loadMtxConcatView_NCPU(int slot, u16 drw) const {
Mtx m;
MTXConcat(*j3dSys.getShapePacket()->getBaseMtxPtr(), j3dSys.getModelDrawMtx(drw), m);
@@ -345,8 +319,6 @@ void J3DShapeMtxConcatView::loadMtxConcatView_NCPU(int slot, u16 drw) const {
J3DFifoLoadNrmMtxToTexMtx(*j3dSys.getShapePacket()->getBaseMtxPtr(), slot * 3 + GX_TEXMTX0);
}
/* 80313A14-80313AC8 30E354 00B4+00 2/0 0/0 0/0 .text
* loadMtxConcatView_PNCPU__21J3DShapeMtxConcatViewCFiUs */
void J3DShapeMtxConcatView::loadMtxConcatView_PNCPU(int slot, u16 drw) const {
if (J3DDifferedTexMtx::sTexGenBlock != NULL) {
Mtx m;
@@ -361,8 +333,6 @@ void J3DShapeMtxConcatView::loadMtxConcatView_PNCPU(int slot, u16 drw) const {
J3DFifoLoadNrmMtxToTexMtx(*j3dSys.getShapePacket()->getBaseMtxPtr(), slot * 3 + GX_TEXMTX0);
}
/* 80313AC8-80313B94 30E408 00CC+00 1/0 0/0 0/0 .text
* loadMtxConcatView_PNGP_LOD__21J3DShapeMtxConcatViewCFiUs */
void J3DShapeMtxConcatView::loadMtxConcatView_PNGP_LOD(int slot, u16 drw) const {
Mtx m;
MTXConcat(*j3dSys.getShapePacket()->getBaseMtxPtr(), j3dSys.getModelDrawMtx(drw), m);
@@ -372,20 +342,16 @@ void J3DShapeMtxConcatView::loadMtxConcatView_PNGP_LOD(int slot, u16 drw) const
loadNrmMtx(slot, drw, m);
}
/* 80313B94-80313BF0 30E4D4 005C+00 1/0 0/0 0/0 .text load__11J3DShapeMtxCFv */
void J3DShapeMtx::load() const {
J3DShapeMtx_LoadFunc func = sMtxLoadPipeline[sCurrentPipeline];
(this->*func)(0, mUseMtxIndex);
}
/* 80313BF0-80313C54 30E530 0064+00 5/0 0/0 0/0 .text
* calcNBTScale__11J3DShapeMtxFRC3VecPA3_A3_fPA3_A3_f */
void J3DShapeMtx::calcNBTScale(Vec const& param_0, Mtx33* param_1, Mtx33* param_2) {
J3DPSMtx33Copy(param_1[mUseMtxIndex], param_2[mUseMtxIndex]);
J3DScaleNrmMtx33(param_2[mUseMtxIndex], param_0);
}
/* 80313C54-80313D28 30E594 00D4+00 1/0 0/0 0/0 .text load__21J3DShapeMtxConcatViewCFv */
void J3DShapeMtxConcatView::load() const {
sMtxPtrTbl[0] = j3dSys.getModel()->getMtxBuffer()->getUserAnmMtx(0);
sMtxPtrTbl[1] = j3dSys.getModel()->getWeightAnmMtx(0);
@@ -397,8 +363,6 @@ void J3DShapeMtxConcatView::load() const {
(this->*func)(0, draw_mtx_index);
}
/* 80313D28-80313E4C 30E668 0124+00 3/0 0/0 0/0 .text
* loadNrmMtx__21J3DShapeMtxConcatViewCFiUsPA4_f */
void J3DShapeMtxConcatView::loadNrmMtx(int param_0, u16 param_1, MtxP param_2) const {
if (sCurrentScaleFlag[param_1] == 1) {
if (sTexMtxLoadType == 0x2000) {
@@ -431,7 +395,6 @@ void J3DShapeMtxConcatView::loadNrmMtx(int param_0, u16 param_1, MtxP param_2) c
}
}
/* 80313E4C-80313EEC 30E78C 00A0+00 1/0 0/0 0/0 .text load__16J3DShapeMtxMultiCFv */
void J3DShapeMtxMulti::load() const {
J3DShapeMtx_LoadFunc func = sMtxLoadPipeline[sCurrentPipeline];
@@ -443,8 +406,6 @@ void J3DShapeMtxMulti::load() const {
}
}
/* 80313EEC-80313FA4 30E82C 00B8+00 1/0 0/0 0/0 .text
* calcNBTScale__16J3DShapeMtxMultiFRC3VecPA3_A3_fPA3_A3_f */
void J3DShapeMtxMulti::calcNBTScale(Vec const& param_0, Mtx33* param_1, Mtx33* param_2) {
int use_mtx_num = mUseMtxNum;
for (int i = 0; i < use_mtx_num; i++) {
@@ -455,7 +416,6 @@ void J3DShapeMtxMulti::calcNBTScale(Vec const& param_0, Mtx33* param_1, Mtx33* p
}
}
/* 80313FA4-8031419C 30E8E4 01F8+00 1/0 0/0 0/0 .text load__26J3DShapeMtxMultiConcatViewCFv */
void J3DShapeMtxMultiConcatView::load() const {
sMtxPtrTbl[0] = j3dSys.getModel()->getMtxBuffer()->getUserAnmMtx(0);
sMtxPtrTbl[1] = j3dSys.getModel()->getWeightAnmMtx(0);
@@ -494,8 +454,6 @@ void J3DShapeMtxMultiConcatView::load() const {
}
}
/* 8031419C-803142D4 30EADC 0138+00 1/0 0/0 0/0 .text
* loadNrmMtx__26J3DShapeMtxMultiConcatViewCFiUsPA4_f */
void J3DShapeMtxMultiConcatView::loadNrmMtx(int param_0, u16 param_1, MtxP param_2) const {
Mtx33 mtx1, mtx2;
if (sCurrentScaleFlag[param_1] == 1) {
@@ -525,7 +483,6 @@ void J3DShapeMtxMultiConcatView::loadNrmMtx(int param_0, u16 param_1, MtxP param
}
}
/* 803142D4-803143E4 30EC14 0110+00 1/0 0/0 0/0 .text load__27J3DShapeMtxBBoardConcatViewCFv */
void J3DShapeMtxBBoardConcatView::load() const {
Mtx mtx;
u16 draw_mtx_index = j3dSys.getModel()->getModelData()->getDrawMtxIndex(mUseMtxIndex);
@@ -556,7 +513,6 @@ void J3DShapeMtxBBoardConcatView::load() const {
}
}
/* 803143E4-80314520 30ED24 013C+00 1/0 0/0 0/0 .text load__28J3DShapeMtxYBBoardConcatViewCFv */
void J3DShapeMtxYBBoardConcatView::load() const {
Mtx mtx1;
Mtx33 mtx2;
+2 -10
View File
@@ -7,7 +7,6 @@
#include "JSystem/J3DGraphBase/J3DStruct.h"
#include "JSystem/JMath/JMath.h"
/* 803256C4-80325718 320004 0054+00 0/0 11/11 24/24 .text __as__12J3DLightInfoFRC12J3DLightInfo */
J3DLightInfo& J3DLightInfo::operator=(J3DLightInfo const& param_0) {
JMath::gekko_ps_copy6(&mLightPosition, &param_0.mLightPosition);
mColor = param_0.mColor;
@@ -15,7 +14,6 @@ J3DLightInfo& J3DLightInfo::operator=(J3DLightInfo const& param_0) {
return *this;
}
/* 80325718-80325794 320058 007C+00 0/0 4/4 0/0 .text __as__13J3DTexMtxInfoFRC13J3DTexMtxInfo */
J3DTexMtxInfo& J3DTexMtxInfo::operator=(J3DTexMtxInfo const& param_0) {
mProjection = param_0.mProjection;
mInfo = param_0.mInfo;
@@ -30,9 +28,8 @@ static f32 dummyLiteralOrder() {
return 1.0f;
}
/* 80325794-803257DC 3200D4 0048+00 0/0 2/2 7/7 .text setEffectMtx__13J3DTexMtxInfoFPA4_f
*/
void J3DTexMtxInfo::setEffectMtx(Mtx param_0) {
#ifdef __MWERKS__
JMath::gekko_ps_copy12(&mEffectMtx, param_0);
register f32 zero = 0.0f;
register f32* mtx = (f32*)mEffectMtx;
@@ -41,18 +38,15 @@ void J3DTexMtxInfo::setEffectMtx(Mtx param_0) {
};
mEffectMtx[3][2] = 0.0f;
mEffectMtx[3][3] = 1.0f;
#endif
}
/* 803257DC-80325800 32011C 0024+00 0/0 5/5 0/0 .text
* __as__16J3DIndTexMtxInfoFRC16J3DIndTexMtxInfo */
J3DIndTexMtxInfo& J3DIndTexMtxInfo::operator=(J3DIndTexMtxInfo const& param_0) {
JMath::gekko_ps_copy6(field_0x0, param_0.field_0x0);
field_0x18 = param_0.field_0x18;
return *this;
}
/* 80325800-8032587C 320140 007C+00 0/0 6/6 0/0 .text __as__10J3DFogInfoFRC10J3DFogInfo
*/
J3DFogInfo& J3DFogInfo::operator=(J3DFogInfo const& param_0) {
mType = param_0.mType;
mAdjEnable = param_0.mAdjEnable;
@@ -68,8 +62,6 @@ J3DFogInfo& J3DFogInfo::operator=(J3DFogInfo const& param_0) {
return *this;
}
/* 8032587C-803258A0 3201BC 0024+00 0/0 6/6 0/0 .text __as__15J3DNBTScaleInfoFRC15J3DNBTScaleInfo
*/
J3DNBTScaleInfo& J3DNBTScaleInfo::operator=(J3DNBTScaleInfo const& param_0) {
mbHasScale = param_0.mbHasScale;
mScale = param_0.mScale;
+1 -26
View File
@@ -6,47 +6,35 @@
#include "JSystem/J3DGraphBase/J3DFifo.h"
#include "global.h"
/* 80434AC8-80434BE4 0617E8 011C+00 1/1 151/151 486/486 .bss j3dSys */
J3DSys j3dSys;
/* 80434BE4-80434C14 061904 0030+00 0/0 17/17 154/154 .bss mCurrentMtx__6J3DSys */
Mtx J3DSys::mCurrentMtx;
/* 80434C14-80434C20 061934 000C+00 0/0 6/6 0/0 .bss mCurrentS__6J3DSys */
Vec J3DSys::mCurrentS;
/* 80434C20-80434C2C 061940 000C+00 0/0 5/5 0/0 .bss mParentS__6J3DSys */
Vec J3DSys::mParentS;
/* 80434C2C-80434C70 06194C 0040+04 1/1 17/17 0/0 .bss sTexCoordScaleTable__6J3DSys */
J3DTexCoordScaleInfo J3DSys::sTexCoordScaleTable[8];
/* 803CD8A0-803CD8B0 02A9C0 0010+00 1/1 0/0 0/0 .data NullTexData */
static u8 NullTexData[0x10] ALIGN_DECL(32) = {0};
static u8 NullTexData[0x10] ATTRIBUTE_ALIGN(32) = {0};
/* 803CD8B0-803CD8E0 02A9D0 0030+00 1/1 0/0 0/0 .data j3dIdentityMtx */
static Mtx j3dIdentityMtx = {
1.0f, 0.0f, 0.0f, 0.0f,
0.0f, 1.0f, 0.0f, 0.0f,
0.0f, 0.0f, 1.0f, 0.0f,
};
/* 803CD8E0-803CD8F8 02AA00 0018+00 1/1 0/0 0/0 .data IndMtx */
static Mtx23 IndMtx = {
0.5f, 0.0f, 0.0f,
0.0f, 0.5f, 0.0f,
};
/* 80451598-804515A0 000A98 0004+04 0/0 1/1 0/0 .sbss j3dDefaultViewNo */
u32 j3dDefaultViewNo;
/* 80450950-80450954 0003D0 0004+00 2/2 0/0 0/0 .sdata ColorBlack */
static GXColor ColorBlack = {0x00, 0x00, 0x00, 0x00};
/* 80450954-80450958 0003D4 0004+00 2/2 0/0 0/0 .sdata ColorWhite */
static GXColor ColorWhite = {0xFF, 0xFF, 0xFF, 0xFF};
/* 8030FDE8-8030FEC0 30A728 00D8+00 1/1 0/0 0/0 .text __ct__6J3DSysFv */
J3DSys::J3DSys() {
makeTexCoordTable();
makeTevSwapTable();
@@ -80,19 +68,15 @@ J3DSys::J3DSys() {
}
}
/* 8030FEC0-8030FEE4 30A800 0024+00 0/0 1/1 0/0 .text loadPosMtxIndx__6J3DSysCFiUs */
void J3DSys::loadPosMtxIndx(int addr, u16 indx) const {
// J3DFifoLoadPosMtxIndx(indx, addr * 3); // matches debug, not retail
J3DFifoLoadIndx(GX_LOAD_INDX_A, indx, 0xB000 | ((u16)(addr * 0x0C)));
}
/* 8030FEE4-8030FF0C 30A824 0028+00 0/0 1/1 0/0 .text loadNrmMtxIndx__6J3DSysCFiUs */
void J3DSys::loadNrmMtxIndx(int addr, u16 indx) const {
J3DFifoLoadNrmMtxIndx3x3(indx, addr * 3);
}
/* 8030FF0C-803100BC 30A84C 01B0+00 1/1 0/0 0/0 .text setTexCacheRegion__6J3DSysF15_GXTexCacheSize
*/
void J3DSys::setTexCacheRegion(GXTexCacheSize size) {
J3D_ASSERT_RANGE(173, size >= 0 && size < 3);
@@ -131,7 +115,6 @@ void J3DSys::setTexCacheRegion(GXTexCacheSize size) {
}
}
/* 803100BC-8031073C 30A9FC 0680+00 0/0 3/3 0/0 .text drawInit__6J3DSysFv */
void J3DSys::drawInit() {
GXInvalidateVtxCache();
GXSetCurrentMtx(GX_PNMTX0);
@@ -237,7 +220,6 @@ void J3DSys::drawInit() {
setTexCacheRegion(GX_TEXCACHE_32K);
}
/* 8031073C-8031079C 30B07C 0060+00 0/0 16/16 6/6 .text reinitGX__6J3DSysFv */
void J3DSys::reinitGX() {
reinitGenMode();
reinitLighting();
@@ -249,7 +231,6 @@ void J3DSys::reinitGX() {
GXFlush();
}
/* 8031079C-803107E8 30B0DC 004C+00 1/1 0/0 0/0 .text reinitGenMode__6J3DSysFv */
void J3DSys::reinitGenMode() {
GXSetNumChans(0);
GXSetNumTexGens(1);
@@ -259,7 +240,6 @@ void J3DSys::reinitGenMode() {
GXSetCoPlanar(GX_FALSE);
}
/* 803107E8-80310894 30B128 00AC+00 1/1 0/0 0/0 .text reinitLighting__6J3DSysFv */
void J3DSys::reinitLighting() {
GXSetChanCtrl(GX_COLOR0A0, GX_FALSE, GX_SRC_REG, GX_SRC_VTX, GX_LIGHT_NULL, GX_DF_NONE,
GX_AF_NONE);
@@ -271,7 +251,6 @@ void J3DSys::reinitLighting() {
GXSetChanMatColor(GX_COLOR1A1, ColorWhite);
}
/* 80310894-80310998 30B1D4 0104+00 1/1 0/0 0/0 .text reinitTransform__6J3DSysFv */
void J3DSys::reinitTransform() {
GXSetCurrentMtx(GX_PNMTX0);
GXSetTexCoordGen(GX_TEXCOORD0, GX_TG_MTX2x4, GX_TG_TEX0, GX_IDENTITY);
@@ -284,7 +263,6 @@ void J3DSys::reinitTransform() {
GXSetTexCoordGen(GX_TEXCOORD7, GX_TG_MTX2x4, GX_TG_TEX7, GX_IDENTITY);
}
/* 80310998-80310A3C 30B2D8 00A4+00 2/2 0/0 0/0 .text reinitTexture__6J3DSysFv */
void J3DSys::reinitTexture() {
GXTexObj texObj;
GXInitTexObj(&texObj, NullTexData, 4, 4, GX_TF_IA8, GX_CLAMP, GX_CLAMP, GX_FALSE);
@@ -298,7 +276,6 @@ void J3DSys::reinitTexture() {
GXLoadTexObj(&texObj, GX_TEXMAP7);
}
/* 80310A3C-80310D44 30B37C 0308+00 1/1 0/0 0/0 .text reinitTevStages__6J3DSysFv */
void J3DSys::reinitTevStages() {
GXSetTevOrder(GX_TEVSTAGE0, GX_TEXCOORD_NULL, GX_TEXMAP_NULL, GX_COLOR_NULL);
GXSetTevOrder(GX_TEVSTAGE1, GX_TEXCOORD_NULL, GX_TEXMAP_NULL, GX_COLOR_NULL);
@@ -346,7 +323,6 @@ void J3DSys::reinitTevStages() {
GXSetAlphaCompare(GX_ALWAYS, 0, GX_AOP_AND, GX_ALWAYS, 0);
}
/* 80310D44-80310E3C 30B684 00F8+00 1/1 0/0 0/0 .text reinitIndStages__6J3DSysFv */
void J3DSys::reinitIndStages() {
u32 i;
for (i = 0; i < GX_MAX_TEVSTAGE; i++) {
@@ -366,7 +342,6 @@ void J3DSys::reinitIndStages() {
GXSetIndTexMtx(GX_ITM_2, IndMtx, 1);
}
/* 80310E3C-80310ED0 30B77C 0094+00 1/1 0/0 0/0 .text reinitPixelProc__6J3DSysFv */
void J3DSys::reinitPixelProc() {
GXSetBlendMode(GX_BM_NONE, GX_BL_SRCALPHA, GX_BL_INVSRCALPHA, GX_LO_CLEAR);
GXSetColorUpdate(GX_TRUE);
-49
View File
@@ -14,7 +14,6 @@
static void J3DGDLoadTexMtxImm(f32 (*)[4], u32, GXTexMtxType);
static void J3DGDLoadPostTexMtxImm(f32 (*)[4], u32);
/* 80323590-80323644 31DED0 00B4+00 0/0 3/3 0/0 .text load__11J3DLightObjCFUl */
void J3DLightObj::load(u32 lightIdx) const {
GDOverflowCheck(0x48);
J3DGDSetLightPos(GXLightID(1 << lightIdx), mInfo.mLightPosition.x, mInfo.mLightPosition.y, mInfo.mLightPosition.z);
@@ -23,8 +22,6 @@ void J3DLightObj::load(u32 lightIdx) const {
J3DGDSetLightDir(GXLightID(1 << lightIdx), mInfo.mLightDirection.x, mInfo.mLightDirection.y, mInfo.mLightDirection.z);
}
/* 80323644-803238C4 31DF84 0280+00 0/0 3/3 0/0 .text loadTexCoordGens__FUlP11J3DTexCoord
*/
void loadTexCoordGens(u32 texGenNum, J3DTexCoord* texCoords) {
u32 var_r28;
GDOverflowCheck(texGenNum * 4 * 2 + 10);
@@ -56,7 +53,6 @@ void loadTexCoordGens(u32 texGenNum, J3DTexCoord* texCoords) {
}
}
/* 803238C4-80323900 31E204 003C+00 0/0 6/6 0/0 .text load__9J3DTexMtxCFUl */
void J3DTexMtx::load(u32 mtxIdx) const {
if (j3dSys.checkFlag(J3DSysFlag_PostTexMtx)) {
loadPostTexMtx(mtxIdx);
@@ -65,12 +61,10 @@ void J3DTexMtx::load(u32 mtxIdx) const {
}
}
/* 80323900-80323920 31E240 0020+00 0/0 2/2 0/0 .text calc__9J3DTexMtxFPA4_Cf */
void J3DTexMtx::calc(f32 const (*param_0)[4]) {
calcTexMtx(param_0);
}
/* 80323920-80323C0C 31E260 02EC+00 2/1 0/0 0/0 .text calcTexMtx__9J3DTexMtxFPA4_Cf */
void J3DTexMtx::calcTexMtx(const Mtx param_0) {
Mtx44 mtx1;
Mtx44 mtx2;
@@ -166,8 +160,6 @@ void J3DTexMtx::calcTexMtx(const Mtx param_0) {
}
}
/* 80323C0C-80323F64 31E54C 0358+00 1/0 2/2 0/0 .text calcPostTexMtx__9J3DTexMtxFPA4_Cf
*/
void J3DTexMtx::calcPostTexMtx(const Mtx param_0) {
Mtx44 mtx1;
Mtx44 mtx2;
@@ -275,7 +267,6 @@ void J3DTexMtx::calcPostTexMtx(const Mtx param_0) {
}
}
/* 80323F64-80323F88 31E8A4 0024+00 0/0 1/1 0/0 .text isTexNoReg__FPv */
bool isTexNoReg(void* pDL) {
u8 r31 = ((u8*)pDL)[1];
if (r31 >= 0x80 && r31 <= 0xbb) {
@@ -284,13 +275,11 @@ bool isTexNoReg(void* pDL) {
return false;
}
/* 80323F88-80323F94 31E8C8 000C+00 0/0 1/1 0/0 .text getTexNoReg__FPv */
u16 getTexNoReg(void* pDL) {
u32 var_r31 = *(u32*)((u8*)pDL + 1);
return var_r31 & 0xFFFFFF;
}
/* 80323F94-8032413C 31E8D4 01A8+00 0/0 20/20 0/0 .text loadTexNo__FUlRCUs */
void loadTexNo(u32 param_0, const u16& texNo) {
ResTIMG* resTIMG = j3dSys.getTexture()->getResTIMG(texNo);
J3D_ASSERT_NULLPTR(462, resTIMG != NULL);
@@ -311,7 +300,6 @@ void loadTexNo(u32 param_0, const u16& texNo) {
}
}
/* 8032413C-80324160 31EA7C 0024+00 0/0 2/2 0/0 .text patchTexNo_PtrToIdx__FUlRCUs */
void patchTexNo_PtrToIdx(u32 texID, const u16& idx) {
ResTIMG* timg = j3dSys.getTexture()->getResTIMG(idx);
J3D_ASSERT_NULLPTR(523, timg != NULL);
@@ -319,7 +307,6 @@ void patchTexNo_PtrToIdx(u32 texID, const u16& idx) {
J3DGDSetTexImgPtrRaw(GXTexMapID(texID), idx);
}
/* 80324160-80324194 31EAA0 0034+00 0/0 2/2 0/0 .text loadNBTScale__FR11J3DNBTScale */
void loadNBTScale(J3DNBTScale& NBTScale) {
if (NBTScale.mbHasScale == true) {
j3dSys.setNBTScale(&NBTScale.mScale);
@@ -328,7 +315,6 @@ void loadNBTScale(J3DNBTScale& NBTScale) {
}
}
/* 803A1EC8-803A1EFC 02E528 0034+00 0/0 9/9 24/24 .rodata j3dDefaultLightInfo */
extern const J3DLightInfo j3dDefaultLightInfo = {
0.0f, 0.0f, 0.0f,
0.0f, -1.0f, 0.0f,
@@ -337,7 +323,6 @@ extern const J3DLightInfo j3dDefaultLightInfo = {
1.0f, 0.0f, 0.0f,
};
/* 803A1EFC-803A1F1C 02E55C 0020+00 0/0 5/5 0/0 .rodata j3dDefaultTexCoordInfo */
extern J3DTexCoordInfo const j3dDefaultTexCoordInfo[8] = {
{GX_MTX2x4, GX_TG_TEX0, GX_IDENTITY, 0}, {GX_MTX2x4, GX_TG_TEX1, GX_IDENTITY, 0},
{GX_MTX2x4, GX_TG_TEX2, GX_IDENTITY, 0}, {GX_MTX2x4, GX_TG_TEX3, GX_IDENTITY, 0},
@@ -345,7 +330,6 @@ extern J3DTexCoordInfo const j3dDefaultTexCoordInfo[8] = {
{GX_MTX2x4, GX_TG_TEX6, GX_IDENTITY, 0}, {GX_MTX2x4, GX_TG_TEX7, GX_IDENTITY, 0},
};
/* 803A1F1C-803A1F80 02E57C 0064+00 0/0 1/1 0/0 .rodata j3dDefaultTexMtxInfo */
extern J3DTexMtxInfo const j3dDefaultTexMtxInfo = {
0x01,
0x00,
@@ -357,39 +341,32 @@ extern J3DTexMtxInfo const j3dDefaultTexMtxInfo = {
1.0f},
};
/* 803A1F80-803A1F9C 02E5E0 001C+00 0/0 2/2 0/0 .rodata j3dDefaultIndTexMtxInfo */
extern J3DIndTexMtxInfo const j3dDefaultIndTexMtxInfo = {
0.5f, 0.0f, 0.0f,
0.0f, 0.5f, 0.0f,
1
};
/* 803A1F9C-803A1FB0 02E5FC 0014+00 0/0 1/1 0/0 .rodata j3dDefaultTevStageInfo */
extern J3DTevStageInfo const j3dDefaultTevStageInfo = {
0x04, 0x0A, 0x0F, 0x0F, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00,
0x05, 0x07, 0x07, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00,
};
/* 803A1FB0-803A1FBC 02E610 000C+00 0/0 2/2 0/0 .rodata j3dDefaultIndTevStageInfo */
extern J3DIndTevStageInfo const j3dDefaultIndTevStageInfo = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
/* 803A1FBC-803A1FE8 02E61C 002C+00 0/0 3/3 0/0 .rodata j3dDefaultFogInfo */
extern J3DFogInfo const j3dDefaultFogInfo = {
0x00, 0x00, 0x0140, 0.0f, 0.0f, 0.1f, 10000.0f, 0xFF, 0xFF, 0xFF, 0x00,
0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000,
};
/* 803A1FE8-803A1FF8 02E648 0010+00 0/0 3/3 0/0 .rodata j3dDefaultNBTScaleInfo */
extern J3DNBTScaleInfo const j3dDefaultNBTScaleInfo = {
0x00, 1.0f, 1.0f, 1.0f,
};
/* 80434C98-80436A60 0619B8 1DC7+01 1/1 0/0 0/0 .bss j3dTexCoordTable */
static u8 j3dTexCoordTable[7623];
/* 80324194-8032423C 31EAD4 00A8+00 0/0 1/1 0/0 .text makeTexCoordTable__Fv */
void makeTexCoordTable() {
u8 texMtx[] = {
GX_TEXMTX0,
@@ -418,13 +395,10 @@ void makeTexCoordTable() {
}
}
/* 80436A60-80436E60 063780 0400+00 1/1 3/3 0/0 .bss j3dTevSwapTableTable */
u8 j3dTevSwapTableTable[1024];
/* 80436E60-80437160 063B80 0300+00 1/1 2/2 0/0 .bss j3dAlphaCmpTable */
u8 j3dAlphaCmpTable[768];
/* 8032423C-803242A8 31EB7C 006C+00 0/0 1/1 0/0 .text makeAlphaCmpTable__Fv */
void makeAlphaCmpTable() {
u8* table = j3dAlphaCmpTable;
for (u32 i = 0; i < 8; i++) {
@@ -439,11 +413,9 @@ void makeAlphaCmpTable() {
}
}
/* 80437160-804371C0 063E80 0060+00 1/1 4/4 5/5 .bss j3dZModeTable */
extern u8 j3dZModeTable[96];
u8 j3dZModeTable[96];
/* 803242A8-80324314 31EBE8 006C+00 0/0 1/1 0/0 .text makeZModeTable__Fv */
void makeZModeTable() {
u8* table = j3dZModeTable;
for (int i = 0; i < 2; i++) {
@@ -458,7 +430,6 @@ void makeZModeTable() {
}
}
/* 80324314-80324358 31EC54 0044+00 0/0 1/1 0/0 .text makeTevSwapTable__Fv */
void makeTevSwapTable() {
u8* table = j3dTevSwapTableTable;
int i = 0;
@@ -472,20 +443,16 @@ void makeTevSwapTable() {
} while (i < 256);
}
/* 80324358-803243BC 31EC98 0064+00 1/1 0/0 0/0 .text loadTexMtx__9J3DTexMtxCFUl */
void J3DTexMtx::loadTexMtx(u32 param_0) const {
GDOverflowCheck(0x35);
J3DGDLoadTexMtxImm((MtxP)mMtx, param_0 * 3 + 30, (_GXTexMtxType)mTexMtxInfo.mProjection);
}
/* 803243BC-8032441C 31ECFC 0060+00 1/1 0/0 0/0 .text loadPostTexMtx__9J3DTexMtxCFUl */
void J3DTexMtx::loadPostTexMtx(u32 param_0) const {
GDOverflowCheck(0x35);
J3DGDLoadPostTexMtxImm((MtxP)mMtx, param_0 * 3 + 0x40);
}
/* 8032441C-8032499C 31ED5C 0580+00 1/1 0/0 0/0 .text J3DGDLoadTexMtxImm__FPA4_fUl13_GXTexMtxType
*/
static void J3DGDLoadTexMtxImm(f32 (*param_1)[4], u32 param_2, _GXTexMtxType param_3) {
u16 addr = param_2 << 2;
u8 len = param_3 == GX_MTX2x4 ? 8 : 12;
@@ -506,7 +473,6 @@ static void J3DGDLoadTexMtxImm(f32 (*param_1)[4], u32 param_2, _GXTexMtxType par
}
}
/* 8032499C-80324F08 31F2DC 056C+00 1/1 0/0 0/0 .text J3DGDLoadPostTexMtxImm__FPA4_fUl */
static void J3DGDLoadPostTexMtxImm(f32 (*param_1)[4], u32 param_2) {
u16 addr = (param_2 - 0x40) * 4 + 0x500;
int stride = 12;
@@ -526,25 +492,18 @@ static void J3DGDLoadPostTexMtxImm(f32 (*param_1)[4], u32 param_2) {
J3DGDWrite_f32(param_1[2][3]);
}
/* 804563C0-804563C4 0049C0 0004+00 0/0 4/4 0/0 .sdata2 j3dDefaultColInfo */
extern const GXColor j3dDefaultColInfo = {0xFF, 0xFF, 0xFF, 0xFF};
/* 804563C4-804563C8 0049C4 0004+00 0/0 2/2 0/0 .sdata2 j3dDefaultAmbInfo */
extern const GXColor j3dDefaultAmbInfo = {0x32, 0x32, 0x32, 0x32};
/* 804563C8-804563CC 0049C8 0004+00 0/0 1/1 0/0 .sdata2 None */
extern const u8 j3dDefaultNumChans = 1;
/* 804563CC-804563D0 0049CC 0004+00 0/0 3/3 0/0 .sdata2 j3dDefaultTevOrderInfoNull */
extern const J3DTevOrderInfo j3dDefaultTevOrderInfoNull = {0xFF, 0xFF, 0xFF, 0x00};
/* 804563D0-804563D4 0049D0 0004+00 0/0 2/2 0/0 .sdata2 j3dDefaultIndTexOrderNull */
extern const J3DIndTexOrderInfo j3dDefaultIndTexOrderNull = {0xFF, 0xFF, 0x00, 0x00};
/* 804563D4-804563D8 0049D4 0004+00 0/0 5/5 0/0 .sdata2 j3dDefaultTevColor */
extern const GXColorS10 j3dDefaultTevColor = {0xFF, 0xFF, 0xFF, 0xFF};
/* 804563DC-804563E0 0049DC 0004+00 0/0 2/2 0/0 .sdata2 j3dDefaultIndTexCoordScaleInfo */
extern const J3DIndTexCoordScaleInfo j3dDefaultIndTexCoordScaleInfo = {
0x00,
0x00,
@@ -552,10 +511,8 @@ extern const J3DIndTexCoordScaleInfo j3dDefaultIndTexCoordScaleInfo = {
0x00,
};
/* 804563E0-804563E4 0049E0 0004+00 0/0 5/5 0/0 .sdata2 j3dDefaultTevKColor */
extern const GXColor j3dDefaultTevKColor = {0xFF, 0xFF, 0xFF, 0xFF};
/* 804563E4-804563E8 0049E4 0004+00 0/0 2/2 0/0 .sdata2 j3dDefaultTevSwapMode */
extern J3DTevSwapModeInfo const j3dDefaultTevSwapMode = {
0x00,
0x00,
@@ -563,22 +520,16 @@ extern J3DTevSwapModeInfo const j3dDefaultTevSwapMode = {
0x00,
};
/* 804563E8-804563EC 0049E8 0004+00 0/0 2/2 0/0 .sdata2 j3dDefaultTevSwapModeTable */
extern const J3DTevSwapModeTableInfo j3dDefaultTevSwapModeTable = {0x00, 0x01, 0x02, 0x03};
/* 804563EC-804563F0 0049EC 0004+00 0/0 3/3 0/0 .sdata2 j3dDefaultBlendInfo */
extern const J3DBlendInfo j3dDefaultBlendInfo = {GX_BM_BLEND, GX_BL_SRCALPHA, GX_BL_INVSRCALPHA, GX_LO_NOOP};
/* 804563F0-804563F8 0049F0 0008+00 0/0 3/3 0/0 .sdata2 j3dDefaultColorChanInfo */
extern const J3DColorChanInfo j3dDefaultColorChanInfo = {
0x00, 0x00, 0x00, 0x02, 0x02, 0x00, 0xFF, 0xFF,
};
/* 804563F8-804563FA 0049F8 0002+00 0/0 1/1 0/0 .sdata2 None */
extern const u8 j3dDefaultTevSwapTableID = 0x1B;
/* 804563FA-804563FC 0049FA 0002+00 0/0 1/1 0/0 .sdata2 j3dDefaultAlphaCmpID */
const u16 j3dDefaultAlphaCmpID = 0x00E7;
/* 804563FC-80456400 0049FC 0002+02 0/0 3/3 0/0 .sdata2 j3dDefaultZModeID */
const u16 j3dDefaultZModeID = 0x0017;
-3
View File
@@ -3,7 +3,6 @@
#include "JSystem/J3DGraphBase/J3DTexture.h"
#include "JSystem/J3DAssert.h"
/* 8031204C-803121A4 30C98C 0158+00 0/0 1/1 0/0 .text loadGX__10J3DTextureCFUs11_GXTexMapID */
void J3DTexture::loadGX(u16 idx, GXTexMapID texMapID) const {
J3D_ASSERT_RANGE(29, idx < mNum);
@@ -33,7 +32,6 @@ void J3DTexture::loadGX(u16 idx, GXTexMapID texMapID) const {
GXLoadTexObj(&texObj, texMapID);
}
/* 803121A4-8031221C 30CAE4 0078+00 1/1 0/0 0/0 .text entryNum__10J3DTextureFUs */
void J3DTexture::entryNum(u16 num) {
J3D_ASSERT_NONZEROARG(79, num != 0);
@@ -47,7 +45,6 @@ void J3DTexture::entryNum(u16 num) {
}
}
/* 8031221C-80312488 30CB5C 026C+00 0/0 1/1 0/0 .text addResTIMG__10J3DTextureFUsPC7ResTIMG */
void J3DTexture::addResTIMG(u16 newNum, const ResTIMG* newRes) {
if (newNum == 0)
return;
+2 -26
View File
@@ -5,23 +5,22 @@
#include "JSystem/JMath/JMATrigonometric.h"
#include "JSystem/JMath/JMath.h"
/* 80311630-80311638 -00001 0008+00 0/0 0/0 0/0 .text __MTGQR7__FUl */
void __MTGQR7(register u32 v) {
#ifdef __MWERKS__
// clang-format off
asm {
mtspr GQR7, v
}
// clang-format on
#endif
}
/* 80311638-80311670 30BF78 0038+00 0/0 2/2 0/0 .text J3DGQRSetup7__FUlUlUlUl */
void J3DGQRSetup7(u32 r0, u32 r1, u32 r2, u32 r3) {
u32 v = ((r0 << 8) + r1) << 16;
v |= (r2 << 8) + r3;
__MTGQR7(v);
}
/* 80311670-80311760 30BFB0 00F0+00 0/0 2/2 0/0 .text J3DCalcBBoardMtx__FPA4_f */
// this uses a non-standard sqrtf, not sure why or how its supposed to be setup
#if !PLATFORM_SHIELD
inline f32 J3D_sqrtf(register f32 x) {
@@ -71,18 +70,14 @@ void J3DCalcBBoardMtx(register Mtx mtx) {
mtx[2][2] = z;
}
/* 803A1E30-803A1E50 02E490 0020+00 0/0 1/1 0/0 .rodata j3dDefaultTransformInfo */
extern J3DTransformInfo const j3dDefaultTransformInfo = {
{1.0f, 1.0f, 1.0f}, {0, 0, 0}, {0.0f, 0.0f, 0.0f}};
/* 803A1E50-803A1E5C 02E4B0 000C+00 0/0 1/1 0/0 .rodata j3dDefaultScale */
extern Vec const j3dDefaultScale = {1.0f, 1.0f, 1.0f};
/* 803A1E5C-803A1E8C 02E4BC 0030+00 0/0 8/8 7/7 .rodata j3dDefaultMtx */
extern Mtx const j3dDefaultMtx = {
{1.0f, 0.0f, 0.0f, 0.0f}, {0.0f, 1.0f, 0.0f, 0.0f}, {0.0f, 0.0f, 1.0f, 0.0f}};
/* 80311760-8031189C 30C0A0 013C+00 0/0 2/2 0/0 .text J3DCalcYBBoardMtx__FPA4_f */
void J3DCalcYBBoardMtx(Mtx mtx) {
f32 x = (mtx[0][0] * mtx[0][0]) + (mtx[1][0] * mtx[1][0]) + (mtx[2][0] * mtx[2][0]);
f32 z = (mtx[0][2] * mtx[0][2]) + (mtx[1][2] * mtx[1][2]) + (mtx[2][2] * mtx[2][2]);
@@ -106,7 +101,6 @@ void J3DCalcYBBoardMtx(Mtx mtx) {
mtx[2][2] = vec.z * z;
}
/* 8031189C-80311964 30C1DC 00C8+00 0/0 6/6 0/0 .text J3DPSCalcInverseTranspose__FPA4_fPA3_f */
asm void J3DPSCalcInverseTranspose(register Mtx src, register Mtx33 dst) {
#ifdef __MWERKS__ // clang-format off
psq_l f0, 0(src), 1, 0
@@ -164,8 +158,6 @@ lbl_8005F118:
#endif // clang-format on
}
/* 80311964-80311A24 30C2A4 00C0+00 0/0 2/2 2/2 .text
* J3DGetTranslateRotateMtx__FRC16J3DTransformInfoPA4_f */
void J3DGetTranslateRotateMtx(const J3DTransformInfo& tx, Mtx dst) {
f32 cxsz;
f32 sxcz;
@@ -195,7 +187,6 @@ void J3DGetTranslateRotateMtx(const J3DTransformInfo& tx, Mtx dst) {
dst[2][3] = tx.mTranslate.z;
}
/* 80311A24-80311ACC 30C364 00A8+00 0/0 1/1 0/0 .text J3DGetTranslateRotateMtx__FsssfffPA4_f */
void J3DGetTranslateRotateMtx(s16 rx, s16 ry, s16 rz, f32 tx, f32 ty, f32 tz, Mtx dst) {
f32 cxsz;
f32 sxcz;
@@ -225,8 +216,6 @@ void J3DGetTranslateRotateMtx(s16 rx, s16 ry, s16 rz, f32 tx, f32 ty, f32 tz, Mt
dst[2][3] = tz;
}
/* 80311ACC-80311B80 30C40C 00B4+00 0/0 3/3 0/0 .text
* J3DGetTextureMtx__FRC17J3DTextureSRTInfoRC3VecPA4_f */
void J3DGetTextureMtx(const J3DTextureSRTInfo& srt, const Vec& center, Mtx dst) {
f32 sr = JMASSin(srt.mRotation), cr = JMASCos(srt.mRotation);
@@ -247,8 +236,6 @@ void J3DGetTextureMtx(const J3DTextureSRTInfo& srt, const Vec& center, Mtx dst)
dst[2][2] = 1.0f;
}
/* 80311B80-80311C34 30C4C0 00B4+00 0/0 3/3 0/0 .text
* J3DGetTextureMtxOld__FRC17J3DTextureSRTInfoRC3VecPA4_f */
void J3DGetTextureMtxOld(const J3DTextureSRTInfo& srt, const Vec& center, Mtx dst) {
f32 sr = JMASSin(srt.mRotation), cr = JMASCos(srt.mRotation);
@@ -269,8 +256,6 @@ void J3DGetTextureMtxOld(const J3DTextureSRTInfo& srt, const Vec& center, Mtx ds
dst[2][2] = 1.0f;
}
/* 80311C34-80311CE4 30C574 00B0+00 0/0 3/3 0/0 .text
* J3DGetTextureMtxMaya__FRC17J3DTextureSRTInfoPA4_f */
void J3DGetTextureMtxMaya(const J3DTextureSRTInfo& srt, Mtx dst) {
f32 sr = JMASSin(srt.mRotation), cr = JMASCos(srt.mRotation);
f32 tx = srt.mTranslationX - 0.5f;
@@ -288,8 +273,6 @@ void J3DGetTextureMtxMaya(const J3DTextureSRTInfo& srt, Mtx dst) {
dst[2][2] = 1.0f;
}
/* 80311CE4-80311D94 30C624 00B0+00 0/0 3/3 0/0 .text
* J3DGetTextureMtxMayaOld__FRC17J3DTextureSRTInfoPA4_f */
void J3DGetTextureMtxMayaOld(const J3DTextureSRTInfo& srt, Mtx dst) {
f32 sr = JMASSin(srt.mRotation), cr = JMASCos(srt.mRotation);
f32 tx = srt.mTranslationX - 0.5f;
@@ -307,7 +290,6 @@ void J3DGetTextureMtxMayaOld(const J3DTextureSRTInfo& srt, Mtx dst) {
dst[2][2] = 1.0f;
}
/* 80311D94-80311DF8 30C6D4 0064+00 0/0 2/2 0/0 .text J3DScaleNrmMtx__FPA4_fRC3Vec */
asm void J3DScaleNrmMtx(register Mtx mtx, const register Vec& scl) {
#ifdef __MWERKS__ // clang-format off
nofralloc;
@@ -344,7 +326,6 @@ asm void J3DScaleNrmMtx(register Mtx mtx, const register Vec& scl) {
#endif // clang-format on
}
/* 80311DF8-80311E4C 30C738 0054+00 0/0 5/5 0/0 .text J3DScaleNrmMtx33__FPA3_fRC3Vec */
asm void J3DScaleNrmMtx33(register Mtx33 mtx, const register Vec& scale) {
#ifdef __MWERKS__ // clang-format off
psq_l f0, 0(mtx), 0, 0
@@ -371,8 +352,6 @@ asm void J3DScaleNrmMtx33(register Mtx33 mtx, const register Vec& scale) {
#endif // clang-format on
}
/* 80311E4C-80311F70 30C78C 0124+00 0/0 3/3 0/0 .text J3DMtxProjConcat__FPA4_fPA4_fPA4_f
*/
asm void J3DMtxProjConcat(register Mtx mtx1, register Mtx mtx2, register Mtx dst) {
#ifdef __MWERKS__ // clang-format off
psq_l f2, 0(mtx1), 0, 0
@@ -451,12 +430,10 @@ asm void J3DMtxProjConcat(register Mtx mtx1, register Mtx mtx2, register Mtx dst
#endif // clang-format on
}
/* 80450958-80450960 0003D8 0008+00 1/1 0/0 0/0 .sdata Unit01 */
static f32 Unit01[2] = {
0.0f, 1.0f
};
/* 80311F70-8031204C 30C8B0 00DC+00 0/0 1/1 0/0 .text J3DPSMtxArrayConcat__FPA4_fPA4_fPA4_fUl */
#ifdef __MWERKS__ // clang-format off
asm void J3DPSMtxArrayConcat(register Mtx mA, register Mtx mB, register Mtx mAB, register u32 count) {
#define FP0 fp0
@@ -564,7 +541,6 @@ loop:
}
#endif // clang-format on
/* 803CD8F8-803CD900 02AA18 0008+00 0/0 2/2 0/0 .data PSMulUnit01 */
extern f32 PSMulUnit01[] = {
0.0f,
-1.0f,
-17
View File
@@ -6,7 +6,6 @@
#include "JSystem/JKernel/JKRHeap.h"
#include <string.h>
/* 80310EF8-80310F78 30B838 0080+00 0/0 1/1 0/0 .text __ct__13J3DVertexDataFv */
J3DVertexData::J3DVertexData() {
mVtxNum = 0;
mNrmNum = 0;
@@ -31,8 +30,6 @@ J3DVertexData::J3DVertexData() {
mVtxNrmType = GX_F32;
}
/* 80310F78-80310FD8 30B8B8 0060+00 0/0 1/1 0/0 .text
* setVertexData__15J3DVertexBufferFP13J3DVertexData */
void J3DVertexBuffer::setVertexData(J3DVertexData* pVtxData) {
J3D_ASSERT_NULLPTR(175, pVtxData != NULL);
@@ -52,7 +49,6 @@ void J3DVertexBuffer::setVertexData(J3DVertexData* pVtxData) {
frameInit();
}
/* 80310FD8-80311030 30B918 0058+00 0/0 3/3 0/0 .text init__15J3DVertexBufferFv */
void J3DVertexBuffer::init() {
mVtxData = NULL;
@@ -69,18 +65,14 @@ void J3DVertexBuffer::init() {
frameInit();
}
/* 80311030-8031106C 30B970 003C+00 0/0 1/1 0/0 .text __dt__15J3DVertexBufferFv */
J3DVertexBuffer::~J3DVertexBuffer() {}
/* 8031106C-80311090 30B9AC 0024+00 0/0 1/1 0/0 .text setArray__15J3DVertexBufferCFv */
void J3DVertexBuffer::setArray() const {
j3dSys.setVtxPos(mCurrentVtxPos);
j3dSys.setVtxNrm(mCurrentVtxNrm);
j3dSys.setVtxCol(mCurrentVtxCol);
}
/* 80311090-803111B0 30B9D0 0120+00 1/1 0/0 0/0 .text copyLocalVtxPosArray__15J3DVertexBufferFUl
*/
s32 J3DVertexBuffer::copyLocalVtxPosArray(u32 flag) {
if (flag & 1) {
for (int i = 0; i < 2; i++) {
@@ -109,8 +101,6 @@ s32 J3DVertexBuffer::copyLocalVtxPosArray(u32 flag) {
return kJ3DError_Success;
}
/* 803111B0-803112D0 30BAF0 0120+00 1/1 0/0 0/0 .text copyLocalVtxNrmArray__15J3DVertexBufferFUl
*/
s32 J3DVertexBuffer::copyLocalVtxNrmArray(u32 flag) {
if (flag & 1) {
for (int i = 0; i < 2; i++) {
@@ -139,7 +129,6 @@ s32 J3DVertexBuffer::copyLocalVtxNrmArray(u32 flag) {
return kJ3DError_Success;
}
/* 803112D0-80311478 30BC10 01A8+00 0/0 1/1 0/0 .text copyLocalVtxArray__15J3DVertexBufferFUl */
s32 J3DVertexBuffer::copyLocalVtxArray(u32 flag) {
void* oldPosArray[2];
void* oldNrmArray[2];
@@ -191,8 +180,6 @@ s32 J3DVertexBuffer::copyLocalVtxArray(u32 flag) {
return kJ3DError_Success;
}
/* 80311478-8031152C 30BDB8 00B4+00 0/0 1/1 0/0 .text
* allocTransformedVtxPosArray__15J3DVertexBufferFv */
s32 J3DVertexBuffer::allocTransformedVtxPosArray() {
if (mTransformedVtxPosArray[0] != NULL && mTransformedVtxPosArray[1] != NULL)
return kJ3DError_Success;
@@ -208,8 +195,6 @@ s32 J3DVertexBuffer::allocTransformedVtxPosArray() {
return kJ3DError_Success;
}
/* 8031152C-803115E0 30BE6C 00B4+00 0/0 1/1 0/0 .text
* allocTransformedVtxNrmArray__15J3DVertexBufferFv */
s32 J3DVertexBuffer::allocTransformedVtxNrmArray() {
if (mTransformedVtxNrmArray[0] != NULL && mTransformedVtxNrmArray[1] != NULL)
return kJ3DError_Success;
@@ -225,12 +210,10 @@ s32 J3DVertexBuffer::allocTransformedVtxNrmArray() {
return kJ3DError_Success;
}
/* 803115E0-803115F4 30BF20 0014+00 0/0 1/1 0/0 .text __ct__14J3DDrawMtxDataFv */
J3DDrawMtxData::J3DDrawMtxData() {
mEntryNum = 0;
mDrawMtxFlag = NULL;
mDrawMtxIndex = NULL;
}
/* 803115F4-80311630 30BF34 003C+00 0/0 2/2 0/0 .text __dt__14J3DDrawMtxDataFv */
J3DDrawMtxData::~J3DDrawMtxData() {}
@@ -8,8 +8,6 @@
#include "JSystem/JSupport/JSupport.h"
#include "dolphin/os.h"
/* 80337B40-80338134 332480 05F4+00 0/0 7/7 1/1 .text
* load__20J3DAnmLoaderDataBaseFPCv24J3DAnmLoaderDataBaseFlag */
J3DAnmBase* J3DAnmLoaderDataBase::load(const void* i_data, J3DAnmLoaderDataBaseFlag flag) {
if (!i_data) {
return NULL;
@@ -91,8 +89,6 @@ J3DAnmBase* J3DAnmLoaderDataBase::load(const void* i_data, J3DAnmLoaderDataBaseF
return NULL;
}
/* 80338134-80338468 332A74 0334+00 0/0 1/1 0/0 .text
* setResource__20J3DAnmLoaderDataBaseFP10J3DAnmBasePCv */
void J3DAnmLoaderDataBase::setResource(J3DAnmBase* param_1, const void* param_2) {
const JUTDataFileHeader* header = (const JUTDataFileHeader*)param_2;
if (!header) {
@@ -171,19 +167,14 @@ void J3DAnmLoaderDataBase::setResource(J3DAnmBase* param_1, const void* param_2)
}
}
/* 80338468-80338484 332DA8 001C+00 2/2 0/0 0/0 .text __ct__20J3DAnmFullLoader_v15Fv */
J3DAnmFullLoader_v15::J3DAnmFullLoader_v15() {}
/* 80338484-803384E0 332DC4 005C+00 3/2 0/0 0/0 .text __dt__20J3DAnmFullLoader_v15Fv */
J3DAnmFullLoader_v15::~J3DAnmFullLoader_v15() {}
/* 803384E0-803384FC 332E20 001C+00 2/2 0/0 0/0 .text __ct__19J3DAnmKeyLoader_v15Fv */
J3DAnmKeyLoader_v15::J3DAnmKeyLoader_v15() {}
/* 803384FC-80338558 332E3C 005C+00 3/2 0/0 0/0 .text __dt__19J3DAnmKeyLoader_v15Fv */
J3DAnmKeyLoader_v15::~J3DAnmKeyLoader_v15() {}
/* 80338558-803386A0 332E98 0148+00 2/1 0/0 0/0 .text load__20J3DAnmFullLoader_v15FPCv */
J3DAnmBase* J3DAnmFullLoader_v15::load(const void* param_1) {
const JUTDataFileHeader* header = (const JUTDataFileHeader*)param_1;
const JUTDataBlockHeader* block = &header->mFirstBlock;
@@ -216,8 +207,6 @@ J3DAnmBase* J3DAnmFullLoader_v15::load(const void* param_1) {
return mAnm;
}
/* 803386A0-80338800 332FE0 0160+00 2/1 0/0 0/0 .text
* setResource__20J3DAnmFullLoader_v15FP10J3DAnmBasePCv */
void J3DAnmFullLoader_v15::setResource(J3DAnmBase* param_1, const void* param_2) {
const JUTDataFileHeader* header = (const JUTDataFileHeader*)param_2;
const JUTDataBlockHeader* block = &header->mFirstBlock;
@@ -250,14 +239,10 @@ void J3DAnmFullLoader_v15::setResource(J3DAnmBase* param_1, const void* param_2)
}
}
/* 80338800-80338828 333140 0028+00 1/1 0/0 0/0 .text
* readAnmTransform__20J3DAnmFullLoader_v15FPC23J3DAnmTransformFullData */
void J3DAnmFullLoader_v15::readAnmTransform(const J3DAnmTransformFullData* param_1) {
setAnmTransform((J3DAnmTransformFull*)mAnm, param_1);
}
/* 80338828-803388BC 333168 0094+00 2/2 0/0 0/0 .text
* setAnmTransform__20J3DAnmFullLoader_v15FP19J3DAnmTransformFullPC23J3DAnmTransformFullData */
void J3DAnmFullLoader_v15::setAnmTransform(J3DAnmTransformFull* param_1,
const J3DAnmTransformFullData* param_2) {
param_1->field_0x1e = param_2->field_0xc;
@@ -272,14 +257,10 @@ void J3DAnmFullLoader_v15::setAnmTransform(J3DAnmTransformFull* param_1,
}
/* 803388BC-803388E4 3331FC 0028+00 1/1 0/0 0/0 .text
* readAnmColor__20J3DAnmFullLoader_v15FPC19J3DAnmColorFullData */
void J3DAnmFullLoader_v15::readAnmColor(const J3DAnmColorFullData* param_1) {
setAnmColor((J3DAnmColorFull*)mAnm, param_1);
}
/* 803388E4-803389B0 333224 00CC+00 2/2 0/0 0/0 .text
* setAnmColor__20J3DAnmFullLoader_v15FP15J3DAnmColorFullPC19J3DAnmColorFullData */
void J3DAnmFullLoader_v15::setAnmColor(J3DAnmColorFull* param_1,
const J3DAnmColorFullData* param_2) {
param_1->mFrameMax = param_2->mFrameMax;
@@ -298,14 +279,10 @@ void J3DAnmFullLoader_v15::setAnmColor(J3DAnmColorFull* param_1,
JSUConvertOffsetToPtr<ResNTAB>(param_2, param_2->mNameTabOffset));
}
/* 803389B0-803389D8 3332F0 0028+00 1/1 0/0 0/0 .text
* readAnmTexPattern__20J3DAnmFullLoader_v15FPC24J3DAnmTexPatternFullData */
void J3DAnmFullLoader_v15::readAnmTexPattern(const J3DAnmTexPatternFullData* param_1) {
setAnmTexPattern((J3DAnmTexPattern*)mAnm, param_1);
}
/* 803389D8-80338A7C 333318 00A4+00 2/2 0/0 0/0 .text
* setAnmTexPattern__20J3DAnmFullLoader_v15FP16J3DAnmTexPatternPC24J3DAnmTexPatternFullData */
void J3DAnmFullLoader_v15::setAnmTexPattern(J3DAnmTexPattern* param_1,
const J3DAnmTexPatternFullData* param_2) {
param_1->mFrameMax = param_2->mFrameMax;
@@ -322,14 +299,10 @@ void J3DAnmFullLoader_v15::setAnmTexPattern(J3DAnmTexPattern* param_1,
JSUConvertOffsetToPtr<ResNTAB>(param_2, param_2->mNameTabOffset));
}
/* 80338A7C-80338AA4 3333BC 0028+00 1/1 0/0 0/0 .text
* readAnmVisibility__20J3DAnmFullLoader_v15FPC24J3DAnmVisibilityFullData */
void J3DAnmFullLoader_v15::readAnmVisibility(const J3DAnmVisibilityFullData* param_1) {
setAnmVisibility((J3DAnmVisibilityFull*)mAnm, param_1);
}
/* 80338AA4-80338B20 3333E4 007C+00 2/2 0/0 0/0 .text
* setAnmVisibility__20J3DAnmFullLoader_v15FP20J3DAnmVisibilityFullPC24J3DAnmVisibilityFullData */
void J3DAnmFullLoader_v15::setAnmVisibility(J3DAnmVisibilityFull* param_1,
const J3DAnmVisibilityFullData* param_2) {
param_1->mFrameMax = param_2->mFrameMax;
@@ -342,14 +315,10 @@ void J3DAnmFullLoader_v15::setAnmVisibility(J3DAnmVisibilityFull* param_1,
param_1->mVisibility = JSUConvertOffsetToPtr<u8>(param_2, param_2->mValuesOffset);
}
/* 80338B20-80338B48 333460 0028+00 1/1 0/0 0/0 .text
* readAnmCluster__20J3DAnmFullLoader_v15FPC21J3DAnmClusterFullData */
void J3DAnmFullLoader_v15::readAnmCluster(const J3DAnmClusterFullData* param_1) {
setAnmCluster((J3DAnmClusterFull*)mAnm, param_1);
}
/* 80338B48-80338BB4 333488 006C+00 2/2 0/0 0/0 .text
* setAnmCluster__20J3DAnmFullLoader_v15FP17J3DAnmClusterFullPC21J3DAnmClusterFullData */
void J3DAnmFullLoader_v15::setAnmCluster(J3DAnmClusterFull* param_1,
const J3DAnmClusterFullData* param_2) {
param_1->mFrameMax = param_2->mFrameMax;
@@ -360,14 +329,10 @@ void J3DAnmFullLoader_v15::setAnmCluster(J3DAnmClusterFull* param_1,
param_1->mWeight = JSUConvertOffsetToPtr<f32>(param_2, param_2->mWeightOffset);
}
/* 80338BB4-80338BDC 3334F4 0028+00 1/1 0/0 0/0 .text
* readAnmVtxColor__20J3DAnmFullLoader_v15FPC22J3DAnmVtxColorFullData */
void J3DAnmFullLoader_v15::readAnmVtxColor(const J3DAnmVtxColorFullData* param_1) {
setAnmVtxColor((J3DAnmVtxColorFull*)mAnm, param_1);
}
/* 80338BDC-80338D44 33351C 0168+00 2/2 0/0 0/0 .text
* setAnmVtxColor__20J3DAnmFullLoader_v15FP18J3DAnmVtxColorFullPC22J3DAnmVtxColorFullData */
void J3DAnmFullLoader_v15::setAnmVtxColor(J3DAnmVtxColorFull* dst,
const J3DAnmVtxColorFullData* data) {
dst->mFrameMax = data->mFrameMax;
@@ -401,7 +366,6 @@ void J3DAnmFullLoader_v15::setAnmVtxColor(J3DAnmVtxColorFull* dst,
dst->mColorA = JSUConvertOffsetToPtr<u8>(data, data->mAValuesOffset);
}
/* 80338D44-80338E8C 333684 0148+00 2/1 0/0 0/0 .text load__19J3DAnmKeyLoader_v15FPCv */
J3DAnmBase* J3DAnmKeyLoader_v15::load(const void* param_1) {
const JUTDataFileHeader* header = (const JUTDataFileHeader*)param_1;
const JUTDataBlockHeader* block = &header->mFirstBlock;
@@ -434,8 +398,6 @@ J3DAnmBase* J3DAnmKeyLoader_v15::load(const void* param_1) {
return mAnm;
}
/* 80338E8C-80338FEC 3337CC 0160+00 2/1 0/0 0/0 .text
* setResource__19J3DAnmKeyLoader_v15FP10J3DAnmBasePCv */
void J3DAnmKeyLoader_v15::setResource(J3DAnmBase* param_1, const void* param_2) {
const JUTDataFileHeader* header = (const JUTDataFileHeader*)param_2;
const JUTDataBlockHeader* block = &header->mFirstBlock;
@@ -467,14 +429,10 @@ void J3DAnmKeyLoader_v15::setResource(J3DAnmBase* param_1, const void* param_2)
}
}
/* 80338FEC-80339014 33392C 0028+00 1/1 0/0 0/0 .text
* readAnmTransform__19J3DAnmKeyLoader_v15FPC22J3DAnmTransformKeyData */
void J3DAnmKeyLoader_v15::readAnmTransform(const J3DAnmTransformKeyData* param_1) {
setAnmTransform((J3DAnmTransformKey*)mAnm, param_1);
}
/* 80339014-803390B0 333954 009C+00 2/2 0/0 0/0 .text
* setAnmTransform__19J3DAnmKeyLoader_v15FP18J3DAnmTransformKeyPC22J3DAnmTransformKeyData */
void J3DAnmKeyLoader_v15::setAnmTransform(J3DAnmTransformKey* param_1,
const J3DAnmTransformKeyData* param_2) {
param_1->field_0x1e = param_2->field_0xc;
@@ -490,14 +448,10 @@ void J3DAnmKeyLoader_v15::setAnmTransform(J3DAnmTransformKey* param_1,
}
/* 803390B0-803390D8 3339F0 0028+00 1/1 0/0 0/0 .text
* readAnmTextureSRT__19J3DAnmKeyLoader_v15FPC23J3DAnmTextureSRTKeyData */
void J3DAnmKeyLoader_v15::readAnmTextureSRT(const J3DAnmTextureSRTKeyData* param_1) {
setAnmTextureSRT((J3DAnmTextureSRTKey*)mAnm, param_1);
}
/* 803390D8-803392B0 333A18 01D8+00 2/2 0/0 0/0 .text
* setAnmTextureSRT__19J3DAnmKeyLoader_v15FP19J3DAnmTextureSRTKeyPC23J3DAnmTextureSRTKeyData */
void J3DAnmKeyLoader_v15::setAnmTextureSRT(J3DAnmTextureSRTKey* param_1,
const J3DAnmTextureSRTKeyData* param_2) {
param_1->mTrackNum = param_2->field_0xc;
@@ -549,14 +503,10 @@ void J3DAnmKeyLoader_v15::setAnmTextureSRT(J3DAnmTextureSRTKey* param_1,
}
/* 803392B0-803392D8 333BF0 0028+00 1/1 0/0 0/0 .text
* readAnmColor__19J3DAnmKeyLoader_v15FPC18J3DAnmColorKeyData */
void J3DAnmKeyLoader_v15::readAnmColor(const J3DAnmColorKeyData* param_1) {
setAnmColor((J3DAnmColorKey*)mAnm, param_1);
}
/* 803392D8-803393C4 333C18 00EC+00 2/2 0/0 0/0 .text
* setAnmColor__19J3DAnmKeyLoader_v15FP14J3DAnmColorKeyPC18J3DAnmColorKeyData */
void J3DAnmKeyLoader_v15::setAnmColor(J3DAnmColorKey* param_1, const J3DAnmColorKeyData* param_2) {
param_1->mFrameMax = param_2->mFrameMax;
param_1->mAttribute = param_2->field_0x8;
@@ -579,14 +529,10 @@ void J3DAnmKeyLoader_v15::setAnmColor(J3DAnmColorKey* param_1, const J3DAnmColor
}
/* 803393C4-803393EC 333D04 0028+00 1/1 0/0 0/0 .text
* readAnmCluster__19J3DAnmKeyLoader_v15FPC20J3DAnmClusterKeyData */
void J3DAnmKeyLoader_v15::readAnmCluster(const J3DAnmClusterKeyData* param_1) {
setAnmCluster((J3DAnmClusterKey*)mAnm, param_1);
}
/* 803393EC-80339458 333D2C 006C+00 2/2 0/0 0/0 .text
* setAnmCluster__19J3DAnmKeyLoader_v15FP16J3DAnmClusterKeyPC20J3DAnmClusterKeyData */
void J3DAnmKeyLoader_v15::setAnmCluster(J3DAnmClusterKey* param_1,
const J3DAnmClusterKeyData* param_2) {
param_1->mFrameMax = param_2->mFrameMax;
@@ -598,14 +544,10 @@ void J3DAnmKeyLoader_v15::setAnmCluster(J3DAnmClusterKey* param_1,
}
/* 80339458-80339480 333D98 0028+00 1/1 0/0 0/0 .text
* readAnmTevReg__19J3DAnmKeyLoader_v15FPC19J3DAnmTevRegKeyData */
void J3DAnmKeyLoader_v15::readAnmTevReg(const J3DAnmTevRegKeyData* param_1) {
setAnmTevReg((J3DAnmTevRegKey*)mAnm, param_1);
}
/* 80339480-8033960C 333DC0 018C+00 2/2 0/0 0/0 .text
* setAnmTevReg__19J3DAnmKeyLoader_v15FP15J3DAnmTevRegKeyPC19J3DAnmTevRegKeyData */
void J3DAnmKeyLoader_v15::setAnmTevReg(J3DAnmTevRegKey* param_1,
const J3DAnmTevRegKeyData* param_2) {
param_1->mFrameMax = param_2->mFrameMax;
@@ -644,14 +586,10 @@ void J3DAnmKeyLoader_v15::setAnmTevReg(J3DAnmTevRegKey* param_1,
}
/* 8033960C-80339634 333F4C 0028+00 1/1 0/0 0/0 .text
* readAnmVtxColor__19J3DAnmKeyLoader_v15FPC21J3DAnmVtxColorKeyData */
void J3DAnmKeyLoader_v15::readAnmVtxColor(const J3DAnmVtxColorKeyData* param_1) {
setAnmVtxColor((J3DAnmVtxColorKey*)mAnm, param_1);
}
/* 80339634-8033979C 333F74 0168+00 2/2 0/0 0/0 .text
* setAnmVtxColor__19J3DAnmKeyLoader_v15FP17J3DAnmVtxColorKeyPC21J3DAnmVtxColorKeyData */
void J3DAnmKeyLoader_v15::setAnmVtxColor(J3DAnmVtxColorKey* dst,
const J3DAnmVtxColorKeyData* data) {
dst->mFrameMax = data->mFrameMax;
@@ -11,7 +11,6 @@
#include "dolphin/os.h"
#include "string.h"
/* 80334130-803341CC 32EA70 009C+00 0/0 1/1 0/0 .text load__24J3DClusterLoaderDataBaseFPCv */
void* J3DClusterLoaderDataBase::load(const void* i_data) {
const JUTDataFileHeader* fileHeader = (JUTDataFileHeader*)i_data;
if (fileHeader->mMagic == 'J3D1' && fileHeader->mType == 'bls1') {
@@ -23,13 +22,10 @@ void* J3DClusterLoaderDataBase::load(const void* i_data) {
return NULL;
}
/* 803341CC-803341E8 32EB0C 001C+00 1/1 0/0 0/0 .text __ct__20J3DClusterLoader_v15Fv */
J3DClusterLoader_v15::J3DClusterLoader_v15() {}
/* 803341E8-80334244 32EB28 005C+00 2/1 0/0 0/0 .text __dt__20J3DClusterLoader_v15Fv */
J3DClusterLoader_v15::~J3DClusterLoader_v15() {}
/* 80334244-803342F8 32EB84 00B4+00 2/1 0/0 0/0 .text load__20J3DClusterLoader_v15FPCv */
void* J3DClusterLoader_v15::load(const void* i_data) {
mpDeformData = new J3DDeformData();
@@ -50,8 +46,6 @@ void* J3DClusterLoader_v15::load(const void* i_data) {
return mpDeformData;
}
/* 803342F8-803345FC 32EC38 0304+00 1/1 0/0 0/0 .text
* readCluster__20J3DClusterLoader_v15FPC15J3DClusterBlock */
void J3DClusterLoader_v15::readCluster(const J3DClusterBlock* block) {
mpDeformData->mClusterNum = block->mClusterNum;
mpDeformData->mClusterKeyNum = block->mClusterKeyNum;
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J3DJointFactory
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J3DGraphLoader/J3DJointFactory.h"
@@ -10,13 +5,11 @@
#include "JSystem/J3DGraphAnimator/J3DJoint.h"
#include "JSystem/JSupport/JSupport.h"
/* 80337178-803371D0 331AB8 0058+00 0/0 1/1 0/0 .text __ct__15J3DJointFactoryFRC13J3DJointBlock */
J3DJointFactory::J3DJointFactory(J3DJointBlock const& block) {
mJointInitData = JSUConvertOffsetToPtr<J3DJointInitData>(&block, (uintptr_t)block.mpJointInitData);
mIndexTable = JSUConvertOffsetToPtr<u16>(&block, (uintptr_t)block.mpIndexTable);
}
/* 803371D0-80337338 331B10 0168+00 0/0 1/1 0/0 .text create__15J3DJointFactoryFi */
J3DJoint* J3DJointFactory::create(int no) {
J3DJoint* joint = new J3DJoint();
joint->mJntNo = no;
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J3DMaterialFactory
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J3DGraphLoader/J3DMaterialFactory.h"
@@ -10,10 +5,7 @@
#include "JSystem/JMath/JMath.h"
#include "JSystem/JSupport/JSupport.h"
#include "JSystem/JUtility/JUTAssert.h"
#include "dol2asm.h"
/* 8032FFEC-80330234 32A92C 0248+00 0/0 7/7 0/0 .text
* __ct__18J3DMaterialFactoryFRC16J3DMaterialBlock */
J3DMaterialFactory::J3DMaterialFactory(J3DMaterialBlock const& i_block) {
mMaterialNum = i_block.mMaterialNum;
mpMaterialInitData = JSUConvertOffsetToPtr<J3DMaterialInitData>(&i_block, i_block.mpMaterialInitData);
@@ -55,8 +47,6 @@ J3DMaterialFactory::J3DMaterialFactory(J3DMaterialBlock const& i_block) {
mpMaterialMode = NULL;
}
/* 80330234-803302BC 32AB74 0088+00 0/0 2/2 0/0 .text
* __ct__18J3DMaterialFactoryFRC18J3DMaterialDLBlock */
J3DMaterialFactory::J3DMaterialFactory(J3DMaterialDLBlock const& i_block) {
mMaterialNum = i_block.mMaterialNum;
mpMaterialInitData = NULL;
@@ -66,8 +56,6 @@ J3DMaterialFactory::J3DMaterialFactory(J3DMaterialDLBlock const& i_block) {
mpMaterialMode = JSUConvertOffsetToPtr<u8>(&i_block, i_block.mpMaterialMode);
}
/* 803302BC-80330304 32ABFC 0048+00 0/0 3/3 0/0 .text countUniqueMaterials__18J3DMaterialFactoryFv
*/
u16 J3DMaterialFactory::countUniqueMaterials() {
u16 count = 0;
s32 id = -1;
@@ -80,7 +68,6 @@ u16 J3DMaterialFactory::countUniqueMaterials() {
return count;
}
/* 80330304-8033033C 32AC44 0038+00 4/4 0/0 0/0 .text countTexGens__18J3DMaterialFactoryCFi */
u32 J3DMaterialFactory::countTexGens(int i_idx) const {
u8 tex_gen_num_index = mpMaterialInitData[mpMaterialID[i_idx]].mTexGenNumIdx;
if (tex_gen_num_index != 0xff) {
@@ -89,7 +76,6 @@ u32 J3DMaterialFactory::countTexGens(int i_idx) const {
return 0;
}
/* 8033033C-803303C4 32AC7C 0088+00 2/2 0/0 0/0 .text countStages__18J3DMaterialFactoryCFi */
u32 J3DMaterialFactory::countStages(int i_idx) const {
J3DMaterialInitData* init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
u32 count1 = 0;
@@ -113,8 +99,6 @@ u32 J3DMaterialFactory::countStages(int i_idx) const {
return count2;
}
/* 803303C4-80330440 32AD04 007C+00 0/0 4/4 0/0 .text
* create__18J3DMaterialFactoryCFP11J3DMaterialQ218J3DMaterialFactory12MaterialTypeiUl */
J3DMaterial* J3DMaterialFactory::create(J3DMaterial* i_material, MaterialType i_type,
int i_idx, u32 i_flags) const {
switch (i_type) {
@@ -131,8 +115,6 @@ J3DMaterial* J3DMaterialFactory::create(J3DMaterial* i_material, MaterialType i_
return i_material;
}
/* 80330440-80330D84 32AD80 0944+00 1/1 0/0 0/0 .text
* createNormalMaterial__18J3DMaterialFactoryCFP11J3DMaterialiUl */
J3DMaterial* J3DMaterialFactory::createNormalMaterial(J3DMaterial* i_material, int i_idx,
u32 i_flags) const {
if (mpDisplayListInit != NULL) {
@@ -246,8 +228,6 @@ J3DMaterial* J3DMaterialFactory::createNormalMaterial(J3DMaterial* i_material, i
return i_material;
}
/* 80330D84-8033168C 32B6C4 0908+00 1/1 0/0 0/0 .text
* createPatchedMaterial__18J3DMaterialFactoryCFP11J3DMaterialiUl */
J3DMaterial* J3DMaterialFactory::createPatchedMaterial(J3DMaterial* i_material, int i_idx,
u32 i_flags) const {
if (i_material == NULL) {
@@ -339,8 +319,6 @@ J3DMaterial* J3DMaterialFactory::createPatchedMaterial(J3DMaterial* i_material,
return i_material;
}
/* 8033168C-803317D4 32BFCC 0148+00 0/0 1/1 0/0 .text
* modifyPatchedCurrentMtx__18J3DMaterialFactoryCFP11J3DMateriali */
void J3DMaterialFactory::modifyPatchedCurrentMtx(J3DMaterial* i_material, int i_idx) const {
J3DTexCoord coord[8];
u32 tex_gens = countTexGens(i_idx);
@@ -361,8 +339,6 @@ void J3DMaterialFactory::modifyPatchedCurrentMtx(J3DMaterial* i_material, int i_
i_material->mCurrentMtx = currentMtx;
}
/* 803317D4-80331A7C 32C114 02A8+00 2/2 0/0 0/0 .text
* createLockedMaterial__18J3DMaterialFactoryCFP11J3DMaterialiUl */
J3DMaterial* J3DMaterialFactory::createLockedMaterial(J3DMaterial* i_material, int i_idx,
u32 i_flags) const {
if (i_material == NULL) {
@@ -393,8 +369,6 @@ J3DMaterial* J3DMaterialFactory::createLockedMaterial(J3DMaterial* i_material, i
return i_material;
}
/* 80331A7C-80331AFC 32C3BC 0080+00 0/0 4/4 0/0 .text
* calcSize__18J3DMaterialFactoryCFP11J3DMaterialQ218J3DMaterialFactory12MaterialTypeiUl */
u32 J3DMaterialFactory::calcSize(J3DMaterial* i_material, J3DMaterialFactory::MaterialType i_type,
int i_idx, u32 i_flags) const {
u32 size = 0;
@@ -412,8 +386,6 @@ u32 J3DMaterialFactory::calcSize(J3DMaterial* i_material, J3DMaterialFactory::Ma
return size;
}
/* 80331AFC-80331C30 32C43C 0134+00 1/1 0/0 0/0 .text
* calcSizeNormalMaterial__18J3DMaterialFactoryCFP11J3DMaterialiUl */
u32 J3DMaterialFactory::calcSizeNormalMaterial(J3DMaterial* i_material, int i_idx,
u32 i_flags) const {
u32 size = 0;
@@ -447,8 +419,6 @@ u32 J3DMaterialFactory::calcSizeNormalMaterial(J3DMaterial* i_material, int i_id
return size;
}
/* 80331C30-80331D00 32C570 00D0+00 1/1 0/0 0/0 .text
* calcSizePatchedMaterial__18J3DMaterialFactoryCFP11J3DMaterialiUl */
u32 J3DMaterialFactory::calcSizePatchedMaterial(J3DMaterial* i_material, int i_idx,
u32 i_flags) const {
u32 size = 0;
@@ -469,8 +439,6 @@ u32 J3DMaterialFactory::calcSizePatchedMaterial(J3DMaterial* i_material, int i_i
return size;
}
/* 80331D00-80331D18 32C640 0018+00 2/2 0/0 0/0 .text
* calcSizeLockedMaterial__18J3DMaterialFactoryCFP11J3DMaterialiUl */
u32 J3DMaterialFactory::calcSizeLockedMaterial(J3DMaterial* i_material, int i_idx,
u32 i_flags) const {
u32 size = 0;
@@ -481,10 +449,8 @@ u32 J3DMaterialFactory::calcSizeLockedMaterial(J3DMaterial* i_material, int i_id
return size + sizeof(J3DDisplayListObj);
}
/* 804564A8-804564AC 004AA8 0004+00 1/1 0/0 0/0 .sdata2 @1691 */
static GXColor const defaultMatColor = {0xff, 0xff, 0xff, 0xff};
/* 80331D18-80331D74 32C658 005C+00 2/2 0/0 0/0 .text newMatColor__18J3DMaterialFactoryCFii */
J3DGXColor J3DMaterialFactory::newMatColor(int i_idx, int i_no) const {
J3DGXColor dflt = (J3DGXColor)defaultMatColor;
u16 mat_color_index = mpMaterialInitData[mpMaterialID[i_idx]].mMatColorIdx[i_no];
@@ -495,7 +461,6 @@ J3DGXColor J3DMaterialFactory::newMatColor(int i_idx, int i_no) const {
}
}
/* 80331D74-80331DAC 32C6B4 0038+00 2/2 0/0 0/0 .text newColorChanNum__18J3DMaterialFactoryCFi */
u8 J3DMaterialFactory::newColorChanNum(int i_idx) const {
u8 color_chan_num_index = mpMaterialInitData[mpMaterialID[i_idx]].mColorChanNumIdx;
if (color_chan_num_index != 0xff) {
@@ -505,7 +470,6 @@ u8 J3DMaterialFactory::newColorChanNum(int i_idx) const {
}
}
/* 80331DAC-80331F50 32C6EC 01A4+00 2/2 0/0 0/0 .text newColorChan__18J3DMaterialFactoryCFii */
J3DColorChan J3DMaterialFactory::newColorChan(int i_idx, int i_no) const {
u32 r29 = 0;
J3DMaterialInitData* init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
@@ -516,10 +480,8 @@ J3DColorChan J3DMaterialFactory::newColorChan(int i_idx, int i_no) const {
}
}
/* 804564AC-804564B0 004AAC 0004+00 1/1 0/0 0/0 .sdata2 @1798 */
static GXColor const defaultAmbColor = {0x32, 0x32, 0x32, 0x32};
/* 80331F50-80331FAC 32C890 005C+00 1/1 0/0 0/0 .text newAmbColor__18J3DMaterialFactoryCFii */
J3DGXColor J3DMaterialFactory::newAmbColor(int i_idx, int i_no) const {
J3DGXColor dflt = (J3DGXColor)defaultAmbColor;
u16 amb_color_index = mpMaterialInitData[mpMaterialID[i_idx]].mAmbColorIdx[i_no];
@@ -530,7 +492,6 @@ J3DGXColor J3DMaterialFactory::newAmbColor(int i_idx, int i_no) const {
}
}
/* 80331FAC-80331FE4 32C8EC 0038+00 2/2 0/0 0/0 .text newTexGenNum__18J3DMaterialFactoryCFi */
u32 J3DMaterialFactory::newTexGenNum(int i_idx) const {
u8 tex_gen_num_index = mpMaterialInitData[mpMaterialID[i_idx]].mTexGenNumIdx;
if (tex_gen_num_index != 0xff) {
@@ -540,7 +501,6 @@ u32 J3DMaterialFactory::newTexGenNum(int i_idx) const {
}
}
/* 80331FE4-80332044 32C924 0060+00 3/3 0/0 0/0 .text newTexCoord__18J3DMaterialFactoryCFii */
J3DTexCoord J3DMaterialFactory::newTexCoord(int i_idx, int i_no) const {
u16 tex_coord_index = mpMaterialInitData[mpMaterialID[i_idx]].mTexCoordIdx[i_no];
if (tex_coord_index != 0xffff) {
@@ -550,8 +510,6 @@ J3DTexCoord J3DMaterialFactory::newTexCoord(int i_idx, int i_no) const {
}
}
/* 80332044-803320CC 32C984 0088+00 2/2 0/0 0/0 .text newTexMtx__18J3DMaterialFactoryCFii
*/
J3DTexMtx* J3DMaterialFactory::newTexMtx(int i_idx, int i_no) const {
J3DTexMtx* tex_mtx = NULL;
J3DMaterialInitData* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
@@ -561,7 +519,6 @@ J3DTexMtx* J3DMaterialFactory::newTexMtx(int i_idx, int i_no) const {
return tex_mtx;
}
/* 803320CC-8033210C 32CA0C 0040+00 2/2 0/0 0/0 .text newCullMode__18J3DMaterialFactoryCFi */
u8 J3DMaterialFactory::newCullMode(int i_idx) const {
u8 cull_mode_index = mpMaterialInitData[mpMaterialID[i_idx]].mCullModeIdx;
if (cull_mode_index != 0xff) {
@@ -571,8 +528,6 @@ u8 J3DMaterialFactory::newCullMode(int i_idx) const {
}
}
/* 8033210C-80332154 32CA4C 0048+00 2/2 0/0 0/0 .text newTexNo__18J3DMaterialFactoryCFii
*/
u16 J3DMaterialFactory::newTexNo(int i_idx, int i_no) const {
u16 tex_no_index = mpMaterialInitData[mpMaterialID[i_idx]].mTexNoIdx[i_no];
if (tex_no_index != 0xffff) {
@@ -582,7 +537,6 @@ u16 J3DMaterialFactory::newTexNo(int i_idx, int i_no) const {
}
}
/* 80332154-803321A0 32CA94 004C+00 2/2 0/0 0/0 .text newTevOrder__18J3DMaterialFactoryCFii */
J3DTevOrder J3DMaterialFactory::newTevOrder(int i_idx, int i_no) const {
J3DMaterialInitData* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mTevOrderIdx[i_no] != 0xffff) {
@@ -592,7 +546,6 @@ J3DTevOrder J3DMaterialFactory::newTevOrder(int i_idx, int i_no) const {
}
}
/* 803321A0-80332210 32CAE0 0070+00 2/2 0/0 0/0 .text newTevColor__18J3DMaterialFactoryCFii */
J3DGXColorS10 J3DMaterialFactory::newTevColor(int i_idx, int i_no) const {
J3DGXColorS10 dflt = (GXColorS10){0, 0, 0, 0};
J3DMaterialInitData* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
@@ -603,10 +556,8 @@ J3DGXColorS10 J3DMaterialFactory::newTevColor(int i_idx, int i_no) const {
}
}
/* 804564B0-804564B8 004AB0 0004+04 1/1 0/0 0/0 .sdata2 @1915 */
static GXColor const defaultTevKColor = {0xff, 0xff, 0xff, 0xff};
/* 80332210-8033226C 32CB50 005C+00 2/2 0/0 0/0 .text newTevKColor__18J3DMaterialFactoryCFii */
J3DGXColor J3DMaterialFactory::newTevKColor(int i_idx, int i_no) const {
J3DGXColor dflt = (J3DGXColor)defaultTevKColor;
u16 tev_kcolor_index = mpMaterialInitData[mpMaterialID[i_idx]].mTevKColorIdx[i_no];
@@ -617,7 +568,6 @@ J3DGXColor J3DMaterialFactory::newTevKColor(int i_idx, int i_no) const {
}
}
/* 8033226C-803322A4 32CBAC 0038+00 2/2 0/0 0/0 .text newTevStageNum__18J3DMaterialFactoryCFi */
u8 J3DMaterialFactory::newTevStageNum(int i_idx) const {
u8 tev_stage_num_index = mpMaterialInitData[mpMaterialID[i_idx]].mTevStageNumIdx;
if (tev_stage_num_index != 0xff) {
@@ -627,7 +577,6 @@ u8 J3DMaterialFactory::newTevStageNum(int i_idx) const {
}
}
/* 803322A4-80332304 32CBE4 0060+00 2/2 0/0 0/0 .text newTevStage__18J3DMaterialFactoryCFii */
J3DTevStage J3DMaterialFactory::newTevStage(int i_idx, int i_no) const {
u16 tev_stage_index = mpMaterialInitData[mpMaterialID[i_idx]].mTevStageIdx[i_no];
if (tev_stage_index != 0xffff) {
@@ -637,8 +586,6 @@ J3DTevStage J3DMaterialFactory::newTevStage(int i_idx, int i_no) const {
}
}
/* 80332304-803323A0 32CC44 009C+00 1/1 0/0 0/0 .text
* newTevSwapModeTable__18J3DMaterialFactoryCFii */
J3DTevSwapModeTable J3DMaterialFactory::newTevSwapModeTable(int i_idx, int i_no) const {
u16 tev_swap_mode_table_index = mpMaterialInitData[mpMaterialID[i_idx]].mTevSwapModeTableIdx[i_no];
if (tev_swap_mode_table_index != 0xffff) {
@@ -648,8 +595,6 @@ J3DTevSwapModeTable J3DMaterialFactory::newTevSwapModeTable(int i_idx, int i_no)
}
}
/* 803323A0-803323C8 32CCE0 0028+00 2/2 0/0 0/0 .text newIndTexStageNum__18J3DMaterialFactoryCFi
*/
u8 J3DMaterialFactory::newIndTexStageNum(int i_idx) const {
if (mpIndInitData[i_idx].mEnabled == true) {
return mpIndInitData[i_idx].mIndTexStageNum;
@@ -658,7 +603,6 @@ u8 J3DMaterialFactory::newIndTexStageNum(int i_idx) const {
}
}
/* 803323C8-8033240C 32CD08 0044+00 2/2 0/0 0/0 .text newIndTexOrder__18J3DMaterialFactoryCFii */
J3DIndTexOrder J3DMaterialFactory::newIndTexOrder(int i_idx, int i_no) const {
J3DIndTexOrder dflt;
if (mpIndInitData[i_idx].mEnabled == true) {
@@ -668,7 +612,6 @@ J3DIndTexOrder J3DMaterialFactory::newIndTexOrder(int i_idx, int i_no) const {
}
}
/* 8033240C-803324B4 32CD4C 00A8+00 2/2 0/0 0/0 .text newIndTexMtx__18J3DMaterialFactoryCFii */
J3DIndTexMtx J3DMaterialFactory::newIndTexMtx(int i_idx, int i_no) const {
J3DIndTexMtx dflt;
if (mpIndInitData[i_idx].mEnabled == true) {
@@ -678,7 +621,6 @@ J3DIndTexMtx J3DMaterialFactory::newIndTexMtx(int i_idx, int i_no) const {
}
}
/* 803324B4-80332648 32CDF4 0194+00 2/2 0/0 0/0 .text newIndTevStage__18J3DMaterialFactoryCFii */
J3DIndTevStage J3DMaterialFactory::newIndTevStage(int i_idx, int i_no) const {
J3DIndTevStage dflt;
if (mpIndInitData[i_idx].mEnabled == true) {
@@ -688,8 +630,6 @@ J3DIndTevStage J3DMaterialFactory::newIndTevStage(int i_idx, int i_no) const {
}
}
/* 80332648-8033268C 32CF88 0044+00 2/2 0/0 0/0 .text
* newIndTexCoordScale__18J3DMaterialFactoryCFii */
J3DIndTexCoordScale J3DMaterialFactory::newIndTexCoordScale(int i_idx, int i_no) const {
J3DIndTexCoordScale dflt;
if (mpIndInitData[i_idx].mEnabled == true) {
@@ -699,7 +639,6 @@ J3DIndTexCoordScale J3DMaterialFactory::newIndTexCoordScale(int i_idx, int i_no)
}
}
/* 8033268C-80332768 32CFCC 00DC+00 2/2 0/0 0/0 .text newFog__18J3DMaterialFactoryCFi */
J3DFog J3DMaterialFactory::newFog(int i_idx) const {
J3DFog fog;
u16 fog_index = mpMaterialInitData[mpMaterialID[i_idx]].mFogIdx;
@@ -709,7 +648,6 @@ J3DFog J3DMaterialFactory::newFog(int i_idx) const {
return fog;
}
/* 80332768-803327E8 32D0A8 0080+00 2/2 0/0 0/0 .text newAlphaComp__18J3DMaterialFactoryCFi */
J3DAlphaComp J3DMaterialFactory::newAlphaComp(int i_idx) const {
J3DMaterialInitData* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mAlphaCompIdx != 0xffff) {
@@ -719,8 +657,6 @@ J3DAlphaComp J3DMaterialFactory::newAlphaComp(int i_idx) const {
}
}
/* 803327E8-8033282C 32D128 0044+00 2/2 0/0 0/0 .text newBlend__18J3DMaterialFactoryCFi
*/
J3DBlend J3DMaterialFactory::newBlend(int i_idx) const {
J3DMaterialInitData* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mBlendIdx != 0xffff) {
@@ -730,8 +666,6 @@ J3DBlend J3DMaterialFactory::newBlend(int i_idx) const {
}
}
/* 8033282C-8033288C 32D16C 0060+00 2/2 0/0 0/0 .text newZMode__18J3DMaterialFactoryCFi
*/
J3DZMode J3DMaterialFactory::newZMode(int i_idx) const {
J3DMaterialInitData* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mZModeIdx != 0xff) {
@@ -741,7 +675,6 @@ J3DZMode J3DMaterialFactory::newZMode(int i_idx) const {
}
}
/* 8033288C-803328C4 32D1CC 0038+00 2/2 0/0 0/0 .text newZCompLoc__18J3DMaterialFactoryCFi */
u8 J3DMaterialFactory::newZCompLoc(int i_idx) const {
J3DMaterialInitData* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mZCompLocIdx != 0xff){
@@ -751,8 +684,6 @@ u8 J3DMaterialFactory::newZCompLoc(int i_idx) const {
}
}
/* 803328C4-803328FC 32D204 0038+00 2/2 0/0 0/0 .text newDither__18J3DMaterialFactoryCFi
*/
u8 J3DMaterialFactory::newDither(int i_idx) const {
J3DMaterialInitData* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mDitherIdx != 0xff){
@@ -762,7 +693,6 @@ u8 J3DMaterialFactory::newDither(int i_idx) const {
}
}
/* 803328FC-803329A0 32D23C 00A4+00 1/1 0/0 0/0 .text newNBTScale__18J3DMaterialFactoryCFi */
J3DNBTScale J3DMaterialFactory::newNBTScale(int i_idx) const {
J3DNBTScale dflt(j3dDefaultNBTScaleInfo);
J3DMaterialInitData* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J3DMaterialFactory_v21
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J3DGraphLoader/J3DMaterialFactory_v21.h"
@@ -11,8 +6,6 @@
#include "JSystem/JMath/JMath.h"
#include "JSystem/JSupport/JSupport.h"
/* 80332DA4-80332F84 32D6E4 01E0+00 0/0 2/2 0/0 .text
* __ct__22J3DMaterialFactory_v21FRC20J3DMaterialBlock_v21 */
J3DMaterialFactory_v21::J3DMaterialFactory_v21(J3DMaterialBlock_v21 const& i_block) {
mMaterialNum = i_block.mMaterialNum;
mpMaterialInitData = JSUConvertOffsetToPtr<J3DMaterialInitData_v21>(&i_block, i_block.mpMaterialInitData);
@@ -43,8 +36,6 @@ J3DMaterialFactory_v21::J3DMaterialFactory_v21(J3DMaterialBlock_v21 const& i_blo
mpNBTScaleInfo = JSUConvertOffsetToPtr<J3DNBTScaleInfo>(&i_block, i_block.mpNBTScaleInfo);
}
/* 80332F84-80332FA8 32D8C4 0024+00 0/0 1/1 0/0 .text
* countUniqueMaterials__22J3DMaterialFactory_v21Fv */
u16 J3DMaterialFactory_v21::countUniqueMaterials() {
u16 i;
for (i = 0; i < mMaterialNum; i++) {
@@ -52,7 +43,6 @@ u16 J3DMaterialFactory_v21::countUniqueMaterials() {
return i;
}
/* 80332FA8-80332FE0 32D8E8 0038+00 1/1 0/0 0/0 .text countTexGens__22J3DMaterialFactory_v21CFi */
u32 J3DMaterialFactory_v21::countTexGens(int i_idx) const {
u8 tex_gen_num_index = mpMaterialInitData[mpMaterialID[i_idx]].mTexGenNumIdx;
if (tex_gen_num_index != 0xff) {
@@ -61,7 +51,6 @@ u32 J3DMaterialFactory_v21::countTexGens(int i_idx) const {
return 0;
}
/* 80332FE0-80333068 32D920 0088+00 1/1 0/0 0/0 .text countStages__22J3DMaterialFactory_v21CFi */
u32 J3DMaterialFactory_v21::countStages(int i_idx) const {
J3DMaterialInitData_v21* init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
u32 count1 = 0;
@@ -85,8 +74,6 @@ u32 J3DMaterialFactory_v21::countStages(int i_idx) const {
return count2;
}
/* 80333068-803337D8 32D9A8 0770+00 0/0 2/2 0/0 .text
* create__22J3DMaterialFactory_v21CFP11J3DMaterialiUl */
J3DMaterial* J3DMaterialFactory_v21::create(J3DMaterial* i_material, int i_idx, u32 i_flags) const {
const u32 stages = countStages(i_idx);
u32 tev_stage_num = getMdlDataFlag_TevStageNum(i_flags);
@@ -175,7 +162,6 @@ J3DMaterial* J3DMaterialFactory_v21::create(J3DMaterial* i_material, int i_idx,
return i_material;
}
/* 803337D8-80333834 32E118 005C+00 1/1 0/0 0/0 .text newMatColor__22J3DMaterialFactory_v21CFii */
J3DGXColor J3DMaterialFactory_v21::newMatColor(int i_idx, int i_no) const {
GXColor defaultColor = {0xff,0xff,0xff,0xff};
J3DGXColor defaultJ3DGXColor = J3DGXColor(defaultColor);
@@ -186,8 +172,6 @@ J3DGXColor J3DMaterialFactory_v21::newMatColor(int i_idx, int i_no) const {
return J3DGXColor(defaultJ3DGXColor);
}
/* 80333834-8033386C 32E174 0038+00 1/1 0/0 0/0 .text newColorChanNum__22J3DMaterialFactory_v21CFi
*/
u8 J3DMaterialFactory_v21::newColorChanNum(int i_idx) const {
u8 color_chan_num_index = mpMaterialInitData[mpMaterialID[i_idx]].mColorChanNumIdx;
if (color_chan_num_index != 0xff) {
@@ -197,8 +181,6 @@ u8 J3DMaterialFactory_v21::newColorChanNum(int i_idx) const {
}
}
/* 8033386C-80333A10 32E1AC 01A4+00 1/1 0/0 0/0 .text newColorChan__22J3DMaterialFactory_v21CFii
*/
J3DColorChan J3DMaterialFactory_v21::newColorChan(int i_idx, int i_no) const {
J3DMaterialInitData_v21* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mColorChanIdx[i_no] != 0xffff) {
@@ -208,7 +190,6 @@ J3DColorChan J3DMaterialFactory_v21::newColorChan(int i_idx, int i_no) const {
}
}
/* 80333A10-80333A48 32E350 0038+00 1/1 0/0 0/0 .text newTexGenNum__22J3DMaterialFactory_v21CFi */
u32 J3DMaterialFactory_v21::newTexGenNum(int i_idx) const {
u8 tex_gen_num_index = mpMaterialInitData[mpMaterialID[i_idx]].mTexGenNumIdx;
if (tex_gen_num_index != 0xff) {
@@ -218,7 +199,6 @@ u32 J3DMaterialFactory_v21::newTexGenNum(int i_idx) const {
}
}
/* 80333A48-80333AA8 32E388 0060+00 1/1 0/0 0/0 .text newTexCoord__22J3DMaterialFactory_v21CFii */
J3DTexCoord J3DMaterialFactory_v21::newTexCoord(int i_idx, int i_no) const {
u16 tex_coord_index = mpMaterialInitData[mpMaterialID[i_idx]].mTexCoordIdx[i_no];
if (tex_coord_index != 0xffff) {
@@ -228,7 +208,6 @@ J3DTexCoord J3DMaterialFactory_v21::newTexCoord(int i_idx, int i_no) const {
}
}
/* 80333AA8-80333B30 32E3E8 0088+00 1/1 0/0 0/0 .text newTexMtx__22J3DMaterialFactory_v21CFii */
J3DTexMtx* J3DMaterialFactory_v21::newTexMtx(int i_idx, int i_no) const {
J3DTexMtx* tex_mtx = NULL;
J3DMaterialInitData_v21* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
@@ -238,7 +217,6 @@ J3DTexMtx* J3DMaterialFactory_v21::newTexMtx(int i_idx, int i_no) const {
return tex_mtx;
}
/* 80333B30-80333B70 32E470 0040+00 1/1 0/0 0/0 .text newCullMode__22J3DMaterialFactory_v21CFi */
u8 J3DMaterialFactory_v21::newCullMode(int i_idx) const {
u8 cull_mode_index = mpMaterialInitData[mpMaterialID[i_idx]].mCullModeIdx;
if (cull_mode_index != 0xff) {
@@ -248,7 +226,6 @@ u8 J3DMaterialFactory_v21::newCullMode(int i_idx) const {
}
}
/* 80333B70-80333BB8 32E4B0 0048+00 1/1 0/0 0/0 .text newTexNo__22J3DMaterialFactory_v21CFii */
u16 J3DMaterialFactory_v21::newTexNo(int i_idx, int i_no) const {
u16 tex_no_index = mpMaterialInitData[mpMaterialID[i_idx]].mTexNoIdx[i_no];
if (tex_no_index != 0xffff) {
@@ -258,7 +235,6 @@ u16 J3DMaterialFactory_v21::newTexNo(int i_idx, int i_no) const {
}
}
/* 80333BB8-80333C04 32E4F8 004C+00 1/1 0/0 0/0 .text newTevOrder__22J3DMaterialFactory_v21CFii */
J3DTevOrder J3DMaterialFactory_v21::newTevOrder(int i_idx, int i_no) const {
J3DMaterialInitData_v21* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mTevOrderIdx[i_no] != 0xffff) {
@@ -268,7 +244,6 @@ J3DTevOrder J3DMaterialFactory_v21::newTevOrder(int i_idx, int i_no) const {
}
}
/* 80333C04-80333C74 32E544 0070+00 1/1 0/0 0/0 .text newTevColor__22J3DMaterialFactory_v21CFii */
J3DGXColorS10 J3DMaterialFactory_v21::newTevColor(int i_idx, int i_no) const {
GXColorS10 defaultTevColor = {0,0,0,0};
J3DGXColorS10 dflt = defaultTevColor;
@@ -280,8 +255,6 @@ J3DGXColorS10 J3DMaterialFactory_v21::newTevColor(int i_idx, int i_no) const {
}
}
/* 80333C74-80333CD0 32E5B4 005C+00 1/1 0/0 0/0 .text newTevKColor__22J3DMaterialFactory_v21CFii
*/
J3DGXColor J3DMaterialFactory_v21::newTevKColor(int i_idx, int param_1) const {
GXColor defaultColor = {0xff,0xff,0xff,0xff};
J3DGXColor defaultJ3DGXColor = J3DGXColor(defaultColor);
@@ -292,8 +265,6 @@ J3DGXColor J3DMaterialFactory_v21::newTevKColor(int i_idx, int param_1) const {
return J3DGXColor(defaultJ3DGXColor);
}
/* 80333CD0-80333D08 32E610 0038+00 1/1 0/0 0/0 .text newTevStageNum__22J3DMaterialFactory_v21CFi
*/
u8 J3DMaterialFactory_v21::newTevStageNum(int i_idx) const {
u8 tev_stage_num_index = mpMaterialInitData[mpMaterialID[i_idx]].mTevStageNumIdx;
if (tev_stage_num_index != 0xff) {
@@ -303,7 +274,6 @@ u8 J3DMaterialFactory_v21::newTevStageNum(int i_idx) const {
}
}
/* 80333D08-80333D68 32E648 0060+00 1/1 0/0 0/0 .text newTevStage__22J3DMaterialFactory_v21CFii */
J3DTevStage J3DMaterialFactory_v21::newTevStage(int i_idx, int i_no) const {
u16 tev_stage_index = mpMaterialInitData[mpMaterialID[i_idx]].mTevStageIdx[i_no];
if (tev_stage_index != 0xffff) {
@@ -313,8 +283,6 @@ J3DTevStage J3DMaterialFactory_v21::newTevStage(int i_idx, int i_no) const {
}
}
/* 80333D68-80333E04 32E6A8 009C+00 1/1 0/0 0/0 .text
* newTevSwapModeTable__22J3DMaterialFactory_v21CFii */
J3DTevSwapModeTable J3DMaterialFactory_v21::newTevSwapModeTable(int i_idx, int param_1) const {
J3DMaterialInitData_v21* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mTevSwapModeTableIdx[param_1] != 0xffff) {
@@ -323,8 +291,6 @@ J3DTevSwapModeTable J3DMaterialFactory_v21::newTevSwapModeTable(int i_idx, int p
return J3DTevSwapModeTable(j3dDefaultTevSwapModeTable);
}
/* 80333E04-80333EE0 32E744 00DC+00 1/1 0/0 0/0 .text newFog__22J3DMaterialFactory_v21CFi
*/
J3DFog J3DMaterialFactory_v21::newFog(int i_idx) const {
J3DFog fog;
u16 fog_index = mpMaterialInitData[mpMaterialID[i_idx]].mFogIdx;
@@ -334,7 +300,6 @@ J3DFog J3DMaterialFactory_v21::newFog(int i_idx) const {
return fog;
}
/* 80333EE0-80333F60 32E820 0080+00 1/1 0/0 0/0 .text newAlphaComp__22J3DMaterialFactory_v21CFi */
J3DAlphaComp J3DMaterialFactory_v21::newAlphaComp(int i_idx) const {
J3DMaterialInitData_v21* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mAlphaCompIdx != 0xffff) {
@@ -343,7 +308,6 @@ J3DAlphaComp J3DMaterialFactory_v21::newAlphaComp(int i_idx) const {
return J3DAlphaComp(0xffff);
}
/* 80333F60-80333FA4 32E8A0 0044+00 1/1 0/0 0/0 .text newBlend__22J3DMaterialFactory_v21CFi */
J3DBlend J3DMaterialFactory_v21::newBlend(int i_idx) const {
J3DMaterialInitData_v21* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mBlendIdx != 0xffff) {
@@ -353,7 +317,6 @@ J3DBlend J3DMaterialFactory_v21::newBlend(int i_idx) const {
}
}
/* 80333FA4-80334004 32E8E4 0060+00 1/1 0/0 0/0 .text newZMode__22J3DMaterialFactory_v21CFi */
J3DZMode J3DMaterialFactory_v21::newZMode(int i_idx) const {
J3DMaterialInitData_v21* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mZModeIdx != 0xff) {
@@ -363,7 +326,6 @@ J3DZMode J3DMaterialFactory_v21::newZMode(int i_idx) const {
}
}
/* 80334004-8033403C 32E944 0038+00 1/1 0/0 0/0 .text newZCompLoc__22J3DMaterialFactory_v21CFi */
u8 J3DMaterialFactory_v21::newZCompLoc(int i_idx) const {
J3DMaterialInitData_v21* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mZCompLocIdx != 0xff){
@@ -373,7 +335,6 @@ u8 J3DMaterialFactory_v21::newZCompLoc(int i_idx) const {
}
}
/* 8033403C-80334074 32E97C 0038+00 1/1 0/0 0/0 .text newDither__22J3DMaterialFactory_v21CFi */
u8 J3DMaterialFactory_v21::newDither(int i_idx) const {
J3DMaterialInitData_v21* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
if (mtl_init_data->mDitherIdx != 0xff){
@@ -383,7 +344,6 @@ u8 J3DMaterialFactory_v21::newDither(int i_idx) const {
}
}
/* 80334074-80334118 32E9B4 00A4+00 1/1 0/0 0/0 .text newNBTScale__22J3DMaterialFactory_v21CFi */
J3DNBTScale J3DMaterialFactory_v21::newNBTScale(int i_idx) const {
J3DNBTScale dflt(j3dDefaultNBTScaleInfo);
J3DMaterialInitData_v21* mtl_init_data = &mpMaterialInitData[mpMaterialID[i_idx]];
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J3DModelLoader
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J3DGraphLoader/J3DModelLoader.h"
@@ -17,7 +12,6 @@
#include "JSystem/JSupport/JSupport.h"
#include "dolphin/os.h"
/* 8033468C-803346BC 32EFCC 0030+00 1/1 0/0 0/0 .text __ct__14J3DModelLoaderFv */
J3DModelLoader::J3DModelLoader() :
mpModelData(NULL),
mpMaterialTable(NULL),
@@ -29,7 +23,6 @@ J3DModelLoader::J3DModelLoader() :
/* empty function */
}
/* 803346BC-803347E0 32EFFC 0124+00 0/0 4/4 0/0 .text load__22J3DModelLoaderDataBaseFPCvUl */
J3DModelData* J3DModelLoaderDataBase::load(void const* i_data, u32 i_flags) {
if (i_data == NULL) {
return NULL;
@@ -48,7 +41,6 @@ J3DModelData* J3DModelLoaderDataBase::load(void const* i_data, u32 i_flags) {
return NULL;
}
/* 803347E0-80334ABC 32F120 02DC+00 4/1 0/0 0/0 .text load__14J3DModelLoaderFPCvUl */
J3DModelData* J3DModelLoader::load(void const* i_data, u32 i_flags) {
JKRGetCurrentHeap()->getTotalFreeSize();
mpModelData = new J3DModelData();
@@ -107,7 +99,6 @@ J3DModelData* J3DModelLoader::load(void const* i_data, u32 i_flags) {
}
/* 80334ABC-80334C20 32F3FC 0164+00 3/0 0/0 0/0 .text loadMaterialTable__14J3DModelLoaderFPCv */
J3DMaterialTable* J3DModelLoader::loadMaterialTable(void const* i_data) {
mpMaterialTable = new J3DMaterialTable();
mpMaterialTable->clear();
@@ -136,8 +127,6 @@ J3DMaterialTable* J3DModelLoader::loadMaterialTable(void const* i_data) {
return mpMaterialTable;
}
/* 80334C20-80334EE0 32F560 02C0+00 3/0 0/0 0/0 .text
* loadBinaryDisplayList__14J3DModelLoaderFPCvUl */
J3DModelData* J3DModelLoader::loadBinaryDisplayList(void const* i_data, u32 i_flags) {
mpModelData = new J3DModelData();
mpModelData->clear();
@@ -200,8 +189,6 @@ J3DModelData* J3DModelLoader::loadBinaryDisplayList(void const* i_data, u32 i_fl
return mpModelData;
}
/* 80334EE0-80335048 32F820 0168+00 3/0 0/0 0/0 .text setupBBoardInfo__14J3DModelLoaderFv
*/
void J3DModelLoader::setupBBoardInfo() {
for (u16 i = 0; i < mpModelData->getJointNum(); i++) {
J3DMaterial* mesh = mpModelData->getJointNodePointer(i)->getMesh();
@@ -240,8 +227,6 @@ void J3DModelLoader::setupBBoardInfo() {
}
}
/* 80335048-803351A4 32F988 015C+00 2/2 0/0 0/0 .text
* readInformation__14J3DModelLoaderFPC17J3DModelInfoBlockUl */
void J3DModelLoader::readInformation(J3DModelInfoBlock const* i_block, u32 i_flags) {
mpModelData->mFlags = i_flags | i_block->mFlags;
mpModelData->getJointTree().setFlag(mpModelData->mFlags);
@@ -263,7 +248,6 @@ void J3DModelLoader::readInformation(J3DModelInfoBlock const* i_block, u32 i_fla
mpModelData->setHierarchy(JSUConvertOffsetToPtr<J3DModelHierarchy>(i_block, i_block->mpHierarchy));
}
/* 803351A4-803351D0 32FAE4 002C+00 1/1 0/0 0/0 .text getFmtType__FP17_GXVtxAttrFmtList7_GXAttr */
static _GXCompType getFmtType(_GXVtxAttrFmtList* i_fmtList, _GXAttr i_attr) {
for (; i_fmtList->attr != GX_VA_NULL; i_fmtList++) {
if (i_fmtList->attr == i_attr) {
@@ -273,8 +257,6 @@ static _GXCompType getFmtType(_GXVtxAttrFmtList* i_fmtList, _GXAttr i_attr) {
return GX_F32;
}
/* 803351D0-803353F0 32FB10 0220+00 2/2 0/0 0/0 .text
* readVertex__14J3DModelLoaderFPC14J3DVertexBlock */
void J3DModelLoader::readVertex(J3DVertexBlock const* i_block) {
J3DVertexData& vertex_data = mpModelData->getVertexData();
vertex_data.mVtxAttrFmtList =
@@ -333,8 +315,6 @@ void J3DModelLoader::readVertex(J3DVertexBlock const* i_block) {
}
}
/* 803353F0-80335480 32FD30 0090+00 2/2 0/0 0/0 .text
* readEnvelop__14J3DModelLoaderFPC16J3DEnvelopeBlock */
void J3DModelLoader::readEnvelop(J3DEnvelopeBlock const* i_block) {
mpModelData->getJointTree().mWEvlpMtxNum = i_block->mWEvlpMtxNum;
mpModelData->getJointTree().mWEvlpMixMtxNum =
@@ -347,8 +327,6 @@ void J3DModelLoader::readEnvelop(J3DEnvelopeBlock const* i_block) {
JSUConvertOffsetToPtr<Mtx>(i_block, i_block->mpInvJointMtx);
}
/* 80335480-80335530 32FDC0 00B0+00 2/2 0/0 0/0 .text readDraw__14J3DModelLoaderFPC12J3DDrawBlock
*/
void J3DModelLoader::readDraw(J3DDrawBlock const* i_block) {
J3DJointTree& joint_tree = mpModelData->getJointTree();
joint_tree.mDrawMtxData.mEntryNum = i_block->mMtxNum - mpModelData->getJointTree().mWEvlpMtxNum;
@@ -365,8 +343,6 @@ void J3DModelLoader::readDraw(J3DDrawBlock const* i_block) {
}
/* 80335530-80335614 32FE70 00E4+00 2/2 0/0 0/0 .text
* readJoint__14J3DModelLoaderFPC13J3DJointBlock */
void J3DModelLoader::readJoint(J3DJointBlock const* i_block) {
J3DJointFactory factory(*i_block);
mpModelData->getJointTree().mJointNum = i_block->mJointNum;
@@ -383,8 +359,6 @@ void J3DModelLoader::readJoint(J3DJointBlock const* i_block) {
}
}
/* 80335614-80335890 32FF54 027C+00 1/0 0/0 0/0 .text
* readMaterial__18J3DModelLoader_v26FPC16J3DMaterialBlockUl */
void J3DModelLoader_v26::readMaterial(J3DMaterialBlock const* i_block, u32 i_flags) {
J3DMaterialFactory factory(*i_block);
mpMaterialTable->mMaterialNum = i_block->mMaterialNum;
@@ -427,8 +401,6 @@ void J3DModelLoader_v26::readMaterial(J3DMaterialBlock const* i_block, u32 i_fla
}
}
/* 80335890-80335AF4 3301D0 0264+00 1/0 0/0 0/0 .text
* readMaterial_v21__18J3DModelLoader_v21FPC20J3DMaterialBlock_v21Ul */
void J3DModelLoader_v21::readMaterial_v21(J3DMaterialBlock_v21 const* i_block, u32 i_flags) {
J3DMaterialFactory_v21 factory(*i_block);
mpMaterialTable->mMaterialNum = i_block->mMaterialNum;
@@ -468,8 +440,6 @@ void J3DModelLoader_v21::readMaterial_v21(J3DMaterialBlock_v21 const* i_block, u
}
}
/* 80335AF4-80335C18 330434 0124+00 2/2 0/0 0/0 .text
* readShape__14J3DModelLoaderFPC13J3DShapeBlockUl */
void J3DModelLoader::readShape(J3DShapeBlock const* i_block, u32 i_flags) {
mpShapeBlock = i_block;
J3DShapeTable* shape_table = mpModelData->getShapeTable();
@@ -494,8 +464,6 @@ void J3DModelLoader::readShape(J3DShapeBlock const* i_block, u32 i_flags) {
}
}
/* 80335C18-80335CE4 330558 00CC+00 2/2 0/0 0/0 .text
* readTexture__14J3DModelLoaderFPC15J3DTextureBlock */
void J3DModelLoader::readTexture(J3DTextureBlock const* i_block) {
u16 texture_num = i_block->mTextureNum;
ResTIMG* texture_res = JSUConvertOffsetToPtr<ResTIMG>(i_block, i_block->mpTextureRes);
@@ -508,8 +476,6 @@ void J3DModelLoader::readTexture(J3DTextureBlock const* i_block) {
mpMaterialTable->mTexture = new J3DTexture(texture_num, texture_res);
}
/* 80335CE4-80335E20 330624 013C+00 1/0 0/0 0/0 .text
* readMaterialTable__18J3DModelLoader_v26FPC16J3DMaterialBlockUl */
void J3DModelLoader_v26::readMaterialTable(J3DMaterialBlock const* i_block, u32 i_flags) {
J3DMaterialFactory factory(*i_block);
mpMaterialTable->mMaterialNum = i_block->mMaterialNum;
@@ -530,8 +496,6 @@ void J3DModelLoader_v26::readMaterialTable(J3DMaterialBlock const* i_block, u32
}
}
/* 80335E20-80335F5C 330760 013C+00 1/0 0/0 0/0 .text
* readMaterialTable_v21__18J3DModelLoader_v21FPC20J3DMaterialBlock_v21Ul */
void J3DModelLoader_v21::readMaterialTable_v21(J3DMaterialBlock_v21 const* i_block, u32 i_flags) {
J3DMaterialFactory_v21 factory(*i_block);
mpMaterialTable->mMaterialNum = i_block->mMaterialNum;
@@ -552,8 +516,6 @@ void J3DModelLoader_v21::readMaterialTable_v21(J3DMaterialBlock_v21 const* i_blo
}
}
/* 80335F5C-80336028 33089C 00CC+00 1/1 0/0 0/0 .text
* readTextureTable__14J3DModelLoaderFPC15J3DTextureBlock */
void J3DModelLoader::readTextureTable(J3DTextureBlock const* i_block) {
u16 texture_num = i_block->mTextureNum;
ResTIMG* texture_res = JSUConvertOffsetToPtr<ResTIMG>(i_block, i_block->mpTextureRes);
@@ -566,8 +528,6 @@ void J3DModelLoader::readTextureTable(J3DTextureBlock const* i_block) {
mpMaterialTable->mTexture = new J3DTexture(texture_num, texture_res);
}
/* 80336028-80336168 330968 0140+00 1/1 0/0 0/0 .text
* readPatchedMaterial__14J3DModelLoaderFPC16J3DMaterialBlockUl */
void J3DModelLoader::readPatchedMaterial(J3DMaterialBlock const* i_block, u32 i_flags) {
J3DMaterialFactory factory(*i_block);
mpMaterialTable->mMaterialNum = i_block->mMaterialNum;
@@ -588,8 +548,6 @@ void J3DModelLoader::readPatchedMaterial(J3DMaterialBlock const* i_block, u32 i_
}
}
/* 80336168-8033631C 330AA8 01B4+00 1/1 0/0 0/0 .text
* readMaterialDL__14J3DModelLoaderFPC18J3DMaterialDLBlockUl */
void J3DModelLoader::readMaterialDL(J3DMaterialDLBlock const* i_block, u32 i_flags) {
J3DMaterialFactory factory(*i_block);
s32 flags;
@@ -623,8 +581,6 @@ void J3DModelLoader::readMaterialDL(J3DMaterialDLBlock const* i_block, u32 i_fla
}
}
/* 8033631C-80336398 330C5C 007C+00 1/1 0/0 0/0 .text modifyMaterial__14J3DModelLoaderFUl
*/
void J3DModelLoader::modifyMaterial(u32 i_flags) {
if (i_flags & 0x2000) {
J3DMaterialFactory factory(*mpMaterialBlock);
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J3DModelLoaderCalcSize
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J3DGraphLoader/J3DModelLoaderCalcSize.h"
@@ -16,7 +11,6 @@
#include "global.h"
/* 80336794-803367D4 3310D4 0040+00 0/0 3/0 0/0 .text countMaterialNum__14J3DModelLoaderFPCv */
u16 J3DModelLoader::countMaterialNum(const void* stream) {
const J3DModelFileData* header = (const J3DModelFileData*)stream;
const J3DModelBlock* block = header->mBlocks;
@@ -29,7 +23,6 @@ u16 J3DModelLoader::countMaterialNum(const void* stream) {
return 0;
}
/* 803367D4-803369A0 331114 01CC+00 0/0 3/0 0/0 .text calcLoadSize__14J3DModelLoaderFPCvUl */
u32 J3DModelLoader::calcLoadSize(void const* stream, u32 flags_) {
int flags = flags_;
const J3DModelFileData* header = static_cast<const J3DModelFileData*>(stream);
@@ -74,8 +67,6 @@ u32 J3DModelLoader::calcLoadSize(void const* stream, u32 flags_) {
return size;
}
/* 803369A0-80336A98 3312E0 00F8+00 0/0 3/0 0/0 .text
* calcLoadMaterialTableSize__14J3DModelLoaderFPCv */
u32 J3DModelLoader::calcLoadMaterialTableSize(const void* stream) {
size_t size;
const J3DModelBlock* nextBlock;
@@ -118,8 +109,6 @@ inline u32 getBdlFlag_MaterialType(u32 flags) {
return flags & (J3DMLF_13 | J3DMLF_DoBdlMaterialCalc);
}
/* 80336A98-80336CD8 3313D8 0240+00 0/0 3/0 0/0 .text
* calcLoadBinaryDisplayListSize__14J3DModelLoaderFPCvUl */
// NONMATCHING flags issue
u32 J3DModelLoader::calcLoadBinaryDisplayListSize(const void* stream, u32 flags) {
u32 size = 0;
@@ -176,8 +165,6 @@ u32 J3DModelLoader::calcLoadBinaryDisplayListSize(const void* stream, u32 flags)
return size;
}
/* 80336CD8-80336D64 331618 008C+00 2/2 0/0 0/0 .text
* calcSizeInformation__14J3DModelLoaderFPC17J3DModelInfoBlockUl */
u32 J3DModelLoader::calcSizeInformation(const J3DModelInfoBlock* block, u32 flags) {
int size = 0;
switch ((flags | block->mFlags) & J3DMLF_MtxTypeMask) {
@@ -197,8 +184,6 @@ u32 J3DModelLoader::calcSizeInformation(const J3DModelInfoBlock* block, u32 flag
return size;
}
/* 80336D64-80336D90 3316A4 002C+00 2/2 0/0 0/0 .text
* calcSizeJoint__14J3DModelLoaderFPC13J3DJointBlock */
u32 J3DModelLoader::calcSizeJoint(const J3DJointBlock* block) {
int size = 0;
if (block->mpNameTable) {
@@ -209,21 +194,15 @@ u32 J3DModelLoader::calcSizeJoint(const J3DJointBlock* block) {
return size;
}
/* 80336D90-80336DA0 3316D0 0010+00 2/2 0/0 0/0 .text
* calcSizeEnvelope__14J3DModelLoaderFPC16J3DEnvelopeBlock */
u32 J3DModelLoader::calcSizeEnvelope(const J3DEnvelopeBlock* block) {
mEnvelopeSize = block->mWEvlpMtxNum;
return 0;
}
/* 80336DA0-80336DB4 3316E0 0014+00 2/2 0/0 0/0 .text
* calcSizeDraw__14J3DModelLoaderFPC12J3DDrawBlock */
u32 J3DModelLoader::calcSizeDraw(const J3DDrawBlock* block) {
return (block->mMtxNum - mEnvelopeSize) * 2;
}
/* 80336DB4-80336EA0 3316F4 00EC+00 0/0 1/0 0/0 .text
* calcSizeMaterial__18J3DModelLoader_v26FPC16J3DMaterialBlockUl */
u32 J3DModelLoader_v26::calcSizeMaterial(const J3DMaterialBlock* block, u32 flags) {
int padding = 0;
J3DMaterialFactory factory(*block);
@@ -249,8 +228,6 @@ u32 J3DModelLoader_v26::calcSizeMaterial(const J3DMaterialBlock* block, u32 flag
return size;
}
/* 80336EA0-80336F44 3317E0 00A4+00 2/2 0/0 0/0 .text
* calcSizeShape__14J3DModelLoaderFPC13J3DShapeBlockUl */
u32 J3DModelLoader::calcSizeShape(const J3DShapeBlock* block, u32 flags) {
int size = 0;
J3DShapeFactory factory(*block);
@@ -268,8 +245,6 @@ u32 J3DModelLoader::calcSizeShape(const J3DShapeBlock* block, u32 flags) {
return size;
}
/* 80336F44-80336F60 331884 001C+00 3/3 0/0 0/0 .text
* calcSizeTexture__14J3DModelLoaderFPC15J3DTextureBlock */
u32 J3DModelLoader::calcSizeTexture(const J3DTextureBlock* block) {
// TODO: use sizeofs here.
int padding = 0;
@@ -279,8 +254,6 @@ u32 J3DModelLoader::calcSizeTexture(const J3DTextureBlock* block) {
return padding + 0xC;
}
/* 80336F60-80336FF0 3318A0 0090+00 0/0 1/0 0/0 .text
* calcSizeMaterialTable__18J3DModelLoader_v26FPC16J3DMaterialBlockUl */
u32 J3DModelLoader_v26::calcSizeMaterialTable(const J3DMaterialBlock* block, u32 flags) {
int size = 0;
u32 count = block->mMaterialNum;
@@ -295,14 +268,10 @@ u32 J3DModelLoader_v26::calcSizeMaterialTable(const J3DMaterialBlock* block, u32
return size;
}
/* 80336FF0-80337010 331930 0020+00 1/1 0/0 0/0 .text
* calcSizeTextureTable__14J3DModelLoaderFPC15J3DTextureBlock */
u32 J3DModelLoader::calcSizeTextureTable(const J3DTextureBlock* block) {
return calcSizeTexture(block);
}
/* 80337010-803370A0 331950 0090+00 1/1 0/0 0/0 .text
* calcSizePatchedMaterial__14J3DModelLoaderFPC16J3DMaterialBlockUl */
u32 J3DModelLoader::calcSizePatchedMaterial(const J3DMaterialBlock* block, u32 flags) {
int padding = 0;
u32 count = block->mMaterialNum;
@@ -317,8 +286,6 @@ u32 J3DModelLoader::calcSizePatchedMaterial(const J3DMaterialBlock* block, u32 f
return size;
}
/* 803370A0-80337178 3319E0 00D8+00 1/1 0/0 0/0 .text
* calcSizeMaterialDL__14J3DModelLoaderFPC18J3DMaterialDLBlockUl */
u32 J3DModelLoader::calcSizeMaterialDL(const J3DMaterialDLBlock* block, u32 flags_) {
int flags = flags_;
size_t size = 0;
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J3DShapeFactory
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J3DGraphLoader/J3DShapeFactory.h"
@@ -13,7 +8,6 @@
#include "dolphin/os.h"
#include "global.h"
/* 80337350-80337400 331C90 00B0+00 0/0 2/2 0/0 .text __ct__15J3DShapeFactoryFRC13J3DShapeBlock */
J3DShapeFactory::J3DShapeFactory(J3DShapeBlock const& block) {
mShapeInitData = JSUConvertOffsetToPtr<J3DShapeInitData>(&block, (uintptr_t)block.mpShapeInitData);
mIndexTable = JSUConvertOffsetToPtr<u16>(&block, (uintptr_t)block.mpIndexTable);
@@ -25,8 +19,6 @@ J3DShapeFactory::J3DShapeFactory(J3DShapeBlock const& block) {
mVcdVatCmdBuffer = NULL;
}
/* 80337400-803375BC 331D40 01BC+00 0/0 1/1 0/0 .text
* create__15J3DShapeFactoryFiUlP14_GXVtxDescList */
J3DShape* J3DShapeFactory::create(int no, u32 flag, GXVtxDescList* vtxDesc) {
J3DShape* shape = new J3DShape;
shape->mMtxGroupNum = getMtxGroupNum(no);
@@ -58,7 +50,6 @@ enum {
J3DShapeMtxType_Multi = 0x03,
};
/* 803375BC-8033784C 331EFC 0290+00 1/1 0/0 0/0 .text newShapeMtx__15J3DShapeFactoryCFUlii */
J3DShapeMtx* J3DShapeFactory::newShapeMtx(u32 flag, int shapeNo, int mtxGroupNo) const {
J3DShapeMtx* ret = NULL;
const J3DShapeInitData& shapeInitData = mShapeInitData[mIndexTable[shapeNo]];
@@ -109,8 +100,6 @@ J3DShapeMtx* J3DShapeFactory::newShapeMtx(u32 flag, int shapeNo, int mtxGroupNo)
return ret;
}
/* 8033784C-803378D8 33218C 008C+00 1/1 0/0 0/0 .text newShapeDraw__15J3DShapeFactoryCFii
*/
J3DShapeDraw* J3DShapeFactory::newShapeDraw(int shapeNo, int mtxGroupNo) const {
const J3DShapeInitData& shapeInitData = mShapeInitData[mIndexTable[shapeNo]];
const J3DShapeDrawInitData& drawInitData =
@@ -119,15 +108,12 @@ J3DShapeDraw* J3DShapeFactory::newShapeDraw(int shapeNo, int mtxGroupNo) const {
drawInitData.mDisplayListSize);
}
/* 803378D8-80337944 332218 006C+00 0/0 1/1 0/0 .text allocVcdVatCmdBuffer__15J3DShapeFactoryFUl
*/
void J3DShapeFactory::allocVcdVatCmdBuffer(u32 count) {
mVcdVatCmdBuffer = new (0x20) u8[J3DShape::kVcdVatDLSize * count];
for (u32 i = 0; i < (J3DShape::kVcdVatDLSize * count) / 4; i++)
((u32*)mVcdVatCmdBuffer)[i] = 0;
}
/* 80337944-803379D8 332284 0094+00 0/0 1/1 0/0 .text calcSize__15J3DShapeFactoryFiUl */
s32 J3DShapeFactory::calcSize(int shapeNo, u32 flag) {
s32 size = 0x68;
@@ -144,13 +130,10 @@ s32 J3DShapeFactory::calcSize(int shapeNo, u32 flag) {
return size;
}
/* 803379D8-803379E8 332318 0010+00 0/0 1/1 0/0 .text
* calcSizeVcdVatCmdBuffer__15J3DShapeFactoryFUl */
s32 J3DShapeFactory::calcSizeVcdVatCmdBuffer(u32 count) {
return ALIGN_NEXT(count * J3DShape::kVcdVatDLSize, 0x20);
}
/* 803379E8-80337AE0 332328 00F8+00 1/1 0/0 0/0 .text calcSizeShapeMtx__15J3DShapeFactoryCFUlii */
s32 J3DShapeFactory::calcSizeShapeMtx(u32 flag, int shapeNo, int mtxGroupNo) const {
const J3DShapeInitData& shapeInitData = mShapeInitData[mIndexTable[shapeNo]];
u32 ret = 0;
-16
View File
@@ -1,21 +1,13 @@
//
// Generated By: dol2asm
// Translation Unit: J3DUClipper
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J3DU/J3DUClipper.h"
#include "math.h"
/* 80273778-8027378C 26E0B8 0014+00 0/0 1/1 0/0 .text init__11J3DUClipperFv */
void J3DUClipper::init() {
mNear = 1.0f;
mFar = 100000.0f;
}
/* ############################################################################################## */
/* 8027378C-802738FC 26E0CC 0170+00 0/0 3/3 4/4 .text calcViewFrustum__11J3DUClipperFv */
void J3DUClipper::calcViewFrustum() {
static const f32 unused[3] = {0.0f};
f32 f0 = tan(0.5f * mFovY * 0.01745329238474369f);
@@ -35,7 +27,6 @@ void J3DUClipper::calcViewFrustum() {
VECNormalize(&_28, &_28);
}
/* 802738FC-80273A44 26E23C 0148+00 0/0 3/3 2/2 .text clip__11J3DUClipperCFPA4_Cf3Vecf */
int J3DUClipper::clip(f32 const (*param_0)[4], Vec param_1, f32 param_2) const {
Vec vec1;
MTXMultVec(param_0, &param_1, &vec1);
@@ -66,9 +57,7 @@ int J3DUClipper::clip(f32 const (*param_0)[4], Vec param_1, f32 param_2) const {
return 0;
}
/* ############################################################################################## */
/* 80273A44-80273E08 26E384 03C4+00 0/0 3/3 2/2 .text clip__11J3DUClipperCFPA4_CfP3VecP3Vec */
int J3DUClipper::clip(f32 const (*param_1)[4], Vec* param_2, Vec* param_3) const {
s32 local_98[6];
for (int i = 0; i < 6; i++) {
@@ -160,15 +149,10 @@ int J3DUClipper::clip(f32 const (*param_1)[4], Vec* param_2, Vec* param_3) const
return 0;
}
/* ############################################################################################## */
/* 8039A984-8039A99D 026FE4 0019+00 0/0 0/0 0/0 .rodata None */
static char const* const stringBase_8039A984 = " J3DUClipper::mFovy = %f";
/* 8039A99D-8039A9B8 026FFD 001B+00 0/0 0/0 0/0 .rodata None */
static char const* const stringBase_8039A99D = " J3DUClipper::mAspect = %f";
/* 8039A9B8-8039A9D1 027018 0019+00 0/0 0/0 0/0 .rodata None */
static char const* const stringBase_8039A9B8 = " J3DUClipper::mNear = %f";
/* 8039A9D1-8039A9F0 027031 0018+07 0/0 0/0 0/0 .rodata None */
static char const* const stringBase_8039A9D1 = " J3DUClipper::mFar = %f";
-5
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: J3DUDL
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/J3DU/J3DUDL.h"
-21
View File
@@ -4,16 +4,12 @@
#include "JSystem/JAudio2/JAIAudience.h"
#include "JSystem/JAudio2/JAISeMgr.h"
/* 8029F03C-8029F0F8 29997C 00BC+00 0/0 1/1 0/0 .text
* __ct__5JAISeFP8JAISeMgrP27JAISoundStrategyMgr<5JAISe>Ul */
JAISe::JAISe(JAISeMgr* seMgr, JAISoundStrategyMgr<JAISe>* soundStrategyMgr, u32 priority) : JSULink<JAISe>(this) {
inner_.mSoundStrategyMgr = soundStrategyMgr;
inner_.seMgr = seMgr;
inner_.mProperPriority = priority;
}
/* 8029F0F8-8029F214 299A38 011C+00 1/1 0/0 0/0 .text mixOut___5JAISeFRC14JASSoundParams
*/
void JAISe::mixOut_(const JASSoundParams& params) {
inner_.track.setTempoRate(inner_.mTempoMgr.getTempo());
JASSoundParams mixParams;
@@ -33,7 +29,6 @@ void JAISe::mixOut_(const JASSoundParams& params) {
}
}
/* 8029F214-8029F250 299B54 003C+00 1/1 0/0 0/0 .text stopTrack___5JAISeFv */
void JAISe::stopTrack_() {
switch (inner_.track.getStatus()) {
case JASTrack::STATUS_FREE:
@@ -46,7 +41,6 @@ void JAISe::stopTrack_() {
}
}
/* 8029F250-8029F304 299B90 00B4+00 1/1 0/0 0/0 .text startTrack___5JAISeFRC14JASSoundParams */
void JAISe::startTrack_(const JASSoundParams& params) {
JUT_ASSERT(72, inner_.track.getStatus() != JASTrack::STATUS_RUN);
@@ -67,8 +61,6 @@ void JAISe::startTrack_(const JASSoundParams& params) {
inner_.track.startSeq();
}
/* 8029F304-8029F4CC 299C44 01C8+00 0/0 1/1 0/0 .text
* JAISeCategoryMgr_mixOut___5JAISeFbRC14JASSoundParams16JAISoundActivity */
void JAISe::JAISeCategoryMgr_mixOut_(bool param_0, const JASSoundParams& params, JAISoundActivity activity) {
mixOut_(params);
if (isStopping()) {
@@ -104,7 +96,6 @@ void JAISe::JAISeCategoryMgr_mixOut_(bool param_0, const JASSoundParams& params,
}
}
/* 8029F4CC-8029F5C8 299E0C 00FC+00 0/0 1/1 0/0 .text JAISeCategoryMgr_calc___5JAISeFv */
void JAISe::JAISeCategoryMgr_calc_() {
prepare_();
@@ -122,7 +113,6 @@ void JAISe::JAISeCategoryMgr_calc_() {
}
}
/* 8029F5C8-8029F650 299F08 0088+00 2/1 0/0 0/0 .text JAISound_tryDie___5JAISeFv */
bool JAISe::JAISound_tryDie_() {
switch (inner_.track.getStatus()) {
case JASTrack::STATUS_FREE:
@@ -139,8 +129,6 @@ bool JAISe::JAISound_tryDie_() {
return false;
}
/* 8029F650-8029F6D8 299F90 0088+00 0/0 1/1 0/0 .text
* JAISeMgr_startID___5JAISeF10JAISoundIDPCQ29JGeometry8TVec3<f>P11JAIAudience */
void JAISe::JAISeMgr_startID_(JAISoundID id, const JGeometry::TVec3<f32>* posPtr, JAIAudience* audience) {
JUT_ASSERT(221, inner_.track.getStatus() == JASTrack::STATUS_FREE);
@@ -153,20 +141,16 @@ void JAISe::JAISeMgr_startID_(JAISoundID id, const JGeometry::TVec3<f32>* posPtr
}
}
/* 8029F6D8-8029F6E0 29A018 0008+00 2/1 0/0 0/0 .text getNumChild__5JAISeCFv */
s32 JAISe::getNumChild() const {
return 0;
}
/* 8029F6E0-8029F6E8 29A020 0008+00 2/1 0/0 0/0 .text getChild__5JAISeFi */
JAISoundChild* JAISe::getChild(int param_0) {
return NULL;
}
/* 8029F6E8-8029F6EC 29A028 0004+00 2/1 0/0 0/0 .text releaseChild__5JAISeFi */
void JAISe::releaseChild(int param_0) {}
/* 8029F6EC-8029F78C 29A02C 00A0+00 1/1 0/0 0/0 .text prepare_getSeqData___5JAISeFv */
bool JAISe::prepare_getSeqData_() {
JUT_ASSERT(271, inner_.track.getStatus() != JASTrack::STATUS_RUN);
JUT_ASSERT(272, inner_.seMgr);
@@ -189,7 +173,6 @@ bool JAISe::prepare_getSeqData_() {
return false;
}
/* 8029F78C-8029F84C 29A0CC 00C0+00 1/1 0/0 0/0 .text prepare___5JAISeFv */
void JAISe::prepare_() {
switch (status_.state.unk) {
case 6:
@@ -217,22 +200,18 @@ void JAISe::prepare_() {
}
}
/* 8029F84C-8029F854 29A18C 0008+00 2/1 0/0 0/0 .text getTrack__5JAISeFv */
JASTrack* JAISe::getTrack() {
return &inner_.track;
}
/* 8029F854-8029F864 29A194 0010+00 2/1 0/0 0/0 .text getChildTrack__5JAISeFi */
JASTrack* JAISe::getChildTrack(int param_0) {
return inner_.track.getChild(param_0);
}
/* 8029F864-8029F868 29A1A4 0004+00 2/1 0/0 0/0 .text asSe__5JAISeFv */
JAISe* JAISe::asSe() {
return this;
}
/* 8029F868-8029F870 29A1A8 0008+00 2/1 0/0 0/0 .text getTempoMgr__5JAISeFv */
JAITempoMgr* JAISe::getTempoMgr() {
return &inner_.mTempoMgr;
}
-37
View File
@@ -5,8 +5,6 @@
#include "JSystem/JAudio2/JAISoundInfo.h"
#include "JSystem/JAudio2/JASReport.h"
/* 8029F8B0-8029F91C 29A1F0 006C+00 2/1 0/0 0/0 .text
* isUsingSeqData__16JAISeCategoryMgrFRC16JAISeqDataRegion */
bool JAISeCategoryMgr::isUsingSeqData(const JAISeqDataRegion& seqDataRegion) {
JSULink<JAISe>* i = mSeList.getFirst();
while (i != NULL) {
@@ -20,8 +18,6 @@ bool JAISeCategoryMgr::isUsingSeqData(const JAISeqDataRegion& seqDataRegion) {
return false;
}
/* 8029F91C-8029F9C4 29A25C 00A8+00 2/1 0/0 0/0 .text
* releaseSeqData__16JAISeCategoryMgrFRC16JAISeqDataRegion */
int JAISeCategoryMgr::releaseSeqData(const JAISeqDataRegion& seqDataRegion) {
bool bVar1 = false;
for (JSULink<JAISe>* i = mSeList.getFirst(); i != NULL; i = i->getNext()) {
@@ -35,7 +31,6 @@ int JAISeCategoryMgr::releaseSeqData(const JAISeqDataRegion& seqDataRegion) {
return bVar1 ? _1 : _2;
}
/* 8029F9C4-8029FB30 29A304 016C+00 1/1 0/0 0/0 .text JAISeMgr_calc___16JAISeCategoryMgrFv */
void JAISeCategoryMgr::JAISeMgr_calc_() {
mParams.calc();
@@ -46,8 +41,6 @@ void JAISeCategoryMgr::JAISeMgr_calc_() {
sortByPriority_();
}
/* 8029FB30-8029FC34 29A470 0104+00 1/1 0/0 0/0 .text JAISeMgr_freeDeadSe___16JAISeCategoryMgrFv
*/
void JAISeCategoryMgr::JAISeMgr_freeDeadSe_() {
JSULink<JAISe>* i = mSeList.getFirst();
while (i != NULL) {
@@ -61,8 +54,6 @@ void JAISeCategoryMgr::JAISeMgr_freeDeadSe_() {
}
}
/* 8029FC88-8029FD40 29A5C8 00B8+00 1/1 0/0 0/0 .text
* JAISeMgr_acceptsNewSe___16JAISeCategoryMgrCFUl */
bool JAISeCategoryMgr::JAISeMgr_acceptsNewSe_(u32 priority) const {
s32 maxSe = getMaxSe();
if (maxSe <= 0) {
@@ -86,7 +77,6 @@ bool JAISeCategoryMgr::JAISeMgr_acceptsNewSe_(u32 priority) const {
}
}
/* 8029FD40-8029FDE0 29A680 00A0+00 1/1 0/0 0/0 .text sortByPriority___16JAISeCategoryMgrFv */
void JAISeCategoryMgr::sortByPriority_() {
for (u32 i = mSeList.getNumLinks(); i != 0; i--) {
JSULink<JAISe>* link = mSeList.getFirst();
@@ -110,22 +100,18 @@ void JAISeCategoryMgr::sortByPriority_() {
}
}
/* 8029FDE0-8029FE34 29A720 0054+00 0/0 1/1 0/0 .text stop__16JAISeCategoryMgrFUl */
void JAISeCategoryMgr::stop(u32 fadeTime) {
for (JSULink<JAISe>* i = mSeList.getFirst(); i != NULL; i = i->getNext()) {
i->getObject()->stop(fadeTime);
}
}
/* 8029FE34-8029FE78 29A774 0044+00 1/1 0/0 0/0 .text stop__16JAISeCategoryMgrFv */
void JAISeCategoryMgr::stop() {
for (JSULink<JAISe>* i = mSeList.getFirst(); i != NULL; i = i->getNext()) {
i->getObject()->stop();
}
}
/* 8029FE78-8029FEEC 29A7B8 0074+00 1/1 0/0 0/0 .text stopSoundID__16JAISeCategoryMgrF10JAISoundID
*/
void JAISeCategoryMgr::stopSoundID(JAISoundID id) {
if (!id.isAnonymous()) {
for (JSULink<JAISe>* i = mSeList.getFirst(); i != NULL; i = i->getNext()) {
@@ -136,15 +122,12 @@ void JAISeCategoryMgr::stopSoundID(JAISoundID id) {
}
}
/* 8029FEEC-8029FF18 29A82C 002C+00 0/0 2/2 0/0 .text pause__16JAISeCategoryMgrFb */
void JAISeCategoryMgr::pause(bool param_0) {
for (JSULink<JAISe>* i = mSeList.getFirst(); i != NULL; i = i->getNext()) {
i->getObject()->pause(param_0);
}
}
/* 8029FF18-802A0074 29A858 015C+00 1/1 0/0 0/0 .text
* JAISeMgr_mixOut___16JAISeCategoryMgrFRC18JAISoundParamsMove16JAISoundActivity */
void JAISeCategoryMgr::JAISeMgr_mixOut_(const JAISoundParamsMove& params,
JAISoundActivity activity) {
JASSoundParams mixParams;
@@ -174,7 +157,6 @@ void JAISeCategoryMgr::JAISeMgr_mixOut_(const JAISoundParamsMove& params,
}
}
/* 802A0074-802A0168 29A9B4 00F4+00 0/0 1/1 0/0 .text __ct__8JAISeMgrFb */
JAISeMgr::JAISeMgr(bool setInstance) : JASGlobalInstance<JAISeMgr>(setInstance) {
mAudience = NULL;
mSeqDataMgr = NULL;
@@ -183,8 +165,6 @@ JAISeMgr::JAISeMgr(bool setInstance) : JASGlobalInstance<JAISeMgr>(setInstance)
JAISoundActivity::init();
}
/* 802A0168-802A01D8 29AAA8 0070+00 1/0 0/0 0/0 .text
* isUsingSeqData__8JAISeMgrFRC16JAISeqDataRegion */
bool JAISeMgr::isUsingSeqData(const JAISeqDataRegion& seqDataRegion) {
for (int i = 0; i < 16; i++) {
if (mCategoryMgrs[i].JAISeCategoryMgr::isUsingSeqData(seqDataRegion)) {
@@ -194,8 +174,6 @@ bool JAISeMgr::isUsingSeqData(const JAISeqDataRegion& seqDataRegion) {
return false;
}
/* 802A01D8-802A0268 29AB18 0090+00 1/0 0/0 0/0 .text
* releaseSeqData__8JAISeMgrFRC16JAISeqDataRegion */
int JAISeMgr::releaseSeqData(const JAISeqDataRegion& seqDataRegion) {
bool r30 = 0;
for (int i = 0; i < 16; i++) {
@@ -211,8 +189,6 @@ int JAISeMgr::releaseSeqData(const JAISeqDataRegion& seqDataRegion) {
return (r30 != 0) ? 1 : 0;
}
/* 802A0268-802A02A0 29ABA8 0038+00 0/0 1/1 0/0 .text
* setCategoryArrangement__8JAISeMgrFRC24JAISeCategoryArrangement */
void JAISeMgr::setCategoryArrangement(const JAISeCategoryArrangement& arrangement) {
for (int i = 0; i < 16; i++) {
mCategoryMgrs[i].setMaxActiveSe(arrangement.mItems[i].mMaxActiveSe);
@@ -220,22 +196,18 @@ void JAISeMgr::setCategoryArrangement(const JAISeCategoryArrangement& arrangemen
}
}
/* 802A02A0-802A02F4 29ABE0 0054+00 0/0 1/1 0/0 .text stop__8JAISeMgrFv */
void JAISeMgr::stop() {
for (int i = 0; i < 16; i++) {
mCategoryMgrs[i].stop();
}
}
/* 802A02F4-802A0358 29AC34 0064+00 0/0 1/1 0/0 .text stopSoundID__8JAISeMgrF10JAISoundID
*/
void JAISeMgr::stopSoundID(JAISoundID id) {
for (int i = 0; i < 16; i++) {
mCategoryMgrs[i].stopSoundID(id);
}
}
/* 802A0358-802A03D8 29AC98 0080+00 0/0 1/1 0/0 .text initParams__8JAISeMgrFv */
void JAISeMgr::initParams() {
for (int i = 0; i < 16; i++) {
mCategoryMgrs[i].getParams()->init();
@@ -243,13 +215,11 @@ void JAISeMgr::initParams() {
}
/* 802A03D8-802A03E0 -00001 0008+00 0/0 0/0 0/0 .text setAudience__8JAISeMgrFP11JAIAudience */
void JAISeMgr::setAudience(JAIAudience* audience) {
JUT_ASSERT(363, ! isActive());
mAudience = audience;
}
/* 802A03E0-802A0434 29AD20 0054+00 0/0 1/1 0/0 .text setSeqDataMgr__8JAISeMgrFP13JAISeqDataMgr */
void JAISeMgr::setSeqDataMgr(JAISeqDataMgr* seqDataMgr) {
JUT_ASSERT(377, ! isActive());
resetSeqDataMgr();
@@ -257,7 +227,6 @@ void JAISeMgr::setSeqDataMgr(JAISeqDataMgr* seqDataMgr) {
mSeqDataMgr->setSeqDataUser(this);
}
/* 802A0434-802A0484 29AD74 0050+00 1/1 0/0 0/0 .text resetSeqDataMgr__8JAISeMgrFv */
void JAISeMgr::resetSeqDataMgr() {
if (mSeqDataMgr) {
mSeqDataMgr->setSeqDataUser(NULL);
@@ -265,7 +234,6 @@ void JAISeMgr::resetSeqDataMgr() {
}
}
/* 802A0484-802A0574 29ADC4 00F0+00 1/1 0/0 0/0 .text newSe___8JAISeMgrFiUl */
JAISe* JAISeMgr::newSe_(int category, u32 priority) {
JUT_ASSERT(396, category < NUM_CATEGORIES);
@@ -288,7 +256,6 @@ JAISe* JAISeMgr::newSe_(int category, u32 priority) {
return se;
}
/* 802A0574-802A0704 29AEB4 0190+00 0/0 1/1 0/0 .text calc__8JAISeMgrFv */
void JAISeMgr::calc() {
mParams.calc();
for (int i = 0; i < 16; i++) {
@@ -299,15 +266,12 @@ void JAISeMgr::calc() {
}
}
/* 802A0704-802A0768 29B044 0064+00 0/0 1/1 0/0 .text mixOut__8JAISeMgrFv */
void JAISeMgr::mixOut() {
for (int i = 0; i < 16; i++) {
mCategoryMgrs[i].JAISeMgr_mixOut_(mParams, *this);
}
}
/* 802A0768-802A08D0 29B0A8 0168+00 0/0 1/1 0/0 .text
* startSound__8JAISeMgrF10JAISoundIDP14JAISoundHandlePCQ29JGeometry8TVec3<f> */
bool JAISeMgr::startSound(JAISoundID id, JAISoundHandle* handle, const JGeometry::TVec3<f32>* posPtr) {
if (handle && *handle) {
(*handle)->stop();
@@ -346,7 +310,6 @@ bool JAISeMgr::startSound(JAISoundID id, JAISoundHandle* handle, const JGeometry
return true;
}
/* 802A08D0-802A08FC 29B210 002C+00 0/0 2/2 0/0 .text getNumActiveSe__8JAISeMgrCFv */
int JAISeMgr::getNumActiveSe() const {
int num = 0;
for (int i = 0; i < 16; i++) {
-27
View File
@@ -8,8 +8,6 @@
namespace {
/* 802A0A6C-802A0A8C 29B3AC 0020+00 1/1 0/0 0/0 .text
* JASTrack_isFreeOrStopped__20@unnamed@JAISeq_cpp@FP8JASTrack */
static bool JASTrack_isFreeOrStopped(JASTrack* track) {
u32 status = track->getStatus();
return status == JASTrack::STATUS_FREE || status == JASTrack::STATUS_STOP;
@@ -17,8 +15,6 @@ static bool JASTrack_isFreeOrStopped(JASTrack* track) {
} // namespace
/* 802A0A8C-802A0B64 29B3CC 00D8+00 0/0 2/1 0/0 .text
* __ct__6JAISeqFP9JAISeqMgrP28JAISoundStrategyMgr<6JAISeq> */
JAISeq::JAISeq(JAISeqMgr* seqMgr, JAISoundStrategyMgr<JAISeq>* soundStrategyMgr) : JSULink<JAISeq>(this) {
inner_.seqMgr = seqMgr;
inner_.strategyMgr = soundStrategyMgr;
@@ -28,8 +24,6 @@ JAISeq::JAISeq(JAISeqMgr* seqMgr, JAISoundStrategyMgr<JAISeq>* soundStrategyMgr)
}
}
/* 802A0B64-802A0C04 29B4A4 00A0+00 0/0 1/1 0/0 .text
* JAISeqMgr_startID___6JAISeqF10JAISoundIDPCQ29JGeometry8TVec3<f>P11JAIAudienceii */
void JAISeq::JAISeqMgr_startID_(JAISoundID id, const JGeometry::TVec3<f32>* posPtr,
JAIAudience* audience, int category, int param_4) {
inner_.field_0x39c = category;
@@ -43,8 +37,6 @@ void JAISeq::JAISeqMgr_startID_(JAISoundID id, const JGeometry::TVec3<f32>* posP
}
}
/* 802A0C04-802A0CA4 29B544 00A0+00 1/1 0/0 0/0 .text
* playSeqData___6JAISeqFRC14JASSoundParams16JAISoundActivity */
void JAISeq::playSeqData_(const JASSoundParams& params, JAISoundActivity activity) {
JUT_ASSERT(72, JASTrack_isFreeOrStopped( & inner_.outputTrack ));
@@ -60,7 +52,6 @@ void JAISeq::playSeqData_(const JASSoundParams& params, JAISoundActivity activit
inner_.outputTrack.startSeq();
}
/* 802A0CA4-802A0E48 29B5E4 01A4+00 1/1 0/0 0/0 .text reserveChildTracks___6JAISeqFi */
void JAISeq::reserveChildTracks_(int param_0) {
JUT_ASSERT(92, inner_.outputTrack.getStatus() == JASTrack::STATUS_FREE);
@@ -90,7 +81,6 @@ void JAISeq::reserveChildTracks_(int param_0) {
}
}
/* 802A0E48-802A0EDC 29B788 0094+00 1/1 0/0 0/0 .text releaseChildTracks___6JAISeqFv */
void JAISeq::releaseChildTracks_() {
for (u32 i = 0; i < 2; i++) {
JASTrack* track = inner_.outputTrack.getChild(i);
@@ -106,7 +96,6 @@ void JAISeq::releaseChildTracks_() {
}
}
/* 802A0EDC-802A0F90 29B81C 00B4+00 1/1 0/0 0/0 .text prepare_getSeqData___6JAISeqFv */
bool JAISeq::prepare_getSeqData_() {
JAISoundID id(soundID_); // fakematch, should be using getID but it messes up stack
if (id.isAnonymous()) {
@@ -131,8 +120,6 @@ bool JAISeq::prepare_getSeqData_() {
return false;
}
/* 802A0F90-802A108C 29B8D0 00FC+00 2/1 0/0 0/0 .text
* prepare___6JAISeqFRC14JASSoundParams16JAISoundActivity */
bool JAISeq::prepare_(const JASSoundParams& params, JAISoundActivity activity) {
switch (status_.state.unk) {
case 6:
@@ -164,7 +151,6 @@ bool JAISeq::prepare_(const JASSoundParams& params, JAISoundActivity activity) {
return false;
}
/* 802A108C-802A1180 29B9CC 00F4+00 0/0 1/1 0/0 .text JAISeqMgr_calc___6JAISeqFv */
void JAISeq::JAISeqMgr_calc_() {
if (inner_.outputTrack.getStatus() == JASTrack::STATUS_STOP || (inner_.outputTrack.getStatus() == JASTrack::STATUS_FREE && status_.state.unk == 2)) {
die_();
@@ -184,7 +170,6 @@ void JAISeq::JAISeqMgr_calc_() {
}
}
/* 802A1180-802A1268 29BAC0 00E8+00 2/2 0/0 0/0 .text die___6JAISeqFv */
void JAISeq::die_() {
JUT_ASSERT(269, JASTrack_isFreeOrStopped( & inner_.outputTrack ));
@@ -205,7 +190,6 @@ void JAISeq::die_() {
die_JAISound_();
}
/* 802A12BC-802A1348 29BBFC 008C+00 1/0 0/0 0/0 .text JAISound_tryDie___6JAISeqFv */
bool JAISeq::JAISound_tryDie_() {
if (JASTrack_isFreeOrStopped(&inner_.outputTrack)) {
die_();
@@ -223,8 +207,6 @@ bool JAISeq::JAISound_tryDie_() {
return false;
}
/* 802A1348-802A14FC 29BC88 01B4+00 2/2 0/0 0/0 .text
* mixOut___6JAISeqFRC14JASSoundParams16JAISoundActivity */
void JAISeq::mixOut_(const JASSoundParams& params, JAISoundActivity activity) {
inner_.outputTrack.setTempoRate(inner_.mTempoMgr.getTempo());
inner_.outputTrack.mute(activity.field_0x0.flags.flag1 || status_.isMute());
@@ -255,20 +237,16 @@ void JAISeq::mixOut_(const JASSoundParams& params, JAISoundActivity activity) {
}
}
/* 802A14FC-802A1570 29BE3C 0074+00 0/0 1/1 0/0 .text
* JAISeqMgr_mixOut___6JAISeqFRC14JASSoundParams16JAISoundActivity */
void JAISeq::JAISeqMgr_mixOut_(const JASSoundParams& params, JAISoundActivity activity) {
if (prepare_(params, activity) && inner_.outputTrack.getStatus() == JASTrack::STATUS_RUN) {
mixOut_(params, activity);
}
}
/* 802A1570-802A1578 29BEB0 0008+00 1/0 0/0 0/0 .text getNumChild__6JAISeqCFv */
s32 JAISeq::getNumChild() const {
return NUM_CHILDREN;
}
/* 802A1578-802A165C 29BEB8 00E4+00 1/0 0/0 0/0 .text getChild__6JAISeqFi */
JAISoundChild* JAISeq::getChild(int index) {
JUT_ASSERT(371, status_.isAlive());
JUT_ASSERT(372, index >= 0);
@@ -288,7 +266,6 @@ JAISoundChild* JAISeq::getChild(int index) {
}
/* 802A165C-802A1728 29BF9C 00CC+00 1/0 0/0 0/0 .text releaseChild__6JAISeqFi */
void JAISeq::releaseChild(int index) {
if (inner_.outputTrack.getStatus() == JASTrack::STATUS_RUN && inner_.mSoundChild[index]) {
JASTrack* track = getChildTrack(index);
@@ -300,12 +277,10 @@ void JAISeq::releaseChild(int index) {
}
}
/* 802A1728-802A1730 29C068 0008+00 1/0 0/0 0/0 .text getTrack__6JAISeqFv */
JASTrack* JAISeq::getTrack() {
return &inner_.outputTrack;
}
/* 802A1730-802A1768 29C070 0038+00 2/1 0/0 0/0 .text getChildTrack__6JAISeqFi */
JASTrack* JAISeq::getChildTrack(int param_0) {
u32 index = u32(param_0) >> 4;
JASTrack* track = inner_.outputTrack.getChild(index);
@@ -319,12 +294,10 @@ JASTrack* JAISeq::getChildTrack(int param_0) {
return NULL;
}
/* 802A1768-802A176C 29C0A8 0004+00 1/0 0/0 0/0 .text asSeq__6JAISeqFv */
JAISeq* JAISeq::asSeq() {
return this;
}
/* 802A176C-802A1774 29C0AC 0008+00 1/0 0/0 0/0 .text getTempoMgr__6JAISeqFv */
JAITempoMgr* JAISeq::getTempoMgr() {
return &inner_.mTempoMgr;
}
-16
View File
@@ -5,8 +5,6 @@
#include "JSystem/JAudio2/JAISoundHandles.h"
#include "JSystem/JAudio2/JAISoundInfo.h"
/* 802A1804-802A1870 29C144 006C+00 1/0 0/0 0/0 .text
* isUsingSeqData__9JAISeqMgrFRC16JAISeqDataRegion */
bool JAISeqMgr::isUsingSeqData(const JAISeqDataRegion& seqDataRegion) {
for (JSULink<JAISeq>* i = mSeqList.getFirst(); i != NULL; i = i->getNext()) {
if (seqDataRegion.intersects(i->getObject()->getSeqData())) {
@@ -16,8 +14,6 @@ bool JAISeqMgr::isUsingSeqData(const JAISeqDataRegion& seqDataRegion) {
return false;
}
/* 802A1870-802A1914 29C1B0 00A4+00 1/0 0/0 0/0 .text
* releaseSeqData__9JAISeqMgrFRC16JAISeqDataRegion */
int JAISeqMgr::releaseSeqData(const JAISeqDataRegion& seqDataRegion) {
bool bVar1 = false;
for (JSULink<JAISeq>* i = mSeqList.getFirst(); i != NULL; i = i->getNext()) {
@@ -30,7 +26,6 @@ int JAISeqMgr::releaseSeqData(const JAISeqDataRegion& seqDataRegion) {
return bVar1 ? RELEASE_SEQ_1 : RELEASE_SEQ_2;
}
/* 802A1914-802A1A08 29C254 00F4+00 0/0 1/1 0/0 .text __ct__9JAISeqMgrFb */
JAISeqMgr::JAISeqMgr(bool setInstance) : JASGlobalInstance<JAISeqMgr>(setInstance), mAudience(NULL) {
seqDataMgr_ = NULL;
field_0x10 = NULL;
@@ -39,7 +34,6 @@ JAISeqMgr::JAISeqMgr(bool setInstance) : JASGlobalInstance<JAISeqMgr>(setInstanc
mActivity.init();
}
/* 802A1A08-802A1AF4 29C348 00EC+00 1/1 0/0 0/0 .text freeDeadSeq___9JAISeqMgrFv */
void JAISeqMgr::freeDeadSeq_() {
JSULink<JAISeq>* i = mSeqList.getFirst();
while (i != NULL) {
@@ -53,8 +47,6 @@ void JAISeqMgr::freeDeadSeq_() {
}
}
/* 802A1B48-802A1C90 29C488 0148+00 0/0 1/1 0/0 .text
* startSound__9JAISeqMgrF10JAISoundIDP14JAISoundHandlePCQ29JGeometry8TVec3<f> */
bool JAISeqMgr::startSound(JAISoundID id, JAISoundHandle* handle, const JGeometry::TVec3<f32>* posPtr) {
if (handle != NULL && *handle) {
(*handle)->stop();
@@ -83,7 +75,6 @@ bool JAISeqMgr::startSound(JAISoundID id, JAISoundHandle* handle, const JGeometr
return false;
}
/* 802A1C90-802A1DFC 29C5D0 016C+00 0/0 4/4 0/0 .text calc__9JAISeqMgrFv */
void JAISeqMgr::calc() {
mMove.calc();
@@ -94,7 +85,6 @@ void JAISeqMgr::calc() {
freeDeadSeq_();
}
/* 802A1DFC-802A1E3C 29C73C 0040+00 0/0 1/1 0/0 .text stop__9JAISeqMgrFv */
void JAISeqMgr::stop() {
JSULink<JAISeq>* i;
for (i = mSeqList.getFirst(); i != NULL; i = i->getNext()) {
@@ -102,7 +92,6 @@ void JAISeqMgr::stop() {
}
}
/* 802A1E3C-802A1E8C 29C77C 0050+00 0/0 1/1 0/0 .text stop__9JAISeqMgrFUl */
void JAISeqMgr::stop(u32 fadeTime) {
JSULink<JAISeq>* i;
for (i = mSeqList.getFirst(); i != NULL; i = i->getNext()) {
@@ -110,7 +99,6 @@ void JAISeqMgr::stop(u32 fadeTime) {
}
}
/* 802A1E8C-802A1EFC 29C7CC 0070+00 0/0 1/1 0/0 .text stopSoundID__9JAISeqMgrF10JAISoundID */
void JAISeqMgr::stopSoundID(JAISoundID id) {
JSULink<JAISeq>* i;
if (!id.isAnonymous()) {
@@ -122,7 +110,6 @@ void JAISeqMgr::stopSoundID(JAISoundID id) {
}
}
/* 802A1EFC-802A1F58 29C83C 005C+00 0/0 4/4 0/0 .text mixOut__9JAISeqMgrFv */
void JAISeqMgr::mixOut() {
JSULink<JAISeq>* i;
for (i = mSeqList.getFirst(); i != NULL; i = i->getNext()) {
@@ -130,7 +117,6 @@ void JAISeqMgr::mixOut() {
}
}
/* 802A1F58-802A1FE8 29C898 0090+00 1/1 0/0 0/0 .text beginStartSeq___9JAISeqMgrFv */
JAISeq* JAISeqMgr::beginStartSeq_() {
JAISeq* seq = new JAISeq(this, field_0x10);
if (seq == NULL) {
@@ -139,8 +125,6 @@ JAISeq* JAISeqMgr::beginStartSeq_() {
return seq;
}
/* 802A1FE8-802A20F0 29C928 0108+00 1/1 0/0 0/0 .text
* endStartSeq___9JAISeqMgrFP6JAISeqP14JAISoundHandle */
bool JAISeqMgr::endStartSeq_(JAISeq* seq, JAISoundHandle* handle) {
JAISeq* sound = seq->getObject();
if (sound != NULL) {
-25
View File
@@ -6,8 +6,6 @@
#include "JSystem/JAudio2/JASReport.h"
#include "JSystem/JAudio2/JASTrack.h"
/* 802A2184-802A21A0 29CAC4 001C+00 0/0 14/14 0/0 .text releaseSound__14JAISoundHandleFv
*/
void JAISoundHandle::releaseSound() {
if (sound_ != NULL) {
sound_->handle_ = NULL;
@@ -15,7 +13,6 @@ void JAISoundHandle::releaseSound() {
}
}
/* 802A21A0-802A21BC 29CAE0 001C+00 3/3 3/3 0/0 .text releaseHandle__8JAISoundFv */
void JAISound::releaseHandle() {
if (handle_ != NULL) {
handle_->sound_ = NULL;
@@ -23,7 +20,6 @@ void JAISound::releaseHandle() {
}
}
/* 802A21BC-802A2220 29CAFC 0064+00 0/0 3/3 0/0 .text attachHandle__8JAISoundFP14JAISoundHandle */
void JAISound::attachHandle(JAISoundHandle* handle) {
JUT_ASSERT(55, handle);
@@ -37,7 +33,6 @@ void JAISound::attachHandle(JAISoundHandle* handle) {
handle_->sound_ = this;
}
/* 802A2220-802A2244 29CB60 0024+00 0/0 2/2 0/0 .text lockWhenPrepared__15JAISoundStatus_Fv */
s32 JAISoundStatus_::lockWhenPrepared() {
if (state.unk == 0) {
state.unk = 1;
@@ -46,8 +41,6 @@ s32 JAISoundStatus_::lockWhenPrepared() {
return 0;
}
/* 802A2244-802A2280 29CB84 003C+00 0/0 2/2 0/0 .text unlockIfLocked__15JAISoundStatus_Fv
*/
s32 JAISoundStatus_::unlockIfLocked() {
if (state.unk == 3) {
state.unk = 4;
@@ -60,8 +53,6 @@ s32 JAISoundStatus_::unlockIfLocked() {
return 0;
}
/* 802A2280-802A22F8 29CBC0 0078+00 0/0 4/4 0/0 .text
* mixOutAll__14JAISoundParamsFRC14JASSoundParamsP14JASSoundParamsf */
void JAISoundParams::mixOutAll(const JASSoundParams& inParams, JASSoundParams* outParams, f32 param_2) {
outParams->mVolume = move_.params_.mVolume * (inParams.mVolume * property_.field_0x0) * param_2;
outParams->mFxMix = move_.params_.mFxMix + (inParams.mFxMix + property_.field_0x4);
@@ -70,11 +61,8 @@ void JAISoundParams::mixOutAll(const JASSoundParams& inParams, JASSoundParams* o
outParams->mDolby = inParams.mDolby + move_.params_.mDolby;
}
/* 802A22F8-802A2328 29CC38 0030+00 0/0 3/3 0/0 .text __ct__8JAISoundFv */
JAISound::JAISound() : params_() {}
/* 802A2328-802A244C 29CC68 0124+00 0/0 3/3 0/0 .text
* start_JAISound___8JAISoundF10JAISoundIDPCQ29JGeometry8TVec3<f>P11JAIAudience */
void JAISound::start_JAISound_(JAISoundID id, const JGeometry::TVec3<f32>* posPtr, JAIAudience* audience) {
handle_ = NULL;
soundID_ = id;
@@ -94,7 +82,6 @@ void JAISound::start_JAISound_(JAISoundID id, const JGeometry::TVec3<f32>* posPt
priority_ = 0;
}
/* 802A244C-802A2474 29CD8C 0028+00 0/0 2/2 0/0 .text acceptsNewAudible__8JAISoundCFv */
bool JAISound::acceptsNewAudible() const {
bool accepts = false;
if (audible_ == NULL && status_.state.flags.calcedOnce == 0) {
@@ -103,8 +90,6 @@ bool JAISound::acceptsNewAudible() const {
return accepts;
}
/* 802A2474-802A24DC 29CDB4 0068+00 0/0 2/2 0/0 .text
/* * newAudible__8JAISoundFRCQ29JGeometry8TVec3<f>PCQ29JGeometry8TVec3<f>UlP11JAIAudience */
void JAISound::newAudible(const JGeometry::TVec3<f32>& pos,
const JGeometry::TVec3<f32>* param_1, u32 param_2, JAIAudience* audience) {
JUT_ASSERT(151, acceptsNewAudible());
@@ -116,7 +101,6 @@ void JAISound::newAudible(const JGeometry::TVec3<f32>& pos,
audible_ = audience_->newAudible(pos, soundID_, param_1, param_2);
}
/* 802A24DC-802A2598 29CE1C 00BC+00 0/0 24/24 0/0 .text stop__8JAISoundFUl */
void JAISound::stop(u32 fadeTime) {
JUT_ASSERT(164, status_.isAlive());
if (fadeTime == 0) {
@@ -129,28 +113,23 @@ void JAISound::stop(u32 fadeTime) {
}
}
/* 802A2598-802A25D8 29CED8 0040+00 2/2 21/21 0/0 .text stop__8JAISoundFv */
void JAISound::stop() {
stop_JAISound_();
releaseHandle();
}
/* 802A25D8-802A25E0 29CF18 0008+00 1/0 2/0 0/0 .text asSe__8JAISoundFv */
JAISe* JAISound::asSe() {
return NULL;
}
/* 802A25E0-802A25E8 29CF20 0008+00 1/0 2/0 0/0 .text asSeq__8JAISoundFv */
JAISeq* JAISound::asSeq() {
return NULL;
}
/* 802A25E8-802A25F0 29CF28 0008+00 1/0 2/0 0/0 .text asStream__8JAISoundFv */
JAIStream* JAISound::asStream() {
return NULL;
}
/* 802A25F0-802A266C 29CF30 007C+00 0/0 3/3 0/0 .text die_JAISound___8JAISoundFv */
void JAISound::die_JAISound_() {
if (audible_ != NULL) {
audience_->deleteAudible(audible_);
@@ -162,8 +141,6 @@ void JAISound::die_JAISound_() {
status_.state.unk = 6;
}
/* 802A266C-802A26B8 29CFAC 004C+00 0/0 3/3 0/0 .text increasePrepareCount_JAISound___8JAISoundFv
*/
void JAISound::increasePrepareCount_JAISound_() {
if ((++prepareCount_ & 0xFF) == 0) {
JASReport("It cost %d steps to prepare Sound(ID:%08x, Address%08x).\n", prepareCount_,
@@ -171,7 +148,6 @@ void JAISound::increasePrepareCount_JAISound_() {
}
}
/* 802A26B8-802A29DC 29CFF8 0324+00 0/0 3/3 0/0 .text calc_JAISound___8JAISoundFv */
bool JAISound::calc_JAISound_() {
status_.state.flags.calcedOnce = 1;
if (isStopping() && JAISound_tryDie_()) {
@@ -215,7 +191,6 @@ bool JAISound::calc_JAISound_() {
return playing;
}
/* 802A29DC-802A2AB0 29D31C 00D4+00 0/0 2/2 0/0 .text initTrack_JAISound___8JAISoundFP8JASTrack */
void JAISound::initTrack_JAISound_(JASTrack* track) {
JASSoundParams* soundParams[JASTrack::TChannelMgr::CHANNEL_MAX];
JUT_ASSERT(286, audience_);
-4
View File
@@ -2,8 +2,6 @@
#include "JSystem/JAudio2/JAISoundHandles.h"
/* 802A2C98-802A2CF4 29D5D8 005C+00 0/0 1/1 0/0 .text
* getHandleSoundID__15JAISoundHandlesF10JAISoundID */
JAISoundHandle* JAISoundHandles::getHandleSoundID(JAISoundID id) {
for (int i = 0; i < numHandles_; i++) {
if (handle_[i].isSoundAttached()) {
@@ -16,8 +14,6 @@ JAISoundHandle* JAISoundHandles::getHandleSoundID(JAISoundID id) {
return NULL;
}
/* 802A2CF4-802A2D34 29D634 0040+00 0/0 2/2 0/0 .text getFreeHandle__15JAISoundHandlesFv
*/
JAISoundHandle* JAISoundHandles::getFreeHandle() {
for (int i = 0; i < numHandles_; i++) {
if (!handle_[i].isSoundAttached()) {
-2
View File
@@ -2,10 +2,8 @@
#include "JSystem/JAudio2/JAISoundInfo.h"
/* 802A2D34-802A2D50 29D674 001C+00 0/0 1/1 0/0 .text __ct__12JAISoundInfoFb */
JAISoundInfo::JAISoundInfo(bool setInstance) : JASGlobalInstance<JAISoundInfo>(setInstance) {}
/* 802A2D50-802A2DB4 29D690 0064+00 1/0 2/2 0/0 .text __dt__12JAISoundInfoFv */
JAISoundInfo::~JAISoundInfo() {
JUT_ASSERT(14, false);
}
-4
View File
@@ -3,15 +3,11 @@
#include "JSystem/JAudio2/JAISoundStarter.h"
#include "JSystem/JAudio2/JAISoundHandles.h"
/* 802A2F6C-802A2F88 29D8AC 001C+00 0/0 1/1 0/0 .text __ct__15JAISoundStarterFb */
JAISoundStarter::JAISoundStarter(bool setInstance) :
JASGlobalInstance<JAISoundStarter>(setInstance) {}
/* 802A2F88-802A2FEC 29D8C8 0064+00 1/0 7/7 0/0 .text __dt__15JAISoundStarterFv */
JAISoundStarter::~JAISoundStarter() {}
/* 802A2FEC-802A30D4 29D92C 00E8+00 0/0 4/4 0/0 .text
* startLevelSound__15JAISoundStarterF10JAISoundIDP14JAISoundHandlePCQ29JGeometry8TVec3<f> */
bool JAISoundStarter::startLevelSound(JAISoundID id, JAISoundHandle* handlePtr, const JGeometry::TVec3<f32>* posPtr) {
JUT_ASSERT(20, handlePtr);
if (*handlePtr) {
-22
View File
@@ -6,8 +6,6 @@
#include "JSystem/JAudio2/JAIStreamDataMgr.h"
#include "JSystem/JAudio2/JAIAudience.h"
/* 802A30D4-802A3104 29DA14 0030+00 1/1 0/0 0/0 .text
* JAIStream_JASAramStreamCallback___FUlP13JASAramStreamPv */
static void JAIStream_JASAramStreamCallback_(u32 type, JASAramStream* aramStream, void* userData) {
JAIStream* stream = (JAIStream*)userData;
@@ -21,8 +19,6 @@ static void JAIStream_JASAramStreamCallback_(u32 type, JASAramStream* aramStream
}
}
/* 802A3104-802A319C 29DA44 0098+00 0/0 1/1 0/0 .text
* __ct__9JAIStreamFP12JAIStreamMgrP31JAISoundStrategyMgr<9JAIStream> */
JAIStream::JAIStream(JAIStreamMgr* streamMgr, JAISoundStrategyMgr<JAIStream>* soundStrategyMgr) : JSULink<JAIStream>(this) {
field_0x290 = 0;
field_0x2c0 = soundStrategyMgr;
@@ -36,8 +32,6 @@ JAIStream::JAIStream(JAIStreamMgr* streamMgr, JAISoundStrategyMgr<JAIStream>* so
}
}
/* 802A319C-802A3230 29DADC 0094+00 0/0 1/1 0/0 .text
* JAIStreamMgr_startID___9JAIStreamF10JAISoundIDlPCQ29JGeometry8TVec3<f>P11JAIAudiencei */
void JAIStream::JAIStreamMgr_startID_(JAISoundID id, s32 streamFileEntry,
const JGeometry::TVec3<f32>* posPtr, JAIAudience* audience,
int category) {
@@ -53,7 +47,6 @@ void JAIStream::JAIStreamMgr_startID_(JAISoundID id, s32 streamFileEntry,
}
}
/* 802A3230-802A33F4 29DB70 01C4+00 1/1 0/0 0/0 .text prepare_prepareStream___9JAIStreamFv */
bool JAIStream::prepare_prepareStream_() {
u32 local_28;
JAIStreamAramMgr* streamAramMgr;
@@ -106,7 +99,6 @@ bool JAIStream::prepare_prepareStream_() {
return false;
}
/* 802A33F4-802A3498 29DD34 00A4+00 1/1 0/0 0/0 .text prepare___9JAIStreamFv */
void JAIStream::prepare_() {
if (field_0x2c6 != 0) {
return;
@@ -136,8 +128,6 @@ void JAIStream::prepare_() {
}
}
/* 802A3498-802A34E4 29DDD8 004C+00 1/1 0/0 0/0 .text prepare_startStream___9JAIStreamFv
*/
void JAIStream::prepare_startStream_() {
if (inner_.aramStream_.start()) {
field_0x2c6 = 0;
@@ -146,8 +136,6 @@ void JAIStream::prepare_startStream_() {
}
}
/* 802A34E4-802A3720 29DE24 023C+00 0/0 1/1 0/0 .text
* JAIStreamMgr_mixOut___9JAIStreamFRC14JASSoundParams16JAISoundActivity */
void JAIStream::JAIStreamMgr_mixOut_(const JASSoundParams& inParams, JAISoundActivity activity) {
bool local_54;
JASSoundParams outParams;
@@ -195,7 +183,6 @@ void JAIStream::JAIStreamMgr_mixOut_(const JASSoundParams& inParams, JAISoundAct
}
}
/* 802A3720-802A37FC 29E060 00DC+00 1/1 0/0 0/0 .text die_JAIStream___9JAIStreamFv */
void JAIStream::die_JAIStream_() {
die_JAISound_();
@@ -212,7 +199,6 @@ void JAIStream::die_JAIStream_() {
}
}
/* 802A37FC-802A388C 29E13C 0090+00 1/0 0/0 0/0 .text JAISound_tryDie___9JAIStreamFv */
bool JAIStream::JAISound_tryDie_() {
if (field_0x2c6) {
die_JAIStream_();
@@ -238,7 +224,6 @@ bool JAIStream::JAISound_tryDie_() {
return false;
}
/* 802A388C-802A3948 29E1CC 00BC+00 0/0 1/1 0/0 .text JAIStreamMgr_calc___9JAIStreamFv */
void JAIStream::JAIStreamMgr_calc_() {
if (field_0x2c6 != 0) {
field_0x290 = 0;
@@ -258,12 +243,10 @@ void JAIStream::JAIStreamMgr_calc_() {
}
}
/* 802A3948-802A3950 29E288 0008+00 1/0 0/0 0/0 .text getNumChild__9JAIStreamCFv */
s32 JAIStream::getNumChild() const {
return NUM_CHILDREN;
}
/* 802A3950-802A3A24 29E290 00D4+00 1/0 0/0 0/0 .text getChild__9JAIStreamFi */
JAISoundChild* JAIStream::getChild(int index) {
if (children_[index] == NULL) {
children_[index] = new JAISoundChild();
@@ -274,7 +257,6 @@ JAISoundChild* JAIStream::getChild(int index) {
return children_[index];
}
/* 802A3A24-802A3ABC 29E364 0098+00 1/0 0/0 0/0 .text releaseChild__9JAIStreamFi */
void JAIStream::releaseChild(int index) {
if (children_[index] != NULL) {
delete children_[index];
@@ -282,22 +264,18 @@ void JAIStream::releaseChild(int index) {
}
}
/* 802A3ABC-802A3AC4 29E3FC 0008+00 1/0 0/0 0/0 .text getTrack__9JAIStreamFv */
JASTrack* JAIStream::getTrack() {
return NULL;
}
/* 802A3AC4-802A3ACC 29E404 0008+00 1/0 0/0 0/0 .text getChildTrack__9JAIStreamFi */
JASTrack* JAIStream::getChildTrack(int param_0) {
return NULL;
}
/* 802A3ACC-802A3AD0 29E40C 0004+00 1/0 0/0 0/0 .text asStream__9JAIStreamFv */
JAIStream* JAIStream::asStream() {
return this;
}
/* 802A3AD0-802A3AD8 29E410 0008+00 1/0 0/0 0/0 .text getTempoMgr__9JAIStreamFv */
JAITempoMgr* JAIStream::getTempoMgr() {
return NULL;
}
-11
View File
@@ -5,7 +5,6 @@
#include "JSystem/JAudio2/JAIStreamDataMgr.h"
#include "JSystem/JAudio2/JAISoundInfo.h"
/* 802A3B68-802A3C3C 29E4A8 00D4+00 0/0 1/1 0/0 .text __ct__12JAIStreamMgrFb */
JAIStreamMgr::JAIStreamMgr(bool setInstance) : JASGlobalInstance<JAIStreamMgr>(setInstance) {
streamDataMgr_ = NULL;
mStreamAramMgr = NULL;
@@ -15,8 +14,6 @@ JAIStreamMgr::JAIStreamMgr(bool setInstance) : JASGlobalInstance<JAIStreamMgr>(s
mActivity.init();
}
/* 802A3C3C-802A3D70 29E57C 0134+00 0/0 1/1 0/0 .text
* startSound__12JAIStreamMgrF10JAISoundIDP14JAISoundHandlePCQ29JGeometry8TVec3<f> */
bool JAIStreamMgr::startSound(JAISoundID id, JAISoundHandle* handle, const JGeometry::TVec3<f32>* posPtr) {
JUT_ASSERT(37, streamDataMgr_);
if (handle != NULL && *handle) {
@@ -53,8 +50,6 @@ bool JAIStreamMgr::startSound(JAISoundID id, JAISoundHandle* handle, const JGeom
return false;
}
/* 802A3D70-802A3E68 29E6B0 00F8+00 1/1 0/0 0/0 .text freeDeadStream___12JAIStreamMgrFv
*/
void JAIStreamMgr::freeDeadStream_() {
JSULink<JAIStream>* i = mStreamList.getFirst();
while (i != NULL) {
@@ -74,7 +69,6 @@ void JAIStreamMgr::freeDeadStream_() {
}
}
/* 802A3EBC-802A4028 29E7FC 016C+00 0/0 1/1 0/0 .text calc__12JAIStreamMgrFv */
void JAIStreamMgr::calc() {
JSULink<JAIStream>* i;
mParams.calc();
@@ -84,7 +78,6 @@ void JAIStreamMgr::calc() {
freeDeadStream_();
}
/* 802A4028-802A4068 29E968 0040+00 0/0 1/1 0/0 .text stop__12JAIStreamMgrFv */
void JAIStreamMgr::stop() {
JSULink<JAIStream>* i;
for (i = mStreamList.getFirst(); i != NULL; i = i->getNext()) {
@@ -92,7 +85,6 @@ void JAIStreamMgr::stop() {
}
}
/* 802A4068-802A40B8 29E9A8 0050+00 0/0 2/2 0/0 .text stop__12JAIStreamMgrFUl */
void JAIStreamMgr::stop(u32 fadeTime) {
JSULink<JAIStream>* i;
for (i = mStreamList.getFirst(); i != NULL; i = i->getNext()) {
@@ -100,7 +92,6 @@ void JAIStreamMgr::stop(u32 fadeTime) {
}
}
/* 802A40B8-802A4118 29E9F8 0060+00 0/0 1/1 0/0 .text stopSoundID__12JAIStreamMgrF10JAISoundID */
void JAIStreamMgr::stopSoundID(JAISoundID id) {
JSULink<JAIStream>* i;
for (i = mStreamList.getFirst(); i != NULL; i = i->getNext()) {
@@ -110,7 +101,6 @@ void JAIStreamMgr::stopSoundID(JAISoundID id) {
}
}
/* 802A4118-802A4174 29EA58 005C+00 0/0 1/1 0/0 .text mixOut__12JAIStreamMgrFv */
void JAIStreamMgr::mixOut() {
JSULink<JAIStream>* i;
for (i = mStreamList.getFirst(); i != NULL; i = i->getNext()) {
@@ -118,7 +108,6 @@ void JAIStreamMgr::mixOut() {
}
}
/* 802A4174-802A4244 29EAB4 00D0+00 1/1 0/0 0/0 .text newStream___12JAIStreamMgrFv */
JAIStream* JAIStreamMgr::newStream_() {
if (mStreamAramMgr == NULL) {
JUT_WARN(229, "%s", "JAIStreamAramMgr must be set.\n");
-41
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: JASAiCtrl
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASAiCtrl.h"
@@ -23,49 +18,34 @@
#include <dolphin/os.h>
#include <stdint.h>
/* 80431C58-80431C68 05E978 000C+04 2/2 0/0 0/0 .bss sDmaDacBuffer__9JASDriver */
s16* JASDriver::sDmaDacBuffer[3];
/* 804507A8-804507AC 000228 0004+00 3/3 0/0 0/0 .sdata None */
static u8 data_804507A8 = 3;
/* 804512A0-804512A4 0007A0 0004+00 3/3 0/0 0/0 .sbss sDspDacBuffer__9JASDriver */
s16** JASDriver::sDspDacBuffer;
/* 804512A4-804512A8 0007A4 0004+00 3/3 0/0 0/0 .sbss sDspDacWriteBuffer__9JASDriver */
s32 JASDriver::sDspDacWriteBuffer;
/* 804512A8-804512AC 0007A8 0004+00 3/3 0/0 0/0 .sbss sDspDacReadBuffer__9JASDriver */
s32 JASDriver::sDspDacReadBuffer;
/* 804512AC-804512B0 0007AC 0004+00 3/3 0/0 0/0 .sbss sDspStatus__9JASDriver */
s32 JASDriver::sDspStatus;
/* 804512B0-804512B4 0007B0 0004+00 1/1 0/0 0/0 .sbss sDspDacCallback__9JASDriver */
void (*JASDriver::sDspDacCallback)(s16*, u32);
/* 804512B4-804512B8 0007B4 0004+00 1/1 0/0 0/0 .sbss lastRspMadep__9JASDriver */
s16* JASDriver::lastRspMadep;
/* 804512B8-804512BC 0007B8 0004+00 1/1 0/0 0/0 .sbss dacCallbackFunc__9JASDriver */
void (*JASDriver::dacCallbackFunc)(s16*, u32);
/* 804512BC-804512C0 0007BC 0004+00 2/2 0/0 0/0 .sbss extMixCallback__9JASDriver */
JASDriver::MixCallback JASDriver::extMixCallback;
/* 804512C0-804512C4 0007C0 0004+00 2/2 0/0 0/0 .sbss sOutputRate__9JASDriver */
u32 JASDriver::sOutputRate;
/* 804507AC-804507B0 00022C 0004+00 2/2 0/0 0/0 .sdata sMixMode__9JASDriver */
JASMixMode JASDriver::sMixMode = MIX_MODE_EXTRA;
/* 804507B0-804507B4 000230 0004+00 2/2 0/0 0/0 .sdata sDacRate__9JASDriver */
f32 JASDriver::sDacRate = 32028.5f;
/* 804507B4-804507B8 000234 0004+00 4/3 0/0 0/0 .sdata sSubFrames__9JASDriver */
u32 JASDriver::sSubFrames = 0x00000007;
/* 8029C388-8029C4E4 296CC8 015C+00 0/0 1/1 0/0 .text initAI__9JASDriverFPFv_v */
// NONMATCHING missing instructions
void JASDriver::initAI(void (*param_0)(void)) {
setOutputRate(OUTPUT_RATE_0);
@@ -101,18 +81,15 @@ void JASDriver::initAI(void (*param_0)(void)) {
AIRegisterDMACallback(param_0);
}
/* 8029C4E4-8029C504 296E24 0020+00 0/0 1/1 0/0 .text startDMA__9JASDriverFv */
void JASDriver::startDMA() {
AIStartDMA();
}
/* 8029C504-8029C524 296E44 0020+00 0/0 1/1 0/0 .text stopDMA__9JASDriverFv */
void JASDriver::stopDMA() {
AIStopDMA();
}
/* 8029C524-8029C568 296E64 0044+00 1/1 0/0 0/0 .text setOutputRate__9JASDriverF13JASOutputRate */
void JASDriver::setOutputRate(JASOutputRate param_0) {
sOutputRate = param_0;
if (param_0 == 0) {
@@ -125,7 +102,6 @@ void JASDriver::setOutputRate(JASOutputRate param_0) {
sDacRate *= 1.0008897f;
}
/* 8039B2E0-8039B2F0 -00001 0010+00 1/1 0/0 0/0 .rodata sMixFuncs__9JASDriver */
const JASDriver::MixFunc JASDriver::sMixFuncs[4] = {
mixMonoTrack,
mixMonoTrackWide,
@@ -133,10 +109,8 @@ const JASDriver::MixFunc JASDriver::sMixFuncs[4] = {
mixInterleaveTrack,
};
/* 804512C4-804512C8 0007C4 0004+00 2/1 0/0 0/0 .sbss sSubFrameCounter__9JASDriver */
u32 JASDriver::sSubFrameCounter;
/* 8029C568-8029C6C4 296EA8 015C+00 0/0 1/1 0/0 .text updateDac__9JASDriverFv */
void JASDriver::updateDac() {
static u32 dacp = 0;
s16* r30 = lastRspMadep;
@@ -166,7 +140,6 @@ void JASDriver::updateDac() {
}
}
/* 8029C6C4-8029C7E0 297004 011C+00 1/1 1/1 0/0 .text updateDSP__9JASDriverFv */
void JASDriver::updateDSP() {
static u32 history[10] = {0x000F4240};
JASProbe::start(3, "SFR-UPDATE");
@@ -211,7 +184,6 @@ void JASDriver::updateDSP() {
sSubFrameCounter++;
}
/* 8029C7E0-8029C900 297120 0120+00 1/1 0/0 0/0 .text readDspBuffer__9JASDriverFPsUl */
void JASDriver::readDspBuffer(s16* param_0, u32 param_1) {
s32 nbuf = sDspDacReadBuffer + 1;
if (nbuf == data_804507A8) {
@@ -239,7 +211,6 @@ void JASDriver::readDspBuffer(s16* param_0, u32 param_1) {
JASCalc::imixcopy(endDacBuffer, dacBuffer, param_0, param_1);
}
/* 8029C900-8029C9DC 297240 00DC+00 1/1 1/1 0/0 .text finishDSPFrame__9JASDriverFv */
void JASDriver::finishDSPFrame() {
int r30 = sDspDacWriteBuffer + 1;
if (r30 == data_804507A8) {
@@ -261,35 +232,27 @@ void JASDriver::finishDSPFrame() {
}
}
/* 8029C9DC-8029C9E8 29731C 000C+00 0/0 0/0 2/2 .text
* registerMixCallback__9JASDriverFPFl_Ps10JASMixMode */
void JASDriver::registerMixCallback(MixCallback param_0, JASMixMode param_1) {
extMixCallback = param_0;
sMixMode = param_1;
}
/* 8029C9E8-8029C9F0 297328 0008+00 1/1 5/5 0/0 .text getDacRate__9JASDriverFv */
f32 JASDriver::getDacRate() {
return sDacRate;
}
/* 8029C9F0-8029C9F8 -00001 0008+00 0/0 0/0 0/0 .text getSubFrames__9JASDriverFv */
u32 JASDriver::getSubFrames() {
return sSubFrames;
}
/* 8029C9F8-8029CA04 297338 000C+00 2/2 0/0 0/0 .text getDacSize__9JASDriverFv */
u32 JASDriver::getDacSize() {
return sSubFrames * 0x50 * 2;
}
/* 8029CA04-8029CA10 297344 000C+00 3/3 0/0 0/0 .text getFrameSamples__9JASDriverFv */
u32 JASDriver::getFrameSamples() {
return sSubFrames * 0x50;
}
/* 8029CA10-8029CAC0 297350 00B0+00 1/0 0/0 0/0 .text mixMonoTrack__9JASDriverFPsUlPFl_Ps
*/
void JASDriver::mixMonoTrack(s16* buffer, u32 param_1, MixCallback param_2) {
JASProbe::start(5, "MONO-MIX");
s16* r31 = param_2(param_1);
@@ -306,7 +269,6 @@ void JASDriver::mixMonoTrack(s16* buffer, u32 param_1, MixCallback param_2) {
}
}
/* 8029CAC0-8029CB70 297400 00B0+00 1/0 0/0 0/0 .text mixMonoTrackWide__9JASDriverFPsUlPFl_Ps */
void JASDriver::mixMonoTrackWide(s16* buffer, u32 param_1, MixCallback param_2) {
JASProbe::start(5, "MONO(W)-MIX");
s16* r31 = param_2(param_1);
@@ -325,7 +287,6 @@ void JASDriver::mixMonoTrackWide(s16* buffer, u32 param_1, MixCallback param_2)
}
}
/* 8029CB70-8029CC50 2974B0 00E0+00 1/0 0/0 0/0 .text mixExtraTrack__9JASDriverFPsUlPFl_Ps */
void JASDriver::mixExtraTrack(s16* buffer, u32 param_1, MixCallback param_2) {
JASProbe::start(5, "DSPMIX");
s16* r31 = param_2(param_1);
@@ -346,7 +307,6 @@ void JASDriver::mixExtraTrack(s16* buffer, u32 param_1, MixCallback param_2) {
JASProbe::stop(6);
}
/* 8029CC50-8029CCD4 297590 0084+00 1/0 0/0 0/0 .text mixInterleaveTrack__9JASDriverFPsUlPFl_Ps */
void JASDriver::mixInterleaveTrack(s16* buffer, u32 param_1, MixCallback param_2) {
s16* r31 = param_2(param_1);
if (r31) {
@@ -360,7 +320,6 @@ void JASDriver::mixInterleaveTrack(s16* buffer, u32 param_1, MixCallback param_2
}
}
/* 8029CCD4-8029CCDC -00001 0008+00 0/0 0/0 0/0 .text getSubFrameCounter__9JASDriverFv */
u32 JASDriver::getSubFrameCounter() {
return sSubFrameCounter;
}
-43
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: JASAramStream
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASAramStream.h"
@@ -15,26 +10,20 @@
#include "JSystem/JKernel/JKRAram.h"
#include "JSystem/JKernel/JKRSolidHeap.h"
/* 80451250-80451254 000750 0004+00 6/6 0/0 0/0 .sbss sLoadThread__13JASAramStream */
JASTaskThread* JASAramStream::sLoadThread;
/* 80451254-80451258 000754 0004+00 3/3 0/0 0/0 .sbss sReadBuffer__13JASAramStream */
u8* JASAramStream::sReadBuffer;
/* 80451258-8045125C 000758 0004+00 6/6 1/1 0/0 .sbss sBlockSize__13JASAramStream */
u32 JASAramStream::sBlockSize;
/* 8045125C-80451260 00075C 0004+00 1/1 0/0 0/0 .sbss sChannelMax__13JASAramStream */
u32 JASAramStream::sChannelMax;
/* 80451260-80451268 -00001 0008+00 8/8 4/4 0/0 .sbss None */
/* 80451260 0001+00 data_80451260 None */
/* 80451261 0001+00 data_80451261 None */
/* 80451262 0006+00 data_80451262 None */
bool struct_80451260;
bool struct_80451261;
/* 8029631C-802963A8 290C5C 008C+00 0/0 1/1 0/0 .text initSystem__13JASAramStreamFUlUl */
void JASAramStream::initSystem(u32 i_blockSize, u32 i_channelMax) {
if (JASDriver::registerSubFrameCallback(dvdErrorCheck, NULL)) {
if (sLoadThread == NULL) {
@@ -48,7 +37,6 @@ void JASAramStream::initSystem(u32 i_blockSize, u32 i_channelMax) {
}
}
/* 802963A8-8029649C 290CE8 00F4+00 0/0 1/1 0/0 .text __ct__13JASAramStreamFv */
// NONMATCHING missing load
JASAramStream::JASAramStream() {
field_0x0a8 = NULL;
@@ -96,8 +84,6 @@ JASAramStream::JASAramStream() {
}
}
/* 8029649C-8029655C 290DDC 00C0+00 0/0 1/1 0/0 .text
* init__13JASAramStreamFUlUlPFUlP13JASAramStreamPv_vPv */
// NONMATCHING missing load
void JASAramStream::init(u32 param_0, u32 param_1, StreamCallback i_callback, void* i_callbackData) {
field_0x148 = param_0;
@@ -123,7 +109,6 @@ void JASAramStream::init(u32 param_0, u32 param_1, StreamCallback i_callback, vo
OSInitMessageQueue(&field_0x020, field_0x080, 4);
}
/* 8029655C-80296618 290E9C 00BC+00 0/0 1/1 0/0 .text prepare__13JASAramStreamFli */
bool JASAramStream::prepare(s32 param_0, int param_1) {
if (!DVDFastOpen(param_0, &mDvdFileInfo)) {
return false;
@@ -142,17 +127,14 @@ bool JASAramStream::prepare(s32 param_0, int param_1) {
return true;
}
/* 80296618-8029664C 290F58 0034+00 0/0 1/1 0/0 .text start__13JASAramStreamFv */
bool JASAramStream::start() {
return OSSendMessage(&field_0x000, (OSMessage)0, OS_MESSAGE_NOBLOCK);
}
/* 8029664C-80296684 290F8C 0038+00 0/0 1/1 0/0 .text stop__13JASAramStreamFUs */
bool JASAramStream::stop(u16 param_0) {
return OSSendMessage(&field_0x000, (OSMessage)(param_0 << 0x10 | 1), OS_MESSAGE_NOBLOCK);
}
/* 80296684-802966CC 290FC4 0048+00 0/0 1/1 0/0 .text pause__13JASAramStreamFb */
bool JASAramStream::pause(bool param_0) {
OSMessage msg;
if (param_0) {
@@ -166,14 +148,11 @@ bool JASAramStream::pause(bool param_0) {
return true;
}
/* 802966CC-80296710 29100C 0044+00 0/0 1/1 0/0 .text cancel__13JASAramStreamFv */
bool JASAramStream::cancel() {
field_0x114 = 1;
return sLoadThread->sendCmdMsg(finishTask, this);
}
/* 80296710-8029673C 291050 002C+00 4/4 0/0 0/0 .text getBlockSamples__13JASAramStreamCFv
*/
u32 JASAramStream::getBlockSamples() const {
if (field_0x158 == 0) {
return (sBlockSize << 4) / 9;
@@ -181,15 +160,11 @@ u32 JASAramStream::getBlockSamples() const {
return sBlockSize >> 1;
}
/* 8029673C-8029676C 29107C 0030+00 1/1 0/0 0/0 .text headerLoadTask__13JASAramStreamFPv
*/
void JASAramStream::headerLoadTask(void* i_data) {
TaskData* data = (TaskData*)i_data;
data->stream->headerLoad(data->field_0x4, data->field_0x8);
}
/* 8029676C-80296848 2910AC 00DC+00 1/1 0/0 0/0 .text firstLoadTask__13JASAramStreamFPv
*/
void JASAramStream::firstLoadTask(void* i_data) {
TaskData* data = (TaskData*)i_data;
JASAramStream* _this = data->stream;
@@ -214,13 +189,10 @@ void JASAramStream::firstLoadTask(void* i_data) {
}
}
/* 80296848-80296868 291188 0020+00 1/1 0/0 0/0 .text loadToAramTask__13JASAramStreamFPv
*/
void JASAramStream::loadToAramTask(void* i_this) {
((JASAramStream*)i_this)->load();
}
/* 80296868-802968C8 2911A8 0060+00 2/2 0/0 0/0 .text finishTask__13JASAramStreamFPv */
void JASAramStream::finishTask(void* i_this) {
JASAramStream* _this = (JASAramStream*)i_this;
JASDriver::rejectCallback(channelProcCallback, _this);
@@ -230,7 +202,6 @@ void JASAramStream::finishTask(void* i_this) {
}
}
/* 802968C8-80296920 291208 0058+00 1/1 0/0 0/0 .text prepareFinishTask__13JASAramStreamFPv */
void JASAramStream::prepareFinishTask(void* i_this) {
JASAramStream* _this = (JASAramStream*)i_this;
OSSendMessage(&_this->field_0x020, (OSMessage)4, OS_MESSAGE_BLOCK);
@@ -239,7 +210,6 @@ void JASAramStream::prepareFinishTask(void* i_this) {
}
}
/* 80296920-80296AE8 291260 01C8+00 1/1 0/0 0/0 .text headerLoad__13JASAramStreamFUli */
bool JASAramStream::headerLoad(u32 param_0, int param_1) {
if (struct_80451261) {
return false;
@@ -287,7 +257,6 @@ bool JASAramStream::headerLoad(u32 param_0, int param_1) {
}
/* 80296AE8-80296D74 291428 028C+00 2/2 0/0 0/0 .text load__13JASAramStreamFv */
// NONMATCHING regalloc and one instruction swap
bool JASAramStream::load() {
{
@@ -357,13 +326,10 @@ bool JASAramStream::load() {
return true;
}
/* 80296D74-80296D94 2916B4 0020+00 2/2 0/0 0/0 .text channelProcCallback__13JASAramStreamFPv */
s32 JASAramStream::channelProcCallback(void* i_this) {
return ((JASAramStream*)i_this)->channelProc();
}
/* 80296D94-80296DF0 2916D4 005C+00 2/1 0/0 0/0 .text dvdErrorCheck__13JASAramStreamFPv
*/
s32 JASAramStream::dvdErrorCheck(void* param_0) {
switch (DVDGetDriveStatus()) {
case DVD_STATE_END:
@@ -387,15 +353,11 @@ s32 JASAramStream::dvdErrorCheck(void* param_0) {
return 0;
}
/* 80296DF0-80296E2C 291730 003C+00 1/1 0/0 0/0 .text
* channelCallback__13JASAramStreamFUlP10JASChannelPQ26JASDsp8TChannelPv */
void JASAramStream::channelCallback(u32 i_callbackType, JASChannel* i_channel,
JASDsp::TChannel* i_dspChannel, void* i_this) {
((JASAramStream*)i_this)->updateChannel(i_callbackType, i_channel, i_dspChannel);
}
/* 80296E2C-802974AC 29176C 0680+00 1/1 0/0 0/0 .text
* updateChannel__13JASAramStreamFUlP10JASChannelPQ26JASDsp8TChannel */
// NONMATCHING missing extra loads of field_0x0c4
void JASAramStream::updateChannel(u32 i_callbackType, JASChannel* i_channel,
JASDsp::TChannel* i_dspChannel) {
@@ -576,7 +538,6 @@ void JASAramStream::updateChannel(u32 i_callbackType, JASChannel* i_channel,
i_channel->mPauseFlag = field_0x0ae != 0;
}
/* 802974AC-80297658 291DEC 01AC+00 1/1 0/0 0/0 .text channelProc__13JASAramStreamFv */
// NONMATCHING instruction ordering / regalloc
s32 JASAramStream::channelProc() {
OSMessage msg;
@@ -636,16 +597,13 @@ s32 JASAramStream::channelProc() {
return 0;
}
/* 8039B168-8039B174 0277C8 000C+00 1/0 0/0 0/0 .rodata OSC_RELEASE_TABLE */
static JASOscillator::Point const OSC_RELEASE_TABLE[2] = {
{0x0000, 0x0002, 0x0000},
{0x000F, 0x0000, 0x0000},
};
/* 8039B174-8039B190 -00001 0018+04 1/1 0/0 0/0 .rodata OSC_ENV */
static JASOscillator::Data const OSC_ENV = {0, 1.0f, NULL, OSC_RELEASE_TABLE, 1.0f, 0.0f};
/* 80297658-80297870 291F98 0218+00 1/1 0/0 0/0 .text channelStart__13JASAramStreamFv */
void JASAramStream::channelStart() {
u8 r31;
switch (field_0x158) {
@@ -685,7 +643,6 @@ void JASAramStream::channelStart() {
}
/* 80297870-802978DC 2921B0 006C+00 1/1 0/0 0/0 .text channelStop__13JASAramStreamFUs */
void JASAramStream::channelStop(u16 i_directRelease) {
for (int i = 0; i < mChannelNum; i++) {
if (mChannels[i] != NULL) {
+2 -14
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: JASAudioReseter
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASAudioReseter.h"
@@ -12,14 +7,13 @@
#include "dolphin/types.h"
struct JASDSPChannel {
/* 8029D340 */ void drop();
/* 8029D948 */ static JASDSPChannel* getHandle(u32);
void drop();
static JASDSPChannel* getHandle(u32);
inline u32 getStatus() {return mStatus;}
u32 mStatus;
};
/* 8029D0B4-8029D0FC 2979F4 0048+00 0/0 1/1 0/0 .text __ct__15JASAudioReseterFv */
JASAudioReseter::JASAudioReseter() {
field_0x0 = 0;
mIsDone = true;
@@ -27,10 +21,8 @@ JASAudioReseter::JASAudioReseter() {
mDSPLevel = JASDriver::getDSPLevel();
}
/* 8029D0FC-8029D138 297A3C 003C+00 0/0 1/1 0/0 .text __dt__15JASAudioReseterFv */
JASAudioReseter::~JASAudioReseter() {}
/* 8029D138-8029D1D4 297A78 009C+00 0/0 1/1 0/0 .text start__15JASAudioReseterFUlb */
bool JASAudioReseter::start(u32 param_0, bool param_1) {
if (mIsDone == false) {
return false;
@@ -47,18 +39,15 @@ bool JASAudioReseter::start(u32 param_0, bool param_1) {
}
}
/* 8029D1D4-8029D1F8 297B14 0024+00 0/0 1/1 0/0 .text resume__15JASAudioReseterFv */
void JASAudioReseter::resume() {
JASDriver::setDSPLevel(mDSPLevel);
}
/* 8029D1F8-8029D200 297B38 0008+00 0/0 2/2 0/0 .text checkDone__15JASAudioReseterCFv */
s32 JASAudioReseter::checkDone() const {
return mIsDone;
}
/* 8029D200-8029D2D4 297B40 00D4+00 1/1 0/0 0/0 .text calc__15JASAudioReseterFv */
s32 JASAudioReseter::calc() {
if(field_0x0==0) {
for(size_t i = 0; i<64; i++) {
@@ -80,7 +69,6 @@ s32 JASAudioReseter::calc() {
return 0;
}
/* 8029D2D4-8029D2F4 297C14 0020+00 1/1 0/0 0/0 .text callback__15JASAudioReseterFPv */
s32 JASAudioReseter::callback(void* param_0) {
return ((JASAudioReseter*)param_0)->calc();
}
-12
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: JASAudioThread
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASAudioThread.h"
@@ -15,7 +10,6 @@
#include "JSystem/JKernel/JKRSolidHeap.h"
#include "dolphin/dsp.h"
/* 8029CCDC-8029CD4C 29761C 0070+00 1/1 0/0 0/0 .text __ct__14JASAudioThreadFiiUl */
JASAudioThread::JASAudioThread(int stackSize, int msgCount, u32 threadPriority)
:
JKRThread(JASDram, threadPriority, msgCount, stackSize),
@@ -25,19 +19,16 @@ JASAudioThread::JASAudioThread(int stackSize, int msgCount, u32 threadPriority)
OSInitThreadQueue(&sThreadQueue);
}
/* 8029CD4C-8029CDC0 29768C 0074+00 0/0 1/1 0/0 .text create__14JASAudioThreadFl */
void JASAudioThread::create(long threadPriority) {
JASAudioThread* sAudioThread = new (JASDram, 0) JASAudioThread(threadPriority, 0x10, 0x1400);
sAudioThread->setCurrentHeap(JKRGetSystemHeap());
sAudioThread->resume();
}
/* 8029CDC0-8029CDEC 297700 002C+00 0/0 1/1 0/0 .text stop__14JASAudioThreadFv */
void JASAudioThread::stop() {
jamMessageBlock((void*)2);
}
/* 804512D8-804512E0 0007D8 0004+04 1/1 2/2 0/0 .sbss snIntCount__14JASAudioThread */
volatile int JASAudioThread::snIntCount;
class Lock {
@@ -56,7 +47,6 @@ class JASChannel {
u8 filler[0x108];
};
/* 8029CDEC-8029CF68 29772C 017C+00 1/0 0/0 0/0 .text run__14JASAudioThreadFv */
// NONMATCHING location of JASPoolAllocObject_MultiThreaded<JASChannel>
void* JASAudioThread::run() {
OSInitFastCast();
@@ -100,7 +90,6 @@ void* JASAudioThread::run() {
}
}
/* 8029CF68-8029CFBC 2978A8 0054+00 1/1 0/0 0/0 .text DMACallback__14JASAudioThreadFv */
void JASAudioThread::DMACallback() {
JASAudioThread* thread = getInstance();
JASProbe::stop(4);
@@ -108,7 +97,6 @@ void JASAudioThread::DMACallback() {
thread->sendMessage((void*)AUDIOMSG_DMA);
}
/* 8029CFBC-8029D028 2978FC 006C+00 1/1 0/0 0/0 .text DSPCallback__14JASAudioThreadFPv */
void JASAudioThread::DSPCallback(void*) {
JASAudioThread* thread = getInstance();
while (DSPCheckMailFromDSP() == 0) { }
-16
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: JASBNKParser
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASBNKParser.h"
@@ -14,16 +9,12 @@
#include "JSystem/JKernel/JKRSolidHeap.h"
#include "JSystem/JSupport/JSupport.h"
/* 80299538-80299558 293E78 0020+00 0/0 1/1 0/0 .text createBank__12JASBNKParserFPCvP7JKRHeap */
JASBank* JASBNKParser::createBank(void const* stream, JKRHeap* heap) {
return createBasicBank(stream, heap);
}
/* 80451288-8045128C 000788 0004+00 1/1 0/0 0/0 .sbss sUsedHeapSize__12JASBNKParser */
u32 JASBNKParser::sUsedHeapSize;
/* 80299558-80299600 293E98 00A8+00 1/1 0/0 0/0 .text createBasicBank__12JASBNKParserFPCvP7JKRHeap
*/
JASBasicBank* JASBNKParser::createBasicBank(void const* stream, JKRHeap* heap) {
if (heap == NULL) {
heap = JASDram;
@@ -47,7 +38,6 @@ JASBasicBank* JASBNKParser::createBasicBank(void const* stream, JKRHeap* heap) {
return bank;
}
/* 80299600-8029963C 293F40 003C+00 1/1 0/0 0/0 .text findChunk__Q212JASBNKParser4Ver1FPCvUl */
JASBNKParser::Ver1::TChunk* JASBNKParser::Ver1::findChunk(void const* stream, u32 id) {
TFileHeader* header = (TFileHeader*)stream;
void* end = (void*)((int)stream + header->mSize);
@@ -61,8 +51,6 @@ JASBNKParser::Ver1::TChunk* JASBNKParser::Ver1::findChunk(void const* stream, u3
return NULL;
}
/* 8029963C-80299A3C 293F7C 0400+00 1/1 0/0 0/0 .text
* createBasicBank__Q212JASBNKParser4Ver1FPCvP7JKRHeap */
JASBasicBank* JASBNKParser::Ver1::createBasicBank(void const* stream, JKRHeap* heap) {
if (heap == NULL) {
heap = JASDram;
@@ -167,8 +155,6 @@ JASBasicBank* JASBNKParser::Ver1::createBasicBank(void const* stream, JKRHeap* h
return bank;
}
/* 80299A3C-80299E68 29437C 042C+00 1/1 0/0 0/0 .text
* createBasicBank__Q212JASBNKParser4Ver0FPCvP7JKRHeap */
JASBasicBank* JASBNKParser::Ver0::createBasicBank(void const* stream, JKRHeap* heap) {
if (heap == NULL) {
heap = JASDram;
@@ -311,8 +297,6 @@ JASOscillator::Data* JASBNKParser::Ver0::findOscPtr(JASBasicBank* bank, THeader
return NULL;
}
/* 80299F8C-80299FA0 2948CC 0014+00 1/1 0/0 0/0 .text
* getOscTableEndPtr__Q212JASBNKParser4Ver0FPCQ213JASOscillator5Point */
JASOscillator::Point const* JASBNKParser::Ver0::getOscTableEndPtr(JASOscillator::Point const* points) {
s16 tmp;
do {
-9
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: JASBank
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASBank.h"
@@ -11,8 +6,6 @@
#include "JSystem/JAudio2/JASBasicWaveBank.h"
#include "JSystem/JAudio2/JASChannel.h"
/* 80297930-80297C40 292270 0310+00 0/0 1/1 0/0 .text
* noteOn__7JASBankFPC7JASBankiUcUcUsPFUlP10JASChannelPQ26JASDsp8TChannelPv_vPv */
// NONMATCHING JASPoolAllocObject_MultiThreaded<_> locations
JASChannel* JASBank::noteOn(JASBank const* param_0, int param_1, u8 param_2, u8 param_3, u16 param_4,
void (*param_5)(u32, JASChannel*, JASDsp::TChannel*, void*),
@@ -72,8 +65,6 @@ JASChannel* JASBank::noteOn(JASBank const* param_0, int param_1, u8 param_2, u8
return channel;
}
/* 80297C40-80297D78 292580 0138+00 1/1 0/0 0/0 .text
* noteOnOsc__7JASBankFiUcUcUsPFUlP10JASChannelPQ26JASDsp8TChannelPv_vPv */
// NONMATCHING JASPoolAllocObject_MultiThreaded<_> locations
JASChannel* JASBank::noteOnOsc(int param_0, u8 param_1, u8 param_2, u16 param_3,
void (*param_4)(u32, JASChannel*, JASDsp::TChannel*, void*),
-12
View File
@@ -1,20 +1,13 @@
//
// Generated By: dol2asm
// Translation Unit: JASBasicBank
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASBasicBank.h"
#include "JSystem/JAudio2/JASCalc.h"
/* 80297D78-80297DA4 2926B8 002C+00 0/0 2/2 0/0 .text __ct__12JASBasicBankFv */
JASBasicBank::JASBasicBank() {
mInstTable = NULL;
mInstNumMax = 0;
}
/* 80297DA4-80297E00 2926E4 005C+00 0/0 2/2 0/0 .text newInstTable__12JASBasicBankFUcP7JKRHeap */
void JASBasicBank::newInstTable(u8 num, JKRHeap* heap) {
if (num != 0) {
mInstNumMax = num;
@@ -23,8 +16,6 @@ void JASBasicBank::newInstTable(u8 num, JKRHeap* heap) {
}
}
/* 80297E00-80297E68 292740 0068+00 1/0 0/0 0/0 .text
* getInstParam__12JASBasicBankCFiiiP12JASInstParam */
bool JASBasicBank::getInstParam(int prg_no, int param_1, int param_2,
JASInstParam* o_param) const {
JASInst* inst = getInst(prg_no);
@@ -34,15 +25,12 @@ bool JASBasicBank::getInstParam(int prg_no, int param_1, int param_2,
return inst->getParam(param_1, param_2, o_param);
}
/* 80297E68-80297E80 2927A8 0018+00 0/0 2/2 0/0 .text setInst__12JASBasicBankFiP7JASInst
*/
void JASBasicBank::setInst(int prg_no, JASInst* inst) {
if (mInstTable != NULL) {
mInstTable[prg_no] = inst;
}
}
/* 80297E80-80297EC4 2927C0 0044+00 1/1 1/1 0/0 .text getInst__12JASBasicBankCFi */
JASInst* JASBasicBank::getInst(int prg_no) const {
if (prg_no < 0) {
return NULL;
-10
View File
@@ -8,7 +8,6 @@
#include "JSystem/JAudio2/JASCalc.h"
#include "JSystem/JKernel/JKRHeap.h"
/* 80298014-8029807C 292954 0068+00 0/0 2/2 0/0 .text __ct__12JASBasicInstFv */
JASBasicInst::JASBasicInst() {
mVolume = 1.0;
mPitch = 1.0;
@@ -17,13 +16,10 @@ JASBasicInst::JASBasicInst() {
JASCalc::bzero(field_0xc, sizeof(field_0xc));
}
/* 8029807C-802980F8 2929BC 007C+00 1/0 0/0 0/0 .text __dt__12JASBasicInstFv */
JASBasicInst::~JASBasicInst() {
delete[] mKeymap;
}
/* 802980F8-8029819C 292A38 00A4+00 1/0 0/0 0/0 .text getParam__12JASBasicInstCFiiP12JASInstParam
*/
bool JASBasicInst::getParam(int param_0, int param_1, JASInstParam* param_2) const {
param_2->field_0x1c = 0;
param_2->field_0x1e = 0;
@@ -50,21 +46,16 @@ bool JASBasicInst::getParam(int param_0, int param_1, JASInstParam* param_2) con
return true;
}
/* 8029819C-8029821C 292ADC 0080+00 0/0 2/2 0/0 .text
* setKeyRegionCount__12JASBasicInstFUlP7JKRHeap */
void JASBasicInst::setKeyRegionCount(u32 count, JKRHeap* param_1) {
delete [] mKeymap;
mKeymap = new (param_1, 0) TKeymap[count];
mKeymapCount = count;
}
/* 8029821C-8029822C 292B5C 0010+00 0/0 2/2 0/0 .text
* setOsc__12JASBasicInstFiPCQ213JASOscillator4Data */
void JASBasicInst::setOsc(int param_0, JASOscillator::Data const* param_1) {
field_0xc[param_0] = param_1;
}
/* 8029822C-80298250 292B6C 0024+00 0/0 2/2 0/0 .text getKeyRegion__12JASBasicInstFi */
JASBasicInst::TKeymap* JASBasicInst::getKeyRegion(int param_0) {
if (param_0 >= mKeymapCount) {
return NULL;
@@ -73,6 +64,5 @@ JASBasicInst::TKeymap* JASBasicInst::getKeyRegion(int param_0) {
return mKeymap + param_0;
}
/* 80298250-8029828C 292B90 003C+00 2/2 0/0 0/0 .text __dt__Q212JASBasicInst7TKeymapFv */
JASBasicInst::TKeymap::~TKeymap() {
}
-33
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: JASBasicWaveBank
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASBasicWaveBank.h"
@@ -10,7 +5,6 @@
#include "JSystem/JKernel/JKRHeap.h"
#include "JSystem/JUtility/JUTAssert.h"
/* 802984F8-80298558 292E38 0060+00 0/0 1/1 0/0 .text __ct__16JASBasicWaveBankFv */
JASBasicWaveBank::JASBasicWaveBank() {
mWaveTable = NULL;
mWaveGroupArray = NULL;
@@ -19,14 +13,11 @@ JASBasicWaveBank::JASBasicWaveBank() {
OSInitMutex(&field_0x4);
}
/* 80298558-802985E4 292E98 008C+00 1/0 0/0 0/0 .text __dt__16JASBasicWaveBankFv */
JASBasicWaveBank::~JASBasicWaveBank() {
delete[] mWaveTable;
delete[] mWaveGroupArray;
}
/* 80298640-80298664 292F80 0024+00 1/1 1/1 0/0 .text getWaveGroup__16JASBasicWaveBankFUl
*/
JASBasicWaveBank::TWaveGroup* JASBasicWaveBank::getWaveGroup(u32 param_0) {
if (param_0 >= mGroupCount) {
return NULL;
@@ -34,8 +25,6 @@ JASBasicWaveBank::TWaveGroup* JASBasicWaveBank::getWaveGroup(u32 param_0) {
return mWaveGroupArray + param_0;
}
/* 80298664-80298710 292FA4 00AC+00 0/0 1/1 0/0 .text
* setGroupCount__16JASBasicWaveBankFUlP7JKRHeap */
void JASBasicWaveBank::setGroupCount(u32 param_0, JKRHeap* param_1) {
delete[] mWaveGroupArray;
mGroupCount = param_0;
@@ -46,8 +35,6 @@ void JASBasicWaveBank::setGroupCount(u32 param_0, JKRHeap* param_1) {
}
}
/* 80298710-80298790 293050 0080+00 0/0 1/1 0/0 .text
* setWaveTableSize__16JASBasicWaveBankFUlP7JKRHeap */
void JASBasicWaveBank::setWaveTableSize(u32 param_0, JKRHeap* param_1) {
delete[] mWaveTable;
mWaveTable = new(param_1, 0) TWaveHandle[param_0];
@@ -55,8 +42,6 @@ void JASBasicWaveBank::setWaveTableSize(u32 param_0, JKRHeap* param_1) {
mHandleCount = param_0;
}
/* 80298790-8029883C 2930D0 00AC+00 1/1 0/0 0/0 .text
* incWaveTable__16JASBasicWaveBankFPCQ216JASBasicWaveBank10TWaveGroup */
void JASBasicWaveBank::incWaveTable(JASBasicWaveBank::TWaveGroup const* param_0) {
JASMutexLock lock(&field_0x4);
for (u32 i = 0; i < param_0->getWaveCount(); i++) {
@@ -69,11 +54,8 @@ void JASBasicWaveBank::incWaveTable(JASBasicWaveBank::TWaveGroup const* param_0)
}
}
/* 80451278-80451280 000778 0004+04 2/2 0/0 0/0 .sbss mNoLoad__16JASBasicWaveBank */
u32 JASBasicWaveBank::mNoLoad;
/* 8029883C-802988DC 29317C 00A0+00 1/1 0/0 0/0 .text
* decWaveTable__16JASBasicWaveBankFPCQ216JASBasicWaveBank10TWaveGroup */
void JASBasicWaveBank::decWaveTable(JASBasicWaveBank::TWaveGroup const* param_0) {
JASMutexLock lock(&field_0x4);
for (u32 i = 0; i < param_0->getWaveCount(); i++) {
@@ -86,7 +68,6 @@ void JASBasicWaveBank::decWaveTable(JASBasicWaveBank::TWaveGroup const* param_0)
}
}
/* 802988DC-80298910 29321C 0034+00 1/0 0/0 0/0 .text getWaveHandle__16JASBasicWaveBankCFUl */
JASWaveHandle* JASBasicWaveBank::getWaveHandle(u32 param_0) const {
if (param_0 >= mHandleCount) {
return NULL;
@@ -97,8 +78,6 @@ JASWaveHandle* JASBasicWaveBank::getWaveHandle(u32 param_0) const {
return mWaveTable + param_0;
}
/* 80298910-802989C0 293250 00B0+00 0/0 1/1 0/0 .text
* setWaveInfo__16JASBasicWaveBankFPQ216JASBasicWaveBank10TWaveGroupiUsRC11JASWaveInfo */
void JASBasicWaveBank::setWaveInfo(JASBasicWaveBank::TWaveGroup* wgrp, int index,
u16 param_2, JASWaveInfo const& param_3) {
JUT_ASSERT(204, wgrp);
@@ -111,20 +90,16 @@ void JASBasicWaveBank::setWaveInfo(JASBasicWaveBank::TWaveGroup* wgrp, int index
wgrp->mCtrlWaveArray[index].field_0x4 = param_3.field_0x08;
}
/* 802989C0-80298A0C 293300 004C+00 1/1 0/0 0/0 .text __ct__Q216JASBasicWaveBank10TWaveGroupFv */
JASBasicWaveBank::TWaveGroup::TWaveGroup() {
mBank = NULL;
mCtrlWaveArray = NULL;
mWaveCount = 0;
}
/* 80298A0C-80298A84 29334C 0078+00 3/2 0/0 0/0 .text __dt__Q216JASBasicWaveBank10TWaveGroupFv */
JASBasicWaveBank::TWaveGroup::~TWaveGroup() {
delete[] mCtrlWaveArray;
}
/* 80298A84-80298B04 2933C4 0080+00 0/0 1/1 0/0 .text
* setWaveCount__Q216JASBasicWaveBank10TWaveGroupFUlP7JKRHeap */
void JASBasicWaveBank::TWaveGroup::setWaveCount(u32 param_0, JKRHeap* param_1) {
delete[] mCtrlWaveArray;
mWaveCount = param_0;
@@ -132,31 +107,23 @@ void JASBasicWaveBank::TWaveGroup::setWaveCount(u32 param_0, JKRHeap* param_1) {
JUT_ASSERT(255, mCtrlWaveArray != NULL);
}
/* 80298B04-80298B2C 293444 0028+00 1/0 0/0 0/0 .text
* onLoadDone__Q216JASBasicWaveBank10TWaveGroupFv */
void JASBasicWaveBank::TWaveGroup::onLoadDone() {
JUT_ASSERT(286, mBank);
mBank->incWaveTable(this);
}
/* 80298B2C-80298B54 29346C 0028+00 1/0 0/0 0/0 .text
* onEraseDone__Q216JASBasicWaveBank10TWaveGroupFv */
void JASBasicWaveBank::TWaveGroup::onEraseDone() {
JUT_ASSERT(292, mBank);
mBank->decWaveTable(this);
}
/* 80298B54-80298B64 293494 0010+00 2/2 0/0 0/0 .text
* getWaveID__Q216JASBasicWaveBank10TWaveGroupCFi */
u32 JASBasicWaveBank::TWaveGroup::getWaveID(int index) const {
JUT_ASSERT(298, index < mWaveCount);
JUT_ASSERT(299, index >= 0);
return mCtrlWaveArray[index].field_0x0;
}
/* 80298B64-80298B88 2934A4 0024+00 1/0 0/0 0/0 .text
* getWavePtr__Q216JASBasicWaveBank11TWaveHandleCFv */
int JASBasicWaveBank::TWaveHandle::getWavePtr() const {
JUT_ASSERT(313, mHeap);
void* base = mHeap->getBase();
-7
View File
@@ -4,7 +4,6 @@
#include <math.h>
#include <limits.h>
/* 8028F2E8-8028F318 289C28 0030+00 0/0 1/1 0/0 .text imixcopy__7JASCalcFPCsPCsPsUl */
void JASCalc::imixcopy(const s16* s1, const s16* s2, s16* dst, u32 n) {
for (n; n != 0; n--) {
*dst++ = *((s16*)s1)++;
@@ -12,7 +11,6 @@ void JASCalc::imixcopy(const s16* s1, const s16* s2, s16* dst, u32 n) {
}
}
/* 8028F318-8028F354 289C58 003C+00 1/1 0/0 0/0 .text bcopyfast__7JASCalcFPCvPvUl */
void JASCalc::bcopyfast(const void* src, void* dest, u32 size) {
JUT_ASSERT(226, (reinterpret_cast<u32>(src) & 0x03) == 0);
JUT_ASSERT(227, (reinterpret_cast<u32>(dest) & 0x03) == 0);
@@ -35,7 +33,6 @@ void JASCalc::bcopyfast(const void* src, void* dest, u32 size) {
}
}
/* 8028F354-8028F454 289C94 0100+00 0/0 3/3 0/0 .text bcopy__7JASCalcFPCvPvUl */
void JASCalc::bcopy(const void* src, void* dest, u32 size) {
u32* usrc;
u32* udest;
@@ -79,7 +76,6 @@ void JASCalc::bcopy(const void* src, void* dest, u32 size) {
}
}
/* 8028F454-8028F480 289D94 002C+00 1/1 0/0 0/0 .text bzerofast__7JASCalcFPvUl */
void JASCalc::bzerofast(void* dest, u32 size) {
JUT_ASSERT(336, (reinterpret_cast<u32>(dest) & 0x03) == 0);
JUT_ASSERT(337, (size & 0x0f) == 0);
@@ -94,7 +90,6 @@ void JASCalc::bzerofast(void* dest, u32 size) {
}
}
/* 8028F480-8028F578 289DC0 00F8+00 0/0 6/6 0/0 .text bzero__7JASCalcFPvUl */
void JASCalc::bzero(void* dest, u32 size) {
u32* udest;
u8* bdest = (u8*)dest;
@@ -137,7 +132,6 @@ void JASCalc::bzero(void* dest, u32 size) {
}
}
/* 8039ABB8-8039AFB8 027218 0400+00 0/0 4/4 0/0 .rodata CUTOFF_TO_IIR_TABLE__7JASCalc */
s16 const JASCalc::CUTOFF_TO_IIR_TABLE[128][4] = {
0x0F5C, 0x0A3D, 0x4665, 0x1E73,
0x0F5E, 0x0A3D, 0x4664, 0x1E73,
@@ -277,7 +271,6 @@ f32 JASCalc::fake1() { return 0.5f; }
f32 JASCalc::fake2(long x) { return JASCalc::clamp<s16, long>(x); }
f32 JASCalc::fake3() { return 0.0f; }
/* 8028F578-8028F69C 289EB8 0124+00 0/0 2/2 0/0 .text pow2__7JASCalcFf */
f32 JASCalc::pow2(f32 x) {
s32 frac_index = 0;
union {
-5
View File
@@ -3,8 +3,6 @@
#include "JSystem/JAudio2/JASCallback.h"
#include "JSystem/JAudio2/JASCriticalSection.h"
/* 8028FFA8-80290030 28A8E8 0088+00 0/0 2/2 0/0 .text regist__14JASCallbackMgrFPFPv_lPv
*/
bool JASCallbackMgr::regist(JASCallback* callback, void* argument) {
JASCriticalSection criticalSection;
for (int i = 0; i < NUM_CALLBACKS; i++) {
@@ -18,8 +16,6 @@ bool JASCallbackMgr::regist(JASCallback* callback, void* argument) {
return false;
}
/* 80290030-802900C4 28A970 0094+00 0/0 1/1 0/0 .text reject__14JASCallbackMgrFPFPv_lPv
*/
int JASCallbackMgr::reject(JASCallback* callback, void* argument) {
int rejectNum = 0;
JASCriticalSection criticalSection;
@@ -33,7 +29,6 @@ int JASCallbackMgr::reject(JASCallback* callback, void* argument) {
return rejectNum;
}
/* 802900C4-80290140 28AA04 007C+00 0/0 3/3 0/0 .text callback__14JASCallbackMgrFv */
void JASCallbackMgr::callback() {
for (int i = 0; i < NUM_CALLBACKS; i++) {
if (callbacks_[i].callback_ && callbacks_[i].callback_(callbacks_[i].arg_) < 0) {
-44
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: JASChannel
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASChannel.h"
@@ -14,21 +9,14 @@
#include "JSystem/JMath/JMATrigonometric.h"
#include "JSystem/JGeometry.h"
/* 80431B90-80431BB0 05E8B0 0020+00 2/2 0/0 0/0 .bss sBankDisposeMsgQ__10JASChannel */
OSMessageQueue JASChannel::sBankDisposeMsgQ;
/* 80431BB0-80431BF0 05E8D0 0040+00 1/1 0/0 0/0 .bss sBankDisposeMsg__10JASChannel */
OSMessage JASChannel::sBankDisposeMsg[16];
/* 80431BF0-80431C30 05E910 0040+00 2/2 0/3 0/0 .bss sBankDisposeList__10JASChannel */
OSMessage JASChannel::sBankDisposeList[16];
/* 80451298-804512A0 000798 0004+04 3/3 0/0 0/0 .sbss sBankDisposeListSize__10JASChannel
*/
int JASChannel::sBankDisposeListSize;
/* 8029A800-8029A918 295140 0118+00 0/0 3/3 0/0 .text
* __ct__10JASChannelFPFUlP10JASChannelPQ26JASDsp8TChannelPv_vPv */
JASChannel::JASChannel(Callback i_callback, void* i_callbackData) :
mStatus(STATUS_INACTIVE),
mDspCh(NULL),
@@ -55,7 +43,6 @@ JASChannel::JASChannel(Callback i_callback, void* i_callbackData) :
mPauseFlag = false;
}
/* 8029A918-8029A9F0 295258 00D8+00 5/5 0/0 0/0 .text __dt__10JASChannelFv */
JASChannel::~JASChannel() {
if (mDspCh != NULL) {
mDspCh->drop();
@@ -66,7 +53,6 @@ JASChannel::~JASChannel() {
}
/* 8029A9F0-8029AA60 295330 0070+00 0/0 2/2 0/0 .text play__10JASChannelFv */
int JASChannel::play() {
JASDSPChannel* channel = JASDSPChannel::alloc(JSULoByte(mPriority), dspUpdateCallback, this);
if (channel == NULL) {
@@ -79,7 +65,6 @@ int JASChannel::play() {
return 1;
}
/* 8029AA60-8029AAD0 2953A0 0070+00 0/0 1/1 0/0 .text playForce__10JASChannelFv */
int JASChannel::playForce() {
JASDSPChannel* channel = JASDSPChannel::allocForce(JSULoByte(mPriority),
dspUpdateCallback, this);
@@ -93,7 +78,6 @@ int JASChannel::playForce() {
return 1;
}
/* 8029AAD0-8029AB64 295410 0094+00 0/0 4/4 0/0 .text release__10JASChannelFUs */
void JASChannel::release(u16 i_directRelease) {
if (mStatus == STATUS_ACTIVE) {
if (i_directRelease != 0) {
@@ -109,32 +93,23 @@ void JASChannel::release(u16 i_directRelease) {
}
}
/* 8029AB64-8029AB98 2954A4 0034+00 0/0 4/4 0/0 .text
* setOscInit__10JASChannelFUlPCQ213JASOscillator4Data */
void JASChannel::setOscInit(u32 i_index, JASOscillator::Data const* i_data) {
mOscillators[i_index].initStart(i_data);
}
/* 8029AB98-8029ABA8 2954D8 0010+00 0/0 2/2 0/0 .text setMixConfig__10JASChannelFUlUs */
void JASChannel::setMixConfig(u32 i_index, u16 i_config) {
mMixConfig[i_index].whole = i_config;
}
/* 8029ABA8-8029ABC0 2954E8 0018+00 1/1 0/0 0/0 .text
* calcEffect__10JASChannelFPCQ210JASChannel9PanVector */
f32 JASChannel::calcEffect(JASChannel::PanVector const* i_vector) {
return i_vector->mSound + i_vector->mEffect + i_vector->mChannel;
}
/* 8029ABC0-8029ABEC 295500 002C+00 1/1 0/0 0/0 .text
* calcPan__10JASChannelFPCQ210JASChannel9PanVector */
f32 JASChannel::calcPan(JASChannel::PanVector const* i_vector) {
return 0.5f + (i_vector->mSound - 0.5f) + (i_vector->mEffect - 0.5f)
+ (i_vector->mChannel - 0.5f);
}
/* 8029ABEC-8029ACD4 29552C 00E8+00 3/2 0/0 0/0 .text
* effectOsc__10JASChannelFUlPQ213JASOscillator12EffectParams */
void JASChannel::effectOsc(u32 i_index, JASOscillator::EffectParams* i_params) {
f32 value = mOscillators[i_index].getValue();
switch (mOscillators[i_index].getTarget()) {
@@ -163,8 +138,6 @@ void JASChannel::effectOsc(u32 i_index, JASOscillator::EffectParams* i_params) {
}
}
/* 8029ACD4-8029AD38 295614 0064+00 0/0 1/1 0/0 .text setKeySweepTarget__10JASChannelFlUl
*/
void JASChannel::setKeySweepTarget(s32 i_target, u32 i_count) {
if (i_count == 0) {
mKeySweep = i_target;
@@ -175,8 +148,6 @@ void JASChannel::setKeySweepTarget(s32 i_target, u32 i_count) {
mKeySweepCount = i_count;
}
/* 8029AD38-8029AF78 295678 0240+00 2/2 0/0 0/0 .text
* updateEffectorParam__10JASChannelFPQ26JASDsp8TChannelPUsRCQ213JASOscillator12EffectParams */
void JASChannel::updateEffectorParam(JASDsp::TChannel* i_channel, u16* i_mixerVolume,
JASOscillator::EffectParams const& i_params) {
PanVector pan_vector, fxmix_vector, dolby_vector;
@@ -223,8 +194,6 @@ void JASChannel::updateEffectorParam(JASDsp::TChannel* i_channel, u16* i_mixerVo
}
}
/* 8029AF78-8029B004 2958B8 008C+00 2/2 0/0 0/0 .text
* dspUpdateCallback__10JASChannelFUlPQ26JASDsp8TChannelPv */
s32 JASChannel::dspUpdateCallback(u32 i_type, JASDsp::TChannel* i_channel, void* i_this) {
JASChannel* _this = static_cast<JASChannel*>(i_this);
switch (i_type) {
@@ -242,8 +211,6 @@ s32 JASChannel::dspUpdateCallback(u32 i_type, JASDsp::TChannel* i_channel, void*
return 0;
}
/* 8029B004-8029B324 295944 0320+00 1/1 0/0 0/0 .text
* initialUpdateDSPChannel__10JASChannelFPQ26JASDsp8TChannel */
s32 JASChannel::initialUpdateDSPChannel(JASDsp::TChannel* i_channel) {
if (isDolbyMode()) {
i_channel->initAutoMixer();
@@ -322,8 +289,6 @@ s32 JASChannel::initialUpdateDSPChannel(JASDsp::TChannel* i_channel) {
return 0;
}
/* 8029B324-8029B6A0 295C64 037C+00 1/1 0/0 0/0 .text
* updateDSPChannel__10JASChannelFPQ26JASDsp8TChannel */
s32 JASChannel::updateDSPChannel(JASDsp::TChannel* i_channel) {
if (mCallback != NULL) {
mCallback(CB_PLAY, this, i_channel, mCallbackData);
@@ -398,8 +363,6 @@ s32 JASChannel::updateDSPChannel(JASDsp::TChannel* i_channel) {
return 0;
}
/* 8029B6A0-8029B7D8 295FE0 0138+00 1/1 0/0 0/0 .text
* updateAutoMixer__10JASChannelFPQ26JASDsp8TChannelffff */
void JASChannel::updateAutoMixer(JASDsp::TChannel* i_channel, f32 param_1, f32 param_2,
f32 param_3, f32 param_4) {
if (JASDriver::getOutputMode() == 0) {
@@ -410,8 +373,6 @@ void JASChannel::updateAutoMixer(JASDsp::TChannel* i_channel, f32 param_1, f32 p
param_4 * 127.5f, param_3 * 127.5f, 0);
}
/* 8029B7D8-8029BBFC 296118 0424+00 3/1 0/0 0/0 .text updateMixer__10JASChannelFffffPUs
*/
void JASChannel::updateMixer(f32 i_volume, f32 i_pan, f32 i_fxmix, f32 i_dolby, u16* i_volumeOut) {
for (u32 i = 0; i < 6; i++) {
f32 volume = i_volume;
@@ -505,19 +466,16 @@ void JASChannel::updateMixer(f32 i_volume, f32 i_pan, f32 i_fxmix, f32 i_dolby,
}
}
/* 8029BBFC-8029BC0C 29653C 0010+00 0/0 3/3 0/0 .text free__10JASChannelFv */
void JASChannel::free() {
mCallback = NULL;
mCallbackData = NULL;
}
/* 8029BC0C-8029BC48 29654C 003C+00 0/0 1/1 0/0 .text initBankDisposeMsgQueue__10JASChannelFv */
void JASChannel::initBankDisposeMsgQueue() {
OSInitMessageQueue(&sBankDisposeMsgQ, sBankDisposeMsg, 0x10);
sBankDisposeListSize = 0;
}
/* 8029BC48-8029BCC0 296588 0078+00 0/0 1/1 0/0 .text receiveBankDisposeMsg__10JASChannelFv */
void JASChannel::receiveBankDisposeMsg() {
OSMessage msg;
for (sBankDisposeListSize = 0;
@@ -528,8 +486,6 @@ void JASChannel::receiveBankDisposeMsg() {
}
}
/* 8029BCC0-8029BD14 296600 0054+00 2/2 0/0 0/0 .text checkBankDispose__10JASChannelCFv
*/
bool JASChannel::checkBankDispose() const {
if (mBankDisposeID == NULL) {
return false;
-7
View File
@@ -7,20 +7,15 @@
#include "JSystem/JAudio2/JASCmdStack.h"
#include "dolphin/os.h"
/* 80431684-80431690 05E3A4 000C+00 1/2 0/0 0/0 .bss sCommandListOnce__10JASPortCmd */
JASPortCmd::TPortHead JASPortCmd::sCommandListOnce;
/* 8043169C-804316A8 05E3BC 000C+00 1/2 0/0 0/0 .bss sCommandListStay__10JASPortCmd */
JASPortCmd::TPortHead JASPortCmd::sCommandListStay;
/* 80291060-80291094 28B9A0 0034+00 0/0 1/1 0/0 .text execAllCommand__10JASPortCmdFv */
void JASPortCmd::execAllCommand() {
sCommandListOnce.execCommandOnce();
sCommandListStay.execCommandStay();
}
/* 80291094-8029110C 28B9D4 0078+00 1/1 0/0 0/0 .text execCommandOnce__Q210JASPortCmd9TPortHeadFv
*/
void JASPortCmd::TPortHead::execCommandOnce() {
volatile BOOL interrupts = OSDisableInterrupts();
JSULink<JASPortCmd>* next;
@@ -32,8 +27,6 @@ void JASPortCmd::TPortHead::execCommandOnce() {
OSRestoreInterrupts(interrupts);
}
/* 8029110C-8029116C 28BA4C 0060+00 1/1 0/0 0/0 .text execCommandStay__Q210JASPortCmd9TPortHeadFv
*/
void JASPortCmd::TPortHead::execCommandStay() {
volatile int interrupts = OSDisableInterrupts();
for (JSULink<JASPortCmd>* link = getFirst(); link != NULL; link = link->getNext()) {
-23
View File
@@ -1,18 +1,11 @@
//
// Generated By: dol2asm
// Translation Unit: JASDSPChannel
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASDSPChannel.h"
#include "JSystem/JAudio2/JASHeapCtrl.h"
#include "JSystem/JKernel/JKRSolidHeap.h"
/* 804512E0-804512E8 0007E0 0004+04 5/5 0/0 0/0 .sbss sDspChannels__13JASDSPChannel */
JASDSPChannel* JASDSPChannel::sDspChannels;
/* 8029D2F4-8029D320 297C34 002C+00 1/1 0/0 0/0 .text __ct__13JASDSPChannelFv */
JASDSPChannel::JASDSPChannel() :
mStatus(STATUS_INACTIVE),
mPriority(-1),
@@ -25,18 +18,15 @@ JASDSPChannel::JASDSPChannel() :
/* empty function */
}
/* 8029D320-8029D330 297C60 0010+00 0/0 3/3 0/0 .text free__13JASDSPChannelFv */
void JASDSPChannel::free() {
mCallback = NULL;
mCallbackData = NULL;
}
/* 8029D330-8029D340 297C70 0010+00 0/0 2/2 0/0 .text start__13JASDSPChannelFv */
void JASDSPChannel::start() {
mFlags |= 1;
}
/* 8029D340-8029D3C8 297C80 0088+00 3/3 2/2 0/0 .text drop__13JASDSPChannelFv */
void JASDSPChannel::drop() {
if (mCallback != NULL) {
mCallback(CB_DROP, NULL, mCallbackData);
@@ -51,7 +41,6 @@ void JASDSPChannel::drop() {
}
}
/* 8029D3C8-8029D44C 297D08 0084+00 0/0 1/1 0/0 .text initAll__13JASDSPChannelFv */
void JASDSPChannel::initAll() {
sDspChannels = new (JASDram, 0x20) JASDSPChannel[0x40];
for (int i = 0; i < 0x40; i++) {
@@ -59,8 +48,6 @@ void JASDSPChannel::initAll() {
}
}
/* 8029D44C-8029D4BC 297D8C 0070+00 0/0 1/1 0/0 .text
* alloc__13JASDSPChannelFUcPFUlPQ26JASDsp8TChannelPv_lPv */
JASDSPChannel* JASDSPChannel::alloc(u8 i_priority, Callback i_callback, void* i_callbackData) {
JASDSPChannel* channel = getLowestChannel(i_priority);
if (channel == NULL) {
@@ -74,8 +61,6 @@ JASDSPChannel* JASDSPChannel::alloc(u8 i_priority, Callback i_callback, void* i_
return channel;
}
/* 8029D4BC-8029D534 297DFC 0078+00 0/0 1/1 0/0 .text
* allocForce__13JASDSPChannelFUcPFUlPQ26JASDsp8TChannelPv_lPv */
JASDSPChannel* JASDSPChannel::allocForce(u8 i_priority, Callback i_callback, void* i_callbackData) {
JASDSPChannel* channel = getLowestChannel(i_priority);
if (channel == NULL) {
@@ -90,13 +75,10 @@ JASDSPChannel* JASDSPChannel::allocForce(u8 i_priority, Callback i_callback, voi
return channel;
}
/* 8029D534-8029D540 297E74 000C+00 0/0 1/1 0/0 .text setPriority__13JASDSPChannelFUc */
void JASDSPChannel::setPriority(u8 i_priority) {
mPriority = i_priority;
}
/* 8029D540-8029D5D0 297E80 0090+00 2/2 0/0 0/0 .text getLowestChannel__13JASDSPChannelFi
*/
JASDSPChannel* JASDSPChannel::getLowestChannel(int i_priority) {
s16 best_priority = 0xff;
int best_index = -1;
@@ -121,7 +103,6 @@ JASDSPChannel* JASDSPChannel::getLowestChannel(int i_priority) {
return &sDspChannels[best_index];
}
/* 8029D5D0-8029D65C 297F10 008C+00 1/1 0/0 0/0 .text getLowestActiveChannel__13JASDSPChannelFv */
JASDSPChannel* JASDSPChannel::getLowestActiveChannel() {
s16 best_priority = 0xff;
int best_index = -1;
@@ -145,7 +126,6 @@ JASDSPChannel* JASDSPChannel::getLowestActiveChannel() {
return &sDspChannels[best_index];
}
/* 8029D65C-8029D89C 297F9C 0240+00 1/1 0/0 0/0 .text updateProc__13JASDSPChannelFv */
void JASDSPChannel::updateProc() {
int ret;
if (mChannel->isFinish()) {
@@ -222,7 +202,6 @@ void JASDSPChannel::updateProc() {
}
}
/* 8029D89C-8029D910 2981DC 0074+00 0/0 1/1 0/0 .text updateAll__13JASDSPChannelFv */
void JASDSPChannel::updateAll() {
for (u32 i = 0; i < 0x40; i++) {
if ((i & 0xf) == 0 && i != 0) {
@@ -233,7 +212,6 @@ void JASDSPChannel::updateAll() {
JASDsp::releaseHalt(3);
}
/* 8029D910-8029D948 298250 0038+00 0/0 1/1 0/0 .text killActiveChannel__13JASDSPChannelFv */
int JASDSPChannel::killActiveChannel() {
JASDSPChannel* channel = getLowestActiveChannel();
if (channel == NULL) {
@@ -244,7 +222,6 @@ int JASDSPChannel::killActiveChannel() {
}
}
/* 8029D948-8029D958 298288 0010+00 0/0 1/1 0/0 .text getHandle__13JASDSPChannelFUl */
JASDSPChannel* JASDSPChannel::getHandle(u32 i_index) {
return &sDspChannels[i_index];
}
+2 -57
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: JASDSPInterface
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASDSPInterface.h"
@@ -16,16 +11,12 @@
#include "JSystem/JKernel/JKRSolidHeap.h"
#include <dolphin/os.h>
/* 804512E8-804512EC 0007E8 0004+00 5/5 0/0 0/0 .sbss CH_BUF__6JASDsp */
JASDsp::TChannel* JASDsp::CH_BUF;
/* 804512EC-804512F0 0007EC 0004+00 3/3 0/0 0/0 .sbss FX_BUF__6JASDsp */
JASDsp::FxBuf* JASDsp::FX_BUF;
/* 804512F0-804512F4 0007F0 0004+00 2/2 0/0 0/0 .sbss sDSPVolume__6JASDsp */
f32 JASDsp::sDSPVolume;
/* 8029D958-8029D9A4 298298 004C+00 0/0 1/1 0/0 .text boot__6JASDspFPFPv_v */
void JASDsp::boot(void (*param_0)(void*)) {
static bool data_804512F4 = true;
if (data_804512F4) {
@@ -34,66 +25,55 @@ void JASDsp::boot(void (*param_0)(void*)) {
}
}
/* 8029D9A4-8029D9C4 2982E4 0020+00 0/0 1/1 0/0 .text releaseHalt__6JASDspFUl */
void JASDsp::releaseHalt(u32 param_0) {
DSPReleaseHalt2(param_0);
}
/* 8029D9C4-8029D9E4 298304 0020+00 0/0 1/1 0/0 .text finishWork__6JASDspFUs */
void JASDsp::finishWork(u16 param_0) {
DspFinishWork(param_0);
}
/* 8029D9E4-8029DA04 298324 0020+00 0/0 1/1 0/0 .text syncFrame__6JASDspFUlUlUl */
void JASDsp::syncFrame(u32 param_0, u32 param_1, u32 param_2) {
DsyncFrame2(param_0, param_1, param_2);
}
/* 8029DA04-8029DA30 298344 002C+00 0/0 1/1 0/0 .text setDSPMixerLevel__6JASDspFf */
void JASDsp::setDSPMixerLevel(f32 dsp_level) {
sDSPVolume = dsp_level;
dsp_level *= 4.0f;
DsetMixerLevel(dsp_level);
}
/* 8029DA30-8029DA38 298370 0008+00 0/0 1/1 0/0 .text getDSPMixerLevel__6JASDspFv */
f32 JASDsp::getDSPMixerLevel() {
return sDSPVolume;
}
/* 8029DA38-8029DA48 298378 0010+00 0/0 1/1 0/0 .text getDSPHandle__6JASDspFi */
JASDsp::TChannel* JASDsp::getDSPHandle(int param_0) {
return CH_BUF + param_0;
}
/* 8029DA48-8029DA6C 298388 0024+00 3/3 0/0 0/0 .text setFilterTable__6JASDspFPsPsUl */
void JASDsp::setFilterTable(s16* param_0, s16* param_1, u32 param_2) {
for (int i = 0; i < param_2; i++) {
*param_0++ = *param_1++;
}
}
/* 8029DA6C-8029DAA0 2983AC 0034+00 1/1 0/0 0/0 .text flushBuffer__6JASDspFv */
void JASDsp::flushBuffer() {
DCFlushRange(CH_BUF, sizeof(TChannel) * 64);
DCFlushRange(FX_BUF, sizeof(FxBuf) * 4);
}
/* 8029DAA0-8029DAC8 2983E0 0028+00 0/0 1/1 0/0 .text invalChannelAll__6JASDspFv */
void JASDsp::invalChannelAll() {
DCInvalidateRange(CH_BUF, sizeof(TChannel) * 64);
}
/* 8039B360-8039B3A0 0279C0 0040+00 1/1 0/0 0/0 .rodata DSPADPCM_FILTER__6JASDsp */
u8 const ALIGN_DECL(32) JASDsp::DSPADPCM_FILTER[64] = {
u8 const ATTRIBUTE_ALIGN(32) JASDsp::DSPADPCM_FILTER[64] = {
0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08, 0x00, 0x04, 0x00, 0x04, 0x00,
0x10, 0x00, 0xF8, 0x00, 0x0E, 0x00, 0xFA, 0x00, 0x0C, 0x00, 0xFC, 0x00, 0x12, 0x00, 0xF6, 0x00,
0x10, 0x68, 0xF7, 0x38, 0x12, 0xC0, 0xF7, 0x04, 0x14, 0x00, 0xF4, 0x00, 0x08, 0x00, 0xF8, 0x00,
0x04, 0x00, 0xFC, 0x00, 0xFC, 0x00, 0x04, 0x00, 0xFC, 0x00, 0x00, 0x00, 0xF8, 0x00, 0x00, 0x00,
};
/* 8039B3A0-8039B8A0 -00001 0500+00 1/1 0/0 0/0 .rodata DSPRES_FILTER__6JASDsp */
u32 const ALIGN_DECL(32) JASDsp::DSPRES_FILTER[320] = {
u32 const ATTRIBUTE_ALIGN(32) JASDsp::DSPRES_FILTER[320] = {
0x0C3966AD,
0x0D46FFDF,
0x0B396696,
@@ -416,7 +396,6 @@ u32 const ALIGN_DECL(32) JASDsp::DSPRES_FILTER[320] = {
0x7FF57FFD,
};
/* 8029DAC8-8029DB78 298408 00B0+00 0/0 1/1 0/0 .text initBuffer__6JASDspFv */
void JASDsp::initBuffer() {
CH_BUF = new(JASDram, 0x20) TChannel[64];
FX_BUF = new(JASDram, 0x20) FxBuf[4];
@@ -429,7 +408,6 @@ void JASDsp::initBuffer() {
flushBuffer();
}
/* 803C78F0-803C7920 024A10 0018+18 1/1 0/0 0/0 .data SEND_TABLE__6JASDsp */
u16 JASDsp::SEND_TABLE[] = {
0x0D00,
0x0D60,
@@ -445,8 +423,6 @@ u16 JASDsp::SEND_TABLE[] = {
0x0000,
};
/* 8029DB78-8029DCA4 2984B8 012C+00 1/1 1/1 0/0 .text
* setFXLine__6JASDspFUcPsPQ26JASDsp13FxlineConfig_ */
int JASDsp::setFXLine(u8 param_0, s16* param_1, JASDsp::FxlineConfig_* param_2) {
FxBuf* puVar3 = FX_BUF + param_0;
JASCriticalSection aJStack_20;
@@ -477,7 +453,6 @@ int JASDsp::setFXLine(u8 param_0, s16* param_1, JASDsp::FxlineConfig_* param_2)
return 1;
}
/* 8029DCA4-8029DCE0 2985E4 003C+00 0/0 1/1 0/0 .text init__Q26JASDsp8TChannelFv */
void JASDsp::TChannel::init() {
mPauseFlag = 0;
mIsFinished = 0;
@@ -488,7 +463,6 @@ void JASDsp::TChannel::init() {
initFilter();
}
/* 8029DCE0-8029DD44 298620 0064+00 0/0 1/1 0/0 .text playStart__Q26JASDsp8TChannelFv */
void JASDsp::TChannel::playStart() {
field_0x10c = 0;
field_0x060 = 0;
@@ -505,34 +479,27 @@ void JASDsp::TChannel::playStart() {
mIsActive = 1;
}
/* 8029DD44-8029DD50 298684 000C+00 0/0 1/1 0/0 .text playStop__Q26JASDsp8TChannelFv */
void JASDsp::TChannel::playStop() {
mIsActive = 0;
}
/* 8029DD50-8029DD60 298690 0010+00 0/0 1/1 0/0 .text replyFinishRequest__Q26JASDsp8TChannelFv */
void JASDsp::TChannel::replyFinishRequest() {
mIsFinished = 0;
mIsActive = 0;
}
/* 8029DD60-8029DD6C 2986A0 000C+00 0/0 1/1 0/0 .text forceStop__Q26JASDsp8TChannelFv */
void JASDsp::TChannel::forceStop() {
mForcedStop = 1;
}
/* 8029DD6C-8029DD7C 2986AC 0010+00 1/1 0/0 0/0 .text isActive__Q26JASDsp8TChannelCFv */
bool JASDsp::TChannel::isActive() const {
return mIsActive != 0;
}
/* 8029DD7C-8029DD8C 2986BC 0010+00 0/0 1/1 0/0 .text isFinish__Q26JASDsp8TChannelCFv */
bool JASDsp::TChannel::isFinish() const {
return mIsFinished != 0;
}
/* 8029DD8C-8029DEAC 2986CC 0120+00 0/0 1/1 0/0 .text
* setWaveInfo__Q26JASDsp8TChannelFRC11JASWaveInfoUlUl */
void JASDsp::TChannel::setWaveInfo(JASWaveInfo const& param_0, u32 param_1, u32 param_2) {
field_0x118 = param_1;
static const u8 COMP_BLOCKSAMPLES[8] = {0x10, 0x10, 0x01, 0x01, 0x01, 0x10, 0x10, 0x01};
@@ -575,16 +542,12 @@ void JASDsp::TChannel::setWaveInfo(JASWaveInfo const& param_0, u32 param_1, u32
}
}
/* 8029DEAC-8029DEC4 2987EC 0018+00 0/0 1/1 0/0 .text setOscInfo__Q26JASDsp8TChannelFUl
*/
void JASDsp::TChannel::setOscInfo(u32 param_0) {
field_0x118 = 0;
field_0x064 = 16;
field_0x100 = param_0;
}
/* 8029DEC4-8029DEF0 298804 002C+00 0/0 1/1 0/0 .text initAutoMixer__Q26JASDsp8TChannelFv
*/
void JASDsp::TChannel::initAutoMixer() {
if (field_0x058) {
field_0x054 = field_0x056;
@@ -594,8 +557,6 @@ void JASDsp::TChannel::initAutoMixer() {
}
}
/* 8029DEF0-8029DF1C 298830 002C+00 0/0 1/1 0/0 .text setAutoMixer__Q26JASDsp8TChannelFUsUcUcUcUc
*/
void JASDsp::TChannel::setAutoMixer(u16 param_0, u8 param_1, u8 param_2, u8 param_3,
u8 param_4) {
field_0x050 = (param_1 << 8) | param_2;
@@ -604,7 +565,6 @@ void JASDsp::TChannel::setAutoMixer(u16 param_0, u8 param_1, u8 param_2, u8 para
field_0x058 = 1;
}
/* 8029DF1C-8029DF34 29885C 0018+00 0/0 2/2 0/0 .text setPitch__Q26JASDsp8TChannelFUs */
void JASDsp::TChannel::setPitch(u16 param_0) {
if (param_0 >= 0x7fff) {
param_0 = 0x7fff;
@@ -612,8 +572,6 @@ void JASDsp::TChannel::setPitch(u16 param_0) {
mPitch = param_0;
}
/* 8029DF34-8029DF54 298874 0020+00 0/0 1/1 0/0 .text setMixerInitVolume__Q26JASDsp8TChannelFUcs
*/
void JASDsp::TChannel::setMixerInitVolume(u8 param_0, s16 param_1) {
u16* tmp = field_0x010[param_0];
tmp[2] = param_1;
@@ -621,7 +579,6 @@ void JASDsp::TChannel::setMixerInitVolume(u8 param_0, s16 param_1) {
tmp[3] = 0;
}
/* 8029DF54-8029DF80 298894 002C+00 0/0 1/1 0/0 .text setMixerVolume__Q26JASDsp8TChannelFUcs */
void JASDsp::TChannel::setMixerVolume(u8 param_0, s16 param_1) {
if (mForcedStop == 0) {
u16* tmp = field_0x010[param_0];
@@ -630,18 +587,14 @@ void JASDsp::TChannel::setMixerVolume(u8 param_0, s16 param_1) {
}
}
/* 8029DF80-8029DF8C 2988C0 000C+00 0/0 2/2 0/0 .text setPauseFlag__Q26JASDsp8TChannelFUc
*/
void JASDsp::TChannel::setPauseFlag(u8 param_0) {
mPauseFlag = param_0;
}
/* 8029DF8C-8029DFB0 2988CC 0024+00 0/0 1/1 0/0 .text flush__Q26JASDsp8TChannelFv */
void JASDsp::TChannel::flush() {
DCFlushRange(this, sizeof(*this));
}
/* 8029DFB0-8029E00C 2988F0 005C+00 1/1 0/0 0/0 .text initFilter__Q26JASDsp8TChannelFv */
void JASDsp::TChannel::initFilter() {
int i;
for (i = 0; i < 8; i++) {
@@ -655,7 +608,6 @@ void JASDsp::TChannel::initFilter() {
iir_filter_params[4] = 0;
}
/* 8029E00C-8029E044 29894C 0038+00 0/0 1/1 0/0 .text setFilterMode__Q26JASDsp8TChannelFUs */
void JASDsp::TChannel::setFilterMode(u16 param_0) {
u8 r30 = param_0 & 0x20;
u8 r31 = param_0 & 0x1f;
@@ -671,23 +623,18 @@ void JASDsp::TChannel::setFilterMode(u16 param_0) {
mFilterMode = r30 + r31;
}
/* 8029E044-8029E06C 298984 0028+00 0/0 1/1 0/0 .text setIIRFilterParam__Q26JASDsp8TChannelFPs */
void JASDsp::TChannel::setIIRFilterParam(s16* param_0) {
setFilterTable(iir_filter_params, param_0, 8);
}
/* 8029E06C-8029E094 2989AC 0028+00 0/0 1/1 0/0 .text setFIR8FilterParam__Q26JASDsp8TChannelFPs */
void JASDsp::TChannel::setFIR8FilterParam(s16* param_0) {
setFilterTable(fir_filter_params, param_0, 8);
}
/* 8029E094-8029E09C -00001 0008+00 0/0 0/0 0/0 .text setDistFilter__Q26JASDsp8TChannelFs
*/
void JASDsp::TChannel::setDistFilter(s16 param_0) {
iir_filter_params[4] = param_0;
}
/* 8029E09C-8029E0BC 2989DC 0020+00 0/0 1/1 0/0 .text setBusConnect__Q26JASDsp8TChannelFUcUc */
void JASDsp::TChannel::setBusConnect(u8 param_0, u8 param_1) {
u16* tmp = field_0x010[param_0];
static u16 const connect_table[12] = {
@@ -697,7 +644,6 @@ void JASDsp::TChannel::setBusConnect(u8 param_0, u8 param_1) {
tmp[0] = connect_table[param_1];
}
/* 8029E0BC-8029E130 2989FC 0074+00 0/0 1/1 0/0 .text DSP_CreateMap2__FUl */
u16 DSP_CreateMap2(u32 param_0) {
u16 r30 = 0;
JASDsp::TChannel* channel = &JASDsp::CH_BUF[param_0 << 4];
@@ -711,7 +657,6 @@ u16 DSP_CreateMap2(u32 param_0) {
return r30;
}
/* 804507B8-804507C0 000238 0004+04 0/0 5/5 0/0 .sdata one__11JASWaveInfo */
u32 JASWaveInfo::one = 1;
#ifdef DEBUG
-30
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: JASDriverIF
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASDriverIF.h"
@@ -10,42 +5,30 @@
#include "JSystem/JAudio2/JASDSPInterface.h"
#include <dolphin/os.h>
/* 8029E130-8029E150 298A70 0020+00 0/0 3/3 0/0 .text setDSPLevel__9JASDriverFf */
void JASDriver::setDSPLevel(f32 param_0) {
JASDsp::setDSPMixerLevel(param_0);
}
/* ############################################################################################## */
/* 804507C0-804507C4 000240 0002+02 1/0 0/0 0/0 .sdata MAX_MIXERLEVEL__9JASDriver */
u16 JASDriver::MAX_MIXERLEVEL = 0x2EE0;
/* 8029E150-8029E158 -00001 0008+00 0/0 0/0 0/0 .text getChannelLevel_dsp__9JASDriverFv
*/
u16 JASDriver::getChannelLevel_dsp() {
return JASDriver::MAX_MIXERLEVEL;
}
/* 8029E158-8029E178 298A98 0020+00 0/0 3/3 0/0 .text getDSPLevel__9JASDriverFv */
f32 JASDriver::getDSPLevel() {
return JASDsp::getDSPMixerLevel();
}
/* ############################################################################################## */
/* 804507C4-804507C8 000244 0004+00 2/1 0/0 0/0 .sdata JAS_SYSTEM_OUTPUT_MODE__9JASDriver
*/
u32 JASDriver::JAS_SYSTEM_OUTPUT_MODE = 0x00000001;
/* 8029E178-8029E180 298AB8 0008+00 0/0 2/2 0/0 .text setOutputMode__9JASDriverFUl */
void JASDriver::setOutputMode(u32 param_0) {
JAS_SYSTEM_OUTPUT_MODE = param_0;
}
/* 8029E180-8029E188 -00001 0008+00 0/0 0/0 0/0 .text getOutputMode__9JASDriverFv */
u32 JASDriver::getOutputMode() {
return JASDriver::JAS_SYSTEM_OUTPUT_MODE;
}
/* 8029E188-8029E1C4 298AC8 003C+00 0/0 1/1 0/0 .text waitSubFrame__9JASDriverFv */
void JASDriver::waitSubFrame() {
u32 r31 = getSubFrameCounter();
do {
@@ -53,18 +36,12 @@ void JASDriver::waitSubFrame() {
} while (r31 == getSubFrameCounter());
}
/* ############################################################################################## */
/* 80431C78-80431D78 05E998 0100+00 4/4 0/0 0/0 .bss sDspSyncCallback__9JASDriver */
JASCallbackMgr JASDriver::sDspSyncCallback;
/* 80431D78-80431E78 05EA98 0100+00 2/4 0/0 0/0 .bss sSubFrameCallback__9JASDriver */
JASCallbackMgr JASDriver::sSubFrameCallback;
/* 80431E78-80431F80 05EB98 0100+08 1/3 0/0 0/0 .bss sUpdateDacCallback__9JASDriver */
JASCallbackMgr JASDriver::sUpdateDacCallback;
/* 8029E1C4-8029E240 298B04 007C+00 0/0 2/2 0/0 .text rejectCallback__9JASDriverFPFPv_lPv
*/
int JASDriver::rejectCallback(DriverCallback callback, void* param_1) {
int r31 = sDspSyncCallback.reject(callback, param_1);
r31 += sSubFrameCallback.reject(callback, param_1);
@@ -72,29 +49,22 @@ int JASDriver::rejectCallback(DriverCallback callback, void* param_1) {
return r31;
}
/* 8029E240-8029E274 298B80 0034+00 0/0 1/1 0/0 .text registerDspSyncCallback__9JASDriverFPFPv_lPv
*/
bool JASDriver::registerDspSyncCallback(DriverCallback callback, void* param_1) {
return sDspSyncCallback.regist(callback, param_1);
}
/* 8029E274-8029E2A8 298BB4 0034+00 0/0 3/3 0/0 .text
* registerSubFrameCallback__9JASDriverFPFPv_lPv */
bool JASDriver::registerSubFrameCallback(DriverCallback callback, void* param_1) {
return sSubFrameCallback.regist(callback, param_1);
}
/* 8029E2A8-8029E2D0 298BE8 0028+00 0/0 1/1 0/0 .text subframeCallback__9JASDriverFv */
void JASDriver::subframeCallback() {
sSubFrameCallback.callback();
}
/* 8029E2D0-8029E2F8 298C10 0028+00 0/0 1/1 0/0 .text DSPSyncCallback__9JASDriverFv */
void JASDriver::DSPSyncCallback() {
sDspSyncCallback.callback();
}
/* 8029E2F8-8029E320 298C38 0028+00 0/0 1/1 0/0 .text updateDacCallback__9JASDriverFv */
void JASDriver::updateDacCallback() {
sUpdateDacCallback.callback();
}
-21
View File
@@ -1,27 +1,18 @@
//
// Generated By: dol2asm
// Translation Unit: JASDrumSet
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASDrumSet.h"
#include "JSystem/JAudio2/JASCalc.h"
#include "JSystem/JKernel/JKRHeap.h"
/* ############################################################################################## */
/* 802982EC-80298314 292C2C 0028+00 0/0 2/2 0/0 .text __ct__10JASDrumSetFv */
JASDrumSet::JASDrumSet() {
field_0x4 = NULL;
field_0x8 = 0;
}
/* 80298314-80298370 292C54 005C+00 1/0 0/0 0/0 .text __dt__10JASDrumSetFv */
JASDrumSet::~JASDrumSet() {
}
/* 80298370-802983CC 292CB0 005C+00 0/0 2/2 0/0 .text newPercArray__10JASDrumSetFUcP7JKRHeap */
void JASDrumSet::newPercArray(u8 param_0, JKRHeap* param_1) {
if (param_0) {
field_0x8 = param_0;
@@ -30,17 +21,12 @@ void JASDrumSet::newPercArray(u8 param_0, JKRHeap* param_1) {
}
}
/* ############################################################################################## */
/* 80431B58-80431B70 05E878 0018+00 1/1 0/0 0/0 .bss osc$213 */
static JASOscillator::Data osc;
/* 80451270-80451274 000770 0004+00 1/1 0/0 0/0 .sbss oscp$214 */
static JASOscillator::Data* oscp;
/* 80451274-80451278 000774 0004+00 1/1 0/0 0/0 .sbss None */
static s8 data_80451274[4];
/* 802983CC-802984B4 292D0C 00E8+00 1/0 0/0 0/0 .text getParam__10JASDrumSetCFiiP12JASInstParam */
bool JASDrumSet::getParam(int param_0, int param_1, JASInstParam* param_2) const {
if (field_0x4 == NULL) {
return false;
@@ -81,15 +67,11 @@ bool JASDrumSet::getParam(int param_0, int param_1, JASInstParam* param_2) const
return true;
}
/* 802984B4-802984C4 292DF4 0010+00 0/0 2/2 0/0 .text setPerc__10JASDrumSetFiPQ210JASDrumSet5TPerc
*/
void JASDrumSet::setPerc(int param_0, JASDrumSet::TPerc* param_1) {
field_0x4[param_0] = param_1;
}
/* ############################################################################################## */
/* 802984C4-802984E4 292E04 0020+00 0/0 2/2 0/0 .text __ct__Q210JASDrumSet5TPercFv */
JASDrumSet::TPerc::TPerc() {
mVolume = 1.0f;
mPitch = 1.0f;
@@ -97,11 +79,8 @@ JASDrumSet::TPerc::TPerc() {
field_0xc = 1000;
}
/* 802984E4-802984EC -00001 0008+00 0/0 0/0 0/0 .text setRelease__Q210JASDrumSet5TPercFUl
*/
void JASDrumSet::TPerc::setRelease(u32 param_0) {
field_0xc = param_0;
}
/* 802984EC-802984F8 292E2C 000C+00 1/0 0/0 0/0 .text getType__10JASDrumSetCFv */
u32 JASDrumSet::getType() const { return 'PERC'; }
-3
View File
@@ -4,15 +4,12 @@
#include "JSystem/JAudio2/JASTaskThread.h"
#include "JSystem/JKernel/JKRSolidHeap.h"
/* 80451208-80451210 000708 0004+04 2/1 0/0 0/0 .sbss sThread__6JASDvd */
JASTaskThread* JASDvd::sThread;
/* 8028FEFC-8028FF04 -00001 0008+00 0/0 0/0 0/0 .text getThreadPointer__6JASDvdFv */
JASTaskThread* JASDvd::getThreadPointer() {
return JASDvd::sThread;
}
/* 8028FF04-8028FFA8 28A844 00A4+00 0/0 1/1 0/0 .text createThread__6JASDvdFliUl */
bool JASDvd::createThread(s32 priority, int msgCount, u32 stackSize) {
if (sThread != NULL) {
JUT_WARN_DEVICE(32, 2, "%s", "JASDvd::createThread が2回呼び出されました");
+2 -31
View File
@@ -7,7 +7,6 @@
#include "JSystem/JKernel/JKRSolidHeap.h"
#include "JSystem/JUtility/JUTAssert.h"
/* 80290140-802901AC 28AA80 006C+00 1/1 2/2 0/0 .text __ct__7JASHeapFP11JASDisposer */
JASHeap::JASHeap(JASDisposer* disposer) : mTree(this) {
mDisposer = disposer;
mBase = NULL;
@@ -16,7 +15,6 @@ JASHeap::JASHeap(JASDisposer* disposer) : mTree(this) {
OSInitMutex(&mMutex);
}
/* 802901AC-8029021C 28AAEC 0070+00 1/1 0/0 0/0 .text initRootHeap__7JASHeapFPvUl */
void JASHeap::initRootHeap(void* param_0, u32 param_1) {
JUT_ASSERT(97, ! isAllocated());
JASMutexLock lock(&mMutex);
@@ -25,7 +23,6 @@ void JASHeap::initRootHeap(void* param_0, u32 param_1) {
mSize = param_1 - (u32(mBase) - u32(param_0));
}
/* 8029021C-802903F4 28AB5C 01D8+00 0/0 2/2 0/0 .text alloc__7JASHeapFP7JASHeapUl */
bool JASHeap::alloc(JASHeap* mother, u32 param_1) {
JUT_ASSERT(120, mother != NULL);
JASMutexLock lock(&mMutex);
@@ -83,7 +80,6 @@ bool JASHeap::alloc(JASHeap* mother, u32 param_1) {
return 1;
}
/* 802903F4-802904E4 28AD34 00F0+00 0/0 1/1 0/0 .text allocTail__7JASHeapFP7JASHeapUl */
bool JASHeap::allocTail(JASHeap* mother, u32 size) {
JASMutexLock lock(&mMutex);
if (isAllocated()) {
@@ -103,8 +99,6 @@ bool JASHeap::allocTail(JASHeap* mother, u32 size) {
return true;
}
/* 802904E4-80290608 28AE24 0124+00 0/0 4/4 0/0 .text free__7JASHeapFv */
// NONMATCHING regswap
bool JASHeap::free() {
JASMutexLock lock(&mMutex);
if (!isAllocated()) {
@@ -138,12 +132,9 @@ bool JASHeap::free() {
return true;
}
/* 80290608-802906F0 28AF48 00E8+00 2/2 0/0 0/0 .text
* insertChild__7JASHeapFP7JASHeapP7JASHeapPvUlb */
// NONMATCHING regalloc
void JASHeap::insertChild(JASHeap* heap, JASHeap* next, void* param_2, u32 param_3, bool param_4) {
JUT_ASSERT(537, heap != NULL);
JUT_ASSERT(538, next == NULL || &mTree == next->mTree.getParent());
JUT_ASSERT(513, heap != NULL);
JUT_ASSERT(514, next == NULL || &mTree == next->mTree.getParent());
JASMutexLock lock(&mMutex);
if (!param_4) {
JSUTreeIterator<JASHeap> it;
@@ -163,7 +154,6 @@ void JASHeap::insertChild(JASHeap* heap, JASHeap* next, void* param_2, u32 param
mTree.insertChild(&next->mTree, &heap->mTree);
}
/* 802906F0-8029077C 28B030 008C+00 3/3 0/0 0/0 .text getTailHeap__7JASHeapFv */
JASHeap* JASHeap::getTailHeap() {
JSUTreeIterator<JASHeap> it;
JASMutexLock lock(&mMutex);
@@ -178,7 +168,6 @@ JASHeap* JASHeap::getTailHeap() {
return it.getObject();
}
/* 8029077C-802907E0 28B0BC 0064+00 2/2 0/0 0/0 .text getTailOffset__7JASHeapFv */
u32 JASHeap::getTailOffset() {
JASMutexLock lock(&mMutex);
JASHeap* heap = getTailHeap();
@@ -186,14 +175,12 @@ u32 JASHeap::getTailOffset() {
return offset;
}
/* 802907E0-80290848 28B120 0068+00 2/2 0/0 0/0 .text getCurOffset__7JASHeapFv */
u32 JASHeap::getCurOffset() {
JASMutexLock lock(&mMutex);
u32 offset = !field_0x40 ? 0 : field_0x40->mBase + field_0x40->mSize - mBase;
return offset;
}
/* 80290848-80290860 28B188 0018+00 0/0 32/32 0/0 .text __ct__17JASGenericMemPoolFv */
JASGenericMemPool::JASGenericMemPool() {
field_0x0 = NULL;
freeMemCount = 0;
@@ -201,7 +188,6 @@ JASGenericMemPool::JASGenericMemPool() {
usedMemCount = 0;
}
/* 80290860-802908C8 28B1A0 0068+00 0/0 9/9 0/0 .text __dt__17JASGenericMemPoolFv */
JASGenericMemPool::~JASGenericMemPool() {
void* chunk = field_0x0;
while (chunk != NULL) {
@@ -211,11 +197,8 @@ JASGenericMemPool::~JASGenericMemPool() {
}
}
/* 80451210-80451214 000710 0004+00 2/2 15/15 0/0 .sbss JASDram */
JKRSolidHeap* JASDram;
/* 802908C8-80290948 28B208 0080+00 0/0 4/4 0/0 .text newMemPool__17JASGenericMemPoolFUli
*/
void JASGenericMemPool::newMemPool(u32 size, int param_1) {
for (int i = 0; i < param_1; i++) {
void* chunk = new (JASDram, 0) u8[size];
@@ -226,7 +209,6 @@ void JASGenericMemPool::newMemPool(u32 size, int param_1) {
totalMemCount += param_1;
}
/* 80290948-80290994 28B288 004C+00 0/0 13/13 0/0 .text alloc__17JASGenericMemPoolFUl */
void* JASGenericMemPool::alloc(u32 param_0) {
void* chunk = field_0x0;
if (chunk == NULL) {
@@ -240,7 +222,6 @@ void* JASGenericMemPool::alloc(u32 param_0) {
return chunk;
}
/* 80290994-802909B8 28B2D4 0024+00 0/0 15/15 0/0 .text free__17JASGenericMemPoolFPvUl */
void JASGenericMemPool::free(void* ptr, u32 param_1) {
if (ptr != NULL) {
*(void**)ptr = field_0x0;
@@ -249,17 +230,12 @@ void JASGenericMemPool::free(void* ptr, u32 param_1) {
}
}
/* 80451214-80451218 000714 0004+00 1/1 0/0 0/0 .sbss sAramBase__9JASKernel */
u32 JASKernel::sAramBase;
/* 80451218-8045121C 000718 0004+00 2/1 0/0 0/0 .sbss sSystemHeap__9JASKernel */
JKRHeap* JASKernel::sSystemHeap;
/* 8045121C-80451220 00071C 0004+00 2/1 0/0 0/0 .sbss sCommandHeap__9JASKernel */
JASMemChunkPool<1024, JASThreadingModel::ObjectLevelLockable>* JASKernel::sCommandHeap;
/* 802909B8-80290AC0 28B2F8 0108+00 0/0 1/1 0/0 .text setupRootHeap__9JASKernelFP12JKRSolidHeapUl
*/
void JASKernel::setupRootHeap(JKRSolidHeap* heap, u32 size) {
JUT_ASSERT(784, heap);
sSystemHeap = JKRExpHeap::create(size, heap, false);
@@ -269,26 +245,21 @@ void JASKernel::setupRootHeap(JKRSolidHeap* heap, u32 size) {
JASDram = heap;
}
/* 80290AC0-80290AC8 -00001 0008+00 0/0 0/0 0/0 .text getSystemHeap__9JASKernelFv */
JKRHeap* JASKernel::getSystemHeap() {
return JASKernel::sSystemHeap;
}
/* 80290AC8-80290AD0 -00001 0008+00 0/0 0/0 0/0 .text getCommandHeap__9JASKernelFv */
JASMemChunkPool<1024, JASThreadingModel::ObjectLevelLockable>* JASKernel::getCommandHeap() {
return JASKernel::sCommandHeap;
}
/* 804315DC-80431620 05E2FC 0044+00 3/3 0/0 0/0 .bss audioAramHeap__9JASKernel */
JASHeap JASKernel::audioAramHeap;
/* 80290AD0-80290B08 28B410 0038+00 0/0 1/1 0/0 .text setupAramHeap__9JASKernelFUlUl */
void JASKernel::setupAramHeap(u32 param_0, u32 param_1) {
sAramBase = param_0;
audioAramHeap.initRootHeap((void*)sAramBase, param_1);
}
/* 80290B08-80290B14 28B448 000C+00 0/0 3/2 0/0 .text getAramHeap__9JASKernelFv */
JASHeap* JASKernel::getAramHeap() {
return &audioAramHeap;
}
-16
View File
@@ -1,16 +1,9 @@
//
// Generated By: dol2asm
// Translation Unit: JASLfo
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASLfo.h"
#include "SSystem/SComponent/c_math.h"
/* ############################################################################################## */
/* 8029BD14-8029BD44 296654 0030+00 1/1 1/1 0/0 .text __ct__6JASLfoFv */
JASLfo::JASLfo() {
field_0x0 = 0;
field_0x4 = 1;
@@ -21,9 +14,7 @@ JASLfo::JASLfo() {
field_0x16 = 0;
}
/* ############################################################################################## */
/* 8029BD44-8029BDD8 296684 0094+00 0/0 3/3 0/0 .text getValue__6JASLfoCFv */
f32 JASLfo::getValue() const {
if (field_0x16) {
return 0.0f;
@@ -36,9 +27,7 @@ f32 JASLfo::getValue() const {
return mDepth * JMASinLap(field_0x8);
}
/* ############################################################################################## */
/* 8029BDD8-8029BE2C 296718 0054+00 0/0 2/2 0/0 .text incCounter__6JASLfoFf */
void JASLfo::incCounter(f32 param_0) {
if (field_0x16) {
field_0x16--;
@@ -51,11 +40,8 @@ void JASLfo::incCounter(f32 param_0) {
}
}
/* ############################################################################################## */
/* 80431C40-80431C58 05E960 0018+00 2/2 1/1 0/0 .bss sFreeRunLfo__6JASLfo */
JASLfo JASLfo::sFreeRunLfo;
/* 8029BE2C-8029BE6C 29676C 0040+00 0/0 1/1 0/0 .text resetCounter__6JASLfoFv */
void JASLfo::resetCounter() {
field_0x16 = mDelay;
switch (field_0x4) {
@@ -67,5 +53,3 @@ void JASLfo::resetCounter() {
break;
}
}
/* 8029BE6C-8029BE94 2967AC 0028+00 0/0 1/0 0/0 .text __sinit_JASLfo_cpp */
-23
View File
@@ -1,13 +1,7 @@
//
// Generated By: dol2asm
// Translation Unit: JASOscillator
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASOscillator.h"
/* 8029BE94-8029BEC4 2967D4 0030+00 0/0 1/1 0/0 .text __ct__13JASOscillatorFv */
JASOscillator::JASOscillator() {
mData = NULL;
_14 = 0;
@@ -20,10 +14,7 @@ JASOscillator::JASOscillator() {
_04 = 0.0f;
}
/* ############################################################################################## */
/* 8029BEC4-8029BF68 296804 00A4+00 0/0 1/1 0/0 .text
* initStart__13JASOscillatorFPCQ213JASOscillator4Data */
void JASOscillator::initStart(JASOscillator::Data const* data) {
mData = data;
_04 = 0.0f;
@@ -47,7 +38,6 @@ void JASOscillator::initStart(JASOscillator::Data const* data) {
_1C = 1;
}
/* 8029BF68-8029BFC8 2968A8 0060+00 0/0 1/1 0/0 .text incCounter__13JASOscillatorFf */
void JASOscillator::incCounter(f32 param_0) {
const short* v1;
switch (_1C) {
@@ -61,12 +51,10 @@ void JASOscillator::incCounter(f32 param_0) {
update();
}
/* 8029BFC8-8029BFE4 296908 001C+00 0/0 1/1 0/0 .text getValue__13JASOscillatorCFv */
f32 JASOscillator::getValue() const {
return _08 * mData->mScale + mData->_14;
}
/* 8029BFE4-8029C0E0 296924 00FC+00 0/0 1/1 0/0 .text release__13JASOscillatorFv */
void JASOscillator::release() {
if (mData->_0C == NULL && mDirectRelease == 0) {
stop();
@@ -96,7 +84,6 @@ void JASOscillator::release() {
update();
}
/* 8029C0E0-8029C2C0 296A20 01E0+00 2/2 1/1 0/0 .text update__13JASOscillatorFv */
void JASOscillator::update() {
if (_1C == 4) {
s16 x = mDirectRelease & 0x3FFF;
@@ -149,15 +136,11 @@ void JASOscillator::update() {
updateCurrentValue(psVar1[_14]._2);
}
/* ############################################################################################## */
/* 8039B1D0-8039B214 027830 0044+00 1/0 0/0 0/0 .rodata sCurveTableLinear__13JASOscillator
*/
f32 const JASOscillator::sCurveTableLinear[17] = {
1.0, 0.9375, 0.875, 0.8125, 0.75, 0.6875, 0.625, 0.5625, 0.5,
0.4375, 0.375, 0.3125, 0.25, 0.1875, 0.125, 0.0625, 0.0,
};
/* 8039B214-8039B258 027874 0044+00 1/0 0/0 0/0 .rodata sCurveTableSampleCell__13JASOscillator */
f32 const JASOscillator::sCurveTableSampleCell[17] = {
1.0, 0.9704890251159668, 0.7812740206718445, 0.5462809801101685, 0.39979198575019836,
0.28931498527526855, 0.21210399270057678, 0.15747599303722382, 0.1126129999756813, 0.08178959786891937,
@@ -165,23 +148,18 @@ f32 const JASOscillator::sCurveTableSampleCell[17] = {
0.00915555004030466, 0.0
};
/* 8039B258-8039B29C 0278B8 0044+00 1/0 0/0 0/0 .rodata sCurveTableSqRoot__13JASOscillator
*/
f32 const JASOscillator::sCurveTableSqRoot[17] = {
1.0, 0.8789060115814209, 0.765625, 0.6601560115814209, 0.5625, 0.4726560115814209,
0.390625, 0.3164060115814209, 0.25, 0.1914059966802597, 0.140625, 0.09765619784593582,
0.0625, 0.03515620157122612, 0.015625, 0.00390625, 0.0
};
/* 8039B29C-8039B2E0 0278FC 0044+00 1/0 0/0 0/0 .rodata sCurveTableSquare__13JASOscillator
*/
f32 const JASOscillator::sCurveTableSquare[17] = {
1.0, 0.9682459831237793, 0.9354140162467957, 0.9013879895210266, 0.8660249710083008,
0.8291559815406799, 0.790569007396698, 0.75, 0.7071070075035095, 0.66143798828125,
0.6123719811439514, 0.55901700258255, 0.5, 0.433012992143631, 0.35355299711227417, 0.25, 0.0,
};
/* 803C78A8-803C78B8 -00001 0010+00 1/1 0/0 0/0 .data table_list$151 */
static f32* table_list[4] = {
(f32*)JASOscillator::sCurveTableLinear,
(f32*)JASOscillator::sCurveTableSquare,
@@ -189,7 +167,6 @@ static f32* table_list[4] = {
(f32*)JASOscillator::sCurveTableSampleCell,
};
/* 8029C2C0-8029C388 296C00 00C8+00 1/1 0/0 0/0 .text updateCurrentValue__13JASOscillatorFf */
void JASOscillator::updateCurrentValue(f32 param_0) {
f32* table = table_list[_18];
f32 fVar1 = 16.0f * (_04 / param_0);
-12
View File
@@ -1,14 +1,8 @@
//
// Generated By: dol2asm
// Translation Unit: JASProbe
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASProbe.h"
#include "dolphin/os.h"
/* 80290D74-80290DC4 28B6B4 0050+00 1/1 0/0 0/0 .text start__8JASProbeFPCc */
void JASProbe::start(char const* name) {
volatile BOOL interrupts = OSDisableInterrupts();
mName = name;
@@ -16,9 +10,7 @@ void JASProbe::start(char const* name) {
OSRestoreInterrupts(interrupts);
}
/* ############################################################################################## */
/* 80290DC4-80290EE4 28B704 0120+00 1/1 0/0 0/0 .text stop__8JASProbeFv */
void JASProbe::stop() {
volatile int interrupts = OSDisableInterrupts();
_08 = (u32)OSGetTime() - mStartTime;
@@ -35,11 +27,8 @@ void JASProbe::stop() {
OSRestoreInterrupts(interrupts);
}
/* ############################################################################################## */
/* 80431620-80431660 05E340 0040+00 2/2 0/0 0/0 .bss sProbeTable__8JASProbe */
JASProbe* JASProbe::sProbeTable[16];
/* 80290EE4-80290F24 28B824 0040+00 0/0 7/7 0/0 .text start__8JASProbeFlPCc */
void JASProbe::start(s32 index, char const* name) {
if (index < 16) {
if (sProbeTable[index] != NULL) {
@@ -48,7 +37,6 @@ void JASProbe::start(s32 index, char const* name) {
}
}
/* 80290F24-80290F64 28B864 0040+00 0/0 6/6 0/0 .text stop__8JASProbeFl */
void JASProbe::stop(s32 index) {
if (index < 16) {
if (sProbeTable[index] != NULL) {
-13
View File
@@ -1,30 +1,20 @@
//
// Generated By: dol2asm
// Translation Unit: JASRegisterParam
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASRegisterParam.h"
/* 80293644-80293664 28DF84 0020+00 0/0 1/1 0/0 .text __ct__16JASRegisterParamFv */
JASRegisterParam::JASRegisterParam() {
for (int i = 0; i < 14; i++) {
field_0x0[i] = 0;
}
}
/* 80293664-80293684 28DFA4 0020+00 0/0 1/1 0/0 .text init__16JASRegisterParamFv */
void JASRegisterParam::init() {
for (int i = 0; i < 14; i++) {
field_0x0[i] = 0;
}
}
/* ############################################################################################## */
/* 80293684-802937B8 28DFC4 0134+00 1/0 4/4 0/0 .text
* write__16JASRegisterParamFQ216JASRegisterParam5RegIDUl */
void JASRegisterParam::write(JASRegisterParam::RegID param_0, u32 param_1) {
if (param_0 < 14) {
if (param_0 <= 2) {
@@ -80,10 +70,7 @@ void JASRegisterParam::write(JASRegisterParam::RegID param_0, u32 param_1) {
}
}
/* ############################################################################################## */
/* 802937B8-802938BC 28E0F8 0104+00 1/0 1/1 0/0 .text
* read__16JASRegisterParamFQ216JASRegisterParam5RegID */
u32 JASRegisterParam::read(JASRegisterParam::RegID param_0) {
if (param_0 < 14) {
return field_0x0[param_0];
-6
View File
@@ -8,22 +8,16 @@
#include "JSystem/JAudio2/JASMutex.h"
#include "stdio.h"
/* 80431660-80431678 05E380 0018+00 1/1 0/0 0/0 .bss sMutex */
static OSMutex sMutex;
/* 80451220-80451224 000720 0004+00 1/1 0/0 0/0 .sbss sBuffer */
static char* sBuffer;
/* 80451224-80451228 000724 0004+00 1/1 0/0 0/0 .sbss sLineMax */
static int sLineMax;
/* 80451228-8045122C 000728 0004+00 1/1 0/0 0/0 .sbss sLineCount */
static int sLineCount;
/* 8045122C-80451230 00072C 0004+00 1/1 0/0 0/0 .sbss sTop */
static int sTop;
/* 80290F64-80291060 28B8A4 00FC+00 0/0 5/5 0/0 .text JASReport__FPCce */
void JASReport(const char * str, ...) {
if(sBuffer) {
va_list vl;
-8
View File
@@ -10,8 +10,6 @@
#include "JSystem/JAudio2/JASTaskThread.h"
/* 80290BD0-80290C04 28B510 0034+00 0/0 2/2 0/0 .text
* getResSize__15JASResArcLoaderFPC10JKRArchiveUs */
size_t JASResArcLoader::getResSize(JKRArchive const* i_archiveP, u16 i_resourceID) {
JKRArchive::SDIFileEntry* file = i_archiveP->findIdResource(i_resourceID);
@@ -22,8 +20,6 @@ size_t JASResArcLoader::getResSize(JKRArchive const* i_archiveP, u16 i_resourceI
return file->data_size;
}
/* 80290C04-80290C7C 28B544 0078+00 0/0 1/1 0/0 .text
* getResMaxSize__15JASResArcLoaderFPC10JKRArchive */
size_t JASResArcLoader::getResMaxSize(JKRArchive const* i_archiveP) {
u32 maxSize, index;
u32 fileEntries = i_archiveP->countFile();
@@ -40,8 +36,6 @@ size_t JASResArcLoader::getResMaxSize(JKRArchive const* i_archiveP) {
return maxSize;
}
/* 80290C7C-80290D18 28B5BC 009C+00 1/1 0/0 0/0 .text loadResourceCallback__15JASResArcLoaderFPv
*/
static void JASResArcLoader::loadResourceCallback(void* args) {
CallbackArgs* castedArgs = static_cast<CallbackArgs*>(args);
u32 readResult = castedArgs->mArchive->readResource(castedArgs->mBuffer, castedArgs->mBufferSize, castedArgs->mID);
@@ -60,8 +54,6 @@ static void JASResArcLoader::loadResourceCallback(void* args) {
}
}
/* 80290D18-80290D74 28B658 005C+00 0/0 1/1 0/0 .text
* loadResourceAsync__15JASResArcLoaderFP10JKRArchiveUsPUcUlPFUlUl_vUl */
int JASResArcLoader::loadResourceAsync(JKRArchive* archive, u16 id, u8* buffer, u32 size, LoadCallback callback, u32 cbArg)
{
-22
View File
@@ -1,19 +1,11 @@
//
// Generated By: dol2asm
// Translation Unit: JASSeqCtrl
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASSeqCtrl.h"
#include "JSystem/JAudio2/JASSeqParser.h"
#include "JSystem/JAudio2/JASTrack.h"
/* ############################################################################################## */
/* 80451238-80451240 000738 0004+04 3/3 0/0 0/0 .sbss sDefaultParser__10JASSeqCtrl */
JASSeqParser JASSeqCtrl::sDefaultParser;
/* 802938BC-80293924 28E1FC 0068+00 0/0 1/1 0/0 .text __ct__10JASSeqCtrlFv */
JASSeqCtrl::JASSeqCtrl() {
mReader.init();
field_0x3c = &sDefaultParser;
@@ -29,7 +21,6 @@ JASSeqCtrl::JASSeqCtrl() {
mReader.init();
}
/* 80293924-80293980 28E264 005C+00 0/0 1/1 0/0 .text init__10JASSeqCtrlFv */
void JASSeqCtrl::init() {
mReader.init();
field_0x3c = &sDefaultParser;
@@ -44,14 +35,11 @@ void JASSeqCtrl::init() {
field_0x51 = 0;
}
/* 80293980-802939C4 28E2C0 0044+00 0/0 1/1 0/0 .text start__10JASSeqCtrlFPvUl */
void JASSeqCtrl::start(void* param_0, u32 param_1) {
mReader.init(param_0);
mReader.jump(param_1);
}
/* 802939C4-80293ABC 28E304 00F8+00 0/0 1/1 0/0 .text tickProc__10JASSeqCtrlFP8JASTrack
*/
int JASSeqCtrl::tickProc(JASTrack* param_0) {
if (!mReader.getBase()) {
return 0;
@@ -83,25 +71,20 @@ int JASSeqCtrl::tickProc(JASTrack* param_0) {
return 0;
}
/* 80293ABC-80293AE0 28E3FC 0024+00 2/2 2/2 0/0 .text
* interrupt__10JASSeqCtrlFQ210JASSeqCtrl8IntrType */
void JASSeqCtrl::interrupt(JASSeqCtrl::IntrType param_0) {
if (field_0x4e & (1 << param_0)) {
field_0x4c |= (1 << param_0);
}
}
/* 80293AE0-80293AF0 28E420 0010+00 0/0 1/1 0/0 .text setIntrMask__10JASSeqCtrlFUl */
void JASSeqCtrl::setIntrMask(u32 param_0) {
field_0x4e |= param_0;
}
/* 80293AF0-80293B00 28E430 0010+00 0/0 1/1 0/0 .text clrIntrMask__10JASSeqCtrlFUl */
void JASSeqCtrl::clrIntrMask(u32 param_0) {
field_0x4e &= ~param_0;
}
/* 80293B00-80293B28 28E440 0028+00 0/0 1/1 0/0 .text retIntr__10JASSeqCtrlFv */
int JASSeqCtrl::retIntr() {
if (field_0x44 == NULL) {
return 0;
@@ -112,7 +95,6 @@ int JASSeqCtrl::retIntr() {
return 1;
}
/* 80293B28-80293B78 28E468 0050+00 1/1 0/0 0/0 .text findIntr__10JASSeqCtrlFv */
int JASSeqCtrl::findIntr() {
u32 uVar1 = field_0x4e & field_0x4c;
for (int i = 0; uVar1 != 0; uVar1 >>= 1, i++) {
@@ -124,7 +106,6 @@ int JASSeqCtrl::findIntr() {
return -1;
}
/* 80293B78-80293BE8 28E4B8 0070+00 1/1 2/2 0/0 .text checkIntr__10JASSeqCtrlFv */
void JASSeqCtrl::checkIntr() {
if (field_0x44) return;
int intr = findIntr();
@@ -138,7 +119,6 @@ void JASSeqCtrl::checkIntr() {
mReader.jump(uVar1);
}
/* 80293BE8-80293C6C 28E528 0084+00 1/1 0/0 0/0 .text timerProcess__10JASSeqCtrlFv */
void JASSeqCtrl::timerProcess() {
if (field_0x54 == 0) return;
@@ -156,5 +136,3 @@ void JASSeqCtrl::timerProcess() {
field_0x54 = field_0x58;
}
}
/* ############################################################################################## */
-101
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: JASSeqParser
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASSeqParser.h"
@@ -14,7 +9,6 @@
#include "JSystem/JUtility/JUTAssert.h"
/* 803C5E80-803C6480 022FA0 0600+00 1/2 0/0 0/0 .data sCmdInfo__12JASSeqParser */
JASSeqParser::CmdInfo JASSeqParser::sCmdInfo[96] = {
NULL, 0x0000, 0x0000,
NULL, 0x0000, 0x0000,
@@ -114,7 +108,6 @@ JASSeqParser::CmdInfo JASSeqParser::sCmdInfo[96] = {
&JASSeqParser::cmdFinish, 0x0000, 0x0000,
};
/* 803C648C-803C747C 0235AC 0FF0+00 1/2 0/0 0/0 .data sExtCmdInfo__12JASSeqParser */
JASSeqParser::CmdInfo JASSeqParser::sExtCmdInfo[255] = {
NULL, 0x0000, 0x0000,
&JASSeqParser::cmdDump, 0x0000, 0x0000,
@@ -125,8 +118,6 @@ JASSeqParser::CmdInfo JASSeqParser::sExtCmdInfo[255] = {
NULL, 0x0000, 0x0000,
};
/* 80293CF4-80293DC4 28E634 00D0+00 3/3 0/0 0/0 .text
* conditionCheck__12JASSeqParserFP8JASTrackQ212JASSeqParser15BranchCondition */
bool JASSeqParser::conditionCheck(JASTrack* param_0, JASSeqParser::BranchCondition param_1) {
u16 reg = readReg(param_0, 3);
switch (param_1) {
@@ -148,7 +139,6 @@ bool JASSeqParser::conditionCheck(JASTrack* param_0, JASSeqParser::BranchConditi
}
}
/* 80293DC4-80293FC8 28E704 0204+00 8/7 0/0 0/0 .text writeReg__12JASSeqParserFP8JASTrackUlUl */
void JASSeqParser::writeReg(JASTrack* param_0, u32 param_1, u32 param_2) {
param_0->writeReg(JASRegisterParam::REG3, param_2);
if (param_1 < 0x40) {
@@ -241,7 +231,6 @@ void JASSeqParser::writeReg(JASTrack* param_0, u32 param_1, u32 param_2) {
}
}
/* 80293FC8-80294188 28E908 01C0+00 7/6 0/0 0/0 .text readReg__12JASSeqParserCFP8JASTrackUl */
u32 JASSeqParser::readReg(JASTrack* param_0, u32 param_1) const {
if (param_1 < 0x40) {
return param_0->readReg(JASRegisterParam::RegID(param_1));
@@ -345,8 +334,6 @@ u32 JASSeqParser::readReg(JASTrack* param_0, u32 param_1) const {
return result;
}
/* 80294188-802941F0 28EAC8 0068+00 1/0 0/0 0/0 .text cmdOpenTrack__12JASSeqParserFP8JASTrackPUl
*/
s32 JASSeqParser::cmdOpenTrack(JASTrack* param_0, u32* param_1) {
u32 r29 = param_1[0];
u32 r28 = param_1[1];
@@ -360,20 +347,16 @@ s32 JASSeqParser::cmdOpenTrack(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 802941F0-8029421C 28EB30 002C+00 1/0 0/0 0/0 .text cmdCloseTrack__12JASSeqParserFP8JASTrackPUl
*/
s32 JASSeqParser::cmdCloseTrack(JASTrack* param_0, u32* param_1) {
param_0->closeChild(*param_1);
return 0;
}
/* 8029421C-80294248 28EB5C 002C+00 1/0 0/0 0/0 .text cmdCall__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdCall(JASTrack* param_0, u32* param_1) {
param_0->getSeqCtrl()->call(*param_1);
return 0;
}
/* 80294248-8029429C 28EB88 0054+00 1/0 0/0 0/0 .text cmdCallF__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdCallF(JASTrack* param_0, u32* param_1) {
if (conditionCheck(param_0, BranchCondition(param_1[0]))) {
param_0->getSeqCtrl()->call(param_1[1]);
@@ -381,7 +364,6 @@ s32 JASSeqParser::cmdCallF(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 8029429C-802942D4 28EBDC 0038+00 1/0 0/0 0/0 .text cmdRet__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdRet(JASTrack* param_0, u32* param_1) {
if (!param_0->getSeqCtrl()->ret()) {
JUT_WARN(718, "%s", "cannot ret for call-stack is NULL");
@@ -390,7 +372,6 @@ s32 JASSeqParser::cmdRet(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 802942D4-80294328 28EC14 0054+00 1/0 0/0 0/0 .text cmdRetF__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdRetF(JASTrack* param_0, u32* param_1) {
if (conditionCheck(param_0, BranchCondition(param_1[0]))) {
if (!param_0->getSeqCtrl()->ret()) {
@@ -401,13 +382,11 @@ s32 JASSeqParser::cmdRetF(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294328-80294340 28EC68 0018+00 1/0 0/0 0/0 .text cmdJmp__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdJmp(JASTrack* param_0, u32* param_1) {
param_0->getSeqCtrl()->jump(param_1[0]);
return 0;
}
/* 80294340-80294398 28EC80 0058+00 1/0 0/0 0/0 .text cmdJmpF__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdJmpF(JASTrack* param_0, u32* param_1) {
if (conditionCheck(param_0, BranchCondition(param_1[0]))) {
param_0->getSeqCtrl()->jump(param_1[1]);
@@ -415,7 +394,6 @@ s32 JASSeqParser::cmdJmpF(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294398-802943CC 28ECD8 0034+00 1/0 0/0 0/0 .text cmdJmpTable__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdJmpTable(JASTrack* param_0, u32* param_1) {
JASSeqCtrl* seqCtrl = param_0->getSeqCtrl();
u32 uVar1 = param_1[0];
@@ -424,8 +402,6 @@ s32 JASSeqParser::cmdJmpTable(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 802943CC-8029441C 28ED0C 0050+00 1/0 0/0 0/0 .text cmdCallTable__12JASSeqParserFP8JASTrackPUl
*/
s32 JASSeqParser::cmdCallTable(JASTrack* param_0, u32* param_1) {
JASSeqCtrl* seqCtrl = param_0->getSeqCtrl();
u32 uVar1 = param_1[0];
@@ -434,52 +410,42 @@ s32 JASSeqParser::cmdCallTable(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 8029441C-80294448 28ED5C 002C+00 1/0 0/0 0/0 .text cmdLoopS__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdLoopS(JASTrack* param_0, u32* param_1) {
param_0->getSeqCtrl()->loopStart(param_1[0]);
return 0;
}
/* 80294448-80294470 28ED88 0028+00 1/0 0/0 0/0 .text cmdLoopE__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdLoopE(JASTrack* param_0, u32* param_1) {
param_0->getSeqCtrl()->loopEnd();
return 0;
}
/* 80294470-802944B4 28EDB0 0044+00 1/0 0/0 0/0 .text cmdNote__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdNote(JASTrack* param_0, u32* param_1) {
execNoteOnGate(param_0, param_1[1], param_1[2], param_1[3], param_1[0]);
return 0;
}
/* 802944B4-802944F4 28EDF4 0040+00 1/0 0/0 0/0 .text cmdNoteOn__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdNoteOn(JASTrack* param_0, u32* param_1) {
execNoteOnMidi(param_0, param_1[1], param_1[0], param_1[2]);
return 0;
}
/* 802944F4-80294528 28EE34 0034+00 1/0 0/0 0/0 .text cmdNoteOff__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdNoteOff(JASTrack* param_0, u32* param_1) {
execNoteOff(param_0, param_1[0]);
return 0;
}
/* 80294528-80294588 28EE68 0060+00 1/0 0/0 0/0 .text cmdReadPort__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdReadPort(JASTrack* param_0, u32* param_1) {
u16 tmp = param_0->readPortSelf(param_1[0]);
writeReg(param_0, param_1[1], tmp);
return 0;
}
/* 80294588-802945BC 28EEC8 0034+00 1/0 0/0 0/0 .text cmdWritePort__12JASSeqParserFP8JASTrackPUl
*/
s32 JASSeqParser::cmdWritePort(JASTrack* param_0, u32* param_1) {
param_0->writePortSelf(param_1[0], param_1[1]);
return 0;
}
/* 802945BC-802945F8 28EEFC 003C+00 1/0 0/0 0/0 .text
* cmdParentWritePort__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdParentWritePort(JASTrack* param_0, u32* param_1) {
{
u32* p1 = param_1;
@@ -494,8 +460,6 @@ s32 JASSeqParser::cmdParentWritePort(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 802945F8-80294644 28EF38 004C+00 1/0 0/0 0/0 .text
* cmdChildWritePort__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdChildWritePort(JASTrack* param_0, u32* param_1) {
{
u8 val = param_1[0];
@@ -509,8 +473,6 @@ s32 JASSeqParser::cmdChildWritePort(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294644-802946AC 28EF84 0068+00 1/0 0/0 0/0 .text
* cmdParentReadPort__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdParentReadPort(JASTrack* param_0, u32* param_1) {
u32* p1 = param_1;
u32* p2 = param_1 + 1;
@@ -524,8 +486,6 @@ s32 JASSeqParser::cmdParentReadPort(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 802946AC-80294724 28EFEC 0078+00 1/0 0/0 0/0 .text
* cmdChildReadPort__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdChildReadPort(JASTrack* param_0, u32* param_1) {
u8 val = param_1[0];
u32* p2 = param_1 + 1;
@@ -539,23 +499,18 @@ s32 JASSeqParser::cmdChildReadPort(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294724-80294770 28F064 004C+00 1/0 0/0 0/0 .text
* cmdCheckPortImport__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdCheckPortImport(JASTrack* param_0, u32* param_1) {
u8 tmp = param_0->checkPortIn(param_1[0]);
param_0->writeReg(JASRegisterParam::REG3, tmp);
return 0;
}
/* 80294770-802947BC 28F0B0 004C+00 1/0 0/0 0/0 .text
* cmdCheckPortExport__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdCheckPortExport(JASTrack* param_0, u32* param_1) {
u8 tmp = param_0->checkPort(param_1[0]);
param_0->writeReg(JASRegisterParam::REG3, tmp);
return 0;
}
/* 802947BC-802947F4 28F0FC 0038+00 1/0 0/0 0/0 .text cmdWait__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdWait(JASTrack* param_0, u32* param_1) {
JASSeqCtrl* seqCtrl = param_0->getSeqCtrl();
int midiValue = seqCtrl->readMidiValue();
@@ -563,15 +518,12 @@ s32 JASSeqParser::cmdWait(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 802947F4-80294804 28F134 0010+00 1/0 0/0 0/0 .text cmdWaitByte__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdWaitByte(JASTrack* param_0, u32* param_1) {
u32 val = param_1[0];
param_0->getSeqCtrl()->wait(val);
return 0;
}
/* 80294804-8029483C 28F144 0038+00 1/0 0/0 0/0 .text cmdSetLastNote__12JASSeqParserFP8JASTrackPUl
*/
s32 JASSeqParser::cmdSetLastNote(JASTrack* param_0, u32* param_1) {
u32 r31 = param_1[0];
if (r31 < 256) {
@@ -582,56 +534,42 @@ s32 JASSeqParser::cmdSetLastNote(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 8029483C-8029488C 28F17C 0050+00 1/0 0/0 0/0 .text cmdEnvScaleSet__12JASSeqParserFP8JASTrackPUl
*/
s32 JASSeqParser::cmdEnvScaleSet(JASTrack* param_0, u32* param_1) {
param_0->setOscScale(param_1[0], param_1[1] / 16383.0f);
return 0;
}
/* 8029488C-802948C8 28F1CC 003C+00 1/0 0/0 0/0 .text cmdEnvSet__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdEnvSet(JASTrack* param_0, u32* param_1) {
param_0->setOscTable(param_1[0], (JASOscillator::Point*)param_0->getSeqCtrl()->getAddr(param_1[1]));
return 0;
}
/* 802948C8-8029491C 28F208 0054+00 1/0 0/0 0/0 .text cmdSimpleADSR__12JASSeqParserFP8JASTrackPUl
*/
s32 JASSeqParser::cmdSimpleADSR(JASTrack* param_0, u32* param_1) {
param_0->setOscAdsr(param_1[0], param_1[1], param_1[2], param_1[3], param_1[4]);
return 0;
}
/* 8029491C-8029494C 28F25C 0030+00 1/0 0/0 0/0 .text cmdBusConnect__12JASSeqParserFP8JASTrackPUl
*/
s32 JASSeqParser::cmdBusConnect(JASTrack* param_0, u32* param_1) {
param_0->connectBus(param_1[0], param_1[1]);
return 0;
}
/* 8029494C-8029495C 28F28C 0010+00 1/0 0/0 0/0 .text cmdSetIntTable__12JASSeqParserFP8JASTrackPUl
*/
s32 JASSeqParser::cmdSetIntTable(JASTrack* param_0, u32* param_1) {
param_0->getSeqCtrl()->setIntrTable(param_1[0]);
return 0;
}
/* 8029495C-80294988 28F29C 002C+00 1/0 0/0 0/0 .text
* cmdSetInterrupt__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdSetInterrupt(JASTrack* param_0, u32* param_1) {
param_0->getSeqCtrl()->setIntrMask(param_1[0]);
return 0;
}
/* 80294988-802949B4 28F2C8 002C+00 1/0 0/0 0/0 .text
* cmdDisInterrupt__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdDisInterrupt(JASTrack* param_0, u32* param_1) {
param_0->getSeqCtrl()->clrIntrMask(param_1[0]);
return 0;
}
/* 802949B4-802949E4 28F2F4 0030+00 1/0 0/0 0/0 .text cmdClrI__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdClrI(JASTrack* param_0, u32* param_1) {
JASSeqCtrl* seqCtrl = param_0->getSeqCtrl();
seqCtrl->clrIntr();
@@ -639,7 +577,6 @@ s32 JASSeqParser::cmdClrI(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 802949E4-80294A20 28F324 003C+00 1/0 0/0 0/0 .text cmdRetI__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdRetI(JASTrack* param_0, u32* param_1) {
JASSeqCtrl* seqCtrl = param_0->getSeqCtrl();
seqCtrl->retIntr();
@@ -647,16 +584,13 @@ s32 JASSeqParser::cmdRetI(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294A20-80294A3C 28F360 001C+00 1/0 0/0 0/0 .text cmdIntTimer__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdIntTimer(JASTrack* param_0, u32* param_1) {
param_0->getSeqCtrl()->setIntrTimer(param_1[0], param_1[1]);
return 0;
}
/* 80451240-80451244 000740 0004+00 1/1 1/1 0/0 .sbss sCallBackFunc__12JASSeqParser */
u16 (*JASSeqParser::sCallBackFunc)(JASTrack*, u16);
/* 80294A3C-80294AA4 28F37C 0068+00 1/0 0/0 0/0 .text cmdSyncCPU__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdSyncCPU(JASTrack* param_0, u32* param_1) {
u16 r31 = 0xffff;
if (sCallBackFunc) {
@@ -666,30 +600,25 @@ s32 JASSeqParser::cmdSyncCPU(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294AA4-80294AD4 28F3E4 0030+00 1/0 0/0 0/0 .text cmdTempo__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdTempo(JASTrack* param_0, u32* param_1) {
param_0->setTempo(param_1[0]);
return 0;
}
/* 80294AD4-80294ADC 28F414 0008+00 1/0 0/0 0/0 .text cmdFinish__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdFinish(JASTrack* param_0, u32* param_1) {
return -1;
}
/* 80294ADC-80294AE4 28F41C 0008+00 1/0 0/0 0/0 .text cmdNop__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdNop(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294AE4-80294B1C 28F424 0038+00 1/0 0/0 0/0 .text cmdFIRSet__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdFIRSet(JASTrack* param_0, u32* param_1) {
s16* addr = (s16*)param_0->getSeqCtrl()->getAddr(param_1[0]);
param_0->setFIR(addr);
return 0;
}
/* 80294B1C-80294B70 28F45C 0054+00 1/0 0/0 0/0 .text cmdIIRSet__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdIIRSet(JASTrack* param_0, u32* param_1) {
s16 stack_10[4];
for (int i = 0; i < 4; i++) {
@@ -699,8 +628,6 @@ s32 JASSeqParser::cmdIIRSet(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294B70-80294BB4 28F4B0 0044+00 1/0 0/0 0/0 .text cmdIIRCutOff__12JASSeqParserFP8JASTrackPUl
*/
s32 JASSeqParser::cmdIIRCutOff(JASTrack* param_0, u32* param_1) {
u32 r31 = param_1[0];
if (r31 < 128) {
@@ -711,7 +638,6 @@ s32 JASSeqParser::cmdIIRCutOff(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294BB4-80294BD0 28F4F4 001C+00 1/0 0/0 0/0 .text cmdBankPrg__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdBankPrg(JASTrack* param_0, u32* param_1) {
u16 r31 = JSULoHalf(param_1[0]);
param_0->setBankNumber(JSUHiByte(r31));
@@ -719,19 +645,16 @@ s32 JASSeqParser::cmdBankPrg(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294BD0-80294BE4 28F510 0014+00 1/0 0/0 0/0 .text cmdBank__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdBank(JASTrack* param_0, u32* param_1) {
param_0->setBankNumber(param_1[0] & 0xff);
return 0;
}
/* 80294BE4-80294BF8 28F524 0014+00 1/0 0/0 0/0 .text cmdPrg__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdPrg(JASTrack* param_0, u32* param_1) {
param_0->setProgNumber(param_1[0] & 0xff);
return 0;
}
/* 80294BF8-80294C54 28F538 005C+00 1/0 0/0 0/0 .text cmdParamI__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdParamI(JASTrack* param_0, u32* param_1) {
s16 val = param_1[1];
param_0->setParam(param_1[0], val / 32767.0f, 0);
@@ -739,7 +662,6 @@ s32 JASSeqParser::cmdParamI(JASTrack* param_0, u32* param_1) {
}
/* 80294C54-80294CB0 28F594 005C+00 1/0 0/0 0/0 .text cmdParamII__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdParamII(JASTrack* param_0, u32* param_1) {
s16 val = param_1[1];
param_0->setParam(param_1[0], val / 32767.0f, param_1[2]);
@@ -747,7 +669,6 @@ s32 JASSeqParser::cmdParamII(JASTrack* param_0, u32* param_1) {
}
/* 80294CB0-80294D2C 28F5F0 007C+00 1/0 0/0 0/0 .text cmdParamE__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdParamE(JASTrack* param_0, u32* param_1) {
s32* r31 = (s32*)param_1 + 1;
s16 r30 = *r31 << 8;
@@ -759,7 +680,6 @@ s32 JASSeqParser::cmdParamE(JASTrack* param_0, u32* param_1) {
}
/* 80294D2C-80294DA8 28F66C 007C+00 1/0 0/0 0/0 .text cmdParamEI__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdParamEI(JASTrack* param_0, u32* param_1) {
s32* r31 = (s32*)param_1 + 1;
s16 r30 = *r31 << 8;
@@ -770,7 +690,6 @@ s32 JASSeqParser::cmdParamEI(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294DA8-80294F10 28F6E8 0168+00 3/0 0/0 0/0 .text cmdReg__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdReg(JASTrack* param_0, u32* param_1) {
u32 val = param_1[0];
u32 r29 = param_1[1];
@@ -820,7 +739,6 @@ s32 JASSeqParser::cmdReg(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294F10-80294F40 28F850 0030+00 1/0 0/0 0/0 .text cmdRegLoad__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdRegLoad(JASTrack* param_0, u32* param_1) {
u32 val1 = param_1[0];
u32 val2 = param_1[1];
@@ -828,7 +746,6 @@ s32 JASSeqParser::cmdRegLoad(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294F40-80294FB4 28F880 0074+00 1/0 0/0 0/0 .text cmdRegUni__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdRegUni(JASTrack* param_0, u32* param_1) {
u32 val1 = param_1[0];
u32 r31 = param_1[1];
@@ -845,8 +762,6 @@ s32 JASSeqParser::cmdRegUni(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80294FB4-80295088 28F8F4 00D4+00 1/0 0/0 0/0 .text cmdRegTblLoad__12JASSeqParserFP8JASTrackPUl
*/
s32 JASSeqParser::cmdRegTblLoad(JASTrack* param_0, u32* param_1) {
JASSeqCtrl* seqCtrl = param_0->getSeqCtrl();
u32 p0 = param_1[0];
@@ -881,7 +796,6 @@ s32 JASSeqParser::cmdRegTblLoad(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80295088-8029526C 28F9C8 01E4+00 1/0 0/0 0/0 .text cmdDump__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdDump(JASTrack* param_0, u32* param_1) {
JASSeqCtrl* seqCtrl = param_0->getSeqCtrl();
JASReport("--------------- JASTrack (%8x) dump ----------------", param_0);
@@ -898,7 +812,6 @@ s32 JASSeqParser::cmdDump(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 8029526C-80295498 28FBAC 022C+00 1/0 0/0 0/0 .text cmdPrintf__12JASSeqParserFP8JASTrackPUl */
s32 JASSeqParser::cmdPrintf(JASTrack* param_0, u32* param_1) {
u8 stack_c[4];
u32 stack_10[4];
@@ -968,8 +881,6 @@ s32 JASSeqParser::cmdPrintf(JASTrack* param_0, u32* param_1) {
return 0;
}
/* 80295498-80295540 28FDD8 00A8+00 1/0 0/0 0/0 .text
* execNoteOnGate__12JASSeqParserFP8JASTrackUlUlUlUl */
s32 JASSeqParser::execNoteOnGate(JASTrack* param_0, u32 param_1, u32 param_2, u32 param_3,
u32 param_4) {
JASSeqCtrl* seqCtrl = param_0->getSeqCtrl();
@@ -1001,25 +912,19 @@ s32 JASSeqParser::execNoteOnGate(JASTrack* param_0, u32 param_1, u32 param_2, u3
return result;
}
/* 80295540-80295570 28FE80 0030+00 1/0 0/0 0/0 .text
* execNoteOnMidi__12JASSeqParserFP8JASTrackUlUlUl */
s32 JASSeqParser::execNoteOnMidi(JASTrack* param_0, u32 param_1, u32 param_2, u32 param_3) {
return param_0->noteOn(param_1, param_2, param_3);
}
/* 80295570-8029559C 28FEB0 002C+00 1/0 0/0 0/0 .text execNoteOff__12JASSeqParserFP8JASTrackUl */
s32 JASSeqParser::execNoteOff(JASTrack* param_0, u32 param_1) {
return param_0->noteOff(param_1, 0);
}
/* 8029559C-802955C8 28FEDC 002C+00 1/0 0/0 0/0 .text
* execCommand__12JASSeqParserFP8JASTrackM12JASSeqParserFPCvPvP8JASTrackPUl_lUlPUl */
s32 JASSeqParser::execCommand(JASTrack* param_0, s32 (JASSeqParser::*param_1)(JASTrack*, u32*),
u32 param_2, u32* param_3) {
return (this->*param_1)(param_0, param_3);
}
/* 802955C8-80295600 28FF08 0038+00 1/1 0/0 0/0 .text parseNoteOff__12JASSeqParserFP8JASTrackUc */
s32 JASSeqParser::parseNoteOff(JASTrack* param_0, u8 param_1) {
u8 note_id = param_1 & 7;
if (note_id) {
@@ -1030,7 +935,6 @@ s32 JASSeqParser::parseNoteOff(JASTrack* param_0, u8 param_1) {
return 0;
}
/* 80295600-802956B0 28FF40 00B0+00 1/1 0/0 0/0 .text parseNoteOn__12JASSeqParserFP8JASTrackUc */
s32 JASSeqParser::parseNoteOn(JASTrack* param_0, u8 param_1) {
JASSeqCtrl* seqCtrl = param_0->getSeqCtrl();
u32 r28 = seqCtrl->readByte();
@@ -1046,8 +950,6 @@ s32 JASSeqParser::parseNoteOn(JASTrack* param_0, u8 param_1) {
return 0;
}
/* 802956B0-80295864 28FFF0 01B4+00 2/2 0/0 0/0 .text parseCommand__12JASSeqParserFP8JASTrackUcUs
*/
s32 JASSeqParser::parseCommand(JASTrack* param_0, u8 cmd, u16 param_2) {
JASSeqCtrl* seqCtrl = param_0->getSeqCtrl();
CmdInfo* cmdInfo = NULL;
@@ -1085,8 +987,6 @@ s32 JASSeqParser::parseCommand(JASTrack* param_0, u8 cmd, u16 param_2) {
return execCommand(param_0, ptr, cmdInfo->field_0xc, stack_28);
}
/* 80295864-802958D4 2901A4 0070+00 1/1 0/0 0/0 .text parseRegCommand__12JASSeqParserFP8JASTracki
*/
s32 JASSeqParser::parseRegCommand(JASTrack* param_0, int param_1) {
JASSeqCtrl* seqCtrl = param_0->getSeqCtrl();
u8 r30 = seqCtrl->readByte();
@@ -1102,7 +1002,6 @@ s32 JASSeqParser::parseRegCommand(JASTrack* param_0, int param_1) {
return parseCommand(param_0, seqCtrl->readByte(), r29);
}
/* 802958D4-80295950 290214 007C+00 1/0 0/0 0/0 .text parse__12JASSeqParserFP8JASTrack */
s32 JASSeqParser::parse(JASTrack* param_0) {
u32 r31 = param_0->getSeqCtrl()->readByte();
s32 r30 = 0;
-7
View File
@@ -7,7 +7,6 @@
#include "JSystem/JAudio2/JASSeqReader.h"
/* 80296108-80296148 290A48 0040+00 0/0 2/2 0/0 .text init__12JASSeqReaderFv */
void JASSeqReader::init() {
field_0x00 = 0;
field_0x04 = 0;
@@ -19,7 +18,6 @@ void JASSeqReader::init() {
}
}
/* 80296148-8029618C 290A88 0044+00 0/0 1/1 0/0 .text init__12JASSeqReaderFPv */
void JASSeqReader::init(void* param_0) {
field_0x00 = (u8*)param_0;
field_0x04 = field_0x00;
@@ -32,7 +30,6 @@ void JASSeqReader::init(void* param_0) {
}
/* 8029618C-802961CC 290ACC 0040+00 0/0 3/3 0/0 .text call__12JASSeqReaderFUl */
bool JASSeqReader::call(u32 param_0) {
if (field_0x08 >= 8) {
return false;
@@ -44,7 +41,6 @@ bool JASSeqReader::call(u32 param_0) {
return true;
}
/* 802961CC-80296210 290B0C 0044+00 0/0 1/1 0/0 .text loopStart__12JASSeqReaderFUl */
bool JASSeqReader::loopStart(u32 param_0) {
if (8 <= field_0x08) {
return false;
@@ -57,7 +53,6 @@ bool JASSeqReader::loopStart(u32 param_0) {
}
/* 80296210-8029627C 290B50 006C+00 0/0 1/1 0/0 .text loopEnd__12JASSeqReaderFv */
bool JASSeqReader::loopEnd() {
if (field_0x08 == 0) {
return false;
@@ -79,7 +74,6 @@ bool JASSeqReader::loopEnd() {
return true;
}
/* 8029627C-802962B0 290BBC 0034+00 0/0 2/2 0/0 .text ret__12JASSeqReaderFv */
bool JASSeqReader::ret() {
if (field_0x08 == 0) {
return false;
@@ -90,7 +84,6 @@ bool JASSeqReader::ret() {
return true;
}
/* 802962B0-8029631C 290BF0 006C+00 0/0 2/2 0/0 .text readMidiValue__12JASSeqReaderFv */
int JASSeqReader::readMidiValue() {
int byte = readByte();
-22
View File
@@ -1,32 +1,22 @@
//
// Generated By: dol2asm
// Translation Unit: JASSimpleWaveBank
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASSimpleWaveBank.h"
/* 80298C94-80298CF4 2935D4 0060+00 0/0 1/1 0/0 .text __ct__17JASSimpleWaveBankFv */
JASSimpleWaveBank::JASSimpleWaveBank() {
mWaveTable = NULL;
mWaveTableSize = 0;
}
/* 80298CF4-80298D84 293634 0090+00 2/1 0/0 0/0 .text __dt__17JASSimpleWaveBankFv */
JASSimpleWaveBank::~JASSimpleWaveBank() {
delete[] mWaveTable;
}
/* 80298DE0-80298E60 293720 0080+00 0/0 1/1 0/0 .text
* setWaveTableSize__17JASSimpleWaveBankFUlP7JKRHeap */
void JASSimpleWaveBank::setWaveTableSize(u32 size, JKRHeap* heap) {
delete[] mWaveTable;
mWaveTable = new (heap, 0) TWaveHandle[size];
mWaveTableSize = size;
}
/* 80298E60-80298E84 2937A0 0024+00 1/0 0/0 0/0 .text getWaveHandle__17JASSimpleWaveBankCFUl */
JASWaveHandle* JASSimpleWaveBank::getWaveHandle(u32 no) const {
if (no >= mWaveTableSize) {
return NULL;
@@ -34,16 +24,12 @@ JASWaveHandle* JASSimpleWaveBank::getWaveHandle(u32 no) const {
return &mWaveTable[no];
}
/* 80298E84-80298F18 2937C4 0094+00 0/0 1/1 0/0 .text
* setWaveInfo__17JASSimpleWaveBankFUlRC11JASWaveInfo */
void JASSimpleWaveBank::setWaveInfo(u32 no, JASWaveInfo const& waveInfo) {
mWaveTable[no].mWaveInfo = waveInfo;
mWaveTable[no].mWaveInfo.field_0x20 = &_48;
mWaveTable[no].mHeap = &mHeap;
}
/* 80298F18-80298F38 293858 0020+00 1/0 0/0 0/0 .text getWaveArc__17JASSimpleWaveBankFUl
*/
JASWaveArc* JASSimpleWaveBank::getWaveArc(u32 no) {
if (no != 0) {
return NULL;
@@ -51,8 +37,6 @@ JASWaveArc* JASSimpleWaveBank::getWaveArc(u32 no) {
return this;
}
/* 80298F38-80298F5C 293878 0024+00 1/0 0/0 0/0 .text
* getWavePtr__Q217JASSimpleWaveBank11TWaveHandleCFv */
int JASSimpleWaveBank::TWaveHandle::getWavePtr() const {
void* base = mHeap->getBase();
if (base == NULL) {
@@ -61,20 +45,14 @@ int JASSimpleWaveBank::TWaveHandle::getWavePtr() const {
return (int)base + mWaveInfo.field_0x08;
}
/* 80298F5C-80298F90 29389C 0034+00 1/1 0/0 0/0 .text __ct__Q217JASSimpleWaveBank11TWaveHandleFv
*/
JASSimpleWaveBank::TWaveHandle::TWaveHandle() {
mHeap = NULL;
}
/* 80298F90-80298F98 2938D0 0008+00 1/0 0/0 0/0 .text
* getWaveInfo__Q217JASSimpleWaveBank11TWaveHandleCFv */
const JASWaveInfo* JASSimpleWaveBank::TWaveHandle::getWaveInfo() const {
return &mWaveInfo;
}
/* 80298F98-80298FA0 2938D8 0008+00 1/0 0/0 0/0 .text getArcCount__17JASSimpleWaveBankCFv
*/
u32 JASSimpleWaveBank::getArcCount() const {
return 1;
}
-8
View File
@@ -1,13 +1,7 @@
//
// Generated By: dol2asm
// Translation Unit: JASSoundParams
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASSoundParams.h"
/* 8029E3B0-8029E47C 298CF0 00CC+00 0/0 2/2 0/0 .text clamp__14JASSoundParamsFv */
void JASSoundParams::clamp() {
clampVolume();
clampPitch();
@@ -16,8 +10,6 @@ void JASSoundParams::clamp() {
clampDolby();
}
/* 8029E47C-8029E4D8 298DBC 005C+00 0/0 2/2 0/0 .text
* combine__14JASSoundParamsFRC14JASSoundParamsRC14JASSoundParams */
void JASSoundParams::combine(const JASSoundParams &other1, const JASSoundParams &other2) {
mVolume = other1.mVolume * other2.mVolume;
mPitch = other1.mPitch * other2.mPitch;
-9
View File
@@ -5,7 +5,6 @@
#include "JSystem/JAudio2/JASCriticalSection.h"
#include "JSystem/JKernel/JKRSolidHeap.h"
/* 8028F6C4-8028F724 28A004 0060+00 0/0 1/1 0/0 .text __ct__13JASTaskThreadFiiUl */
JASTaskThread::JASTaskThread(int priority, int msgCount, u32 stackSize) :
JKRThread(JASDram, stackSize, msgCount, priority)
{
@@ -13,7 +12,6 @@ JASTaskThread::JASTaskThread(int priority, int msgCount, u32 stackSize) :
OSInitThreadQueue(&threadQueue_);
}
/* 8028F724-8028F850 28A064 012C+00 1/0 0/0 0/0 .text __dt__13JASTaskThreadFv */
JASTaskThread::~JASTaskThread() {
OSMessage msg;
BOOL received;
@@ -26,8 +24,6 @@ JASTaskThread::~JASTaskThread() {
}
}
/* 8028F850-8028F9EC 28A190 019C+00 1/1 0/0 0/0 .text allocCallStack__13JASTaskThreadFPFPv_vPCvUl
*/
void* JASTaskThread::allocCallStack(JASThreadCallback callback, const void* msg, u32 msgSize) {
ThreadMemPool* heap;
u32 size = msgSize + 8;
@@ -42,7 +38,6 @@ void* JASTaskThread::allocCallStack(JASThreadCallback callback, const void* msg,
return callStack;
}
/* 8028F9EC-8028FB5C 28A32C 0170+00 1/1 0/0 0/0 .text allocCallStack__13JASTaskThreadFPFPv_vPv */
void* JASTaskThread::allocCallStack(JASThreadCallback callback, void* msg) {
JASThreadCallStack *callStack;
callStack = (JASThreadCallStack*)JASKernel::getCommandHeap()->alloc(12);
@@ -56,7 +51,6 @@ void* JASTaskThread::allocCallStack(JASThreadCallback callback, void* msg) {
return callStack;
}
/* 8028FB5C-8028FC54 28A49C 00F8+00 0/0 6/6 0/0 .text sendCmdMsg__13JASTaskThreadFPFPv_vPCvUl */
int JASTaskThread::sendCmdMsg(JASThreadCallback callback, const void* msg, u32 msgSize) {
void* callstack;
@@ -72,7 +66,6 @@ int JASTaskThread::sendCmdMsg(JASThreadCallback callback, const void* msg, u32 m
return iVar2;
}
/* 8028FC54-8028FD4C 28A594 00F8+00 0/0 3/3 0/0 .text sendCmdMsg__13JASTaskThreadFPFPv_vPv */
int JASTaskThread::sendCmdMsg(JASThreadCallback callback, void* msg) {
void* callstack;
@@ -88,7 +81,6 @@ int JASTaskThread::sendCmdMsg(JASThreadCallback callback, void* msg) {
return iVar2;
}
/* 8028FD4C-8028FE88 28A68C 013C+00 1/0 0/0 0/0 .text run__13JASTaskThreadFv */
// NONMATCHING Regalloc
void* JASTaskThread::run() {
JASThreadCallStack* callstack;
@@ -109,7 +101,6 @@ void* JASTaskThread::run() {
} while (true);
}
/* 8028FE88-8028FEFC 28A7C8 0074+00 0/0 1/1 0/0 .text pause__13JASTaskThreadFb */
void JASTaskThread::pause(bool param_0) {
JASCriticalSection aJStack_14;
if (param_0) {
-71
View File
@@ -7,7 +7,6 @@
#include "JSystem/JAudio2/JASAiCtrl.h"
#include "JSystem/JAudio2/JASDSPInterface.h"
/* 80291228-8029131C 28BB68 00F4+00 1/1 3/3 0/0 .text __ct__8JASTrackFv */
JASTrack::JASTrack() : mDefaultChannelMgr(this), mChannelMgrCount(1), mStatus(0) {
mChannelMgrs[0] = &mDefaultChannelMgr;
for (int i = 1; i < 4; i++) {
@@ -16,13 +15,10 @@ JASTrack::JASTrack() : mDefaultChannelMgr(this), mChannelMgrCount(1), mStatus(0)
init();
}
/* 804316B4-80431AC0 05E3D4 040C+00 1/2 0/0 0/0 .bss sDefaultBankTable__8JASTrack */
JASDefaultBankTable JASTrack::sDefaultBankTable;
/* 80431ACC-80431ADC 05E7EC 0010+00 1/2 0/0 0/0 .bss sTrackList__8JASTrack */
JASTrack::TList JASTrack::sTrackList;
/* 8029131C-80291444 28BC5C 0128+00 4/4 4/4 0/0 .text __dt__8JASTrackFv */
// NONMATCHING JASPoolAllocObject_MultiThreaded<_> locations
JASTrack::~JASTrack() {
for (int i = 1; i < 4; i++) {
@@ -30,7 +26,6 @@ JASTrack::~JASTrack() {
}
}
/* 80291444-802915D4 28BD84 0190+00 1/1 3/3 0/0 .text setChannelMgrCount__8JASTrackFUl */
// NONMATCHING JASPoolAllocObject_MultiThreaded<_> locations
void JASTrack::setChannelMgrCount(u32 i_count) {
mChannelMgrCount = 1;
@@ -51,7 +46,6 @@ void JASTrack::setChannelMgrCount(u32 i_count) {
}
}
/* 8039AFD0-8039AFE8 027630 0018+00 1/1 0/0 0/0 .rodata sAdsTable__8JASTrack */
JASOscillator::Point const JASTrack::sAdsTable[4] = {
{0, 0, 0x7fff},
{0, 0, 0x7fff},
@@ -59,13 +53,10 @@ JASOscillator::Point const JASTrack::sAdsTable[4] = {
{0xe, 0, 0},
};
/* 8039AFE8-8039B000 027648 0018+00 1/2 0/0 0/0 .rodata sEnvOsc__8JASTrack */
JASOscillator::Data const JASTrack::sEnvOsc = {0, 1.0f, NULL, NULL, 1.0f, 0.0f};
/* 8039B000-8039B018 027660 0018+00 0/1 0/0 0/0 .rodata sPitchEnvOsc__8JASTrack */
JASOscillator::Data const JASTrack::sPitchEnvOsc = {1, 1.0f, NULL, NULL, 1.0f, 0.0f};
/* 802915D4-802918FC 28BF14 0328+00 2/2 1/1 0/0 .text init__8JASTrackFv */
// NONMATCHING JASPoolAllocObject_MultiThreaded<_> locations
void JASTrack::init() {
mSeqCtrl.init();
@@ -138,7 +129,6 @@ void JASTrack::init() {
mStatus = 0;
}
/* 802918FC-8029194C 28C23C 0050+00 1/1 0/0 0/0 .text initTimed__8JASTrackFv */
void JASTrack::initTimed() {
mMoveParam.params.volume.mValue = 1.0f;
mMoveParam.params.pitch.mValue = 0.0f;
@@ -152,7 +142,6 @@ void JASTrack::initTimed() {
}
}
/* 8029194C-802919F4 28C28C 00A8+00 1/1 0/0 0/0 .text inherit__8JASTrackFRC8JASTrack */
void JASTrack::inherit(JASTrack const& i_parent) {
mFlags.flag2 = i_parent.mFlags.flag2;
mBankNumber = i_parent.mBankNumber;
@@ -172,36 +161,29 @@ void JASTrack::inherit(JASTrack const& i_parent) {
}
}
/* 802919F4-80291A08 28C334 0014+00 0/0 5/5 0/0 .text
* assignExtBuffer__8JASTrackFUlP14JASSoundParams */
void JASTrack::assignExtBuffer(u32 i_index, JASSoundParams* i_soundParams) {
mChannelMgrs[i_index]->mSoundParams = i_soundParams;
}
/* 80291A08-80291A28 28C348 0020+00 0/0 3/3 0/0 .text setSeqData__8JASTrackFPvUl */
void JASTrack::setSeqData(void* param_0, u32 param_1) {
mSeqCtrl.start(param_0, param_1);
}
/* 80291A28-80291A78 28C368 0050+00 0/0 2/2 0/0 .text startSeq__8JASTrackFv */
void JASTrack::startSeq() {
JASCriticalSection critical_section;
sTrackList.append(this);
mStatus = 1;
}
/* 80291A78-80291ABC 28C3B8 0044+00 0/0 2/2 0/0 .text stopSeq__8JASTrackFv */
void JASTrack::stopSeq() {
JASCriticalSection critical_section;
mFlags.flag6 = 1;
}
/* 80291ABC-80291AC8 28C3FC 000C+00 0/0 1/1 0/0 .text start__8JASTrackFv */
void JASTrack::start() {
mStatus = 1;
}
/* 80291AC8-80291B8C 28C408 00C4+00 4/4 0/0 0/0 .text close__8JASTrackFv */
void JASTrack::close() {
for (int i = 0; i < 16; i++) {
JASTrack* child = mChildren[i];
@@ -222,7 +204,6 @@ void JASTrack::close() {
mStatus = 2;
}
/* 80291B8C-80291BB8 28C4CC 002C+00 1/1 1/1 0/0 .text connectChild__8JASTrackFUlP8JASTrack */
bool JASTrack::connectChild(u32 i_index, JASTrack* i_child) {
if (mChildren[i_index] != NULL) {
return false;
@@ -232,7 +213,6 @@ bool JASTrack::connectChild(u32 i_index, JASTrack* i_child) {
return true;
}
/* 80291BB8-80291C30 28C4F8 0078+00 0/0 1/1 0/0 .text closeChild__8JASTrackFUl */
void JASTrack::closeChild(u32 i_index) {
JASTrack* child = mChildren[i_index];
if (child != NULL) {
@@ -245,7 +225,6 @@ void JASTrack::closeChild(u32 i_index) {
}
}
/* 80291C30-80291DAC 28C570 017C+00 0/0 2/2 0/0 .text openChild__8JASTrackFUl */
// NONMATCHING JASPoolAllocObject_MultiThreaded<_> locations
JASTrack* JASTrack::openChild(u32 i_index) {
JASTrack* child = mChildren[i_index];
@@ -278,19 +257,15 @@ JASTrack* JASTrack::openChild(u32 i_index) {
return child;
}
/* 80291DAC-80291DBC 28C6EC 0010+00 0/0 1/1 0/0 .text connectBus__8JASTrackFii */
void JASTrack::connectBus(int param_0, int param_1) {
mMixConfig[param_0] = param_1;
}
/* 80291DBC-80291DF8 28C6FC 003C+00 0/0 1/1 0/0 .text setLatestKey__8JASTrackFUc */
void JASTrack::setLatestKey(u8 param_0) {
field_0x22b = param_0;
field_0x22b += getTransposeTotal();
}
/* 80291DF8-80291F38 28C738 0140+00 2/2 0/0 0/0 .text
* channelStart__8JASTrackFPQ28JASTrack11TChannelMgrUlUlUl */
JASChannel* JASTrack::channelStart(JASTrack::TChannelMgr* i_channelMgr, u32 param_1, u32 param_2,
u32 i_updateTimer) {
JASBank* bank = NULL;
@@ -318,7 +293,6 @@ JASChannel* JASTrack::channelStart(JASTrack::TChannelMgr* i_channelMgr, u32 para
return channel;
}
/* 80291F38-80292008 28C878 00D0+00 0/0 1/1 0/0 .text noteOn__8JASTrackFUlUlUl */
int JASTrack::noteOn(u32 i_noteID, u32 param_1, u32 param_2) {
if (isMute()) {
return 0;
@@ -338,7 +312,6 @@ int JASTrack::noteOn(u32 i_noteID, u32 param_1, u32 param_2) {
return ret;
}
/* 80292008-80292198 28C948 0190+00 0/0 1/1 0/0 .text gateOn__8JASTrackFUlUlfUl */
int JASTrack::gateOn(u32 param_0, u32 i_velocity, f32 i_time, u32 i_flags) {
param_0 += getTransposeTotal();
if (mGateRate != 100) {
@@ -379,7 +352,6 @@ int JASTrack::gateOn(u32 param_0, u32 i_velocity, f32 i_time, u32 i_flags) {
return 1;
}
/* 80292198-80292220 28CAD8 0088+00 1/1 1/1 0/0 .text noteOff__8JASTrackFUlUs */
int JASTrack::noteOff(u32 i_noteID, u16 param_1) {
int ret = 1;
for (u32 i = 0; i < mChannelMgrCount; i++) {
@@ -392,7 +364,6 @@ int JASTrack::noteOff(u32 i_noteID, u16 param_1) {
return ret;
}
/* 80292220-8029226C 28CB60 004C+00 0/0 1/1 0/0 .text checkNoteStop__8JASTrackCFUl */
bool JASTrack::checkNoteStop(u32 i_noteID) const {
for (u32 i = 0; i < mChannelMgrCount; i++) {
if (mChannelMgrs[i] != NULL && mChannelMgrs[i]->mChannels[i_noteID] != NULL) {
@@ -402,7 +373,6 @@ bool JASTrack::checkNoteStop(u32 i_noteID) const {
return true;
}
/* 8029226C-802922D8 28CBAC 006C+00 1/1 0/0 0/0 .text overwriteOsc__8JASTrackFP10JASChannel */
void JASTrack::overwriteOsc(JASChannel* i_channel) {
for (u32 i = 0; i < 2; i++) {
if (mOscParam[i].mTable != NULL) {
@@ -411,7 +381,6 @@ void JASTrack::overwriteOsc(JASChannel* i_channel) {
}
}
/* 802922D8-80292348 28CC18 0070+00 1/1 0/0 0/0 .text updateTimedParam__8JASTrackFv */
void JASTrack::updateTimedParam() {
for (u32 i = 0; i < 6; i++) {
MoveParam_* param = &mMoveParam.array[i];
@@ -422,7 +391,6 @@ void JASTrack::updateTimedParam() {
}
}
/* 80292348-802924E4 28CC88 019C+00 1/1 0/0 0/0 .text updateTrack__8JASTrackFf */
void JASTrack::updateTrack(f32 param_0) {
updateTempo();
for (u32 i = 0; i < mChannelMgrCount; i++) {
@@ -468,7 +436,6 @@ void JASTrack::updateTrack(f32 param_0) {
}
}
/* 802924E4-80292580 28CE24 009C+00 5/5 0/0 0/0 .text updateTempo__8JASTrackFv */
void JASTrack::updateTempo() {
if (mParent == NULL) {
field_0x1dc = mTempoRate * (mTimebase * mTempo * (4.0f / 3.0f) / JASDriver::getDacRate());
@@ -479,7 +446,6 @@ void JASTrack::updateTempo() {
}
}
/* 80292580-80292644 28CEC0 00C4+00 4/4 0/0 0/0 .text updateSeq__8JASTrackFbf */
void JASTrack::updateSeq(bool param_0, f32 param_1) {
if (!param_0) {
param_0 = mFlags.flag5;
@@ -496,7 +462,6 @@ void JASTrack::updateSeq(bool param_0, f32 param_1) {
}
}
/* 80292644-802926E0 28CF84 009C+00 1/1 0/0 0/0 .text seqTimeToDspTime__8JASTrackFf */
u32 JASTrack::seqTimeToDspTime(f32 i_seqTime) {
f32 dsp_time;
if (mFlags.flag2) {
@@ -508,7 +473,6 @@ u32 JASTrack::seqTimeToDspTime(f32 i_seqTime) {
return dsp_time;
}
/* 802926E0-80292708 28D020 0028+00 0/0 4/4 0/0 .text setParam__8JASTrackFUlfUl */
void JASTrack::setParam(u32 i_index, f32 i_target, u32 i_count) {
MoveParam_* param = &mMoveParam.array[i_index];
param->mTarget = i_target;
@@ -518,7 +482,6 @@ void JASTrack::setParam(u32 i_index, f32 i_target, u32 i_count) {
param->mCount = i_count;
}
/* 80292708-802927A0 28D048 0098+00 1/1 0/0 0/0 .text noteOffAll__8JASTrackFUs */
void JASTrack::noteOffAll(u16 param_0) {
for (u8 i = 0; i < 8; i++) {
noteOff(i, param_0);
@@ -530,7 +493,6 @@ void JASTrack::noteOffAll(u16 param_0) {
}
}
/* 802927A0-802927D8 28D0E0 0038+00 0/0 2/2 0/0 .text mute__8JASTrackFb */
void JASTrack::mute(bool i_mute) {
mFlags.mute = i_mute;
if (i_mute) {
@@ -538,13 +500,10 @@ void JASTrack::mute(bool i_mute) {
}
}
/* 802927D8-802927E8 28D118 0010+00 0/0 1/1 0/0 .text setOscScale__8JASTrackFUlf */
void JASTrack::setOscScale(u32 i_oscNo, f32 i_scale) {
mOscParam[i_oscNo].mScale = i_scale;
}
/* 802927E8-80292808 28D128 0020+00 0/0 1/1 0/0 .text
* setOscTable__8JASTrackFUlPCQ213JASOscillator5Point */
void JASTrack::setOscTable(u32 i_oscNo, JASOscillator::Point const* i_table) {
mOscParam[i_oscNo].mTable = i_table;
if (i_oscNo != 0) {
@@ -552,7 +511,6 @@ void JASTrack::setOscTable(u32 i_oscNo, JASOscillator::Point const* i_table) {
}
}
/* 80292808-8029285C 28D148 0054+00 0/0 1/1 0/0 .text setOscAdsr__8JASTrackFssssUs */
void JASTrack::setOscAdsr(s16 param_0, s16 param_1, s16 param_2, s16 param_3, u16 i_directRelease) {
mOscParam[0] = sEnvOsc;
mOscParam[0].mTable = mOscPoint;
@@ -563,10 +521,8 @@ void JASTrack::setOscAdsr(s16 param_0, s16 param_1, s16 param_2, s16 param_3, u1
mDirectRelease = i_directRelease;
}
/* 804555D0-804555D4 003BD0 0004+00 2/2 0/0 0/0 .sdata2 FILTER_MODE_IIR__6JASDsp */
const u32 JASDsp::FILTER_MODE_IIR = 0x00000020;
/* 8029285C-8029289C 28D19C 0040+00 0/0 2/2 0/0 .text setFIR__8JASTrackFPCs */
void JASTrack::setFIR(s16 const* i_FIR) {
for (int i = 0; i < 8; i++) {
mFIR[i] = i_FIR[i];
@@ -575,7 +531,6 @@ void JASTrack::setFIR(s16 const* i_FIR) {
mFilterMode |= 8;
}
/* 8029289C-802928D0 28D1DC 0034+00 0/0 4/4 0/0 .text setIIR__8JASTrackFPCs */
void JASTrack::setIIR(s16 const* i_IIR) {
for (int i = 0; i < 8; i++) {
mIIR[i] = i_IIR[i];
@@ -583,17 +538,14 @@ void JASTrack::setIIR(s16 const* i_IIR) {
mFilterMode |= JASDsp::FILTER_MODE_IIR;
}
/* 802928D0-802928F4 28D210 0024+00 0/0 1/1 0/0 .text readPortSelf__8JASTrackFUl */
u16 JASTrack::readPortSelf(u32 param_0) {
return mTrackPort.readImport(param_0);
}
/* 802928F4-80292918 28D234 0024+00 0/0 1/1 0/0 .text writePortSelf__8JASTrackFUlUs */
void JASTrack::writePortSelf(u32 param_0, u16 param_1) {
mTrackPort.writeExport(param_0, param_1);
}
/* 80292918-8029297C 28D258 0064+00 0/0 4/4 0/0 .text writePort__8JASTrackFUlUs */
void JASTrack::writePort(u32 param_0, u16 param_1) {
mTrackPort.writeImport(param_0, param_1);
if (param_0 == 0 || param_0 == 1) {
@@ -607,12 +559,10 @@ void JASTrack::writePort(u32 param_0, u16 param_1) {
}
}
/* 8029297C-802929A0 28D2BC 0024+00 0/0 3/3 0/0 .text readPort__8JASTrackFUl */
u16 JASTrack::readPort(u32 param_0) {
return mTrackPort.readExport(param_0);
}
/* 802929A0-80292A3C 28D2E0 009C+00 1/1 0/0 0/0 .text setChannelPauseFlag__8JASTrackFb */
void JASTrack::setChannelPauseFlag(bool i_pause) {
for (u32 i = 0; i < mChannelMgrCount; i++) {
if (mChannelMgrs[i] != NULL) {
@@ -626,7 +576,6 @@ void JASTrack::setChannelPauseFlag(bool i_pause) {
}
}
/* 80292A3C-80292AA4 28D37C 0068+00 0/0 2/2 0/0 .text pause__8JASTrackFb */
void JASTrack::pause(bool i_pause) {
if (mFlags.pause != i_pause) {
mFlags.pause = i_pause;
@@ -635,7 +584,6 @@ void JASTrack::pause(bool i_pause) {
}
}
/* 80292AA4-80292AF4 28D3E4 0050+00 3/3 0/0 0/0 .text getTransposeTotal__8JASTrackCFv */
int JASTrack::getTransposeTotal() const {
if (mParent != NULL) {
return mTranspose + mParent->getTransposeTotal();
@@ -644,7 +592,6 @@ int JASTrack::getTransposeTotal() const {
}
}
/* 80292AF4-80292B58 28D434 0064+00 2/2 0/0 0/0 .text isMute__8JASTrackCFv */
bool JASTrack::isMute() const {
if (mParent != NULL) {
return mFlags.mute || mParent->isMute();
@@ -653,29 +600,24 @@ bool JASTrack::isMute() const {
}
}
/* 80292B58-80292B8C 28D498 0034+00 0/0 1/1 0/0 .text setTempo__8JASTrackFUs */
void JASTrack::setTempo(u16 i_tempo) {
mTempo = i_tempo;
mFlags.flag5 = true;
updateTempo();
}
/* 80292B8C-80292BC0 28D4CC 0034+00 0/0 2/2 0/0 .text setTempoRate__8JASTrackFf */
void JASTrack::setTempoRate(f32 i_tempoRate) {
mTempoRate = i_tempoRate;
mFlags.flag5 = true;
updateTempo();
}
/* 80292BC0-80292BF4 28D500 0034+00 0/0 1/1 0/0 .text setTimebase__8JASTrackFUs */
void JASTrack::setTimebase(u16 i_timebase) {
mTimebase = i_timebase;
mFlags.flag5 = true;
updateTempo();
}
/* 80292BF4-80292CA4 28D534 00B0+00 1/1 0/0 0/0 .text
* updateChannel__8JASTrackFP10JASChannelPQ26JASDsp8TChannel */
void JASTrack::updateChannel(JASChannel* param_0, JASDsp::TChannel* param_1) {
param_0->setVibrate(mVibDepth, mVibPitch);
param_0->setTremolo(mTremDepth, mTremPitch);
@@ -690,8 +632,6 @@ void JASTrack::updateChannel(JASChannel* param_0, JASDsp::TChannel* param_1) {
}
/* 80292CA4-80292D88 28D5E4 00E4+00 1/1 0/0 0/0 .text
* channelUpdateCallback__8JASTrackFUlP10JASChannelPQ26JASDsp8TChannelPv */
void JASTrack::channelUpdateCallback(u32 param_0, JASChannel* param_1,
JASDsp::TChannel* param_2, void* param_3) {
TChannelMgr* channel_mgr = static_cast<TChannelMgr*>(param_3);
@@ -718,7 +658,6 @@ void JASTrack::channelUpdateCallback(u32 param_0, JASChannel* param_1,
}
}
/* 80292D88-80292DA0 28D6C8 0018+00 3/3 0/0 0/0 .text getRootTrack__8JASTrackFv */
JASTrack* JASTrack::getRootTrack() {
JASTrack* track = this;
while (track->mParent != NULL) {
@@ -727,7 +666,6 @@ JASTrack* JASTrack::getRootTrack() {
return track;
}
/* 80292DA0-80292E9C 28D6E0 00FC+00 1/1 0/0 0/0 .text tickProc__8JASTrackFv */
int JASTrack::tickProc() {
if (mFlags.pause) {
return 0;
@@ -755,7 +693,6 @@ int JASTrack::tickProc() {
return 0;
}
/* 80292E9C-80292F6C 28D7DC 00D0+00 1/1 0/0 0/0 .text seqMain__8JASTrackFv */
int JASTrack::seqMain() {
if (mFlags.flag6) {
updateSeq(true, 1.0f);
@@ -776,13 +713,11 @@ int JASTrack::seqMain() {
}
}
/* 80292F6C-80292F90 28D8AC 0024+00 1/1 0/0 0/0 .text cbSeqMain__Q28JASTrack5TListFPv */
s32 JASTrack::TList::cbSeqMain(void* i_this) {
static_cast<JASTrack::TList*>(i_this)->seqMain();
return 0;
}
/* 80292F90-8029301C 28D8D0 008C+00 1/1 0/0 0/0 .text append__Q28JASTrack5TListFP8JASTrack */
void JASTrack::TList::append(JASTrack* i_track) {
if (!mCallbackRegistered) {
if (!JASDriver::registerSubFrameCallback(cbSeqMain, this)) {
@@ -793,7 +728,6 @@ void JASTrack::TList::append(JASTrack* i_track) {
Push_back(i_track);
}
/* 8029301C-802930DC 28D95C 00C0+00 1/1 0/0 0/0 .text seqMain__Q28JASTrack5TListFv */
// NONMATCHING - missing load instruction (matches debug, equivalent)
void JASTrack::TList::seqMain() {
iterator it, it2;
@@ -810,7 +744,6 @@ void JASTrack::TList::seqMain() {
}
}
/* 802930DC-80293148 28DA1C 006C+00 2/2 0/0 0/0 .text __ct__Q28JASTrack11TChannelMgrFP8JASTrack */
JASTrack::TChannelMgr::TChannelMgr(JASTrack* i_track) : mSoundParams(NULL), mTrack(i_track) {
for (int i = 0; i < 8; i++) {
mChannels[i] = NULL;
@@ -821,7 +754,6 @@ JASTrack::TChannelMgr::TChannelMgr(JASTrack* i_track) : mSoundParams(NULL), mTra
}
/* 80293148-802931B0 28DA88 0068+00 1/1 0/0 0/0 .text init__Q28JASTrack11TChannelMgrFv */
void JASTrack::TChannelMgr::init() {
mSoundParams = NULL;
mParams.init();
@@ -834,7 +766,6 @@ void JASTrack::TChannelMgr::init() {
}
/* 802931B0-80293220 28DAF0 0070+00 1/1 0/0 0/0 .text releaseAll__Q28JASTrack11TChannelMgrFv */
void JASTrack::TChannelMgr::releaseAll() {
for (int i = 0; i < 8; i++) {
JASChannel* channel = mChannels[i];
@@ -846,7 +777,6 @@ void JASTrack::TChannelMgr::releaseAll() {
}
}
/* 80293220-802932A0 28DB60 0080+00 3/3 0/0 0/0 .text noteOff__Q28JASTrack11TChannelMgrFUlUs */
bool JASTrack::TChannelMgr::noteOff(u32 i_channel, u16 param_1) {
JASChannel* channel = mChannels[i_channel];
if (channel == NULL) {
@@ -862,7 +792,6 @@ bool JASTrack::TChannelMgr::noteOff(u32 i_channel, u16 param_1) {
return true;
}
/* 802932A0-802932C8 28DBE0 0028+00 1/1 0/0 0/0 .text setPauseFlag__Q28JASTrack11TChannelMgrFb */
void JASTrack::TChannelMgr::setPauseFlag(bool i_pause) {
for (int i = 0; i < 8; i++) {
if (mChannels[i] != NULL) {
-12
View File
@@ -1,13 +1,7 @@
//
// Generated By: dol2asm
// Translation Unit: JASTrackPort
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASTrackPort.h"
/* 8029354C-8029357C 28DE8C 0030+00 0/0 1/1 0/0 .text init__12JASTrackPortFv */
void JASTrackPort::init() {
for (int i = 0; i < 16; i++) {
field_0x4[i] = 0;
@@ -16,36 +10,30 @@ void JASTrackPort::init() {
field_0x2 = 0;
}
/* 8029357C-802935A0 28DEBC 0024+00 0/0 1/1 0/0 .text readImport__12JASTrackPortFUl */
u16 JASTrackPort::readImport(u32 port_num) {
field_0x0 = field_0x0 & ~(1 << port_num);
return field_0x4[port_num];
}
/* 802935A0-802935C4 28DEE0 0024+00 0/0 1/1 0/0 .text readExport__12JASTrackPortFUl */
u16 JASTrackPort::readExport(u32 port_num) {
field_0x2 = field_0x2 & ~(1 << port_num);
return field_0x4[port_num];
}
/* 802935C4-802935E8 28DF04 0024+00 0/0 1/1 0/0 .text writeImport__12JASTrackPortFUlUs */
void JASTrackPort::writeImport(u32 port_num, u16 param_1) {
field_0x0 = field_0x0 | (1 << port_num);
field_0x4[port_num] = param_1;
}
/* 802935E8-8029360C 28DF28 0024+00 0/0 1/1 0/0 .text writeExport__12JASTrackPortFUlUs */
void JASTrackPort::writeExport(u32 port_num, u16 param_1) {
field_0x2 = field_0x2 | (1 << port_num);
field_0x4[port_num] = param_1;
}
/* 8029360C-80293628 28DF4C 001C+00 0/0 1/1 0/0 .text checkImport__12JASTrackPortCFUl */
u32 JASTrackPort::checkImport(u32 param_0) const {
return field_0x0 & 1 << param_0 ? 1 : 0;
}
/* 80293628-80293644 28DF68 001C+00 0/0 1/1 0/0 .text checkExport__12JASTrackPortCFUl */
u32 JASTrackPort::checkExport(u32 param_0) const {
return field_0x2 & 1 << param_0 ? 1 : 0;
}
-12
View File
@@ -1,24 +1,14 @@
//
// Generated By: dol2asm
// Translation Unit: JASVoiceBank
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASVoiceBank.h"
#include "JSystem/JAudio2/JASBasicInst.h"
/* ############################################################################################## */
/* 8039B1B8-8039B1D0 027818 0018+00 1/1 0/0 0/0 .rodata sOscData__12JASVoiceBank */
const JASOscillator::Data JASVoiceBank::sOscData = {
0, 1.0f, NULL, NULL, 1.0f, 0.0f,
};
/* 80451268-80451270 000768 0004+04 1/1 0/0 0/0 .sbss sOscTable__12JASVoiceBank */
JASOscillator::Data* JASVoiceBank::sOscTable;
/* 80297F74-80297FAC 2928B4 0038+00 1/0 0/0 0/0 .text
* getInstParam__12JASVoiceBankCFiiiP12JASInstParam */
bool JASVoiceBank::getInstParam(int param_0, int param_1, int param_2,
JASInstParam* param_3) const {
if (param_0 < 0) {
@@ -31,10 +21,8 @@ bool JASVoiceBank::getInstParam(int param_0, int param_1, int param_2,
return true;
}
/* 80297FAC-80298008 2928EC 005C+00 1/0 0/0 0/0 .text __dt__12JASVoiceBankFv */
JASVoiceBank::~JASVoiceBank() {}
/* 80298008-80298014 292948 000C+00 1/0 0/0 0/0 .text getType__12JASVoiceBankCFv */
u32 JASVoiceBank::getType() const {
return 'VOIC';
}
-13
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: JASWSParser
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASWSParser.h"
@@ -11,15 +6,12 @@
#include "JSystem/JKernel/JKRHeap.h"
#include "JSystem/JKernel/JKRSolidHeap.h"
/* 80298FB0-80298FD8 2938F0 0028+00 1/1 0/0 0/0 .text getGroupCount__11JASWSParserFPCv */
u32 JASWSParser::getGroupCount(void const* stream) {
THeader* header = (THeader*)stream;
return header->mCtrlGroupOffset.ptr(header)->mGroupCount;
}
/* 80298FD8-80299034 293918 005C+00 0/0 1/1 0/0 .text createWaveBank__11JASWSParserFPCvP7JKRHeap
*/
JASWaveBank* JASWSParser::createWaveBank(void const* stream, JKRHeap* heap) {
if (getGroupCount(stream) == 1) {
return createSimpleWaveBank(stream, heap);
@@ -28,11 +20,8 @@ JASWaveBank* JASWSParser::createWaveBank(void const* stream, JKRHeap* heap) {
}
}
/* 80451280-80451288 000780 0004+04 2/2 0/0 0/0 .sbss sUsedHeapSize__11JASWSParser */
u32 JASWSParser::sUsedHeapSize;
/* 80299034-80299264 293974 0230+00 1/1 0/0 0/0 .text
* createBasicWaveBank__11JASWSParserFPCvP7JKRHeap */
JASBasicWaveBank* JASWSParser::createBasicWaveBank(void const* stream, JKRHeap* heap) {
if (heap == NULL) {
heap = JASDram;
@@ -77,8 +66,6 @@ JASBasicWaveBank* JASWSParser::createBasicWaveBank(void const* stream, JKRHeap*
return wave_bank;
}
/* 80299264-80299490 293BA4 022C+00 1/1 0/0 0/0 .text
* createSimpleWaveBank__11JASWSParserFPCvP7JKRHeap */
JASSimpleWaveBank* JASWSParser::createSimpleWaveBank(void const* stream, JKRHeap* heap) {
if (heap == NULL) {
heap = JASDram;
-25
View File
@@ -1,8 +1,3 @@
//
// Generated By: dol2asm
// Translation Unit: JASWaveArcLoader
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JASWaveArcLoader.h"
@@ -14,11 +9,8 @@
#include "dolphin/os.h"
#include <stdint.h>
/* 80451290-80451298 000790 0004+04 1/1 0/0 0/0 .sbss sAramHeap__16JASWaveArcLoader */
JASHeap* JASWaveArcLoader::sAramHeap;
/* 8029A0A0-8029A0D0 2949E0 0030+00 2/2 0/0 0/0 .text getRootHeap__16JASWaveArcLoaderFv
*/
JASHeap* JASWaveArcLoader::getRootHeap() {
if (JASWaveArcLoader::sAramHeap) {
return JASWaveArcLoader::sAramHeap;
@@ -26,10 +18,8 @@ JASHeap* JASWaveArcLoader::getRootHeap() {
return JASKernel::getAramHeap();
}
/* 803C77E0-803C7820 024900 0040+00 2/2 0/0 0/0 .data sCurrentDir__16JASWaveArcLoader */
char JASWaveArcLoader::sCurrentDir[DIR_MAX] = "/AudioRes/Waves/";
/* 8029A0D0-8029A130 294A10 0060+00 0/0 1/1 0/0 .text setCurrentDir__16JASWaveArcLoaderFPCc */
void JASWaveArcLoader::setCurrentDir(char const* dir) {
ASSERT(std::strlen(dir) < DIR_MAX - 1);
strcpy(sCurrentDir, dir);
@@ -41,13 +31,10 @@ void JASWaveArcLoader::setCurrentDir(char const* dir) {
}
}
/* 8029A130-8029A13C 294A70 000C+00 1/1 0/0 0/0 .text getCurrentDir__16JASWaveArcLoaderFv
*/
char* JASWaveArcLoader::getCurrentDir() {
return sCurrentDir;
}
/* 8029A13C-8029A1B4 294A7C 0078+00 0/0 2/2 0/0 .text __ct__10JASWaveArcFv */
JASWaveArc::JASWaveArc() : mHeap(this) {
_48 = 0;
mStatus = 0;
@@ -58,10 +45,8 @@ JASWaveArc::JASWaveArc() : mHeap(this) {
OSInitMutex(&mMutex);
}
/* 8029A1B4-8029A258 294AF4 00A4+00 1/0 2/2 0/0 .text __dt__10JASWaveArcFv */
JASWaveArc::~JASWaveArc() {}
/* 8029A258-8029A2EC 294B98 0094+00 1/1 0/0 0/0 .text loadSetup__10JASWaveArcFUl */
bool JASWaveArc::loadSetup(u32 param_0) {
JASMutexLock mutexLock(&mMutex);
if (_58 != param_0) {
@@ -75,7 +60,6 @@ bool JASWaveArc::loadSetup(u32 param_0) {
return true;
}
/* 8029A2EC-8029A378 294C2C 008C+00 1/1 0/0 0/0 .text eraseSetup__10JASWaveArcFv */
bool JASWaveArc::eraseSetup() {
JASMutexLock mutexLock(&mMutex);
if (mStatus == 0) {
@@ -90,8 +74,6 @@ bool JASWaveArc::eraseSetup() {
return true;
}
/* 8029A378-8029A404 294CB8 008C+00 1/1 0/0 0/0 .text loadToAramCallback__10JASWaveArcFPv
*/
void JASWaveArc::loadToAramCallback(void* this_) {
loadToAramCallbackParams* tmp = (loadToAramCallbackParams*)this_;
JASWaveArc* wavArc = tmp->mWavArc;
@@ -107,7 +89,6 @@ void JASWaveArc::loadToAramCallback(void* this_) {
}
}
/* 8029A404-8029A4C0 294D44 00BC+00 2/2 0/0 0/0 .text sendLoadCmd__10JASWaveArcFv */
bool JASWaveArc::sendLoadCmd() {
JASMutexLock mutexLock(&mMutex);
_48 = 0;
@@ -131,7 +112,6 @@ bool JASWaveArc::sendLoadCmd() {
return true;
}
/* 8029A4C0-8029A580 294E00 00C0+00 0/0 2/2 0/0 .text load__10JASWaveArcFP7JASHeap */
bool JASWaveArc::load(JASHeap* heap) {
if (mEntryNum < 0) {
return false;
@@ -150,7 +130,6 @@ bool JASWaveArc::load(JASHeap* heap) {
return sendLoadCmd();
}
/* 8029A580-8029A640 294EC0 00C0+00 0/0 1/1 0/0 .text loadTail__10JASWaveArcFP7JASHeap */
bool JASWaveArc::loadTail(JASHeap* heap) {
if (mEntryNum < 0) {
return false;
@@ -169,19 +148,16 @@ bool JASWaveArc::loadTail(JASHeap* heap) {
return sendLoadCmd();
}
/* 8029A640-8029A664 294F80 0024+00 0/0 2/2 0/0 .text erase__10JASWaveArcFv */
bool JASWaveArc::erase() {
return mHeap.free();
}
/* 8029A664-8029A6AC 294FA4 0048+00 1/0 2/0 0/0 .text onDispose__10JASWaveArcFv */
void JASWaveArc::onDispose() {
if (eraseSetup()) {
onEraseDone();
}
}
/* 8029A6AC-8029A70C 294FEC 0060+00 1/1 0/0 0/0 .text setEntryNum__10JASWaveArcFl */
void JASWaveArc::setEntryNum(s32 entryNum) {
DVDFileInfo fileInfo;
if (entryNum < 0) {
@@ -196,7 +172,6 @@ void JASWaveArc::setEntryNum(s32 entryNum) {
mEntryNum = entryNum;
}
/* 8029A70C-8029A7B8 29504C 00AC+00 0/0 2/2 0/0 .text setFileName__10JASWaveArcFPCc */
void JASWaveArc::setFileName(char const* fileName) {
char* currentDir = JASWaveArcLoader::getCurrentDir();
size_t length = strlen(currentDir);
@@ -1,24 +1,15 @@
//
// Generated By: dol2asm
// Translation Unit: JAUAudioArcInterpreter
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JAUAudioArcInterpreter.h"
#include "JSystem/JUtility/JUTAssert.h"
/* 802A4244-802A4260 29EB84 001C+00 0/0 1/1 0/0 .text __ct__22JAUAudioArcInterpreterFv */
JAUAudioArcInterpreter::JAUAudioArcInterpreter() {
mBase = NULL;
mReadPtr = NULL;
}
/* 802A4260-802A42A8 29EBA0 0048+00 1/0 3/3 0/0 .text __dt__22JAUAudioArcInterpreterFv */
JAUAudioArcInterpreter::~JAUAudioArcInterpreter() {}
/* 802A42A8-802A4314 29EBE8 006C+00 0/0 1/1 0/0 .text parse__22JAUAudioArcInterpreterFPCv
*/
bool JAUAudioArcInterpreter::parse(void const* param_0) {
mBase = (const u8*)param_0;
mReadPtr = mBase;
@@ -29,13 +20,10 @@ bool JAUAudioArcInterpreter::parse(void const* param_0) {
return true;
}
/* 802A4314-802A431C 29EC54 0008+00 1/0 1/0 0/0 .text readCommandMore__22JAUAudioArcInterpreterFUl
*/
bool JAUAudioArcInterpreter::readCommandMore(u32 param_0) {
return false;
}
/* 802A431C-802A4740 29EC5C 0424+00 1/1 0/0 0/0 .text readCommand___22JAUAudioArcInterpreterFv */
bool JAUAudioArcInterpreter::readCommand_() {
u32 cmd = readU32_();
switch (cmd) {
-30
View File
@@ -1,28 +1,19 @@
//
// Generated By: dol2asm
// Translation Unit: JAUAudioArcLoader
//
#include "JSystem/JSystem.h" // IWYU pragma: keep
#include "JSystem/JAudio2/JAUAudioArcLoader.h"
#include "JSystem/JAudio2/JAISeMgr.h"
#include "JSystem/JAudio2/JAUSectionHeap.h"
/* 802A4740-802A478C 29F080 004C+00 0/0 1/1 0/0 .text __ct__17JAUAudioArcLoaderFP10JAUSection */
JAUAudioArcLoader::JAUAudioArcLoader(JAUSection* section) {
//JUT_ASSERT(13, section->isOpen());
//JUT_ASSERT(14, section->isBuilding());
mSection = section;
}
/* 802A478C-802A47AC 29F0CC 0020+00 0/0 1/1 0/0 .text load__17JAUAudioArcLoaderFPCv */
bool JAUAudioArcLoader::load(void const* param_0) {
return parse(param_0);
}
/* 802A47AC-802A4804 29F0EC 0058+00 1/0 1/0 0/0 .text readWS__17JAUAudioArcLoaderFUlPCvUl
*/
void JAUAudioArcLoader::readWS(u32 param_0, void const* param_1, u32 param_2) {
mSection->newWaveBank(param_0, param_1);
if (param_2) {
@@ -30,73 +21,52 @@ void JAUAudioArcLoader::readWS(u32 param_0, void const* param_1, u32 param_2) {
}
}
/* 802A4804-802A4834 29F144 0030+00 1/0 1/0 0/0 .text readBNK__17JAUAudioArcLoaderFUlPCv
*/
void JAUAudioArcLoader::readBNK(u32 param_0, void const* param_1) {
mSection->newBank(param_1, param_0);
}
/* 802A4834-802A4858 29F174 0024+00 1/0 1/0 0/0 .text readBSC__17JAUAudioArcLoaderFPCvUl
*/
void JAUAudioArcLoader::readBSC(void const* param_0, u32 param_1) {
mSection->newSeSeqCollection(param_0, param_1);
}
/* 802A4858-802A4880 29F198 0028+00 1/0 1/0 0/0 .text readBST__17JAUAudioArcLoaderFPCvUl
*/
void JAUAudioArcLoader::readBST(void const* param_0, u32 param_1) {
mSection->newSoundTable(param_0, param_1, true);
}
/* 802A4880-802A48A8 29F1C0 0028+00 1/0 0/0 0/0 .text readBSTN__17JAUAudioArcLoaderFPCvUl
*/
void JAUAudioArcLoader::readBSTN(void const* param_0, u32 param_1) {
mSection->newSoundNameTable(param_0, param_1, true);
}
/* 802A48A8-802A48D4 29F1E8 002C+00 1/0 1/0 0/0 .text readBMS__17JAUAudioArcLoaderFUlPCvUl */
void JAUAudioArcLoader::readBMS(u32 param_0, void const* param_1, u32 param_2) {
mSection->newStaticSeqData(param_0, param_1, param_2);
}
/* 802A48D4-802A4900 29F214 002C+00 1/0 1/0 0/0 .text readBMS_fromArchive__17JAUAudioArcLoaderFUl
*/
void JAUAudioArcLoader::readBMS_fromArchive(u32 param_0) {
mSection->newStaticSeqData(param_0);
}
/* 802A4900-802A4930 29F240 0030+00 1/0 1/0 0/0 .text newVoiceBank__17JAUAudioArcLoaderFUlUl */
void JAUAudioArcLoader::newVoiceBank(u32 param_0, u32 param_1) {
mSection->newVoiceBank(param_1, param_0);
}
/* 802A4930-802A4968 29F270 0038+00 1/0 1/0 0/0 .text newDynamicSeqBlock__17JAUAudioArcLoaderFUl
*/
void JAUAudioArcLoader::newDynamicSeqBlock(u32 param_0) {
JAUSectionHeap* sectionHeap = mSection->asSectionHeap();
JUT_ASSERT(72, sectionHeap);
sectionHeap->newDynamicSeqBlock(param_0);
}
/* 802A4968-802A4990 29F2A8 0028+00 1/0 1/0 0/0 .text readBSFT__17JAUAudioArcLoaderFPCv
*/
void JAUAudioArcLoader::readBSFT(void const* param_0) {
mSection->newStreamFileTable(param_0, true);
}
/* 802A4990-802A49B4 29F2D0 0024+00 1/0 1/0 0/0 .text beginBNKList__17JAUAudioArcLoaderFUlUl */
void JAUAudioArcLoader::beginBNKList(u32 param_0, u32 param_1) {
mSection->beginNewBankTable(param_0, param_1);
}
/* 802A49B4-802A49D8 29F2F4 0024+00 1/0 1/0 0/0 .text endBNKList__17JAUAudioArcLoaderFv
*/
void JAUAudioArcLoader::endBNKList() {
mSection->endNewBankTable();
}
/* 802A49D8-802A49FC 29F318 0024+00 1/0 1/0 0/0 .text readMaxSeCategory__17JAUAudioArcLoaderFiii
*/
void JAUAudioArcLoader::readMaxSeCategory(int param_0, int param_1, int param_2) {
JAISeMgr* seMgr = JASGlobalInstance<JAISeMgr>::getInstance();
if (seMgr) {

Some files were not shown because too many files have changed in this diff Show More