mirror of
https://github.com/zeldaret/oot-gc.git
synced 2026-10-08 01:34:00 -04:00
Rewrite debug info: variable locations, integer types, formatting (#11)
* Rewrite debug info * Add typedefs to structs/enums/unions
This commit is contained in:
+320
-323
@@ -1,323 +1,320 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// Location: 0x20370D80
|
||||
unsigned char gTgPcTPL[32897];
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x80135580
|
||||
static int gnCountArgument;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x80135584
|
||||
static char **gaszArgument;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x80135588
|
||||
static void *DefaultFifo;
|
||||
|
||||
// size: 0x80
|
||||
struct __anon_0x238
|
||||
{
|
||||
unsigned char pad[128]; // 0x0
|
||||
};
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x8013558C
|
||||
static __anon_0x238 *DefaultFifoObj;
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x29F
|
||||
{
|
||||
VI_TVMODE_NTSC_INT = 0,
|
||||
VI_TVMODE_NTSC_DS = 1,
|
||||
VI_TVMODE_NTSC_PROG = 2,
|
||||
VI_TVMODE_PAL_INT = 4,
|
||||
VI_TVMODE_PAL_DS = 5,
|
||||
VI_TVMODE_EURGB60_INT = 20,
|
||||
VI_TVMODE_EURGB60_DS = 21,
|
||||
VI_TVMODE_MPAL_INT = 8,
|
||||
VI_TVMODE_MPAL_DS = 9,
|
||||
VI_TVMODE_DEBUG_INT = 12,
|
||||
VI_TVMODE_DEBUG_PAL_INT = 16,
|
||||
VI_TVMODE_DEBUG_PAL_DS = 17
|
||||
};
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x3EC
|
||||
{
|
||||
VI_XFBMODE_SF = 0,
|
||||
VI_XFBMODE_DF = 1
|
||||
};
|
||||
|
||||
// size: 0x3C
|
||||
struct _GXRenderModeObj
|
||||
{
|
||||
__anon_0x29F viTVmode; // 0x0
|
||||
unsigned short fbWidth; // 0x4
|
||||
unsigned short efbHeight; // 0x6
|
||||
unsigned short xfbHeight; // 0x8
|
||||
unsigned short viXOrigin; // 0xA
|
||||
unsigned short viYOrigin; // 0xC
|
||||
unsigned short viWidth; // 0xE
|
||||
unsigned short viHeight; // 0x10
|
||||
__anon_0x3EC xFBmode; // 0x14
|
||||
unsigned char field_rendering; // 0x18
|
||||
unsigned char aa; // 0x19
|
||||
unsigned char sample_pattern[12][2]; // 0x1A
|
||||
unsigned char vfilter[7]; // 0x32
|
||||
};
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x800F3EE0
|
||||
static _GXRenderModeObj rmodeobj;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x80135590
|
||||
static void *gpHeap;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x80135594
|
||||
static void *gArenaHi;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x80135598
|
||||
static void *gArenaLo;
|
||||
|
||||
// size: 0x20
|
||||
struct _GXTexObj
|
||||
{
|
||||
unsigned long dummy[8]; // 0x0
|
||||
};
|
||||
|
||||
// Location: 0x1C3F0F80
|
||||
_GXTexObj g_texMap[4];
|
||||
|
||||
// Location: 0x8013559C
|
||||
_GXRenderModeObj *rmode;
|
||||
|
||||
void xlCoreBeforeRender()
|
||||
{
|
||||
// References: rmode (0x8013559C)
|
||||
}
|
||||
|
||||
// Location: 0x20541380
|
||||
int __OSCurrHeap;
|
||||
|
||||
// Location: 0x80135A94
|
||||
void *DemoFrameBuffer1;
|
||||
|
||||
// Location: 0x80135A8C
|
||||
void *DemoCurrentBuffer;
|
||||
|
||||
// Location: 0x80135A90
|
||||
void *DemoFrameBuffer2;
|
||||
|
||||
// size: 0x4
|
||||
enum _GXTexWrapMode
|
||||
{
|
||||
GX_CLAMP = 0,
|
||||
GX_REPEAT = 1,
|
||||
GX_MIRROR = 2,
|
||||
GX_MAX_TEXWRAPMODE = 3
|
||||
};
|
||||
|
||||
// size: 0x4
|
||||
enum _GXTexFilter
|
||||
{
|
||||
GX_NEAR = 0,
|
||||
GX_LINEAR = 1,
|
||||
GX_NEAR_MIP_NEAR = 2,
|
||||
GX_LIN_MIP_NEAR = 3,
|
||||
GX_NEAR_MIP_LIN = 4,
|
||||
GX_LIN_MIP_LIN = 5
|
||||
};
|
||||
|
||||
// size: 0x24
|
||||
struct __anon_0x9F7
|
||||
{
|
||||
unsigned short height; // 0x0
|
||||
unsigned short width; // 0x2
|
||||
unsigned long format; // 0x4
|
||||
char *data; // 0x8
|
||||
_GXTexWrapMode wrapS; // 0xC
|
||||
_GXTexWrapMode wrapT; // 0x10
|
||||
_GXTexFilter minFilter; // 0x14
|
||||
_GXTexFilter magFilter; // 0x18
|
||||
float LODBias; // 0x1C
|
||||
unsigned char edgeLODEnable; // 0x20
|
||||
unsigned char minLOD; // 0x21
|
||||
unsigned char maxLOD; // 0x22
|
||||
unsigned char unpacked; // 0x23
|
||||
};
|
||||
|
||||
// size: 0x4
|
||||
enum _GXTlutFmt
|
||||
{
|
||||
GX_TL_IA8 = 0,
|
||||
GX_TL_RGB565 = 1,
|
||||
GX_TL_RGB5A3 = 2,
|
||||
GX_MAX_TLUTFMT = 3
|
||||
};
|
||||
|
||||
// size: 0xC
|
||||
struct __anon_0xC52
|
||||
{
|
||||
unsigned short numEntries; // 0x0
|
||||
unsigned char unpacked; // 0x2
|
||||
unsigned char pad8; // 0x3
|
||||
_GXTlutFmt format; // 0x4
|
||||
char *data; // 0x8
|
||||
};
|
||||
|
||||
// size: 0x8
|
||||
struct __anon_0xD1E
|
||||
{
|
||||
__anon_0x9F7 *textureHeader; // 0x0
|
||||
__anon_0xC52 *CLUTHeader; // 0x4
|
||||
};
|
||||
|
||||
// size: 0x4
|
||||
struct _GXColor
|
||||
{
|
||||
unsigned char r; // 0x0
|
||||
unsigned char g; // 0x1
|
||||
unsigned char b; // 0x2
|
||||
unsigned char a; // 0x3
|
||||
};
|
||||
|
||||
int main(int nCount, char **aszArgument)
|
||||
{
|
||||
int nSize;
|
||||
void *pHeap;
|
||||
long nSizeHeap;
|
||||
__anon_0xD1E *tdp;
|
||||
_GXColor black;
|
||||
unsigned long i;
|
||||
// References: __OSCurrHeap (0x20541380)
|
||||
// References: gpHeap (0x80135590)
|
||||
// References: g_texMap (0x1C3F0F80)
|
||||
// References: gTgPcTPL (0x20370D80)
|
||||
// References: rmode (0x8013559C)
|
||||
// References: DemoFrameBuffer2 (0x80135A90)
|
||||
// References: DemoCurrentBuffer (0x80135A8C)
|
||||
// References: DemoFrameBuffer1 (0x80135A94)
|
||||
// References: DefaultFifo (0x80135588)
|
||||
// References: DefaultFifoObj (0x8013558C)
|
||||
// References: gaszArgument (0x80135584)
|
||||
// References: gnCountArgument (0x80135580)
|
||||
}
|
||||
|
||||
int xlCoreGetUpper24MB(void *ppBuffer);
|
||||
|
||||
// size: 0x8
|
||||
union DoubleLongLong
|
||||
{
|
||||
long float f; // 0x0
|
||||
signed long long i; // 0x0
|
||||
};
|
||||
|
||||
int xlCoreEnableFPExceptions()
|
||||
{
|
||||
long float control;
|
||||
DoubleLongLong d;
|
||||
}
|
||||
|
||||
int xlCoreHiResolution();
|
||||
|
||||
int xlCoreGetArgument(int iArgument, char **pszArgument)
|
||||
{
|
||||
// References: gaszArgument (0x80135584)
|
||||
// References: gnCountArgument (0x80135580)
|
||||
}
|
||||
|
||||
int xlCoreGetArgumentCount()
|
||||
{
|
||||
// References: gnCountArgument (0x80135580)
|
||||
}
|
||||
|
||||
void xlCoreInitVI()
|
||||
{
|
||||
// References: rmode (0x8013559C)
|
||||
// References: DemoFrameBuffer2 (0x80135A90)
|
||||
// References: DemoCurrentBuffer (0x80135A8C)
|
||||
// References: DemoFrameBuffer1 (0x80135A94)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static void xlCoreInitGX()
|
||||
{
|
||||
unsigned char newFilter[7];
|
||||
// References: DemoCurrentBuffer (0x80135A8C)
|
||||
// References: rmode (0x8013559C)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static void xlCoreInitMem()
|
||||
{
|
||||
void *arenaLo;
|
||||
void *arenaHi;
|
||||
unsigned long fbSize;
|
||||
// References: DemoFrameBuffer2 (0x80135A90)
|
||||
// References: DemoCurrentBuffer (0x80135A8C)
|
||||
// References: DemoFrameBuffer1 (0x80135A94)
|
||||
// References: rmode (0x8013559C)
|
||||
// References: gArenaHi (0x80135594)
|
||||
// References: gArenaLo (0x80135598)
|
||||
}
|
||||
|
||||
// Location: 0x601E0F80
|
||||
_GXRenderModeObj GXNtsc480IntDf;
|
||||
|
||||
// Location: 0x800F1E9C
|
||||
_GXRenderModeObj GXNtsc480Prog;
|
||||
|
||||
// Location: 0x141F0F80
|
||||
_GXRenderModeObj GXPal528IntDf;
|
||||
|
||||
// Location: 0x800F1ED8
|
||||
_GXRenderModeObj GXMpal480IntDf;
|
||||
|
||||
// Local to compilation unit
|
||||
static void xlCoreInitRenderMode(_GXRenderModeObj *mode)
|
||||
{
|
||||
char *szText;
|
||||
int iArgument;
|
||||
// References: rmodeobj (0x800F3EE0)
|
||||
// References: rmode (0x8013559C)
|
||||
// References: GXMpal480IntDf (0x800F1ED8)
|
||||
// References: GXPal528IntDf (0x141F0F80)
|
||||
// References: GXNtsc480Prog (0x800F1E9C)
|
||||
// References: gnCountArgument (0x80135580)
|
||||
// References: gaszArgument (0x80135584)
|
||||
// References: GXNtsc480IntDf (0x601E0F80)
|
||||
}
|
||||
|
||||
int xlCoreReset()
|
||||
{
|
||||
// References: gArenaHi (0x80135594)
|
||||
// References: gArenaLo (0x80135598)
|
||||
// References: gpHeap (0x80135590)
|
||||
// References: __OSCurrHeap (0x20541380)
|
||||
}
|
||||
|
||||
void xlCoreInit(_GXRenderModeObj *mode)
|
||||
{
|
||||
// References: rmode (0x8013559C)
|
||||
// References: DemoFrameBuffer2 (0x80135A90)
|
||||
// References: DemoCurrentBuffer (0x80135A8C)
|
||||
// References: DemoFrameBuffer1 (0x80135A94)
|
||||
// References: DefaultFifo (0x80135588)
|
||||
// References: DefaultFifoObj (0x8013558C)
|
||||
// References: __OSCurrHeap (0x20541380)
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Core\xlCoreGCN.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x800055A0 -> 0x80005E04
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
// size = 0x8081, address = 0x800D3720
|
||||
u8 gTgPcTPL[32897];
|
||||
|
||||
// size = 0x4, address = 0x80135580
|
||||
static s32 gnCountArgument;
|
||||
|
||||
// size = 0x4, address = 0x80135584
|
||||
static char** gaszArgument;
|
||||
|
||||
// size = 0x4, address = 0x80135588
|
||||
static void* DefaultFifo;
|
||||
|
||||
typedef struct __anon_0x238 {
|
||||
/* 0x0 */ u8 pad[128];
|
||||
} __anon_0x238; // size = 0x80
|
||||
|
||||
// size = 0x4, address = 0x8013558C
|
||||
static struct __anon_0x238* DefaultFifoObj;
|
||||
|
||||
typedef enum __anon_0x29F {
|
||||
VI_TVMODE_NTSC_INT = 0,
|
||||
VI_TVMODE_NTSC_DS = 1,
|
||||
VI_TVMODE_NTSC_PROG = 2,
|
||||
VI_TVMODE_PAL_INT = 4,
|
||||
VI_TVMODE_PAL_DS = 5,
|
||||
VI_TVMODE_EURGB60_INT = 20,
|
||||
VI_TVMODE_EURGB60_DS = 21,
|
||||
VI_TVMODE_MPAL_INT = 8,
|
||||
VI_TVMODE_MPAL_DS = 9,
|
||||
VI_TVMODE_DEBUG_INT = 12,
|
||||
VI_TVMODE_DEBUG_PAL_INT = 16,
|
||||
VI_TVMODE_DEBUG_PAL_DS = 17,
|
||||
} __anon_0x29F;
|
||||
|
||||
typedef enum __anon_0x3EC {
|
||||
VI_XFBMODE_SF = 0,
|
||||
VI_XFBMODE_DF = 1,
|
||||
} __anon_0x3EC;
|
||||
|
||||
typedef struct _GXRenderModeObj {
|
||||
/* 0x00 */ enum __anon_0x29F viTVmode;
|
||||
/* 0x04 */ u16 fbWidth;
|
||||
/* 0x06 */ u16 efbHeight;
|
||||
/* 0x08 */ u16 xfbHeight;
|
||||
/* 0x0A */ u16 viXOrigin;
|
||||
/* 0x0C */ u16 viYOrigin;
|
||||
/* 0x0E */ u16 viWidth;
|
||||
/* 0x10 */ u16 viHeight;
|
||||
/* 0x14 */ enum __anon_0x3EC xFBmode;
|
||||
/* 0x18 */ u8 field_rendering;
|
||||
/* 0x19 */ u8 aa;
|
||||
/* 0x1A */ u8 sample_pattern[12][2];
|
||||
/* 0x32 */ u8 vfilter[7];
|
||||
} __anon_0x4A0; // size = 0x3C
|
||||
|
||||
// size = 0x3C, address = 0x800F3EE0
|
||||
static struct _GXRenderModeObj rmodeobj;
|
||||
|
||||
// size = 0x4, address = 0x80135590
|
||||
static void* gpHeap;
|
||||
|
||||
// size = 0x4, address = 0x80135594
|
||||
static void* gArenaHi;
|
||||
|
||||
// size = 0x4, address = 0x80135598
|
||||
static void* gArenaLo;
|
||||
|
||||
typedef struct _GXTexObj {
|
||||
/* 0x0 */ u32 dummy[8];
|
||||
} __anon_0x769; // size = 0x20
|
||||
|
||||
// size = 0x80, address = 0x800F3F1C
|
||||
struct _GXTexObj g_texMap[4];
|
||||
|
||||
// size = 0x4, address = 0x8013559C
|
||||
struct _GXRenderModeObj* rmode;
|
||||
|
||||
// Range: 0x800055A0 -> 0x80005674
|
||||
void xlCoreBeforeRender() {
|
||||
// References
|
||||
// -> struct _GXRenderModeObj* rmode;
|
||||
}
|
||||
|
||||
// size = 0x4, address = 0x80135420
|
||||
s32 __OSCurrHeap;
|
||||
|
||||
// size = 0x4, address = 0x80135A94
|
||||
void* DemoFrameBuffer1;
|
||||
|
||||
// size = 0x4, address = 0x80135A8C
|
||||
void* DemoCurrentBuffer;
|
||||
|
||||
// size = 0x4, address = 0x80135A90
|
||||
void* DemoFrameBuffer2;
|
||||
|
||||
typedef enum _GXTexWrapMode {
|
||||
GX_CLAMP = 0,
|
||||
GX_REPEAT = 1,
|
||||
GX_MIRROR = 2,
|
||||
GX_MAX_TEXWRAPMODE = 3,
|
||||
} __anon_0x8FD;
|
||||
|
||||
typedef enum _GXTexFilter {
|
||||
GX_NEAR = 0,
|
||||
GX_LINEAR = 1,
|
||||
GX_NEAR_MIP_NEAR = 2,
|
||||
GX_LIN_MIP_NEAR = 3,
|
||||
GX_NEAR_MIP_LIN = 4,
|
||||
GX_LIN_MIP_LIN = 5,
|
||||
} __anon_0x966;
|
||||
|
||||
typedef struct __anon_0x9F7 {
|
||||
/* 0x00 */ u16 height;
|
||||
/* 0x02 */ u16 width;
|
||||
/* 0x04 */ u32 format;
|
||||
/* 0x08 */ char* data;
|
||||
/* 0x0C */ enum _GXTexWrapMode wrapS;
|
||||
/* 0x10 */ enum _GXTexWrapMode wrapT;
|
||||
/* 0x14 */ enum _GXTexFilter minFilter;
|
||||
/* 0x18 */ enum _GXTexFilter magFilter;
|
||||
/* 0x1C */ float LODBias;
|
||||
/* 0x20 */ u8 edgeLODEnable;
|
||||
/* 0x21 */ u8 minLOD;
|
||||
/* 0x22 */ u8 maxLOD;
|
||||
/* 0x23 */ u8 unpacked;
|
||||
} __anon_0x9F7; // size = 0x24
|
||||
|
||||
typedef enum _GXTlutFmt {
|
||||
GX_TL_IA8 = 0,
|
||||
GX_TL_RGB565 = 1,
|
||||
GX_TL_RGB5A3 = 2,
|
||||
GX_MAX_TLUTFMT = 3,
|
||||
} __anon_0xBEA;
|
||||
|
||||
typedef struct __anon_0xC52 {
|
||||
/* 0x0 */ u16 numEntries;
|
||||
/* 0x2 */ u8 unpacked;
|
||||
/* 0x3 */ u8 pad8;
|
||||
/* 0x4 */ enum _GXTlutFmt format;
|
||||
/* 0x8 */ char* data;
|
||||
} __anon_0xC52; // size = 0xC
|
||||
|
||||
typedef struct __anon_0xD1E {
|
||||
/* 0x0 */ struct __anon_0x9F7* textureHeader;
|
||||
/* 0x4 */ struct __anon_0xC52* CLUTHeader;
|
||||
} __anon_0xD1E; // size = 0x8
|
||||
|
||||
typedef struct _GXColor {
|
||||
/* 0x0 */ u8 r;
|
||||
/* 0x1 */ u8 g;
|
||||
/* 0x2 */ u8 b;
|
||||
/* 0x3 */ u8 a;
|
||||
} __anon_0xD8F; // size = 0x4
|
||||
|
||||
// Range: 0x80005674 -> 0x800058DC
|
||||
s32 main(s32 nCount, char** aszArgument) {
|
||||
// Parameters
|
||||
// s32 nCount; // r1+0x8
|
||||
// char** aszArgument; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
s32 nSize; // r31
|
||||
void* pHeap; // r27
|
||||
s32 nSizeHeap; // r3
|
||||
struct __anon_0xD1E* tdp; // r1+0x8
|
||||
struct _GXColor black; // r1+0x10
|
||||
u32 i; // r26
|
||||
|
||||
// References
|
||||
// -> s32 __OSCurrHeap;
|
||||
// -> static void* gpHeap;
|
||||
// -> struct _GXTexObj g_texMap[4];
|
||||
// -> u8 gTgPcTPL[32897];
|
||||
// -> struct _GXRenderModeObj* rmode;
|
||||
// -> void* DemoFrameBuffer2;
|
||||
// -> void* DemoCurrentBuffer;
|
||||
// -> void* DemoFrameBuffer1;
|
||||
// -> static void* DefaultFifo;
|
||||
// -> static struct __anon_0x238* DefaultFifoObj;
|
||||
// -> static char** gaszArgument;
|
||||
// -> static s32 gnCountArgument;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlCoreGetUpper24MB(void* ppBuffer) {
|
||||
// Parameters
|
||||
// void* ppBuffer; // r1+0x0
|
||||
}
|
||||
|
||||
typedef union DoubleLongLong {
|
||||
/* 0x0 */ double f;
|
||||
/* 0x0 */ s64 i;
|
||||
} __anon_0x1026;
|
||||
|
||||
// Erased
|
||||
static s32 xlCoreEnableFPExceptions() {
|
||||
// Local variables
|
||||
double control; // r1+0x8
|
||||
union DoubleLongLong d; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x800058DC -> 0x800058E4
|
||||
s32 xlCoreHiResolution() {}
|
||||
|
||||
// Range: 0x800058E4 -> 0x80005918
|
||||
s32 xlCoreGetArgument(s32 iArgument, char** pszArgument) {
|
||||
// Parameters
|
||||
// s32 iArgument; // r1+0x0
|
||||
// char** pszArgument; // r1+0x4
|
||||
|
||||
// References
|
||||
// -> static char** gaszArgument;
|
||||
// -> static s32 gnCountArgument;
|
||||
}
|
||||
|
||||
// Range: 0x80005918 -> 0x80005920
|
||||
s32 xlCoreGetArgumentCount() {
|
||||
// References
|
||||
// -> static s32 gnCountArgument;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void xlCoreInitVI() {
|
||||
// References
|
||||
// -> struct _GXRenderModeObj* rmode;
|
||||
// -> void* DemoFrameBuffer2;
|
||||
// -> void* DemoCurrentBuffer;
|
||||
// -> void* DemoFrameBuffer1;
|
||||
}
|
||||
|
||||
// Range: 0x80005920 -> 0x80005B7C
|
||||
static void xlCoreInitGX() {
|
||||
// Local variables
|
||||
u8 newFilter[7]; // r1+0x18
|
||||
|
||||
// References
|
||||
// -> void* DemoCurrentBuffer;
|
||||
// -> struct _GXRenderModeObj* rmode;
|
||||
}
|
||||
|
||||
// Range: 0x80005B7C -> 0x80005C54
|
||||
static void xlCoreInitMem() {
|
||||
// Local variables
|
||||
void* arenaLo; // r1+0x8
|
||||
void* arenaHi; // r1+0x8
|
||||
u32 fbSize; // r3
|
||||
|
||||
// References
|
||||
// -> void* DemoFrameBuffer2;
|
||||
// -> void* DemoCurrentBuffer;
|
||||
// -> void* DemoFrameBuffer1;
|
||||
// -> struct _GXRenderModeObj* rmode;
|
||||
// -> static void* gArenaHi;
|
||||
// -> static void* gArenaLo;
|
||||
}
|
||||
|
||||
// size = 0x3C, address = 0x800F1E60
|
||||
struct _GXRenderModeObj GXNtsc480IntDf;
|
||||
|
||||
// size = 0x3C, address = 0x800F1E9C
|
||||
struct _GXRenderModeObj GXNtsc480Prog;
|
||||
|
||||
// size = 0x3C, address = 0x800F1F14
|
||||
struct _GXRenderModeObj GXPal528IntDf;
|
||||
|
||||
// size = 0x3C, address = 0x800F1ED8
|
||||
struct _GXRenderModeObj GXMpal480IntDf;
|
||||
|
||||
// Range: 0x80005C54 -> 0x80005DC8
|
||||
static void xlCoreInitRenderMode(struct _GXRenderModeObj* mode) {
|
||||
// Parameters
|
||||
// struct _GXRenderModeObj* mode; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
char* szText; // r31
|
||||
s32 iArgument; // r5
|
||||
|
||||
// References
|
||||
// -> static struct _GXRenderModeObj rmodeobj;
|
||||
// -> struct _GXRenderModeObj* rmode;
|
||||
// -> struct _GXRenderModeObj GXMpal480IntDf;
|
||||
// -> struct _GXRenderModeObj GXPal528IntDf;
|
||||
// -> struct _GXRenderModeObj GXNtsc480Prog;
|
||||
// -> static s32 gnCountArgument;
|
||||
// -> static char** gaszArgument;
|
||||
// -> struct _GXRenderModeObj GXNtsc480IntDf;
|
||||
}
|
||||
|
||||
// Range: 0x80005DC8 -> 0x80005E04
|
||||
s32 xlCoreReset() {
|
||||
// References
|
||||
// -> static void* gArenaHi;
|
||||
// -> static void* gArenaLo;
|
||||
// -> static void* gpHeap;
|
||||
// -> s32 __OSCurrHeap;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void xlCoreInit(struct _GXRenderModeObj* mode) {
|
||||
// Parameters
|
||||
// struct _GXRenderModeObj* mode; // r31
|
||||
|
||||
// References
|
||||
// -> struct _GXRenderModeObj* rmode;
|
||||
// -> void* DemoFrameBuffer2;
|
||||
// -> void* DemoCurrentBuffer;
|
||||
// -> void* DemoFrameBuffer1;
|
||||
// -> static void* DefaultFifo;
|
||||
// -> static struct __anon_0x238* DefaultFifoObj;
|
||||
// -> s32 __OSCurrHeap;
|
||||
}
|
||||
|
||||
+214
-156
@@ -1,156 +1,214 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x800DB7E0
|
||||
_XL_OBJECTTYPE gTypeFile;
|
||||
|
||||
// size: 0x20
|
||||
struct DVDDiskID
|
||||
{
|
||||
char gameName[4]; // 0x0
|
||||
char company[2]; // 0x4
|
||||
unsigned char diskNumber; // 0x6
|
||||
unsigned char gameVersion; // 0x7
|
||||
unsigned char streaming; // 0x8
|
||||
unsigned char streamingBufSize; // 0x9
|
||||
unsigned char padding[22]; // 0xA
|
||||
};
|
||||
|
||||
// size: 0x30
|
||||
struct DVDCommandBlock
|
||||
{
|
||||
DVDCommandBlock *next; // 0x0
|
||||
DVDCommandBlock *prev; // 0x4
|
||||
unsigned long command; // 0x8
|
||||
long state; // 0xC
|
||||
unsigned long offset; // 0x10
|
||||
unsigned long length; // 0x14
|
||||
void *addr; // 0x18
|
||||
unsigned long currTransferSize; // 0x1C
|
||||
unsigned long transferredSize; // 0x20
|
||||
DVDDiskID *id; // 0x24
|
||||
void (*callback)(long /* unknown0 */, DVDCommandBlock */* unknown1 */); // 0x28
|
||||
void *userData; // 0x2C
|
||||
};
|
||||
|
||||
// size: 0x3C
|
||||
struct DVDFileInfo
|
||||
{
|
||||
DVDCommandBlock cb; // 0x0
|
||||
unsigned long startAddr; // 0x30
|
||||
unsigned long length; // 0x34
|
||||
void (*callback)(long /* unknown0 */, DVDFileInfo */* unknown1 */); // 0x38
|
||||
};
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x801355A0
|
||||
static int (*gpfOpen)(char */* unknown0 */, DVDFileInfo */* unknown1 */);
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x801355A4
|
||||
static int (*gpfRead)(DVDFileInfo */* unknown0 */, void */* unknown1 */, int /* unknown2 */, int /* unknown3 */, void (*/* unknown4 */)(long /* unknown0 */, DVDFileInfo */* unknown1 */));
|
||||
|
||||
// size: 0x58
|
||||
struct tXL_FILE
|
||||
{
|
||||
int iBuffer; // 0x0
|
||||
void *pData; // 0x4
|
||||
void *pBuffer; // 0x8
|
||||
int nAttributes; // 0xC
|
||||
int nSize; // 0x10
|
||||
int nOffset; // 0x14
|
||||
__anon_0x2757 eType; // 0x18
|
||||
DVDFileInfo info; // 0x1C
|
||||
};
|
||||
|
||||
int xlFileEvent(tXL_FILE *pFile, int nEvent);
|
||||
|
||||
int xlFileGetPosition(tXL_FILE *pFile, int *pnOffset);
|
||||
|
||||
int xlFileSetPosition(tXL_FILE *pFile, int nOffset);
|
||||
|
||||
int xlFilePutLine();
|
||||
|
||||
int xlFilePutFlip(int nSizeBytes);
|
||||
|
||||
int xlFilePut();
|
||||
|
||||
int xlFileGetLine(tXL_FILE *pFile, char *acLine, int nSizeLine)
|
||||
{
|
||||
int iCharacter;
|
||||
char nCharacter;
|
||||
}
|
||||
|
||||
int xlFileGetFlip(tXL_FILE *pFile, void *pTarget, int nSizeBytes);
|
||||
|
||||
int xlFileGet(tXL_FILE *pFile, void *pTarget, int nSizeBytes)
|
||||
{
|
||||
int nOffset;
|
||||
int nOffsetExtra;
|
||||
int nSize;
|
||||
int nSizeUsed;
|
||||
// References: gpfRead (0x801355A4)
|
||||
}
|
||||
|
||||
int xlFileClose(tXL_FILE **ppFile);
|
||||
|
||||
int xlFileCreate();
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x2757
|
||||
{
|
||||
XLFT_NONE = 4294967295,
|
||||
XLFT_TEXT = 0,
|
||||
XLFT_BINARY = 1
|
||||
};
|
||||
|
||||
int xlFileOpen(tXL_FILE **ppFile, __anon_0x2757 eType, char *szFileName)
|
||||
{
|
||||
int nStatus;
|
||||
// References: gpfOpen (0x801355A0)
|
||||
// References: gTypeFile (0x800DB7E0)
|
||||
}
|
||||
|
||||
int xlFileLoad(char *szFileName, void *ppBuffer)
|
||||
{
|
||||
int nSize;
|
||||
tXL_FILE *pFile;
|
||||
// References: gpfOpen (0x801355A0)
|
||||
// References: gTypeFile (0x800DB7E0)
|
||||
}
|
||||
|
||||
int xlFileGetSize(int *pnSize, char *szFileName)
|
||||
{
|
||||
tXL_FILE *pFile;
|
||||
// References: gpfOpen (0x801355A0)
|
||||
// References: gTypeFile (0x800DB7E0)
|
||||
}
|
||||
|
||||
int xlFileSetRead(int (*pfRead)(DVDFileInfo */* unknown0 */, void */* unknown1 */, int /* unknown2 */, int /* unknown3 */, void (*/* unknown4 */)(long /* unknown0 */, DVDFileInfo */* unknown1 */)))
|
||||
{
|
||||
// References: gpfRead (0x801355A4)
|
||||
}
|
||||
|
||||
int xlFileSetOpen(int (*pfOpen)(char */* unknown0 */, DVDFileInfo */* unknown1 */))
|
||||
{
|
||||
// References: gpfOpen (0x801355A0)
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Core\xlFileGCN.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x80005E68 -> 0x80006280
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x19EC; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800DB7E0
|
||||
struct _XL_OBJECTTYPE gTypeFile;
|
||||
|
||||
typedef struct DVDDiskID {
|
||||
/* 0x0 */ char gameName[4];
|
||||
/* 0x4 */ char company[2];
|
||||
/* 0x6 */ u8 diskNumber;
|
||||
/* 0x7 */ u8 gameVersion;
|
||||
/* 0x8 */ u8 streaming;
|
||||
/* 0x9 */ u8 streamingBufSize;
|
||||
/* 0xA */ u8 padding[22];
|
||||
} __anon_0x1B3D; // size = 0x20
|
||||
|
||||
typedef struct DVDCommandBlock {
|
||||
/* 0x00 */ struct DVDCommandBlock* next;
|
||||
/* 0x04 */ struct DVDCommandBlock* prev;
|
||||
/* 0x08 */ u32 command;
|
||||
/* 0x0C */ s32 state;
|
||||
/* 0x10 */ u32 offset;
|
||||
/* 0x14 */ u32 length;
|
||||
/* 0x18 */ void* addr;
|
||||
/* 0x1C */ u32 currTransferSize;
|
||||
/* 0x20 */ u32 transferredSize;
|
||||
/* 0x24 */ struct DVDDiskID* id;
|
||||
/* 0x28 */ void (*callback)(s32, struct DVDCommandBlock*);
|
||||
/* 0x2C */ void* userData;
|
||||
} __anon_0x1CAD; // size = 0x30
|
||||
|
||||
typedef struct DVDFileInfo {
|
||||
/* 0x00 */ struct DVDCommandBlock cb;
|
||||
/* 0x30 */ u32 startAddr;
|
||||
/* 0x34 */ u32 length;
|
||||
/* 0x38 */ void (*callback)(s32, struct DVDFileInfo*);
|
||||
} __anon_0x1ED3; // size = 0x3C
|
||||
|
||||
// size = 0x4, address = 0x801355A0
|
||||
static s32 (*gpfOpen)(char*, struct DVDFileInfo*);
|
||||
|
||||
// size = 0x4, address = 0x801355A4
|
||||
static s32 (*gpfRead)(struct DVDFileInfo*, void*, s32, s32, void (*)(s32, struct DVDFileInfo*));
|
||||
|
||||
typedef struct tXL_FILE {
|
||||
/* 0x00 */ s32 iBuffer;
|
||||
/* 0x04 */ void* pData;
|
||||
/* 0x08 */ void* pBuffer;
|
||||
/* 0x0C */ s32 nAttributes;
|
||||
/* 0x10 */ s32 nSize;
|
||||
/* 0x14 */ s32 nOffset;
|
||||
/* 0x18 */ enum __anon_0x2757 eType;
|
||||
/* 0x1C */ struct DVDFileInfo info;
|
||||
} __anon_0x2085; // size = 0x58
|
||||
|
||||
// Range: 0x80005E68 -> 0x80005F18
|
||||
s32 xlFileEvent(struct tXL_FILE* pFile, s32 nEvent) {
|
||||
// Parameters
|
||||
// struct tXL_FILE* pFile; // r31
|
||||
// s32 nEvent; // r1+0xC
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlFileGetPosition(struct tXL_FILE* pFile, s32* pnOffset) {
|
||||
// Parameters
|
||||
// struct tXL_FILE* pFile; // r1+0x0
|
||||
// s32* pnOffset; // r1+0x4
|
||||
}
|
||||
|
||||
// Range: 0x80005F18 -> 0x80005F40
|
||||
s32 xlFileSetPosition(struct tXL_FILE* pFile, s32 nOffset) {
|
||||
// Parameters
|
||||
// struct tXL_FILE* pFile; // r1+0x0
|
||||
// s32 nOffset; // r1+0x4
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlFilePutLine() {}
|
||||
|
||||
// Erased
|
||||
static s32 xlFilePutFlip(s32 nSizeBytes) {
|
||||
// Parameters
|
||||
// s32 nSizeBytes; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlFilePut() {}
|
||||
|
||||
// Erased
|
||||
static s32 xlFileGetLine(struct tXL_FILE* pFile, char* acLine, s32 nSizeLine) {
|
||||
// Parameters
|
||||
// struct tXL_FILE* pFile; // r28
|
||||
// char* acLine; // r29
|
||||
// s32 nSizeLine; // r30
|
||||
|
||||
// Local variables
|
||||
s32 iCharacter; // r31
|
||||
char nCharacter; // r1+0x14
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlFileGetFlip(struct tXL_FILE* pFile, void* pTarget, s32 nSizeBytes) {
|
||||
// Parameters
|
||||
// struct tXL_FILE* pFile; // r30
|
||||
// void* pTarget; // r31
|
||||
// s32 nSizeBytes; // r1+0x10
|
||||
}
|
||||
|
||||
// Range: 0x80005F40 -> 0x80006044
|
||||
s32 xlFileGet(struct tXL_FILE* pFile, void* pTarget, s32 nSizeBytes) {
|
||||
// Parameters
|
||||
// struct tXL_FILE* pFile; // r27
|
||||
// void* pTarget; // r28
|
||||
// s32 nSizeBytes; // r29
|
||||
|
||||
// Local variables
|
||||
s32 nOffset; // r6
|
||||
s32 nOffsetExtra; // r1+0x8
|
||||
s32 nSize; // r5
|
||||
s32 nSizeUsed; // r30
|
||||
|
||||
// References
|
||||
// -> static s32 (* gpfRead)(struct DVDFileInfo*, void*, s32, s32, void (*)(s32, struct DVDFileInfo*));
|
||||
}
|
||||
|
||||
// Range: 0x80006044 -> 0x80006078
|
||||
s32 xlFileClose(struct tXL_FILE** ppFile) {
|
||||
// Parameters
|
||||
// struct tXL_FILE** ppFile; // r3
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlFileCreate() {}
|
||||
|
||||
typedef enum __anon_0x2757 {
|
||||
XLFT_NONE = -1,
|
||||
XLFT_TEXT = 0,
|
||||
XLFT_BINARY = 1,
|
||||
} __anon_0x2757;
|
||||
|
||||
// Range: 0x80006078 -> 0x8000614C
|
||||
s32 xlFileOpen(struct tXL_FILE** ppFile, enum __anon_0x2757 eType, char* szFileName) {
|
||||
// Parameters
|
||||
// struct tXL_FILE** ppFile; // r29
|
||||
// enum __anon_0x2757 eType; // r30
|
||||
// char* szFileName; // r31
|
||||
|
||||
// Local variables
|
||||
s32 nStatus; // r3
|
||||
|
||||
// References
|
||||
// -> static s32 (* gpfOpen)(char*, struct DVDFileInfo*);
|
||||
// -> struct _XL_OBJECTTYPE gTypeFile;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlFileLoad(char* szFileName, void* ppBuffer) {
|
||||
// Parameters
|
||||
// char* szFileName; // r30
|
||||
// void* ppBuffer; // r31
|
||||
|
||||
// Local variables
|
||||
s32 nSize; // r1+0x18
|
||||
struct tXL_FILE* pFile; // r1+0x14
|
||||
|
||||
// References
|
||||
// -> static s32 (* gpfOpen)(char*, struct DVDFileInfo*);
|
||||
// -> struct _XL_OBJECTTYPE gTypeFile;
|
||||
}
|
||||
|
||||
// Range: 0x8000614C -> 0x80006268
|
||||
s32 xlFileGetSize(s32* pnSize, char* szFileName) {
|
||||
// Parameters
|
||||
// s32* pnSize; // r31
|
||||
// char* szFileName; // r30
|
||||
|
||||
// Local variables
|
||||
struct tXL_FILE* pFile; // r1+0x10
|
||||
|
||||
// References
|
||||
// -> static s32 (* gpfOpen)(char*, struct DVDFileInfo*);
|
||||
// -> struct _XL_OBJECTTYPE gTypeFile;
|
||||
}
|
||||
|
||||
// Range: 0x80006268 -> 0x80006274
|
||||
s32 xlFileSetRead(s32 (*pfRead)(struct DVDFileInfo*, void*, s32, s32, void (*)(s32, struct DVDFileInfo*))) {
|
||||
// Parameters
|
||||
// s32 (* pfRead)(struct DVDFileInfo*, void*, s32, s32, void (*)(s32, struct DVDFileInfo*)); // r1+0x0
|
||||
|
||||
// References
|
||||
// -> static s32 (* gpfRead)(struct DVDFileInfo*, void*, s32, s32, void (*)(s32, struct DVDFileInfo*));
|
||||
}
|
||||
|
||||
// Range: 0x80006274 -> 0x80006280
|
||||
s32 xlFileSetOpen(s32 (*pfOpen)(char*, struct DVDFileInfo*)) {
|
||||
// Parameters
|
||||
// s32 (* pfOpen)(char*, struct DVDFileInfo*); // r1+0x0
|
||||
|
||||
// References
|
||||
// -> static s32 (* gpfOpen)(char*, struct DVDFileInfo*);
|
||||
}
|
||||
|
||||
+294
-213
@@ -1,213 +1,294 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x801355A8
|
||||
static unsigned int *gpHeap;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x801355AC
|
||||
static unsigned int *gpHeapBlockFirst;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x801355B0
|
||||
static unsigned int *gpHeapBlockLast;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x801355B4
|
||||
static int gnHeapTakeCount;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x801355B8
|
||||
static int gnHeapFreeCount;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x801355BC
|
||||
static int gnHeapTakeCacheCount;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x800F3FB0
|
||||
static unsigned int *gapHeapBlockCache[11][32];
|
||||
|
||||
// Location: 0x801355C0
|
||||
int gnSizeHeap;
|
||||
|
||||
int xlHeapReset()
|
||||
{
|
||||
int nBlockSize;
|
||||
// References: gpHeapBlockLast (0x801355B0)
|
||||
// References: gpHeapBlockFirst (0x801355AC)
|
||||
// References: gpHeap (0x801355A8)
|
||||
// References: gnSizeHeap (0x801355C0)
|
||||
}
|
||||
|
||||
int xlHeapSetup(void *pHeap, int nSizeBytes)
|
||||
{
|
||||
int nSizeWords;
|
||||
// References: gpHeapBlockLast (0x801355B0)
|
||||
// References: gpHeapBlockFirst (0x801355AC)
|
||||
// References: gpHeap (0x801355A8)
|
||||
// References: gnSizeHeap (0x801355C0)
|
||||
}
|
||||
|
||||
int xlHeapGetFree(int *pnFreeBytes)
|
||||
{
|
||||
int nBlockSize;
|
||||
int nFree;
|
||||
int nCount;
|
||||
unsigned int *pBlock;
|
||||
unsigned int nBlock;
|
||||
// References: gpHeapBlockLast (0x801355B0)
|
||||
// References: gpHeapBlockFirst (0x801355AC)
|
||||
}
|
||||
|
||||
int xlHeapFill32(void *pHeap, int nByteCount, unsigned int nData)
|
||||
{
|
||||
unsigned int *pnTarget;
|
||||
}
|
||||
|
||||
int xlHeapFill16(void *pHeap, int nByteCount, unsigned short nData)
|
||||
{
|
||||
unsigned short *pnTarget;
|
||||
}
|
||||
|
||||
int xlHeapFill8(void *pHeap, int nByteCount, unsigned char nData)
|
||||
{
|
||||
unsigned char *pnTarget;
|
||||
}
|
||||
|
||||
int xlHeapCopy(void *pHeapTarget, void *pHeapSource, int nByteCount)
|
||||
{
|
||||
unsigned char *pSource8;
|
||||
unsigned char *pTarget8;
|
||||
unsigned int *pSource32;
|
||||
unsigned int *pTarget32;
|
||||
}
|
||||
|
||||
int xlHeapCompact()
|
||||
{
|
||||
int nCount;
|
||||
int nBlockLarge;
|
||||
int nBlockSize;
|
||||
int nBlockNextSize;
|
||||
int anBlockLarge[6];
|
||||
unsigned int nBlock;
|
||||
unsigned int *pBlock;
|
||||
unsigned int *pBlockPrevious;
|
||||
unsigned int nBlockNext;
|
||||
unsigned int *pBlockNext;
|
||||
// References: gpHeapBlockFirst (0x801355AC)
|
||||
}
|
||||
|
||||
int xlHeapTest(void *pHeap)
|
||||
{
|
||||
unsigned int *pBlock;
|
||||
}
|
||||
|
||||
int xlHeapFree(void *ppHeap)
|
||||
{
|
||||
int nBlockSize;
|
||||
int nBlockNextSize;
|
||||
unsigned int *pBlock;
|
||||
unsigned int *pBlockNext;
|
||||
// References: gnHeapFreeCount (0x801355B8)
|
||||
// References: gpHeapBlockLast (0x801355B0)
|
||||
// References: gpHeapBlockFirst (0x801355AC)
|
||||
}
|
||||
|
||||
int xlHeapTake(void *ppHeap, int nByteCount)
|
||||
{
|
||||
int bValid;
|
||||
unsigned int nSizeExtra;
|
||||
unsigned int iTry;
|
||||
int nSize;
|
||||
int nBlockSize;
|
||||
int nBlockNextSize;
|
||||
int nBlockNextNextSize;
|
||||
unsigned int nBlock;
|
||||
unsigned int *pBlock;
|
||||
unsigned int *pBlockNext;
|
||||
unsigned int *pBlockNextNext;
|
||||
// References: gnHeapTakeCount (0x801355B4)
|
||||
// References: gpHeapBlockLast (0x801355B0)
|
||||
// References: gpHeapBlockFirst (0x801355AC)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int xlHeapFindUpperBlock(int nSize, unsigned int **ppBlock, int *pnBlockSize)
|
||||
{
|
||||
int nBlockSize;
|
||||
unsigned int nBlock;
|
||||
unsigned int *pBlock;
|
||||
unsigned int *pBlockBest;
|
||||
unsigned int *pBlockNext;
|
||||
// References: gpHeapBlockLast (0x801355B0)
|
||||
// References: gpHeapBlockFirst (0x801355AC)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int xlHeapBlockCacheReset()
|
||||
{
|
||||
int nBlockSize;
|
||||
unsigned int *pBlock;
|
||||
unsigned int nBlock;
|
||||
// References: gpHeapBlockFirst (0x801355AC)
|
||||
// References: gapHeapBlockCache (0x800F3FB0)
|
||||
// References: gnHeapFreeCount (0x801355B8)
|
||||
// References: gnHeapTakeCount (0x801355B4)
|
||||
// References: gnHeapTakeCacheCount (0x801355BC)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int xlHeapBlockCacheClear(unsigned int *pBlock)
|
||||
{
|
||||
int nSize;
|
||||
int nBlock;
|
||||
int nBlockSize;
|
||||
// References: gapHeapBlockCache (0x800F3FB0)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int xlHeapBlockCacheAdd(unsigned int *pBlock)
|
||||
{
|
||||
int nSize;
|
||||
int nBlock;
|
||||
int nBlockSize;
|
||||
int nBlockCachedSize;
|
||||
unsigned int *pBlockCached;
|
||||
// References: gapHeapBlockCache (0x800F3FB0)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int xlHeapBlockCacheGet(int nSize, unsigned int **ppBlock, int *pnBlockSize)
|
||||
{
|
||||
int nBlockCachedSize;
|
||||
int nBlock;
|
||||
int nBlockSize;
|
||||
int nBlockBest;
|
||||
int nBlockBestSize;
|
||||
unsigned int *pBlock;
|
||||
// References: gnHeapTakeCacheCount (0x801355BC)
|
||||
// References: gapHeapBlockCache (0x800F3FB0)
|
||||
}
|
||||
|
||||
void xlHeapStatisticsReset()
|
||||
{
|
||||
// References: gnHeapFreeCount (0x801355B8)
|
||||
// References: gnHeapTakeCount (0x801355B4)
|
||||
// References: gnHeapTakeCacheCount (0x801355BC)
|
||||
}
|
||||
|
||||
void xlHeapShowStatistics();
|
||||
|
||||
int xlHeapTestBlock(unsigned int nBlock);
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Core\xlHeap.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x80006648 -> 0x80007BC0
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
// size = 0x4, address = 0x801355A8
|
||||
static u32* gpHeap;
|
||||
|
||||
// size = 0x4, address = 0x801355AC
|
||||
static u32* gpHeapBlockFirst;
|
||||
|
||||
// size = 0x4, address = 0x801355B0
|
||||
static u32* gpHeapBlockLast;
|
||||
|
||||
// size = 0x4, address = 0x801355B4
|
||||
static s32 gnHeapTakeCount;
|
||||
|
||||
// size = 0x4, address = 0x801355B8
|
||||
static s32 gnHeapFreeCount;
|
||||
|
||||
// size = 0x4, address = 0x801355BC
|
||||
static s32 gnHeapTakeCacheCount;
|
||||
|
||||
// size = 0x580, address = 0x800F3FB0
|
||||
static u32* gapHeapBlockCache[11][32];
|
||||
|
||||
// size = 0x4, address = 0x801355C0
|
||||
s32 gnSizeHeap;
|
||||
|
||||
// Range: 0x80006648 -> 0x800066B0
|
||||
s32 xlHeapReset() {
|
||||
// Local variables
|
||||
s32 nBlockSize; // r6
|
||||
|
||||
// References
|
||||
// -> static u32* gpHeapBlockLast;
|
||||
// -> static u32* gpHeapBlockFirst;
|
||||
// -> static u32* gpHeap;
|
||||
// -> s32 gnSizeHeap;
|
||||
}
|
||||
|
||||
// Range: 0x800066B0 -> 0x80006870
|
||||
s32 xlHeapSetup(void* pHeap, s32 nSizeBytes) {
|
||||
// Parameters
|
||||
// void* pHeap; // r6
|
||||
// s32 nSizeBytes; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
s32 nSizeWords; // r5
|
||||
|
||||
// References
|
||||
// -> static u32* gpHeapBlockLast;
|
||||
// -> static u32* gpHeapBlockFirst;
|
||||
// -> static u32* gpHeap;
|
||||
// -> s32 gnSizeHeap;
|
||||
}
|
||||
|
||||
// Range: 0x80006870 -> 0x80006908
|
||||
s32 xlHeapGetFree(s32* pnFreeBytes) {
|
||||
// Parameters
|
||||
// s32* pnFreeBytes; // r31
|
||||
|
||||
// Local variables
|
||||
s32 nBlockSize; // r3
|
||||
s32 nFree; // r5
|
||||
s32 nCount; // r1+0x8
|
||||
u32* pBlock; // r6
|
||||
u32 nBlock; // r7
|
||||
|
||||
// References
|
||||
// -> static u32* gpHeapBlockLast;
|
||||
// -> static u32* gpHeapBlockFirst;
|
||||
}
|
||||
|
||||
// Range: 0x80006908 -> 0x80006AF0
|
||||
s32 xlHeapFill32(void* pHeap, s32 nByteCount, u32 nData) {
|
||||
// Parameters
|
||||
// void* pHeap; // r3
|
||||
// s32 nByteCount; // r6
|
||||
// u32 nData; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
u32* pnTarget; // r3
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlHeapFill16(void* pHeap, s32 nByteCount, u16 nData) {
|
||||
// Parameters
|
||||
// void* pHeap; // r3
|
||||
// s32 nByteCount; // r6
|
||||
// u16 nData; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
u16* pnTarget; // r3
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlHeapFill8(void* pHeap, s32 nByteCount, u8 nData) {
|
||||
// Parameters
|
||||
// void* pHeap; // r3
|
||||
// s32 nByteCount; // r4
|
||||
// u8 nData; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
u8* pnTarget; // r3
|
||||
}
|
||||
|
||||
// Range: 0x80006AF0 -> 0x80006F68
|
||||
s32 xlHeapCopy(void* pHeapTarget, void* pHeapSource, s32 nByteCount) {
|
||||
// Parameters
|
||||
// void* pHeapTarget; // r3
|
||||
// void* pHeapSource; // r4
|
||||
// s32 nByteCount; // r5
|
||||
|
||||
// Local variables
|
||||
u8* pSource8; // r4
|
||||
u8* pTarget8; // r3
|
||||
u32* pSource32; // r4
|
||||
u32* pTarget32; // r3
|
||||
}
|
||||
|
||||
// Range: 0x80006F68 -> 0x80007098
|
||||
s32 xlHeapCompact() {
|
||||
// Local variables
|
||||
s32 nCount; // r1+0x8
|
||||
s32 nBlockLarge; // r1+0x8
|
||||
s32 nBlockSize; // r4
|
||||
s32 nBlockNextSize; // r3
|
||||
s32 anBlockLarge[6]; // r1+0x8
|
||||
u32 nBlock; // r1+0x8
|
||||
u32* pBlock; // r5
|
||||
u32* pBlockPrevious; // r6
|
||||
u32 nBlockNext; // r7
|
||||
u32* pBlockNext; // r8
|
||||
|
||||
// References
|
||||
// -> static u32* gpHeapBlockFirst;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlHeapTest(void* pHeap) {
|
||||
// Parameters
|
||||
// void* pHeap; // r1+0x0
|
||||
|
||||
// Local variables
|
||||
u32* pBlock; // r3
|
||||
}
|
||||
|
||||
// Range: 0x80007098 -> 0x800071B4
|
||||
s32 xlHeapFree(void* ppHeap) {
|
||||
// Parameters
|
||||
// void* ppHeap; // r31
|
||||
|
||||
// Local variables
|
||||
s32 nBlockSize; // r30
|
||||
s32 nBlockNextSize; // r29
|
||||
u32* pBlock; // r28
|
||||
u32* pBlockNext; // r3
|
||||
|
||||
// References
|
||||
// -> static s32 gnHeapFreeCount;
|
||||
// -> static u32* gpHeapBlockLast;
|
||||
// -> static u32* gpHeapBlockFirst;
|
||||
}
|
||||
|
||||
// Range: 0x800071B4 -> 0x8000743C
|
||||
s32 xlHeapTake(void* ppHeap, s32 nByteCount) {
|
||||
// Parameters
|
||||
// void* ppHeap; // r26
|
||||
// s32 nByteCount; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
s32 bValid; // r30
|
||||
u32 nSizeExtra; // r29
|
||||
u32 iTry; // r28
|
||||
s32 nSize; // r27
|
||||
s32 nBlockSize; // r1+0x14
|
||||
s32 nBlockNextSize; // r28
|
||||
s32 nBlockNextNextSize; // r30
|
||||
u32 nBlock; // r6
|
||||
u32* pBlock; // r1+0x10
|
||||
u32* pBlockNext; // r31
|
||||
u32* pBlockNextNext; // r3
|
||||
|
||||
// References
|
||||
// -> static s32 gnHeapTakeCount;
|
||||
// -> static u32* gpHeapBlockLast;
|
||||
// -> static u32* gpHeapBlockFirst;
|
||||
}
|
||||
|
||||
// Range: 0x8000743C -> 0x80007540
|
||||
static s32 xlHeapFindUpperBlock(s32 nSize, u32** ppBlock, s32* pnBlockSize) {
|
||||
// Parameters
|
||||
// s32 nSize; // r28
|
||||
// u32** ppBlock; // r29
|
||||
// s32* pnBlockSize; // r30
|
||||
|
||||
// Local variables
|
||||
s32 nBlockSize; // r3
|
||||
u32 nBlock; // r4
|
||||
u32* pBlock; // r7
|
||||
u32* pBlockBest; // r31
|
||||
u32* pBlockNext; // r27
|
||||
|
||||
// References
|
||||
// -> static u32* gpHeapBlockLast;
|
||||
// -> static u32* gpHeapBlockFirst;
|
||||
}
|
||||
|
||||
// Range: 0x80007540 -> 0x8000764C
|
||||
static s32 xlHeapBlockCacheReset() {
|
||||
// Local variables
|
||||
s32 nBlockSize; // r1+0x8
|
||||
u32* pBlock; // r30
|
||||
u32 nBlock; // r1+0x8
|
||||
|
||||
// References
|
||||
// -> static u32* gpHeapBlockFirst;
|
||||
// -> static u32* gapHeapBlockCache[11][32];
|
||||
// -> static s32 gnHeapFreeCount;
|
||||
// -> static s32 gnHeapTakeCount;
|
||||
// -> static s32 gnHeapTakeCacheCount;
|
||||
}
|
||||
|
||||
// Range: 0x8000764C -> 0x80007758
|
||||
static s32 xlHeapBlockCacheClear(u32* pBlock) {
|
||||
// Parameters
|
||||
// u32* pBlock; // r1+0x0
|
||||
|
||||
// Local variables
|
||||
s32 nSize; // r1+0x0
|
||||
s32 nBlock; // r6
|
||||
s32 nBlockSize; // r1+0x0
|
||||
|
||||
// References
|
||||
// -> static u32* gapHeapBlockCache[11][32];
|
||||
}
|
||||
|
||||
// Range: 0x80007758 -> 0x800079C0
|
||||
static s32 xlHeapBlockCacheAdd(u32* pBlock) {
|
||||
// Parameters
|
||||
// u32* pBlock; // r1+0x0
|
||||
|
||||
// Local variables
|
||||
s32 nSize; // r6
|
||||
s32 nBlock; // r7
|
||||
s32 nBlockSize; // r1+0x0
|
||||
s32 nBlockCachedSize; // r1+0x0
|
||||
u32* pBlockCached; // r8
|
||||
|
||||
// References
|
||||
// -> static u32* gapHeapBlockCache[11][32];
|
||||
}
|
||||
|
||||
// Range: 0x800079C0 -> 0x80007BC0
|
||||
static s32 xlHeapBlockCacheGet(s32 nSize, u32** ppBlock, s32* pnBlockSize) {
|
||||
// Parameters
|
||||
// s32 nSize; // r1+0x0
|
||||
// u32** ppBlock; // r1+0x4
|
||||
// s32* pnBlockSize; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
s32 nBlockCachedSize; // r1+0x0
|
||||
s32 nBlock; // r8
|
||||
s32 nBlockSize; // r9
|
||||
s32 nBlockBest; // r10
|
||||
s32 nBlockBestSize; // r11
|
||||
u32* pBlock; // r12
|
||||
|
||||
// References
|
||||
// -> static s32 gnHeapTakeCacheCount;
|
||||
// -> static u32* gapHeapBlockCache[11][32];
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void xlHeapStatisticsReset() {
|
||||
// References
|
||||
// -> static s32 gnHeapFreeCount;
|
||||
// -> static s32 gnHeapTakeCount;
|
||||
// -> static s32 gnHeapTakeCacheCount;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void xlHeapShowStatistics() {}
|
||||
|
||||
// Erased
|
||||
static s32 xlHeapTestBlock(u32 nBlock) {
|
||||
// Parameters
|
||||
// u32 nBlock; // r1+0x0
|
||||
}
|
||||
|
||||
+183
-115
@@ -1,115 +1,183 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct tXL_LIST
|
||||
{
|
||||
int nItemSize; // 0x0
|
||||
int nItemCount; // 0x4
|
||||
void *pNodeHead; // 0x8
|
||||
void *pNodeNext; // 0xC
|
||||
};
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x800F3FA0
|
||||
static tXL_LIST gListList;
|
||||
|
||||
int xlListReset();
|
||||
|
||||
int xlListSetup()
|
||||
{
|
||||
// References: gListList (0x800F3FA0)
|
||||
}
|
||||
|
||||
int xlListMoveItemToTail(tXL_LIST *pList, void *pItem)
|
||||
{
|
||||
void *pNode;
|
||||
void *pNodeLast;
|
||||
void *pNodeItem;
|
||||
void *pNodeItemLast;
|
||||
}
|
||||
|
||||
int xlListMoveItemToHead(tXL_LIST *pList, void *pItem)
|
||||
{
|
||||
void *pNode;
|
||||
void *pNodeLast;
|
||||
}
|
||||
|
||||
int xlListNodeGetNext(tXL_LIST *pList, void *ppListNode)
|
||||
{
|
||||
// References: gListList (0x800F3FA0)
|
||||
}
|
||||
|
||||
int xlListNodeGetHead(tXL_LIST *pList, void *ppListNode)
|
||||
{
|
||||
// References: gListList (0x800F3FA0)
|
||||
}
|
||||
|
||||
int xlListEnumerate(tXL_LIST *pList, int (*pfCallback)(void */* unknown0 */))
|
||||
{
|
||||
void *pNode;
|
||||
}
|
||||
|
||||
int xlListFindItemIndex(tXL_LIST *pList, int *piItem, void *pItem)
|
||||
{
|
||||
int iItem;
|
||||
void *pListNode;
|
||||
}
|
||||
|
||||
int xlListFindItem(tXL_LIST *pList, int iItem, void *ppItem)
|
||||
{
|
||||
int nItemCount;
|
||||
void *pListNode;
|
||||
}
|
||||
|
||||
int xlListTestItem(tXL_LIST *pList, void *pItem)
|
||||
{
|
||||
void *pListNode;
|
||||
// References: gListList (0x800F3FA0)
|
||||
}
|
||||
|
||||
int xlListFreeItem(tXL_LIST *pList, void *ppItem)
|
||||
{
|
||||
void *pNode;
|
||||
void *pNodeNext;
|
||||
}
|
||||
|
||||
int xlListMakeItem(tXL_LIST *pList, void *ppItem)
|
||||
{
|
||||
int nSize;
|
||||
void *pListNode;
|
||||
void *pNode;
|
||||
void *pNodeNext;
|
||||
}
|
||||
|
||||
int xlListTest(tXL_LIST *pList)
|
||||
{
|
||||
void *pNode;
|
||||
// References: gListList (0x800F3FA0)
|
||||
}
|
||||
|
||||
int xlListFree(tXL_LIST **ppList)
|
||||
{
|
||||
// References: gListList (0x800F3FA0)
|
||||
}
|
||||
|
||||
int xlListMake(tXL_LIST **ppList, int nItemSize)
|
||||
{
|
||||
// References: gListList (0x800F3FA0)
|
||||
}
|
||||
|
||||
int xlListWipe(tXL_LIST *pList)
|
||||
{
|
||||
void *pNode;
|
||||
void *pNodeNext;
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Core\xlList.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x80006280 -> 0x80006648
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct tXL_LIST {
|
||||
/* 0x0 */ s32 nItemSize;
|
||||
/* 0x4 */ s32 nItemCount;
|
||||
/* 0x8 */ void* pNodeHead;
|
||||
/* 0xC */ void* pNodeNext;
|
||||
} __anon_0x2C35; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800F3FA0
|
||||
static struct tXL_LIST gListList;
|
||||
|
||||
// Range: 0x80006280 -> 0x80006288
|
||||
s32 xlListReset() {}
|
||||
|
||||
// Range: 0x80006288 -> 0x800062B0
|
||||
s32 xlListSetup() {
|
||||
// References
|
||||
// -> static struct tXL_LIST gListList;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlListMoveItemToTail(struct tXL_LIST* pList, void* pItem) {
|
||||
// Parameters
|
||||
// struct tXL_LIST* pList; // r1+0x0
|
||||
// void* pItem; // r1+0x4
|
||||
|
||||
// Local variables
|
||||
void* pNode; // r5
|
||||
void* pNodeLast; // r6
|
||||
void* pNodeItem; // r7
|
||||
void* pNodeItemLast; // r8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlListMoveItemToHead(struct tXL_LIST* pList, void* pItem) {
|
||||
// Parameters
|
||||
// struct tXL_LIST* pList; // r1+0x0
|
||||
// void* pItem; // r1+0x4
|
||||
|
||||
// Local variables
|
||||
void* pNode; // r5
|
||||
void* pNodeLast; // r6
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlListNodeGetNext(struct tXL_LIST* pList, void* ppListNode) {
|
||||
// Parameters
|
||||
// struct tXL_LIST* pList; // r1+0x0
|
||||
// void* ppListNode; // r1+0x4
|
||||
|
||||
// References
|
||||
// -> static struct tXL_LIST gListList;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlListNodeGetHead(struct tXL_LIST* pList, void* ppListNode) {
|
||||
// Parameters
|
||||
// struct tXL_LIST* pList; // r1+0x0
|
||||
// void* ppListNode; // r1+0x4
|
||||
|
||||
// References
|
||||
// -> static struct tXL_LIST gListList;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlListEnumerate(struct tXL_LIST* pList, s32 (*pfCallback)(void*)) {
|
||||
// Parameters
|
||||
// struct tXL_LIST* pList; // r1+0x8
|
||||
// s32 (* pfCallback)(void*); // r30
|
||||
|
||||
// Local variables
|
||||
void* pNode; // r31
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlListFindItemIndex(struct tXL_LIST* pList, s32* piItem, void* pItem) {
|
||||
// Parameters
|
||||
// struct tXL_LIST* pList; // r1+0x0
|
||||
// s32* piItem; // r1+0x4
|
||||
// void* pItem; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
s32 iItem; // r3
|
||||
void* pListNode; // r6
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlListFindItem(struct tXL_LIST* pList, s32 iItem, void* ppItem) {
|
||||
// Parameters
|
||||
// struct tXL_LIST* pList; // r1+0x0
|
||||
// s32 iItem; // r1+0x4
|
||||
// void* ppItem; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
s32 nItemCount; // r3
|
||||
void* pListNode; // r6
|
||||
}
|
||||
|
||||
// Range: 0x800062B0 -> 0x8000633C
|
||||
s32 xlListTestItem(struct tXL_LIST* pList, void* pItem) {
|
||||
// Parameters
|
||||
// struct tXL_LIST* pList; // r1+0x0
|
||||
// void* pItem; // r1+0x4
|
||||
|
||||
// Local variables
|
||||
void* pListNode; // r3
|
||||
|
||||
// References
|
||||
// -> static struct tXL_LIST gListList;
|
||||
}
|
||||
|
||||
// Range: 0x8000633C -> 0x800063E8
|
||||
s32 xlListFreeItem(struct tXL_LIST* pList, void* ppItem) {
|
||||
// Parameters
|
||||
// struct tXL_LIST* pList; // r31
|
||||
// void* ppItem; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
void* pNode; // r6
|
||||
void* pNodeNext; // r1+0x10
|
||||
}
|
||||
|
||||
// Range: 0x800063E8 -> 0x80006494
|
||||
s32 xlListMakeItem(struct tXL_LIST* pList, void* ppItem) {
|
||||
// Parameters
|
||||
// struct tXL_LIST* pList; // r30
|
||||
// void* ppItem; // r31
|
||||
|
||||
// Local variables
|
||||
s32 nSize; // r4
|
||||
void* pListNode; // r1+0x10
|
||||
void* pNode; // r4
|
||||
void* pNodeNext; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlListTest(struct tXL_LIST* pList) {
|
||||
// Parameters
|
||||
// struct tXL_LIST* pList; // r1+0x0
|
||||
|
||||
// Local variables
|
||||
void* pNode; // r4
|
||||
|
||||
// References
|
||||
// -> static struct tXL_LIST gListList;
|
||||
}
|
||||
|
||||
// Range: 0x80006494 -> 0x80006550
|
||||
s32 xlListFree(struct tXL_LIST** ppList) {
|
||||
// Parameters
|
||||
// struct tXL_LIST** ppList; // r29
|
||||
|
||||
// References
|
||||
// -> static struct tXL_LIST gListList;
|
||||
}
|
||||
|
||||
// Range: 0x80006550 -> 0x80006648
|
||||
s32 xlListMake(struct tXL_LIST** ppList, s32 nItemSize) {
|
||||
// Parameters
|
||||
// struct tXL_LIST** ppList; // r31
|
||||
// s32 nItemSize; // r29
|
||||
|
||||
// References
|
||||
// -> static struct tXL_LIST gListList;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlListWipe(struct tXL_LIST* pList) {
|
||||
// Parameters
|
||||
// struct tXL_LIST* pList; // r30
|
||||
|
||||
// Local variables
|
||||
void* pNode; // r1+0xC
|
||||
void* pNodeNext; // r31
|
||||
}
|
||||
|
||||
+133
-94
@@ -1,94 +1,133 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct tXL_LIST
|
||||
{
|
||||
int nItemSize; // 0x0
|
||||
int nItemCount; // 0x4
|
||||
void *pNodeHead; // 0x8
|
||||
void *pNodeNext; // 0xC
|
||||
};
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x801355C8
|
||||
static tXL_LIST *gpListData;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// size: 0x8
|
||||
struct __anon_0x5062
|
||||
{
|
||||
tXL_LIST *pList; // 0x0
|
||||
_XL_OBJECTTYPE *pType; // 0x4
|
||||
};
|
||||
|
||||
int xlObjectReset()
|
||||
{
|
||||
__anon_0x5062 *pData;
|
||||
void *pListNode;
|
||||
// References: gpListData (0x801355C8)
|
||||
}
|
||||
|
||||
int xlObjectSetup()
|
||||
{
|
||||
// References: gpListData (0x801355C8)
|
||||
}
|
||||
|
||||
int xlObjectEvent(void *pObject, int nEvent, void *pArgument)
|
||||
{
|
||||
__anon_0x5062 *pData;
|
||||
// References: gpListData (0x801355C8)
|
||||
}
|
||||
|
||||
int xlObjectFindType(void *pObject, _XL_OBJECTTYPE **ppType)
|
||||
{
|
||||
__anon_0x5062 *pData;
|
||||
// References: gpListData (0x801355C8)
|
||||
}
|
||||
|
||||
int xlObjectTest(void *pObject, _XL_OBJECTTYPE *pType)
|
||||
{
|
||||
__anon_0x5062 *pData;
|
||||
// References: gpListData (0x801355C8)
|
||||
}
|
||||
|
||||
int xlObjectFree(void *ppObject)
|
||||
{
|
||||
__anon_0x5062 *pData;
|
||||
}
|
||||
|
||||
int xlObjectMake(void *ppObject, void *pArgument, _XL_OBJECTTYPE *pType)
|
||||
{
|
||||
int bFlag;
|
||||
__anon_0x5062 *pData;
|
||||
// References: gpListData (0x801355C8)
|
||||
}
|
||||
|
||||
int xlObjectMakeData(__anon_0x5062 **ppData, _XL_OBJECTTYPE *pType)
|
||||
{
|
||||
// References: gpListData (0x801355C8)
|
||||
}
|
||||
|
||||
int xlObjectFindData(__anon_0x5062 **ppData, _XL_OBJECTTYPE *pType)
|
||||
{
|
||||
void *pListNode;
|
||||
// References: gpListData (0x801355C8)
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Core\xlObject.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x80007BC0 -> 0x80007F80
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct tXL_LIST {
|
||||
/* 0x0 */ s32 nItemSize;
|
||||
/* 0x4 */ s32 nItemCount;
|
||||
/* 0x8 */ void* pNodeHead;
|
||||
/* 0xC */ void* pNodeNext;
|
||||
} __anon_0x4E6F; // size = 0x10
|
||||
|
||||
// size = 0x4, address = 0x801355C8
|
||||
static struct tXL_LIST* gpListData;
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x4F98; // size = 0x10
|
||||
|
||||
typedef struct __anon_0x5062 {
|
||||
/* 0x0 */ struct tXL_LIST* pList;
|
||||
/* 0x4 */ struct _XL_OBJECTTYPE* pType;
|
||||
} __anon_0x5062; // size = 0x8
|
||||
|
||||
// Range: 0x80007BC0 -> 0x80007C30
|
||||
s32 xlObjectReset() {
|
||||
// Local variables
|
||||
struct __anon_0x5062* pData; // r3
|
||||
void* pListNode; // r31
|
||||
|
||||
// References
|
||||
// -> static struct tXL_LIST* gpListData;
|
||||
}
|
||||
|
||||
// Range: 0x80007C30 -> 0x80007C6C
|
||||
s32 xlObjectSetup() {
|
||||
// References
|
||||
// -> static struct tXL_LIST* gpListData;
|
||||
}
|
||||
|
||||
// Range: 0x80007C6C -> 0x80007D24
|
||||
s32 xlObjectEvent(void* pObject, s32 nEvent, void* pArgument) {
|
||||
// Parameters
|
||||
// void* pObject; // r26
|
||||
// s32 nEvent; // r27
|
||||
// void* pArgument; // r28
|
||||
|
||||
// Local variables
|
||||
struct __anon_0x5062* pData; // r29
|
||||
|
||||
// References
|
||||
// -> static struct tXL_LIST* gpListData;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlObjectFindType(void* pObject, struct _XL_OBJECTTYPE** ppType) {
|
||||
// Parameters
|
||||
// void* pObject; // r1+0x8
|
||||
// struct _XL_OBJECTTYPE** ppType; // r30
|
||||
|
||||
// Local variables
|
||||
struct __anon_0x5062* pData; // r31
|
||||
|
||||
// References
|
||||
// -> static struct tXL_LIST* gpListData;
|
||||
}
|
||||
|
||||
// Range: 0x80007D24 -> 0x80007D8C
|
||||
s32 xlObjectTest(void* pObject, struct _XL_OBJECTTYPE* pType) {
|
||||
// Parameters
|
||||
// void* pObject; // r1+0x8
|
||||
// struct _XL_OBJECTTYPE* pType; // r30
|
||||
|
||||
// Local variables
|
||||
struct __anon_0x5062* pData; // r31
|
||||
|
||||
// References
|
||||
// -> static struct tXL_LIST* gpListData;
|
||||
}
|
||||
|
||||
// Range: 0x80007D8C -> 0x80007E24
|
||||
s32 xlObjectFree(void* ppObject) {
|
||||
// Parameters
|
||||
// void* ppObject; // r30
|
||||
|
||||
// Local variables
|
||||
struct __anon_0x5062* pData; // r31
|
||||
}
|
||||
|
||||
// Range: 0x80007E24 -> 0x80007F80
|
||||
s32 xlObjectMake(void* ppObject, void* pArgument, struct _XL_OBJECTTYPE* pType) {
|
||||
// Parameters
|
||||
// void* ppObject; // r28
|
||||
// void* pArgument; // r29
|
||||
// struct _XL_OBJECTTYPE* pType; // r30
|
||||
|
||||
// Local variables
|
||||
s32 bFlag; // r31
|
||||
struct __anon_0x5062* pData; // r1+0x14
|
||||
|
||||
// References
|
||||
// -> static struct tXL_LIST* gpListData;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlObjectMakeData(struct __anon_0x5062** ppData, struct _XL_OBJECTTYPE* pType) {
|
||||
// Parameters
|
||||
// struct __anon_0x5062** ppData; // r30
|
||||
// struct _XL_OBJECTTYPE* pType; // r31
|
||||
|
||||
// References
|
||||
// -> static struct tXL_LIST* gpListData;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 xlObjectFindData(struct __anon_0x5062** ppData, struct _XL_OBJECTTYPE* pType) {
|
||||
// Parameters
|
||||
// struct __anon_0x5062** ppData; // r1+0x0
|
||||
// struct _XL_OBJECTTYPE* pType; // r1+0x4
|
||||
|
||||
// Local variables
|
||||
void* pListNode; // r6
|
||||
|
||||
// References
|
||||
// -> static struct tXL_LIST* gpListData;
|
||||
}
|
||||
|
||||
+17
-27
@@ -1,27 +1,17 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
char *gszPostFail;
|
||||
|
||||
// Location: 0x0
|
||||
char *gszPostFailSafe;
|
||||
|
||||
// Location: 0x0
|
||||
char *gszPostFailTest;
|
||||
|
||||
int xlPostReset();
|
||||
|
||||
int xlPostSetup();
|
||||
|
||||
int xlPostText();
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Core\xlPostGCN.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x80005E04 -> 0x80005E68
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
// Range: 0x80005E04 -> 0x80005E0C
|
||||
s32 xlPostReset() {}
|
||||
|
||||
// Range: 0x80005E0C -> 0x80005E14
|
||||
s32 xlPostSetup() {}
|
||||
|
||||
// Range: 0x80005E14 -> 0x80005E68
|
||||
s32 xlPostText() {}
|
||||
|
||||
+334
-337
@@ -1,337 +1,334 @@
|
||||
// Local to compilation unit
|
||||
// Location: 0x38561380
|
||||
static long AudioDecodeThreadCreated;
|
||||
|
||||
// size: 0x2C8
|
||||
struct OSContext
|
||||
{
|
||||
unsigned long gpr[32]; // 0x0
|
||||
unsigned long cr; // 0x80
|
||||
unsigned long lr; // 0x84
|
||||
unsigned long ctr; // 0x88
|
||||
unsigned long xer; // 0x8C
|
||||
long float fpr[32]; // 0x90
|
||||
unsigned long fpscr_pad; // 0x190
|
||||
unsigned long fpscr; // 0x194
|
||||
unsigned long srr0; // 0x198
|
||||
unsigned long srr1; // 0x19C
|
||||
unsigned short mode; // 0x1A0
|
||||
unsigned short state; // 0x1A2
|
||||
unsigned long gqr[8]; // 0x1A4
|
||||
unsigned long psf_pad; // 0x1C4
|
||||
long float psf[32]; // 0x1C8
|
||||
};
|
||||
|
||||
// size: 0x8
|
||||
struct OSThreadQueue
|
||||
{
|
||||
OSThread *head; // 0x0
|
||||
OSThread *tail; // 0x4
|
||||
};
|
||||
|
||||
// size: 0x8
|
||||
struct OSThreadLink
|
||||
{
|
||||
OSThread *next; // 0x0
|
||||
OSThread *prev; // 0x4
|
||||
};
|
||||
|
||||
// size: 0x8
|
||||
struct OSMutexLink
|
||||
{
|
||||
OSMutex *next; // 0x0
|
||||
OSMutex *prev; // 0x4
|
||||
};
|
||||
|
||||
// size: 0x18
|
||||
struct OSMutex
|
||||
{
|
||||
OSThreadQueue queue; // 0x0
|
||||
OSThread *thread; // 0x8
|
||||
long count; // 0xC
|
||||
OSMutexLink link; // 0x10
|
||||
};
|
||||
|
||||
// size: 0x8
|
||||
struct OSMutexQueue
|
||||
{
|
||||
OSMutex *head; // 0x0
|
||||
OSMutex *tail; // 0x4
|
||||
};
|
||||
|
||||
// size: 0x318
|
||||
struct OSThread
|
||||
{
|
||||
OSContext context; // 0x0
|
||||
unsigned short state; // 0x2C8
|
||||
unsigned short attr; // 0x2CA
|
||||
long suspend; // 0x2CC
|
||||
long priority; // 0x2D0
|
||||
long base; // 0x2D4
|
||||
void *val; // 0x2D8
|
||||
OSThreadQueue *queue; // 0x2DC
|
||||
OSThreadLink link; // 0x2E0
|
||||
OSThreadQueue queueJoin; // 0x2E8
|
||||
OSMutex *mutex; // 0x2F0
|
||||
OSMutexQueue queueMutex; // 0x2F4
|
||||
OSThreadLink linkActive; // 0x2FC
|
||||
unsigned char *stackBase; // 0x304
|
||||
unsigned long *stackEnd; // 0x308
|
||||
long error; // 0x30C
|
||||
void *specific[2]; // 0x310
|
||||
};
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x509E0F80
|
||||
static OSThread AudioDecodeThread;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x68A10F80
|
||||
static unsigned char AudioDecodeThreadStack[4096];
|
||||
|
||||
// size: 0x20
|
||||
struct OSMessageQueue
|
||||
{
|
||||
OSThreadQueue queueSend; // 0x0
|
||||
OSThreadQueue queueReceive; // 0x8
|
||||
void *msgArray; // 0x10
|
||||
long msgCount; // 0x14
|
||||
long firstIndex; // 0x18
|
||||
long usedCount; // 0x1C
|
||||
};
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x68B10F80
|
||||
static OSMessageQueue FreeAudioBufferQueue;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x800FB188
|
||||
static OSMessageQueue DecodedAudioBufferQueue;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x800FB1A8
|
||||
static void *FreeAudioBufferMessage[3];
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x800FB1B4
|
||||
static void *DecodedAudioBufferMessage[3];
|
||||
|
||||
int CreateAudioDecodeThread(long priority, unsigned char *ptr)
|
||||
{
|
||||
// References: AudioDecodeThreadCreated (0x38561380)
|
||||
// References: DecodedAudioBufferMessage (0x800FB1B4)
|
||||
// References: DecodedAudioBufferQueue (0x800FB188)
|
||||
// References: FreeAudioBufferMessage (0x800FB1A8)
|
||||
// References: FreeAudioBufferQueue (0x68B10F80)
|
||||
// References: AudioDecodeThreadStack (0x68A10F80)
|
||||
// References: AudioDecodeThread (0x509E0F80)
|
||||
}
|
||||
|
||||
void AudioDecodeThreadStart()
|
||||
{
|
||||
// References: AudioDecodeThread (0x509E0F80)
|
||||
// References: AudioDecodeThreadCreated (0x38561380)
|
||||
}
|
||||
|
||||
void AudioDecodeThreadCancel()
|
||||
{
|
||||
// References: AudioDecodeThreadCreated (0x38561380)
|
||||
// References: AudioDecodeThread (0x509E0F80)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static void *AudioDecoder()
|
||||
{
|
||||
__anon_0x14130 *readBuffer;
|
||||
}
|
||||
|
||||
// size: 0x20
|
||||
struct DVDDiskID
|
||||
{
|
||||
char gameName[4]; // 0x0
|
||||
char company[2]; // 0x4
|
||||
unsigned char diskNumber; // 0x6
|
||||
unsigned char gameVersion; // 0x7
|
||||
unsigned char streaming; // 0x8
|
||||
unsigned char streamingBufSize; // 0x9
|
||||
unsigned char padding[22]; // 0xA
|
||||
};
|
||||
|
||||
// size: 0x30
|
||||
struct DVDCommandBlock
|
||||
{
|
||||
DVDCommandBlock *next; // 0x0
|
||||
DVDCommandBlock *prev; // 0x4
|
||||
unsigned long command; // 0x8
|
||||
long state; // 0xC
|
||||
unsigned long offset; // 0x10
|
||||
unsigned long length; // 0x14
|
||||
void *addr; // 0x18
|
||||
unsigned long currTransferSize; // 0x1C
|
||||
unsigned long transferredSize; // 0x20
|
||||
DVDDiskID *id; // 0x24
|
||||
void (*callback)(long /* unknown0 */, DVDCommandBlock */* unknown1 */); // 0x28
|
||||
void *userData; // 0x2C
|
||||
};
|
||||
|
||||
// size: 0x3C
|
||||
struct DVDFileInfo
|
||||
{
|
||||
DVDCommandBlock cb; // 0x0
|
||||
unsigned long startAddr; // 0x30
|
||||
unsigned long length; // 0x34
|
||||
void (*callback)(long /* unknown0 */, DVDFileInfo */* unknown1 */); // 0x38
|
||||
};
|
||||
|
||||
// size: 0x30
|
||||
struct __anon_0x13633
|
||||
{
|
||||
char magic[4]; // 0x0
|
||||
unsigned long version; // 0x4
|
||||
unsigned long bufSize; // 0x8
|
||||
unsigned long audioMaxSamples; // 0xC
|
||||
float frameRate; // 0x10
|
||||
unsigned long numFrames; // 0x14
|
||||
unsigned long firstFrameSize; // 0x18
|
||||
unsigned long movieDataSize; // 0x1C
|
||||
unsigned long compInfoDataOffsets; // 0x20
|
||||
unsigned long offsetDataOffsets; // 0x24
|
||||
unsigned long movieDataOffsets; // 0x28
|
||||
unsigned long finalFrameDataOffsets; // 0x2C
|
||||
};
|
||||
|
||||
// size: 0x14
|
||||
struct __anon_0x1385F
|
||||
{
|
||||
unsigned long numComponents; // 0x0
|
||||
unsigned char frameComp[16]; // 0x4
|
||||
};
|
||||
|
||||
// size: 0xC
|
||||
struct __anon_0x138C7
|
||||
{
|
||||
unsigned long xSize; // 0x0
|
||||
unsigned long ySize; // 0x4
|
||||
unsigned long videoType; // 0x8
|
||||
};
|
||||
|
||||
// size: 0x10
|
||||
struct __anon_0x13947
|
||||
{
|
||||
unsigned long sndChannels; // 0x0
|
||||
unsigned long sndFrequency; // 0x4
|
||||
unsigned long sndNumSamples; // 0x8
|
||||
unsigned long sndNumTracks; // 0xC
|
||||
};
|
||||
|
||||
// size: 0x10
|
||||
struct __anon_0x13A01
|
||||
{
|
||||
unsigned char *ytexture; // 0x0
|
||||
unsigned char *utexture; // 0x4
|
||||
unsigned char *vtexture; // 0x8
|
||||
long frameNumber; // 0xC
|
||||
};
|
||||
|
||||
// size: 0xC
|
||||
struct __anon_0x13AB7
|
||||
{
|
||||
signed short *buffer; // 0x0
|
||||
signed short *curPtr; // 0x4
|
||||
unsigned long validSample; // 0x8
|
||||
};
|
||||
|
||||
// size: 0x1D0
|
||||
struct __anon_0x13BA7
|
||||
{
|
||||
DVDFileInfo fileInfo; // 0x0
|
||||
__anon_0x13633 header; // 0x3C
|
||||
__anon_0x1385F compInfo; // 0x6C
|
||||
__anon_0x138C7 videoInfo; // 0x80
|
||||
__anon_0x13947 audioInfo; // 0x8C
|
||||
void *thpWork; // 0x9C
|
||||
int open; // 0xA0
|
||||
unsigned char state; // 0xA4
|
||||
unsigned char internalState; // 0xA5
|
||||
unsigned char playFlag; // 0xA6
|
||||
unsigned char audioExist; // 0xA7
|
||||
long dvdError; // 0xA8
|
||||
long videoError; // 0xAC
|
||||
int onMemory; // 0xB0
|
||||
unsigned char *movieData; // 0xB4
|
||||
long initOffset; // 0xB8
|
||||
long initReadSize; // 0xBC
|
||||
long initReadFrame; // 0xC0
|
||||
signed long long retraceCount; // 0xC8
|
||||
long prevCount; // 0xD0
|
||||
long curCount; // 0xD4
|
||||
long videoAhead; // 0xD8
|
||||
float curVolume; // 0xDC
|
||||
float targetVolume; // 0xE0
|
||||
float deltaVolume; // 0xE4
|
||||
long rampCount; // 0xE8
|
||||
long curAudioTrack; // 0xEC
|
||||
long curVideoNumber; // 0xF0
|
||||
long curAudioNumber; // 0xF4
|
||||
__anon_0x13A01 *dispTextureSet; // 0xF8
|
||||
__anon_0x13AB7 *playAudioBuffer; // 0xFC
|
||||
__anon_0x14130 readBuffer[10]; // 0x100
|
||||
__anon_0x13A01 textureSet[3]; // 0x178
|
||||
__anon_0x13AB7 audioBuffer[3]; // 0x1A8
|
||||
};
|
||||
|
||||
// Location: 0x800F9C80
|
||||
__anon_0x13BA7 ActivePlayer;
|
||||
|
||||
// size: 0xC
|
||||
struct __anon_0x14130
|
||||
{
|
||||
unsigned char *ptr; // 0x0
|
||||
long frameNumber; // 0x4
|
||||
int isValid; // 0x8
|
||||
};
|
||||
|
||||
// Local to compilation unit
|
||||
static void *AudioDecoderForOnMemory(void *ptr)
|
||||
{
|
||||
__anon_0x14130 readBuffer;
|
||||
long tmp;
|
||||
long size;
|
||||
long readFrame;
|
||||
// References: AudioDecodeThread (0x509E0F80)
|
||||
// References: ActivePlayer (0x800F9C80)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static void AudioDecode(__anon_0x14130 *readBuffer)
|
||||
{
|
||||
__anon_0x13AB7 *audioBuffer;
|
||||
unsigned long i;
|
||||
unsigned long sample;
|
||||
unsigned long *compSizePtr;
|
||||
unsigned char *ptr;
|
||||
// References: ActivePlayer (0x800F9C80)
|
||||
}
|
||||
|
||||
void *PopFreeAudioBuffer()
|
||||
{
|
||||
void *msg;
|
||||
// References: FreeAudioBufferQueue (0x68B10F80)
|
||||
}
|
||||
|
||||
void PushFreeAudioBuffer(void *buffer)
|
||||
{
|
||||
// References: FreeAudioBufferQueue (0x68B10F80)
|
||||
}
|
||||
|
||||
void *PopDecodedAudioBuffer(long flag)
|
||||
{
|
||||
void *msg;
|
||||
// References: DecodedAudioBufferQueue (0x800FB188)
|
||||
}
|
||||
|
||||
void PushDecodedAudioBuffer(void *buffer)
|
||||
{
|
||||
// References: DecodedAudioBufferQueue (0x800FB188)
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\THPAudioDecode.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C89
|
||||
Code range: 0x80010D9C -> 0x80011138
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
// size = 0x4, address = 0x80135638
|
||||
static s32 AudioDecodeThreadCreated;
|
||||
|
||||
typedef struct OSContext {
|
||||
/* 0x000 */ u32 gpr[32];
|
||||
/* 0x080 */ u32 cr;
|
||||
/* 0x084 */ u32 lr;
|
||||
/* 0x088 */ u32 ctr;
|
||||
/* 0x08C */ u32 xer;
|
||||
/* 0x090 */ double fpr[32];
|
||||
/* 0x190 */ u32 fpscr_pad;
|
||||
/* 0x194 */ u32 fpscr;
|
||||
/* 0x198 */ u32 srr0;
|
||||
/* 0x19C */ u32 srr1;
|
||||
/* 0x1A0 */ u16 mode;
|
||||
/* 0x1A2 */ u16 state;
|
||||
/* 0x1A4 */ u32 gqr[8];
|
||||
/* 0x1C4 */ u32 psf_pad;
|
||||
/* 0x1C8 */ double psf[32];
|
||||
} __anon_0x125F9; // size = 0x2C8
|
||||
|
||||
typedef struct OSThreadQueue {
|
||||
/* 0x0 */ struct OSThread* head;
|
||||
/* 0x4 */ struct OSThread* tail;
|
||||
} __anon_0x12812; // size = 0x8
|
||||
|
||||
typedef struct OSThreadLink {
|
||||
/* 0x0 */ struct OSThread* next;
|
||||
/* 0x4 */ struct OSThread* prev;
|
||||
} __anon_0x12884; // size = 0x8
|
||||
|
||||
typedef struct OSMutexLink {
|
||||
/* 0x0 */ struct OSMutex* next;
|
||||
/* 0x4 */ struct OSMutex* prev;
|
||||
} __anon_0x128F5; // size = 0x8
|
||||
|
||||
typedef struct OSMutex {
|
||||
/* 0x00 */ struct OSThreadQueue queue;
|
||||
/* 0x08 */ struct OSThread* thread;
|
||||
/* 0x0C */ s32 count;
|
||||
/* 0x10 */ struct OSMutexLink link;
|
||||
} __anon_0x12965; // size = 0x18
|
||||
|
||||
typedef struct OSMutexQueue {
|
||||
/* 0x0 */ struct OSMutex* head;
|
||||
/* 0x4 */ struct OSMutex* tail;
|
||||
} __anon_0x12A16; // size = 0x8
|
||||
|
||||
typedef struct OSThread {
|
||||
/* 0x000 */ struct OSContext context;
|
||||
/* 0x2C8 */ u16 state;
|
||||
/* 0x2CA */ u16 attr;
|
||||
/* 0x2CC */ s32 suspend;
|
||||
/* 0x2D0 */ s32 priority;
|
||||
/* 0x2D4 */ s32 base;
|
||||
/* 0x2D8 */ void* val;
|
||||
/* 0x2DC */ struct OSThreadQueue* queue;
|
||||
/* 0x2E0 */ struct OSThreadLink link;
|
||||
/* 0x2E8 */ struct OSThreadQueue queueJoin;
|
||||
/* 0x2F0 */ struct OSMutex* mutex;
|
||||
/* 0x2F4 */ struct OSMutexQueue queueMutex;
|
||||
/* 0x2FC */ struct OSThreadLink linkActive;
|
||||
/* 0x304 */ u8* stackBase;
|
||||
/* 0x308 */ u32* stackEnd;
|
||||
/* 0x30C */ s32 error;
|
||||
/* 0x310 */ void* specific[2];
|
||||
} __anon_0x12AA7; // size = 0x318
|
||||
|
||||
// size = 0x318, address = 0x800F9E50
|
||||
static struct OSThread AudioDecodeThread;
|
||||
|
||||
// size = 0x1000, address = 0x800FA168
|
||||
static u8 AudioDecodeThreadStack[4096];
|
||||
|
||||
typedef struct OSMessageQueue {
|
||||
/* 0x00 */ struct OSThreadQueue queueSend;
|
||||
/* 0x08 */ struct OSThreadQueue queueReceive;
|
||||
/* 0x10 */ void* msgArray;
|
||||
/* 0x14 */ s32 msgCount;
|
||||
/* 0x18 */ s32 firstIndex;
|
||||
/* 0x1C */ s32 usedCount;
|
||||
} __anon_0x12DC3; // size = 0x20
|
||||
|
||||
// size = 0x20, address = 0x800FB168
|
||||
static struct OSMessageQueue FreeAudioBufferQueue;
|
||||
|
||||
// size = 0x20, address = 0x800FB188
|
||||
static struct OSMessageQueue DecodedAudioBufferQueue;
|
||||
|
||||
// size = 0xC, address = 0x800FB1A8
|
||||
static void* FreeAudioBufferMessage[3];
|
||||
|
||||
// size = 0xC, address = 0x800FB1B4
|
||||
static void* DecodedAudioBufferMessage[3];
|
||||
|
||||
// Range: 0x80010D9C -> 0x80010E7C
|
||||
s32 CreateAudioDecodeThread(s32 priority, u8* ptr) {
|
||||
// Parameters
|
||||
// s32 priority; // r8
|
||||
// u8* ptr; // r5
|
||||
|
||||
// References
|
||||
// -> static s32 AudioDecodeThreadCreated;
|
||||
// -> static void* DecodedAudioBufferMessage[3];
|
||||
// -> static struct OSMessageQueue DecodedAudioBufferQueue;
|
||||
// -> static void* FreeAudioBufferMessage[3];
|
||||
// -> static struct OSMessageQueue FreeAudioBufferQueue;
|
||||
// -> static u8 AudioDecodeThreadStack[4096];
|
||||
// -> static struct OSThread AudioDecodeThread;
|
||||
}
|
||||
|
||||
// Range: 0x80010E7C -> 0x80010EB0
|
||||
void AudioDecodeThreadStart() {
|
||||
// References
|
||||
// -> static struct OSThread AudioDecodeThread;
|
||||
// -> static s32 AudioDecodeThreadCreated;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void AudioDecodeThreadCancel() {
|
||||
// References
|
||||
// -> static s32 AudioDecodeThreadCreated;
|
||||
// -> static struct OSThread AudioDecodeThread;
|
||||
}
|
||||
|
||||
// Range: 0x80010EB0 -> 0x80010ED8
|
||||
static void* AudioDecoder() {
|
||||
// Local variables
|
||||
struct __anon_0x14130* readBuffer; // r31
|
||||
}
|
||||
|
||||
typedef struct DVDDiskID {
|
||||
/* 0x0 */ char gameName[4];
|
||||
/* 0x4 */ char company[2];
|
||||
/* 0x6 */ u8 diskNumber;
|
||||
/* 0x7 */ u8 gameVersion;
|
||||
/* 0x8 */ u8 streaming;
|
||||
/* 0x9 */ u8 streamingBufSize;
|
||||
/* 0xA */ u8 padding[22];
|
||||
} __anon_0x131C5; // size = 0x20
|
||||
|
||||
typedef struct DVDCommandBlock {
|
||||
/* 0x00 */ struct DVDCommandBlock* next;
|
||||
/* 0x04 */ struct DVDCommandBlock* prev;
|
||||
/* 0x08 */ u32 command;
|
||||
/* 0x0C */ s32 state;
|
||||
/* 0x10 */ u32 offset;
|
||||
/* 0x14 */ u32 length;
|
||||
/* 0x18 */ void* addr;
|
||||
/* 0x1C */ u32 currTransferSize;
|
||||
/* 0x20 */ u32 transferredSize;
|
||||
/* 0x24 */ struct DVDDiskID* id;
|
||||
/* 0x28 */ void (*callback)(s32, struct DVDCommandBlock*);
|
||||
/* 0x2C */ void* userData;
|
||||
} __anon_0x13335; // size = 0x30
|
||||
|
||||
typedef struct DVDFileInfo {
|
||||
/* 0x00 */ struct DVDCommandBlock cb;
|
||||
/* 0x30 */ u32 startAddr;
|
||||
/* 0x34 */ u32 length;
|
||||
/* 0x38 */ void (*callback)(s32, struct DVDFileInfo*);
|
||||
} __anon_0x1355B; // size = 0x3C
|
||||
|
||||
typedef struct __anon_0x13633 {
|
||||
/* 0x00 */ char magic[4];
|
||||
/* 0x04 */ u32 version;
|
||||
/* 0x08 */ u32 bufSize;
|
||||
/* 0x0C */ u32 audioMaxSamples;
|
||||
/* 0x10 */ float frameRate;
|
||||
/* 0x14 */ u32 numFrames;
|
||||
/* 0x18 */ u32 firstFrameSize;
|
||||
/* 0x1C */ u32 movieDataSize;
|
||||
/* 0x20 */ u32 compInfoDataOffsets;
|
||||
/* 0x24 */ u32 offsetDataOffsets;
|
||||
/* 0x28 */ u32 movieDataOffsets;
|
||||
/* 0x2C */ u32 finalFrameDataOffsets;
|
||||
} __anon_0x13633; // size = 0x30
|
||||
|
||||
typedef struct __anon_0x1385F {
|
||||
/* 0x0 */ u32 numComponents;
|
||||
/* 0x4 */ u8 frameComp[16];
|
||||
} __anon_0x1385F; // size = 0x14
|
||||
|
||||
typedef struct __anon_0x138C7 {
|
||||
/* 0x0 */ u32 xSize;
|
||||
/* 0x4 */ u32 ySize;
|
||||
/* 0x8 */ u32 videoType;
|
||||
} __anon_0x138C7; // size = 0xC
|
||||
|
||||
typedef struct __anon_0x13947 {
|
||||
/* 0x0 */ u32 sndChannels;
|
||||
/* 0x4 */ u32 sndFrequency;
|
||||
/* 0x8 */ u32 sndNumSamples;
|
||||
/* 0xC */ u32 sndNumTracks;
|
||||
} __anon_0x13947; // size = 0x10
|
||||
|
||||
typedef struct __anon_0x13A01 {
|
||||
/* 0x0 */ u8* ytexture;
|
||||
/* 0x4 */ u8* utexture;
|
||||
/* 0x8 */ u8* vtexture;
|
||||
/* 0xC */ s32 frameNumber;
|
||||
} __anon_0x13A01; // size = 0x10
|
||||
|
||||
typedef struct __anon_0x13AB7 {
|
||||
/* 0x0 */ s16* buffer;
|
||||
/* 0x4 */ s16* curPtr;
|
||||
/* 0x8 */ u32 validSample;
|
||||
} __anon_0x13AB7; // size = 0xC
|
||||
|
||||
typedef struct __anon_0x13BA7 {
|
||||
/* 0x000 */ struct DVDFileInfo fileInfo;
|
||||
/* 0x03C */ struct __anon_0x13633 header;
|
||||
/* 0x06C */ struct __anon_0x1385F compInfo;
|
||||
/* 0x080 */ struct __anon_0x138C7 videoInfo;
|
||||
/* 0x08C */ struct __anon_0x13947 audioInfo;
|
||||
/* 0x09C */ void* thpWork;
|
||||
/* 0x0A0 */ s32 open;
|
||||
/* 0x0A4 */ u8 state;
|
||||
/* 0x0A5 */ u8 internalState;
|
||||
/* 0x0A6 */ u8 playFlag;
|
||||
/* 0x0A7 */ u8 audioExist;
|
||||
/* 0x0A8 */ s32 dvdError;
|
||||
/* 0x0AC */ s32 videoError;
|
||||
/* 0x0B0 */ s32 onMemory;
|
||||
/* 0x0B4 */ u8* movieData;
|
||||
/* 0x0B8 */ s32 initOffset;
|
||||
/* 0x0BC */ s32 initReadSize;
|
||||
/* 0x0C0 */ s32 initReadFrame;
|
||||
/* 0x0C8 */ s64 retraceCount;
|
||||
/* 0x0D0 */ s32 prevCount;
|
||||
/* 0x0D4 */ s32 curCount;
|
||||
/* 0x0D8 */ s32 videoAhead;
|
||||
/* 0x0DC */ float curVolume;
|
||||
/* 0x0E0 */ float targetVolume;
|
||||
/* 0x0E4 */ float deltaVolume;
|
||||
/* 0x0E8 */ s32 rampCount;
|
||||
/* 0x0EC */ s32 curAudioTrack;
|
||||
/* 0x0F0 */ s32 curVideoNumber;
|
||||
/* 0x0F4 */ s32 curAudioNumber;
|
||||
/* 0x0F8 */ struct __anon_0x13A01* dispTextureSet;
|
||||
/* 0x0FC */ struct __anon_0x13AB7* playAudioBuffer;
|
||||
/* 0x100 */ struct __anon_0x14130 readBuffer[10];
|
||||
/* 0x178 */ struct __anon_0x13A01 textureSet[3];
|
||||
/* 0x1A8 */ struct __anon_0x13AB7 audioBuffer[3];
|
||||
} __anon_0x13BA7; // size = 0x1D0
|
||||
|
||||
// size = 0x1D0, address = 0x800F9C80
|
||||
struct __anon_0x13BA7 ActivePlayer;
|
||||
|
||||
typedef struct __anon_0x14130 {
|
||||
/* 0x0 */ u8* ptr;
|
||||
/* 0x4 */ s32 frameNumber;
|
||||
/* 0x8 */ s32 isValid;
|
||||
} __anon_0x14130; // size = 0xC
|
||||
|
||||
// Range: 0x80010ED8 -> 0x80010F88
|
||||
static void* AudioDecoderForOnMemory(void* ptr) {
|
||||
// Parameters
|
||||
// void* ptr; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
struct __anon_0x14130 readBuffer; // r1+0x10
|
||||
s32 tmp; // r4
|
||||
s32 size; // r28
|
||||
s32 readFrame; // r31
|
||||
|
||||
// References
|
||||
// -> static struct OSThread AudioDecodeThread;
|
||||
// -> struct __anon_0x13BA7 ActivePlayer;
|
||||
}
|
||||
|
||||
// Range: 0x80010F88 -> 0x80011060
|
||||
static void AudioDecode(struct __anon_0x14130* readBuffer) {
|
||||
// Parameters
|
||||
// struct __anon_0x14130* readBuffer; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
struct __anon_0x13AB7* audioBuffer; // r30
|
||||
u32 i; // r1+0x8
|
||||
u32 sample; // r1+0x8
|
||||
u32* compSizePtr; // r29
|
||||
u8* ptr; // r28
|
||||
|
||||
// References
|
||||
// -> struct __anon_0x13BA7 ActivePlayer;
|
||||
}
|
||||
|
||||
// Range: 0x80011060 -> 0x80011094
|
||||
void* PopFreeAudioBuffer() {
|
||||
// Local variables
|
||||
void* msg; // r1+0x8
|
||||
|
||||
// References
|
||||
// -> static struct OSMessageQueue FreeAudioBufferQueue;
|
||||
}
|
||||
|
||||
// Range: 0x80011094 -> 0x800110C4
|
||||
void PushFreeAudioBuffer(void* buffer) {
|
||||
// Parameters
|
||||
// void* buffer; // r4
|
||||
|
||||
// References
|
||||
// -> static struct OSMessageQueue FreeAudioBufferQueue;
|
||||
}
|
||||
|
||||
// Range: 0x800110C4 -> 0x80011108
|
||||
void* PopDecodedAudioBuffer(s32 flag) {
|
||||
// Parameters
|
||||
// s32 flag; // r5
|
||||
|
||||
// Local variables
|
||||
void* msg; // r1+0xC
|
||||
|
||||
// References
|
||||
// -> static struct OSMessageQueue DecodedAudioBufferQueue;
|
||||
}
|
||||
|
||||
// Range: 0x80011108 -> 0x80011138
|
||||
void PushDecodedAudioBuffer(void* buffer) {
|
||||
// Parameters
|
||||
// void* buffer; // r4
|
||||
|
||||
// References
|
||||
// -> static struct OSMessageQueue DecodedAudioBufferQueue;
|
||||
}
|
||||
|
||||
+83
-65
@@ -1,65 +1,83 @@
|
||||
void THPGXRestore();
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x14611
|
||||
{
|
||||
VI_TVMODE_NTSC_INT = 0,
|
||||
VI_TVMODE_NTSC_DS = 1,
|
||||
VI_TVMODE_NTSC_PROG = 2,
|
||||
VI_TVMODE_PAL_INT = 4,
|
||||
VI_TVMODE_PAL_DS = 5,
|
||||
VI_TVMODE_EURGB60_INT = 20,
|
||||
VI_TVMODE_EURGB60_DS = 21,
|
||||
VI_TVMODE_MPAL_INT = 8,
|
||||
VI_TVMODE_MPAL_DS = 9,
|
||||
VI_TVMODE_DEBUG_INT = 12,
|
||||
VI_TVMODE_DEBUG_PAL_INT = 16,
|
||||
VI_TVMODE_DEBUG_PAL_DS = 17
|
||||
};
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x1475B
|
||||
{
|
||||
VI_XFBMODE_SF = 0,
|
||||
VI_XFBMODE_DF = 1
|
||||
};
|
||||
|
||||
// size: 0x3C
|
||||
struct _GXRenderModeObj
|
||||
{
|
||||
__anon_0x14611 viTVmode; // 0x0
|
||||
unsigned short fbWidth; // 0x4
|
||||
unsigned short efbHeight; // 0x6
|
||||
unsigned short xfbHeight; // 0x8
|
||||
unsigned short viXOrigin; // 0xA
|
||||
unsigned short viYOrigin; // 0xC
|
||||
unsigned short viWidth; // 0xE
|
||||
unsigned short viHeight; // 0x10
|
||||
__anon_0x1475B xFBmode; // 0x14
|
||||
unsigned char field_rendering; // 0x18
|
||||
unsigned char aa; // 0x19
|
||||
unsigned char sample_pattern[12][2]; // 0x1A
|
||||
unsigned char vfilter[7]; // 0x32
|
||||
};
|
||||
|
||||
void THPGXYuv2RgbSetup(_GXRenderModeObj *rmode)
|
||||
{
|
||||
long scrWidth;
|
||||
long scrHeight;
|
||||
float pMtx[4][4];
|
||||
float mMtx[3][4];
|
||||
}
|
||||
|
||||
// size: 0x20
|
||||
struct _GXTexObj
|
||||
{
|
||||
unsigned long dummy[8]; // 0x0
|
||||
};
|
||||
|
||||
void THPGXYuv2RgbDraw(unsigned char *y_data, unsigned char *u_data, unsigned char *v_data, signed short x, signed short y, signed short textureWidth, signed short textureHeight, signed short polygonWidth, signed short polygonHeight)
|
||||
{
|
||||
_GXTexObj tobj0;
|
||||
_GXTexObj tobj1;
|
||||
_GXTexObj tobj2;
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\THPDraw.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C89
|
||||
Code range: 0x80011138 -> 0x80011938
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
// Range: 0x80011138 -> 0x80011250
|
||||
void THPGXRestore() {}
|
||||
|
||||
typedef enum __anon_0x14611 {
|
||||
VI_TVMODE_NTSC_INT = 0,
|
||||
VI_TVMODE_NTSC_DS = 1,
|
||||
VI_TVMODE_NTSC_PROG = 2,
|
||||
VI_TVMODE_PAL_INT = 4,
|
||||
VI_TVMODE_PAL_DS = 5,
|
||||
VI_TVMODE_EURGB60_INT = 20,
|
||||
VI_TVMODE_EURGB60_DS = 21,
|
||||
VI_TVMODE_MPAL_INT = 8,
|
||||
VI_TVMODE_MPAL_DS = 9,
|
||||
VI_TVMODE_DEBUG_INT = 12,
|
||||
VI_TVMODE_DEBUG_PAL_INT = 16,
|
||||
VI_TVMODE_DEBUG_PAL_DS = 17,
|
||||
} __anon_0x14611;
|
||||
|
||||
typedef enum __anon_0x1475B {
|
||||
VI_XFBMODE_SF = 0,
|
||||
VI_XFBMODE_DF = 1,
|
||||
} __anon_0x1475B;
|
||||
|
||||
typedef struct _GXRenderModeObj {
|
||||
/* 0x00 */ enum __anon_0x14611 viTVmode;
|
||||
/* 0x04 */ u16 fbWidth;
|
||||
/* 0x06 */ u16 efbHeight;
|
||||
/* 0x08 */ u16 xfbHeight;
|
||||
/* 0x0A */ u16 viXOrigin;
|
||||
/* 0x0C */ u16 viYOrigin;
|
||||
/* 0x0E */ u16 viWidth;
|
||||
/* 0x10 */ u16 viHeight;
|
||||
/* 0x14 */ enum __anon_0x1475B xFBmode;
|
||||
/* 0x18 */ u8 field_rendering;
|
||||
/* 0x19 */ u8 aa;
|
||||
/* 0x1A */ u8 sample_pattern[12][2];
|
||||
/* 0x32 */ u8 vfilter[7];
|
||||
} __anon_0x1480C; // size = 0x3C
|
||||
|
||||
// Range: 0x80011250 -> 0x80011754
|
||||
void THPGXYuv2RgbSetup(struct _GXRenderModeObj* rmode) {
|
||||
// Parameters
|
||||
// struct _GXRenderModeObj* rmode; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
s32 scrWidth; // r28
|
||||
s32 scrHeight; // r27
|
||||
float pMtx[4][4]; // r1+0x74
|
||||
float mMtx[3][4]; // r1+0x44
|
||||
}
|
||||
|
||||
typedef struct _GXTexObj {
|
||||
/* 0x0 */ u32 dummy[8];
|
||||
} __anon_0x14BBE; // size = 0x20
|
||||
|
||||
// Range: 0x80011754 -> 0x80011938
|
||||
void THPGXYuv2RgbDraw(u8* y_data, u8* u_data, u8* v_data, s16 x, s16 y, s16 textureWidth, s16 textureHeight,
|
||||
s16 polygonWidth, s16 polygonHeight) {
|
||||
// Parameters
|
||||
// u8* y_data; // r3
|
||||
// u8* u_data; // r24
|
||||
// u8* v_data; // r25
|
||||
// s16 x; // r30
|
||||
// s16 y; // r31
|
||||
// s16 textureWidth; // r28
|
||||
// s16 textureHeight; // r29
|
||||
// s16 polygonWidth; // r26
|
||||
// s16 polygonHeight; // r27
|
||||
|
||||
// Local variables
|
||||
struct _GXTexObj tobj0; // r1+0x60
|
||||
struct _GXTexObj tobj1; // r1+0x40
|
||||
struct _GXTexObj tobj2; // r1+0x20
|
||||
}
|
||||
|
||||
+608
-555
File diff suppressed because it is too large
Load Diff
+585
-595
File diff suppressed because it is too large
Load Diff
+345
-347
@@ -1,347 +1,345 @@
|
||||
// Local to compilation unit
|
||||
// Location: 0x58561380
|
||||
static long VideoDecodeThreadCreated;
|
||||
|
||||
// size: 0x2C8
|
||||
struct OSContext
|
||||
{
|
||||
unsigned long gpr[32]; // 0x0
|
||||
unsigned long cr; // 0x80
|
||||
unsigned long lr; // 0x84
|
||||
unsigned long ctr; // 0x88
|
||||
unsigned long xer; // 0x8C
|
||||
long float fpr[32]; // 0x90
|
||||
unsigned long fpscr_pad; // 0x190
|
||||
unsigned long fpscr; // 0x194
|
||||
unsigned long srr0; // 0x198
|
||||
unsigned long srr1; // 0x19C
|
||||
unsigned short mode; // 0x1A0
|
||||
unsigned short state; // 0x1A2
|
||||
unsigned long gqr[8]; // 0x1A4
|
||||
unsigned long psf_pad; // 0x1C4
|
||||
long float psf[32]; // 0x1C8
|
||||
};
|
||||
|
||||
// size: 0x8
|
||||
struct OSThreadQueue
|
||||
{
|
||||
OSThread *head; // 0x0
|
||||
OSThread *tail; // 0x4
|
||||
};
|
||||
|
||||
// size: 0x8
|
||||
struct OSThreadLink
|
||||
{
|
||||
OSThread *next; // 0x0
|
||||
OSThread *prev; // 0x4
|
||||
};
|
||||
|
||||
// size: 0x8
|
||||
struct OSMutexLink
|
||||
{
|
||||
OSMutex *next; // 0x0
|
||||
OSMutex *prev; // 0x4
|
||||
};
|
||||
|
||||
// size: 0x18
|
||||
struct OSMutex
|
||||
{
|
||||
OSThreadQueue queue; // 0x0
|
||||
OSThread *thread; // 0x8
|
||||
long count; // 0xC
|
||||
OSMutexLink link; // 0x10
|
||||
};
|
||||
|
||||
// size: 0x8
|
||||
struct OSMutexQueue
|
||||
{
|
||||
OSMutex *head; // 0x0
|
||||
OSMutex *tail; // 0x4
|
||||
};
|
||||
|
||||
// size: 0x318
|
||||
struct OSThread
|
||||
{
|
||||
OSContext context; // 0x0
|
||||
unsigned short state; // 0x2C8
|
||||
unsigned short attr; // 0x2CA
|
||||
long suspend; // 0x2CC
|
||||
long priority; // 0x2D0
|
||||
long base; // 0x2D4
|
||||
void *val; // 0x2D8
|
||||
OSThreadQueue *queue; // 0x2DC
|
||||
OSThreadLink link; // 0x2E0
|
||||
OSThreadQueue queueJoin; // 0x2E8
|
||||
OSMutex *mutex; // 0x2F0
|
||||
OSMutexQueue queueMutex; // 0x2F4
|
||||
OSThreadLink linkActive; // 0x2FC
|
||||
unsigned char *stackBase; // 0x304
|
||||
unsigned long *stackEnd; // 0x308
|
||||
long error; // 0x30C
|
||||
void *specific[2]; // 0x310
|
||||
};
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x800FC5F0
|
||||
static OSThread VideoDecodeThread;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x8C90F80
|
||||
static unsigned char VideoDecodeThreadStack[4096];
|
||||
|
||||
// size: 0x20
|
||||
struct OSMessageQueue
|
||||
{
|
||||
OSThreadQueue queueSend; // 0x0
|
||||
OSThreadQueue queueReceive; // 0x8
|
||||
void *msgArray; // 0x10
|
||||
long msgCount; // 0x14
|
||||
long firstIndex; // 0x18
|
||||
long usedCount; // 0x1C
|
||||
};
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x8D90F80
|
||||
static OSMessageQueue FreeTextureSetQueue;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x28D90F80
|
||||
static OSMessageQueue DecodedTextureSetQueue;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x48D90F80
|
||||
static void *FreeTextureSetMessage[3];
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x54D90F80
|
||||
static void *DecodedTextureSetMessage[3];
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x5C561380
|
||||
static long First;
|
||||
|
||||
int CreateVideoDecodeThread(long priority, unsigned char *ptr)
|
||||
{
|
||||
// References: First (0x5C561380)
|
||||
// References: VideoDecodeThreadCreated (0x58561380)
|
||||
// References: DecodedTextureSetMessage (0x54D90F80)
|
||||
// References: DecodedTextureSetQueue (0x28D90F80)
|
||||
// References: FreeTextureSetMessage (0x48D90F80)
|
||||
// References: FreeTextureSetQueue (0x8D90F80)
|
||||
// References: VideoDecodeThreadStack (0x8C90F80)
|
||||
// References: VideoDecodeThread (0x800FC5F0)
|
||||
}
|
||||
|
||||
void VideoDecodeThreadStart()
|
||||
{
|
||||
// References: VideoDecodeThread (0x800FC5F0)
|
||||
// References: VideoDecodeThreadCreated (0x58561380)
|
||||
}
|
||||
|
||||
void VideoDecodeThreadCancel()
|
||||
{
|
||||
// References: VideoDecodeThreadCreated (0x58561380)
|
||||
// References: VideoDecodeThread (0x800FC5F0)
|
||||
}
|
||||
|
||||
// size: 0x20
|
||||
struct DVDDiskID
|
||||
{
|
||||
char gameName[4]; // 0x0
|
||||
char company[2]; // 0x4
|
||||
unsigned char diskNumber; // 0x6
|
||||
unsigned char gameVersion; // 0x7
|
||||
unsigned char streaming; // 0x8
|
||||
unsigned char streamingBufSize; // 0x9
|
||||
unsigned char padding[22]; // 0xA
|
||||
};
|
||||
|
||||
// size: 0x30
|
||||
struct DVDCommandBlock
|
||||
{
|
||||
DVDCommandBlock *next; // 0x0
|
||||
DVDCommandBlock *prev; // 0x4
|
||||
unsigned long command; // 0x8
|
||||
long state; // 0xC
|
||||
unsigned long offset; // 0x10
|
||||
unsigned long length; // 0x14
|
||||
void *addr; // 0x18
|
||||
unsigned long currTransferSize; // 0x1C
|
||||
unsigned long transferredSize; // 0x20
|
||||
DVDDiskID *id; // 0x24
|
||||
void (*callback)(long /* unknown0 */, DVDCommandBlock */* unknown1 */); // 0x28
|
||||
void *userData; // 0x2C
|
||||
};
|
||||
|
||||
// size: 0x3C
|
||||
struct DVDFileInfo
|
||||
{
|
||||
DVDCommandBlock cb; // 0x0
|
||||
unsigned long startAddr; // 0x30
|
||||
unsigned long length; // 0x34
|
||||
void (*callback)(long /* unknown0 */, DVDFileInfo */* unknown1 */); // 0x38
|
||||
};
|
||||
|
||||
// size: 0x30
|
||||
struct __anon_0x19428
|
||||
{
|
||||
char magic[4]; // 0x0
|
||||
unsigned long version; // 0x4
|
||||
unsigned long bufSize; // 0x8
|
||||
unsigned long audioMaxSamples; // 0xC
|
||||
float frameRate; // 0x10
|
||||
unsigned long numFrames; // 0x14
|
||||
unsigned long firstFrameSize; // 0x18
|
||||
unsigned long movieDataSize; // 0x1C
|
||||
unsigned long compInfoDataOffsets; // 0x20
|
||||
unsigned long offsetDataOffsets; // 0x24
|
||||
unsigned long movieDataOffsets; // 0x28
|
||||
unsigned long finalFrameDataOffsets; // 0x2C
|
||||
};
|
||||
|
||||
// size: 0x14
|
||||
struct __anon_0x19654
|
||||
{
|
||||
unsigned long numComponents; // 0x0
|
||||
unsigned char frameComp[16]; // 0x4
|
||||
};
|
||||
|
||||
// size: 0xC
|
||||
struct __anon_0x196BC
|
||||
{
|
||||
unsigned long xSize; // 0x0
|
||||
unsigned long ySize; // 0x4
|
||||
unsigned long videoType; // 0x8
|
||||
};
|
||||
|
||||
// size: 0x10
|
||||
struct __anon_0x1973C
|
||||
{
|
||||
unsigned long sndChannels; // 0x0
|
||||
unsigned long sndFrequency; // 0x4
|
||||
unsigned long sndNumSamples; // 0x8
|
||||
unsigned long sndNumTracks; // 0xC
|
||||
};
|
||||
|
||||
// size: 0x10
|
||||
struct __anon_0x197F6
|
||||
{
|
||||
unsigned char *ytexture; // 0x0
|
||||
unsigned char *utexture; // 0x4
|
||||
unsigned char *vtexture; // 0x8
|
||||
long frameNumber; // 0xC
|
||||
};
|
||||
|
||||
// size: 0xC
|
||||
struct __anon_0x198AC
|
||||
{
|
||||
signed short *buffer; // 0x0
|
||||
signed short *curPtr; // 0x4
|
||||
unsigned long validSample; // 0x8
|
||||
};
|
||||
|
||||
// size: 0x1D0
|
||||
struct __anon_0x1999C
|
||||
{
|
||||
DVDFileInfo fileInfo; // 0x0
|
||||
__anon_0x19428 header; // 0x3C
|
||||
__anon_0x19654 compInfo; // 0x6C
|
||||
__anon_0x196BC videoInfo; // 0x80
|
||||
__anon_0x1973C audioInfo; // 0x8C
|
||||
void *thpWork; // 0x9C
|
||||
int open; // 0xA0
|
||||
unsigned char state; // 0xA4
|
||||
unsigned char internalState; // 0xA5
|
||||
unsigned char playFlag; // 0xA6
|
||||
unsigned char audioExist; // 0xA7
|
||||
long dvdError; // 0xA8
|
||||
long videoError; // 0xAC
|
||||
int onMemory; // 0xB0
|
||||
unsigned char *movieData; // 0xB4
|
||||
long initOffset; // 0xB8
|
||||
long initReadSize; // 0xBC
|
||||
long initReadFrame; // 0xC0
|
||||
signed long long retraceCount; // 0xC8
|
||||
long prevCount; // 0xD0
|
||||
long curCount; // 0xD4
|
||||
long videoAhead; // 0xD8
|
||||
float curVolume; // 0xDC
|
||||
float targetVolume; // 0xE0
|
||||
float deltaVolume; // 0xE4
|
||||
long rampCount; // 0xE8
|
||||
long curAudioTrack; // 0xEC
|
||||
long curVideoNumber; // 0xF0
|
||||
long curAudioNumber; // 0xF4
|
||||
__anon_0x197F6 *dispTextureSet; // 0xF8
|
||||
__anon_0x198AC *playAudioBuffer; // 0xFC
|
||||
__anon_0x19FA4 readBuffer[10]; // 0x100
|
||||
__anon_0x197F6 textureSet[3]; // 0x178
|
||||
__anon_0x198AC audioBuffer[3]; // 0x1A8
|
||||
};
|
||||
|
||||
// Location: 0x800F9C80
|
||||
__anon_0x1999C ActivePlayer;
|
||||
|
||||
// Local to compilation unit
|
||||
static void *VideoDecoder()
|
||||
{
|
||||
__anon_0x19FA4 *readBuffer;
|
||||
int old;
|
||||
// References: ActivePlayer (0x800F9C80)
|
||||
}
|
||||
|
||||
// size: 0xC
|
||||
struct __anon_0x19FA4
|
||||
{
|
||||
unsigned char *ptr; // 0x0
|
||||
long frameNumber; // 0x4
|
||||
int isValid; // 0x8
|
||||
};
|
||||
|
||||
// Local to compilation unit
|
||||
static void *VideoDecoderForOnMemory(void *ptr)
|
||||
{
|
||||
__anon_0x19FA4 readBuffer;
|
||||
int old;
|
||||
long tmp;
|
||||
long size;
|
||||
long readFrame;
|
||||
// References: VideoDecodeThread (0x800FC5F0)
|
||||
// References: ActivePlayer (0x800F9C80)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static void VideoDecode(__anon_0x19FA4 *readBuffer)
|
||||
{
|
||||
__anon_0x197F6 *textureSet;
|
||||
unsigned long i;
|
||||
unsigned long *compSizePtr;
|
||||
unsigned char *ptr;
|
||||
int old;
|
||||
// References: First (0x5C561380)
|
||||
// References: ActivePlayer (0x800F9C80)
|
||||
// References: VideoDecodeThread (0x800FC5F0)
|
||||
}
|
||||
|
||||
void *PopFreeTextureSet()
|
||||
{
|
||||
void *msg;
|
||||
// References: FreeTextureSetQueue (0x8D90F80)
|
||||
}
|
||||
|
||||
void PushFreeTextureSet(void *buffer)
|
||||
{
|
||||
// References: FreeTextureSetQueue (0x8D90F80)
|
||||
}
|
||||
|
||||
void *PopDecodedTextureSet(long flag)
|
||||
{
|
||||
void *msg;
|
||||
// References: DecodedTextureSetQueue (0x28D90F80)
|
||||
}
|
||||
|
||||
void PushDecodedTextureSet(void *buffer)
|
||||
{
|
||||
// References: DecodedTextureSetQueue (0x28D90F80)
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\THPVideoDecode.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C89
|
||||
Code range: 0x80012F20 -> 0x80013440
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
// size = 0x4, address = 0x80135658
|
||||
static s32 VideoDecodeThreadCreated;
|
||||
|
||||
typedef struct OSContext {
|
||||
/* 0x000 */ u32 gpr[32];
|
||||
/* 0x080 */ u32 cr;
|
||||
/* 0x084 */ u32 lr;
|
||||
/* 0x088 */ u32 ctr;
|
||||
/* 0x08C */ u32 xer;
|
||||
/* 0x090 */ double fpr[32];
|
||||
/* 0x190 */ u32 fpscr_pad;
|
||||
/* 0x194 */ u32 fpscr;
|
||||
/* 0x198 */ u32 srr0;
|
||||
/* 0x19C */ u32 srr1;
|
||||
/* 0x1A0 */ u16 mode;
|
||||
/* 0x1A2 */ u16 state;
|
||||
/* 0x1A4 */ u32 gqr[8];
|
||||
/* 0x1C4 */ u32 psf_pad;
|
||||
/* 0x1C8 */ double psf[32];
|
||||
} __anon_0x18425; // size = 0x2C8
|
||||
|
||||
typedef struct OSThreadQueue {
|
||||
/* 0x0 */ struct OSThread* head;
|
||||
/* 0x4 */ struct OSThread* tail;
|
||||
} __anon_0x1863E; // size = 0x8
|
||||
|
||||
typedef struct OSThreadLink {
|
||||
/* 0x0 */ struct OSThread* next;
|
||||
/* 0x4 */ struct OSThread* prev;
|
||||
} __anon_0x186B0; // size = 0x8
|
||||
|
||||
typedef struct OSMutexLink {
|
||||
/* 0x0 */ struct OSMutex* next;
|
||||
/* 0x4 */ struct OSMutex* prev;
|
||||
} __anon_0x18721; // size = 0x8
|
||||
|
||||
typedef struct OSMutex {
|
||||
/* 0x00 */ struct OSThreadQueue queue;
|
||||
/* 0x08 */ struct OSThread* thread;
|
||||
/* 0x0C */ s32 count;
|
||||
/* 0x10 */ struct OSMutexLink link;
|
||||
} __anon_0x18791; // size = 0x18
|
||||
|
||||
typedef struct OSMutexQueue {
|
||||
/* 0x0 */ struct OSMutex* head;
|
||||
/* 0x4 */ struct OSMutex* tail;
|
||||
} __anon_0x18842; // size = 0x8
|
||||
|
||||
typedef struct OSThread {
|
||||
/* 0x000 */ struct OSContext context;
|
||||
/* 0x2C8 */ u16 state;
|
||||
/* 0x2CA */ u16 attr;
|
||||
/* 0x2CC */ s32 suspend;
|
||||
/* 0x2D0 */ s32 priority;
|
||||
/* 0x2D4 */ s32 base;
|
||||
/* 0x2D8 */ void* val;
|
||||
/* 0x2DC */ struct OSThreadQueue* queue;
|
||||
/* 0x2E0 */ struct OSThreadLink link;
|
||||
/* 0x2E8 */ struct OSThreadQueue queueJoin;
|
||||
/* 0x2F0 */ struct OSMutex* mutex;
|
||||
/* 0x2F4 */ struct OSMutexQueue queueMutex;
|
||||
/* 0x2FC */ struct OSThreadLink linkActive;
|
||||
/* 0x304 */ u8* stackBase;
|
||||
/* 0x308 */ u32* stackEnd;
|
||||
/* 0x30C */ s32 error;
|
||||
/* 0x310 */ void* specific[2];
|
||||
} __anon_0x188D3; // size = 0x318
|
||||
|
||||
// size = 0x318, address = 0x800FC5F0
|
||||
static struct OSThread VideoDecodeThread;
|
||||
|
||||
// size = 0x1000, address = 0x800FC908
|
||||
static u8 VideoDecodeThreadStack[4096];
|
||||
|
||||
typedef struct OSMessageQueue {
|
||||
/* 0x00 */ struct OSThreadQueue queueSend;
|
||||
/* 0x08 */ struct OSThreadQueue queueReceive;
|
||||
/* 0x10 */ void* msgArray;
|
||||
/* 0x14 */ s32 msgCount;
|
||||
/* 0x18 */ s32 firstIndex;
|
||||
/* 0x1C */ s32 usedCount;
|
||||
} __anon_0x18BEF; // size = 0x20
|
||||
|
||||
// size = 0x20, address = 0x800FD908
|
||||
static struct OSMessageQueue FreeTextureSetQueue;
|
||||
|
||||
// size = 0x20, address = 0x800FD928
|
||||
static struct OSMessageQueue DecodedTextureSetQueue;
|
||||
|
||||
// size = 0xC, address = 0x800FD948
|
||||
static void* FreeTextureSetMessage[3];
|
||||
|
||||
// size = 0xC, address = 0x800FD954
|
||||
static void* DecodedTextureSetMessage[3];
|
||||
|
||||
// size = 0x4, address = 0x8013565C
|
||||
static s32 First;
|
||||
|
||||
// Range: 0x80012F20 -> 0x80013004
|
||||
s32 CreateVideoDecodeThread(s32 priority, u8* ptr) {
|
||||
// Parameters
|
||||
// s32 priority; // r8
|
||||
// u8* ptr; // r5
|
||||
|
||||
// References
|
||||
// -> static s32 First;
|
||||
// -> static s32 VideoDecodeThreadCreated;
|
||||
// -> static void* DecodedTextureSetMessage[3];
|
||||
// -> static struct OSMessageQueue DecodedTextureSetQueue;
|
||||
// -> static void* FreeTextureSetMessage[3];
|
||||
// -> static struct OSMessageQueue FreeTextureSetQueue;
|
||||
// -> static u8 VideoDecodeThreadStack[4096];
|
||||
// -> static struct OSThread VideoDecodeThread;
|
||||
}
|
||||
|
||||
// Range: 0x80013004 -> 0x80013038
|
||||
void VideoDecodeThreadStart() {
|
||||
// References
|
||||
// -> static struct OSThread VideoDecodeThread;
|
||||
// -> static s32 VideoDecodeThreadCreated;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void VideoDecodeThreadCancel() {
|
||||
// References
|
||||
// -> static s32 VideoDecodeThreadCreated;
|
||||
// -> static struct OSThread VideoDecodeThread;
|
||||
}
|
||||
|
||||
typedef struct DVDDiskID {
|
||||
/* 0x0 */ char gameName[4];
|
||||
/* 0x4 */ char company[2];
|
||||
/* 0x6 */ u8 diskNumber;
|
||||
/* 0x7 */ u8 gameVersion;
|
||||
/* 0x8 */ u8 streaming;
|
||||
/* 0x9 */ u8 streamingBufSize;
|
||||
/* 0xA */ u8 padding[22];
|
||||
} __anon_0x18FBA; // size = 0x20
|
||||
|
||||
typedef struct DVDCommandBlock {
|
||||
/* 0x00 */ struct DVDCommandBlock* next;
|
||||
/* 0x04 */ struct DVDCommandBlock* prev;
|
||||
/* 0x08 */ u32 command;
|
||||
/* 0x0C */ s32 state;
|
||||
/* 0x10 */ u32 offset;
|
||||
/* 0x14 */ u32 length;
|
||||
/* 0x18 */ void* addr;
|
||||
/* 0x1C */ u32 currTransferSize;
|
||||
/* 0x20 */ u32 transferredSize;
|
||||
/* 0x24 */ struct DVDDiskID* id;
|
||||
/* 0x28 */ void (*callback)(s32, struct DVDCommandBlock*);
|
||||
/* 0x2C */ void* userData;
|
||||
} __anon_0x1912A; // size = 0x30
|
||||
|
||||
typedef struct DVDFileInfo {
|
||||
/* 0x00 */ struct DVDCommandBlock cb;
|
||||
/* 0x30 */ u32 startAddr;
|
||||
/* 0x34 */ u32 length;
|
||||
/* 0x38 */ void (*callback)(s32, struct DVDFileInfo*);
|
||||
} __anon_0x19350; // size = 0x3C
|
||||
|
||||
typedef struct __anon_0x19428 {
|
||||
/* 0x00 */ char magic[4];
|
||||
/* 0x04 */ u32 version;
|
||||
/* 0x08 */ u32 bufSize;
|
||||
/* 0x0C */ u32 audioMaxSamples;
|
||||
/* 0x10 */ float frameRate;
|
||||
/* 0x14 */ u32 numFrames;
|
||||
/* 0x18 */ u32 firstFrameSize;
|
||||
/* 0x1C */ u32 movieDataSize;
|
||||
/* 0x20 */ u32 compInfoDataOffsets;
|
||||
/* 0x24 */ u32 offsetDataOffsets;
|
||||
/* 0x28 */ u32 movieDataOffsets;
|
||||
/* 0x2C */ u32 finalFrameDataOffsets;
|
||||
} __anon_0x19428; // size = 0x30
|
||||
|
||||
typedef struct __anon_0x19654 {
|
||||
/* 0x0 */ u32 numComponents;
|
||||
/* 0x4 */ u8 frameComp[16];
|
||||
} __anon_0x19654; // size = 0x14
|
||||
|
||||
typedef struct __anon_0x196BC {
|
||||
/* 0x0 */ u32 xSize;
|
||||
/* 0x4 */ u32 ySize;
|
||||
/* 0x8 */ u32 videoType;
|
||||
} __anon_0x196BC; // size = 0xC
|
||||
|
||||
typedef struct __anon_0x1973C {
|
||||
/* 0x0 */ u32 sndChannels;
|
||||
/* 0x4 */ u32 sndFrequency;
|
||||
/* 0x8 */ u32 sndNumSamples;
|
||||
/* 0xC */ u32 sndNumTracks;
|
||||
} __anon_0x1973C; // size = 0x10
|
||||
|
||||
typedef struct __anon_0x197F6 {
|
||||
/* 0x0 */ u8* ytexture;
|
||||
/* 0x4 */ u8* utexture;
|
||||
/* 0x8 */ u8* vtexture;
|
||||
/* 0xC */ s32 frameNumber;
|
||||
} __anon_0x197F6; // size = 0x10
|
||||
|
||||
typedef struct __anon_0x198AC {
|
||||
/* 0x0 */ s16* buffer;
|
||||
/* 0x4 */ s16* curPtr;
|
||||
/* 0x8 */ u32 validSample;
|
||||
} __anon_0x198AC; // size = 0xC
|
||||
|
||||
typedef struct __anon_0x1999C {
|
||||
/* 0x000 */ struct DVDFileInfo fileInfo;
|
||||
/* 0x03C */ struct __anon_0x19428 header;
|
||||
/* 0x06C */ struct __anon_0x19654 compInfo;
|
||||
/* 0x080 */ struct __anon_0x196BC videoInfo;
|
||||
/* 0x08C */ struct __anon_0x1973C audioInfo;
|
||||
/* 0x09C */ void* thpWork;
|
||||
/* 0x0A0 */ s32 open;
|
||||
/* 0x0A4 */ u8 state;
|
||||
/* 0x0A5 */ u8 internalState;
|
||||
/* 0x0A6 */ u8 playFlag;
|
||||
/* 0x0A7 */ u8 audioExist;
|
||||
/* 0x0A8 */ s32 dvdError;
|
||||
/* 0x0AC */ s32 videoError;
|
||||
/* 0x0B0 */ s32 onMemory;
|
||||
/* 0x0B4 */ u8* movieData;
|
||||
/* 0x0B8 */ s32 initOffset;
|
||||
/* 0x0BC */ s32 initReadSize;
|
||||
/* 0x0C0 */ s32 initReadFrame;
|
||||
/* 0x0C8 */ s64 retraceCount;
|
||||
/* 0x0D0 */ s32 prevCount;
|
||||
/* 0x0D4 */ s32 curCount;
|
||||
/* 0x0D8 */ s32 videoAhead;
|
||||
/* 0x0DC */ float curVolume;
|
||||
/* 0x0E0 */ float targetVolume;
|
||||
/* 0x0E4 */ float deltaVolume;
|
||||
/* 0x0E8 */ s32 rampCount;
|
||||
/* 0x0EC */ s32 curAudioTrack;
|
||||
/* 0x0F0 */ s32 curVideoNumber;
|
||||
/* 0x0F4 */ s32 curAudioNumber;
|
||||
/* 0x0F8 */ struct __anon_0x197F6* dispTextureSet;
|
||||
/* 0x0FC */ struct __anon_0x198AC* playAudioBuffer;
|
||||
/* 0x100 */ struct __anon_0x19FA4 readBuffer[10];
|
||||
/* 0x178 */ struct __anon_0x197F6 textureSet[3];
|
||||
/* 0x1A8 */ struct __anon_0x198AC audioBuffer[3];
|
||||
} __anon_0x1999C; // size = 0x1D0
|
||||
|
||||
// size = 0x1D0, address = 0x800F9C80
|
||||
struct __anon_0x1999C ActivePlayer;
|
||||
|
||||
// Range: 0x80013038 -> 0x80013114
|
||||
static void* VideoDecoder() {
|
||||
// Local variables
|
||||
struct __anon_0x19FA4* readBuffer; // r28
|
||||
s32 old; // r3
|
||||
|
||||
// References
|
||||
// -> struct __anon_0x1999C ActivePlayer;
|
||||
}
|
||||
|
||||
typedef struct __anon_0x19FA4 {
|
||||
/* 0x0 */ u8* ptr;
|
||||
/* 0x4 */ s32 frameNumber;
|
||||
/* 0x8 */ s32 isValid;
|
||||
} __anon_0x19FA4; // size = 0xC
|
||||
|
||||
// Range: 0x80013114 -> 0x80013248
|
||||
static void* VideoDecoderForOnMemory(void* ptr) {
|
||||
// Parameters
|
||||
// void* ptr; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
struct __anon_0x19FA4 readBuffer; // r1+0x10
|
||||
s32 old; // r3
|
||||
s32 tmp; // r4
|
||||
s32 size; // r29
|
||||
s32 readFrame; // r28
|
||||
|
||||
// References
|
||||
// -> static struct OSThread VideoDecodeThread;
|
||||
// -> struct __anon_0x1999C ActivePlayer;
|
||||
}
|
||||
|
||||
// Range: 0x80013248 -> 0x80013368
|
||||
static void VideoDecode(struct __anon_0x19FA4* readBuffer) {
|
||||
// Parameters
|
||||
// struct __anon_0x19FA4* readBuffer; // r24
|
||||
|
||||
// Local variables
|
||||
struct __anon_0x197F6* textureSet; // r28
|
||||
u32 i; // r27
|
||||
u32* compSizePtr; // r26
|
||||
u8* ptr; // r25
|
||||
s32 old; // r3
|
||||
|
||||
// References
|
||||
// -> static s32 First;
|
||||
// -> struct __anon_0x1999C ActivePlayer;
|
||||
// -> static struct OSThread VideoDecodeThread;
|
||||
}
|
||||
|
||||
// Range: 0x80013368 -> 0x8001339C
|
||||
void* PopFreeTextureSet() {
|
||||
// Local variables
|
||||
void* msg; // r1+0x8
|
||||
|
||||
// References
|
||||
// -> static struct OSMessageQueue FreeTextureSetQueue;
|
||||
}
|
||||
|
||||
// Range: 0x8001339C -> 0x800133CC
|
||||
void PushFreeTextureSet(void* buffer) {
|
||||
// Parameters
|
||||
// void* buffer; // r4
|
||||
|
||||
// References
|
||||
// -> static struct OSMessageQueue FreeTextureSetQueue;
|
||||
}
|
||||
|
||||
// Range: 0x800133CC -> 0x80013410
|
||||
void* PopDecodedTextureSet(s32 flag) {
|
||||
// Parameters
|
||||
// s32 flag; // r5
|
||||
|
||||
// Local variables
|
||||
void* msg; // r1+0xC
|
||||
|
||||
// References
|
||||
// -> static struct OSMessageQueue DecodedTextureSetQueue;
|
||||
}
|
||||
|
||||
// Range: 0x80013410 -> 0x80013440
|
||||
void PushDecodedTextureSet(void* buffer) {
|
||||
// Parameters
|
||||
// void* buffer; // r4
|
||||
|
||||
// References
|
||||
// -> static struct OSMessageQueue DecodedTextureSetQueue;
|
||||
}
|
||||
|
||||
+1019
-652
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,360 @@
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\_buildtev.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x800986A4 -> 0x8009BABC
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef enum _GXTevColorArg {
|
||||
GX_CC_CPREV = 0,
|
||||
GX_CC_APREV = 1,
|
||||
GX_CC_C0 = 2,
|
||||
GX_CC_A0 = 3,
|
||||
GX_CC_C1 = 4,
|
||||
GX_CC_A1 = 5,
|
||||
GX_CC_C2 = 6,
|
||||
GX_CC_A2 = 7,
|
||||
GX_CC_TEXC = 8,
|
||||
GX_CC_TEXA = 9,
|
||||
GX_CC_RASC = 10,
|
||||
GX_CC_RASA = 11,
|
||||
GX_CC_ONE = 12,
|
||||
GX_CC_HALF = 13,
|
||||
GX_CC_KONST = 14,
|
||||
GX_CC_ZERO = 15,
|
||||
GX_CC_TEXRRR = 16,
|
||||
GX_CC_TEXGGG = 17,
|
||||
GX_CC_TEXBBB = 18,
|
||||
GX_CC_QUARTER = 14,
|
||||
} __anon_0x891C8;
|
||||
|
||||
// size = 0x40, address = 0x800F0460
|
||||
enum _GXTevColorArg gColorArgs[16];
|
||||
|
||||
typedef enum _GXTevAlphaArg {
|
||||
GX_CA_APREV = 0,
|
||||
GX_CA_A0 = 1,
|
||||
GX_CA_A1 = 2,
|
||||
GX_CA_A2 = 3,
|
||||
GX_CA_TEXA = 4,
|
||||
GX_CA_RASA = 5,
|
||||
GX_CA_KONST = 6,
|
||||
GX_CA_ZERO = 7,
|
||||
GX_CA_ONE = 6,
|
||||
} __anon_0x89366;
|
||||
|
||||
// size = 0x28, address = 0x800F04A0
|
||||
enum _GXTevAlphaArg gAlphaArgs[10];
|
||||
|
||||
typedef enum _GXTevOp {
|
||||
GX_TEV_ADD = 0,
|
||||
GX_TEV_SUB = 1,
|
||||
GX_TEV_COMP_R8_GT = 8,
|
||||
GX_TEV_COMP_R8_EQ = 9,
|
||||
GX_TEV_COMP_GR16_GT = 10,
|
||||
GX_TEV_COMP_GR16_EQ = 11,
|
||||
GX_TEV_COMP_BGR24_GT = 12,
|
||||
GX_TEV_COMP_BGR24_EQ = 13,
|
||||
GX_TEV_COMP_RGB8_GT = 14,
|
||||
GX_TEV_COMP_RGB8_EQ = 15,
|
||||
GX_TEV_COMP_A8_GT = 14,
|
||||
GX_TEV_COMP_A8_EQ = 15,
|
||||
} __anon_0x8945B;
|
||||
|
||||
typedef enum _GXTevBias {
|
||||
GX_TB_ZERO = 0,
|
||||
GX_TB_ADDHALF = 1,
|
||||
GX_TB_SUBHALF = 2,
|
||||
GX_MAX_TEVBIAS = 3,
|
||||
} __anon_0x89586;
|
||||
|
||||
typedef enum _GXTevScale {
|
||||
GX_CS_SCALE_1 = 0,
|
||||
GX_CS_SCALE_2 = 1,
|
||||
GX_CS_SCALE_4 = 2,
|
||||
GX_CS_DIVIDE_2 = 3,
|
||||
GX_MAX_TEVSCALE = 4,
|
||||
} __anon_0x895F1;
|
||||
|
||||
typedef enum _GXTevRegID {
|
||||
GX_TEVPREV = 0,
|
||||
GX_TEVREG0 = 1,
|
||||
GX_TEVREG1 = 2,
|
||||
GX_TEVREG2 = 3,
|
||||
GX_MAX_TEVREG = 4,
|
||||
} __anon_0x89674;
|
||||
|
||||
typedef struct TevColorOp {
|
||||
/* 0x00 */ enum _GXTevOp op;
|
||||
/* 0x04 */ enum _GXTevBias bias;
|
||||
/* 0x08 */ enum _GXTevScale scale;
|
||||
/* 0x0C */ u8 clamp;
|
||||
/* 0x10 */ enum _GXTevRegID out_reg;
|
||||
} __anon_0x896E8; // size = 0x14
|
||||
|
||||
// size = 0x50, address = 0x800F04C8
|
||||
static struct TevColorOp sUsualOps[4];
|
||||
|
||||
// size = 0x10, address = 0x800F0518
|
||||
static enum _GXTevColorArg sUsualCArgs[4];
|
||||
|
||||
// size = 0x10, address = 0x800F0528
|
||||
static enum _GXTevAlphaArg sUsualAArgs[4];
|
||||
|
||||
// size = 0x8, address = 0x80135400
|
||||
static s32 zeroType$182[2];
|
||||
|
||||
// size = 0x20, address = 0x800F0538
|
||||
static s32 texelType$183[2][4];
|
||||
|
||||
// size = 0x10, address = 0x800F0558
|
||||
static s32 lightType$184[2][2];
|
||||
|
||||
typedef enum _GXTexCoordID {
|
||||
GX_TEXCOORD0 = 0,
|
||||
GX_TEXCOORD1 = 1,
|
||||
GX_TEXCOORD2 = 2,
|
||||
GX_TEXCOORD3 = 3,
|
||||
GX_TEXCOORD4 = 4,
|
||||
GX_TEXCOORD5 = 5,
|
||||
GX_TEXCOORD6 = 6,
|
||||
GX_TEXCOORD7 = 7,
|
||||
GX_MAX_TEXCOORD = 8,
|
||||
GX_TEXCOORD_NULL = 255,
|
||||
} __anon_0x89A00;
|
||||
|
||||
typedef enum _GXTexMapID {
|
||||
GX_TEXMAP0 = 0,
|
||||
GX_TEXMAP1 = 1,
|
||||
GX_TEXMAP2 = 2,
|
||||
GX_TEXMAP3 = 3,
|
||||
GX_TEXMAP4 = 4,
|
||||
GX_TEXMAP5 = 5,
|
||||
GX_TEXMAP6 = 6,
|
||||
GX_TEXMAP7 = 7,
|
||||
GX_MAX_TEXMAP = 8,
|
||||
GX_TEXMAP_NULL = 255,
|
||||
GX_TEX_DISABLE = 256,
|
||||
} __anon_0x89AD9;
|
||||
|
||||
typedef enum _GXChannelID {
|
||||
GX_COLOR0 = 0,
|
||||
GX_COLOR1 = 1,
|
||||
GX_ALPHA0 = 2,
|
||||
GX_ALPHA1 = 3,
|
||||
GX_COLOR0A0 = 4,
|
||||
GX_COLOR1A1 = 5,
|
||||
GX_COLOR_ZERO = 6,
|
||||
GX_ALPHA_BUMP = 7,
|
||||
GX_ALPHA_BUMPN = 8,
|
||||
GX_COLOR_NULL = 255,
|
||||
} __anon_0x89BAF;
|
||||
|
||||
typedef struct TevOrder {
|
||||
/* 0x0 */ enum _GXTexCoordID coordID;
|
||||
/* 0x4 */ enum _GXTexMapID mapID;
|
||||
/* 0x8 */ enum _GXChannelID chanID;
|
||||
} __anon_0x89C77; // size = 0xC
|
||||
|
||||
typedef struct CombineModeTev {
|
||||
/* 0x000 */ u32 ccCodes[2][2];
|
||||
/* 0x010 */ u8 numCycles;
|
||||
/* 0x011 */ u8 numStages;
|
||||
/* 0x012 */ u8 numTexGen;
|
||||
/* 0x013 */ u8 numChan;
|
||||
/* 0x014 */ u32 flags;
|
||||
/* 0x018 */ struct TevOrder tevOrder[8];
|
||||
/* 0x078 */ struct TevColorOp tevColorOpP[8][2];
|
||||
/* 0x1B8 */ enum _GXTevColorArg tevColorArg[8][4];
|
||||
/* 0x238 */ enum _GXTevAlphaArg tevAlphaArg[8][4];
|
||||
} __anon_0x89DF5; // size = 0x2B8
|
||||
|
||||
// size = 0x2B8, address = 0x80130C50
|
||||
static struct CombineModeTev tevStages$519;
|
||||
|
||||
// Range: 0x800986A4 -> 0x80098AE0
|
||||
struct CombineModeTev* BuildCombineModeTev(u32 color1, u32 alpha1, u32 color2, u32 alpha2, u32 numCycles) {
|
||||
// Parameters
|
||||
// u32 color1; // r26
|
||||
// u32 alpha1; // r27
|
||||
// u32 color2; // r28
|
||||
// u32 alpha2; // r29
|
||||
// u32 numCycles; // r30
|
||||
|
||||
// Local variables
|
||||
u8 stageValues[2][2][4]; // r1+0x28
|
||||
s32 i; // r1+0x8
|
||||
s32 j; // r6
|
||||
u8* tempPtr; // r1+0x8
|
||||
|
||||
// References
|
||||
// -> static struct CombineModeTev tevStages$519;
|
||||
// -> static enum _GXTevAlphaArg sUsualAArgs[4];
|
||||
// -> static enum _GXTevColorArg sUsualCArgs[4];
|
||||
}
|
||||
|
||||
// Range: 0x80098AE0 -> 0x80098BCC
|
||||
void BuildCycle(struct CombineModeTev* tvP, u8 (*stageValues)[4]) {
|
||||
// Parameters
|
||||
// struct CombineModeTev* tvP; // r31
|
||||
// u8 (* stageValues)[4]; // r29
|
||||
|
||||
// Local variables
|
||||
s32 numCParts; // r1+0x8
|
||||
s32 numAParts; // r1+0x8
|
||||
s32 i; // r5
|
||||
}
|
||||
|
||||
// Range: 0x80098BCC -> 0x8009B6BC
|
||||
s32 SetupStage(struct CombineModeTev* tvP, u8* stageValues, s32 type) {
|
||||
// Parameters
|
||||
// struct CombineModeTev* tvP; // r26
|
||||
// u8* stageValues; // r27
|
||||
// s32 type; // r22
|
||||
|
||||
// Local variables
|
||||
s32 zero; // r1+0x8
|
||||
s32 curStage; // r31
|
||||
s32 textureFoundPos; // r30
|
||||
s32 numFound[2]; // r1+0x18
|
||||
s32 retStages; // r29
|
||||
s32 ret; // r1+0x8
|
||||
s32 i; // r21
|
||||
s32 num; // r6
|
||||
s32 j; // r7
|
||||
s32 foundTypes; // r28
|
||||
s32 texelNum; // r10
|
||||
s32 mask; // r5
|
||||
s32 mask; // r21
|
||||
s32 index1; // r1+0x8
|
||||
s32 index2; // r23
|
||||
s32 index1; // r1+0x8
|
||||
s32 index2; // r23
|
||||
s32 flag; // r7
|
||||
s32 mask; // r4
|
||||
|
||||
// References
|
||||
// -> enum _GXTevAlphaArg gAlphaArgs[10];
|
||||
// -> static struct TevColorOp sUsualOps[4];
|
||||
// -> enum _GXTevColorArg gColorArgs[16];
|
||||
// -> static s32 lightType$184[2][2];
|
||||
// -> static s32 texelType$183[2][4];
|
||||
// -> static s32 zeroType$182[2];
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void AddColorTevOrder(struct CombineModeTev* tvP, s32 foundTypes, s32 curStage) {
|
||||
// Parameters
|
||||
// struct CombineModeTev* tvP; // r1+0x0
|
||||
// s32 foundTypes; // r1+0x4
|
||||
// s32 curStage; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8009B6BC -> 0x8009B7DC
|
||||
static s32 AddAlphaTevOrder(struct CombineModeTev* tvP, s32 foundTypes, s32 curStage) {
|
||||
// Parameters
|
||||
// struct CombineModeTev* tvP; // r1+0x0
|
||||
// s32 foundTypes; // r1+0x4
|
||||
// s32 curStage; // r5
|
||||
|
||||
// Local variables
|
||||
s32 ret; // r6
|
||||
|
||||
// References
|
||||
// -> static struct TevColorOp sUsualOps[4];
|
||||
}
|
||||
|
||||
// Range: 0x8009B7DC -> 0x8009B914
|
||||
void SetAlpha(u8* stageValues, u32 alphaVal, u8 cycle) {
|
||||
// Parameters
|
||||
// u8* stageValues; // r1+0x0
|
||||
// u32 alphaVal; // r1+0x4
|
||||
// u8 cycle; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
s32 i; // r8
|
||||
}
|
||||
|
||||
typedef enum __anon_0x8A896 {
|
||||
SM_NONE = -1,
|
||||
SM_RUNNING = 0,
|
||||
SM_STOPPED = 1,
|
||||
} __anon_0x8A896;
|
||||
|
||||
typedef struct __anon_0x8A8FE {
|
||||
/* 0x0 */ s32 nSize;
|
||||
/* 0x4 */ s32 nOffsetRAM;
|
||||
/* 0x8 */ s32 nOffsetROM;
|
||||
/* 0xC */ s32 (*pCallback)();
|
||||
} __anon_0x8A8FE; // size = 0x10
|
||||
|
||||
typedef enum __anon_0x8A9AF {
|
||||
SRT_NONE = -1,
|
||||
SRT_MARIO = 0,
|
||||
SRT_WAVERACE = 1,
|
||||
SRT_MARIOKART = 2,
|
||||
SRT_STARFOX = 3,
|
||||
SRT_ZELDA1 = 4,
|
||||
SRT_ZELDA2 = 5,
|
||||
SRT_1080 = 6,
|
||||
SRT_PANEL = 7,
|
||||
SRT_MARIOPARTY1 = 8,
|
||||
SRT_MARIOPARTY2 = 9,
|
||||
SRT_MARIOPARTY3 = 10,
|
||||
SRT_DRMARIO = 11,
|
||||
SRT_UNKNOWN = 12,
|
||||
} __anon_0x8A9AF;
|
||||
|
||||
typedef enum __anon_0x8AAE1 {
|
||||
SOT_NONE = -1,
|
||||
SOT_CPU = 0,
|
||||
SOT_PIF = 1,
|
||||
SOT_RAM = 2,
|
||||
SOT_ROM = 3,
|
||||
SOT_RSP = 4,
|
||||
SOT_RDP = 5,
|
||||
SOT_MIPS = 6,
|
||||
SOT_DISK = 7,
|
||||
SOT_FLASH = 8,
|
||||
SOT_SRAM = 9,
|
||||
SOT_AUDIO = 10,
|
||||
SOT_VIDEO = 11,
|
||||
SOT_SERIAL = 12,
|
||||
SOT_LIBRARY = 13,
|
||||
SOT_PERIPHERAL = 14,
|
||||
SOT_RDB = 15,
|
||||
SOT_COUNT = 16,
|
||||
} __anon_0x8AAE1;
|
||||
|
||||
typedef struct __anon_0x8AC22 {
|
||||
/* 0x00 */ void* pFrame;
|
||||
/* 0x04 */ void* pSound;
|
||||
/* 0x08 */ s32 bException;
|
||||
/* 0x0C */ enum __anon_0x8A896 eMode;
|
||||
/* 0x10 */ struct __anon_0x8A8FE romCopy;
|
||||
/* 0x20 */ enum __anon_0x8A9AF eTypeROM;
|
||||
/* 0x24 */ void* apObject[16];
|
||||
/* 0x68 */ u64 nAddressBreak;
|
||||
/* 0x70 */ enum __anon_0x8AAE1 storageDevice;
|
||||
/* 0x74 */ u8 anException[16];
|
||||
/* 0x84 */ s32 bJapaneseVersion;
|
||||
} __anon_0x8AC22; // size = 0x88
|
||||
|
||||
// size = 0x4, address = 0x80135600
|
||||
struct __anon_0x8AC22* gpSystem;
|
||||
|
||||
// Range: 0x8009B914 -> 0x8009BABC
|
||||
void SetColor(u8* stageValues, u32 colorVal, u8 cycle) {
|
||||
// Parameters
|
||||
// u8* stageValues; // r1+0x0
|
||||
// u32 colorVal; // r1+0x4
|
||||
// u8 cycle; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
s32 i; // r10
|
||||
|
||||
// References
|
||||
// -> struct __anon_0x8AC22* gpSystem;
|
||||
}
|
||||
+368
-242
@@ -1,242 +1,368 @@
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_LWR(int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_LWL(int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_SDC(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_LDC(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_SW(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_SH(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_SB(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_LHU(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_LBU(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_LW(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_LH(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_LB(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
int cpuCompile_TRUNC_W(int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
int cpuCompile_ROUND_W(int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_FLOOR_W(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_CEIL_W(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_L_CVT_SD(int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_W_CVT_SD(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_D_SQRT(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_S_SQRT(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
int cpuCompile_DSUBU(int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
int cpuCompile_DSUB(int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
int cpuCompile_DADDU(int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
int cpuCompile_DADD(int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_DDIVU(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_DDIV(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_DMULTU(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_DMULT(_CPU *pCPU, int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_DSRAV(int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_DSRLV(int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCompile_DSLLV(int *addressGCN)
|
||||
{
|
||||
int *compile;
|
||||
int count;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\_cpuDecodePPC2.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C89
|
||||
Code range: 0x80068368 -> 0x8006BE68
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
// Range: 0x80068368 -> 0x800684F4
|
||||
static s32 cpuCompile_LWR(s32* addressGCN) {
|
||||
// Parameters
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r7
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x800684F4 -> 0x80068684
|
||||
static s32 cpuCompile_LWL(s32* addressGCN) {
|
||||
// Parameters
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r9
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80068684 -> 0x8006880C
|
||||
static s32 cpuCompile_SDC(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r5
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006880C -> 0x80068994
|
||||
static s32 cpuCompile_LDC(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r5
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80068994 -> 0x80068AF0
|
||||
static s32 cpuCompile_SW(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r7
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80068AF0 -> 0x80068C4C
|
||||
static s32 cpuCompile_SH(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r7
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80068C4C -> 0x80068DA8
|
||||
static s32 cpuCompile_SB(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r7
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80068DA8 -> 0x80068F00
|
||||
static s32 cpuCompile_LHU(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r5
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80068F00 -> 0x80069058
|
||||
static s32 cpuCompile_LBU(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r5
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80069058 -> 0x800691B0
|
||||
static s32 cpuCompile_LW(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r5
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x800691B0 -> 0x8006931C
|
||||
static s32 cpuCompile_LH(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r9
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006931C -> 0x80069488
|
||||
static s32 cpuCompile_LB(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r9
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuCompile_TRUNC_W(s32* addressGCN) {
|
||||
// Parameters
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r7
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuCompile_ROUND_W(s32* addressGCN) {
|
||||
// Parameters
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r7
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80069488 -> 0x80069644
|
||||
static s32 cpuCompile_FLOOR_W(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r7
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80069644 -> 0x80069800
|
||||
static s32 cpuCompile_CEIL_W(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r7
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80069800 -> 0x80069D80
|
||||
static s32 cpuCompile_L_CVT_SD(s32* addressGCN) {
|
||||
// Parameters
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r5
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80069D80 -> 0x80069F30
|
||||
static s32 cpuCompile_W_CVT_SD(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r31
|
||||
// s32* addressGCN; // r30
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r30
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80069F30 -> 0x8006A364
|
||||
static s32 cpuCompile_D_SQRT(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r22
|
||||
// s32* addressGCN; // r21
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r21
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006A364 -> 0x8006A6A4
|
||||
static s32 cpuCompile_S_SQRT(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r19
|
||||
// s32* addressGCN; // r18
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r29
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuCompile_DSUBU(s32* addressGCN) {
|
||||
// Parameters
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r7
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuCompile_DSUB(s32* addressGCN) {
|
||||
// Parameters
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r7
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuCompile_DADDU(s32* addressGCN) {
|
||||
// Parameters
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r7
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuCompile_DADD(s32* addressGCN) {
|
||||
// Parameters
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r7
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006A6A4 -> 0x8006AAC0
|
||||
static s32 cpuCompile_DDIVU(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r31
|
||||
// s32* addressGCN; // r24
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r9
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006AAC0 -> 0x8006B07C
|
||||
static s32 cpuCompile_DDIV(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* addressGCN; // r16
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r23
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006B07C -> 0x8006B390
|
||||
static s32 cpuCompile_DMULTU(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r31
|
||||
// s32* addressGCN; // r30
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r7
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006B390 -> 0x8006B894
|
||||
static s32 cpuCompile_DMULT(struct _CPU* pCPU, s32* addressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r31
|
||||
// s32* addressGCN; // r27
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r5
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006B894 -> 0x8006BA98
|
||||
static s32 cpuCompile_DSRAV(s32* addressGCN) {
|
||||
// Parameters
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r1+0x8
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006BA98 -> 0x8006BC80
|
||||
static s32 cpuCompile_DSRLV(s32* addressGCN) {
|
||||
// Parameters
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r11
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006BC80 -> 0x8006BE68
|
||||
static s32 cpuCompile_DSLLV(s32* addressGCN) {
|
||||
// Parameters
|
||||
// s32* addressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32* compile; // r1+0x10
|
||||
s32 count; // r11
|
||||
s32 nSize; // r1+0x8
|
||||
}
|
||||
|
||||
+456
-286
@@ -1,286 +1,456 @@
|
||||
int cpuExecute(_CPU *pCPU)
|
||||
{
|
||||
int iGPR;
|
||||
int *pnCode;
|
||||
int nData;
|
||||
cpu_function *pFunction;
|
||||
void (*pfCode)();
|
||||
// References: cpuCompile_LWR_function (0x5C571380)
|
||||
// References: cpuCompile_LWL_function (0x58571380)
|
||||
// References: cpuCompile_SDC_function (0x54571380)
|
||||
// References: cpuCompile_LDC_function (0x50571380)
|
||||
// References: cpuCompile_SW_function (0x4C571380)
|
||||
// References: cpuCompile_SH_function (0x48571380)
|
||||
// References: cpuCompile_SB_function (0x44571380)
|
||||
// References: cpuCompile_LHU_function (0x40571380)
|
||||
// References: cpuCompile_LBU_function (0x3C571380)
|
||||
// References: cpuCompile_LW_function (0x38571380)
|
||||
// References: cpuCompile_LH_function (0x34571380)
|
||||
// References: cpuCompile_LB_function (0x30571380)
|
||||
// References: cpuCompile_ROUND_W_function (0x28571380)
|
||||
// References: cpuCompile_TRUNC_W_function (0x2C571380)
|
||||
// References: cpuCompile_FLOOR_W_function (0x24571380)
|
||||
// References: cpuCompile_CEIL_W_function (0x20571380)
|
||||
// References: cpuCompile_L_CVT_SD_function (0x1C571380)
|
||||
// References: cpuCompile_W_CVT_SD_function (0x18571380)
|
||||
// References: cpuCompile_D_SQRT_function (0x14571380)
|
||||
// References: cpuCompile_S_SQRT_function (0x10571380)
|
||||
// References: cpuCompile_DSUBU_function (0xC571380)
|
||||
// References: cpuCompile_DSUB_function (0x8571380)
|
||||
// References: cpuCompile_DADDU_function (0x4571380)
|
||||
// References: cpuCompile_DADD_function (0x571380)
|
||||
// References: cpuCompile_DDIVU_function (0x801356FC)
|
||||
// References: cpuCompile_DDIV_function (0x801356F8)
|
||||
// References: cpuCompile_DMULTU_function (0x801356F4)
|
||||
// References: cpuCompile_DMULT_function (0x801356F0)
|
||||
// References: cpuCompile_DSRAV_function (0x801356EC)
|
||||
// References: cpuCompile_DSRLV_function (0x801356E8)
|
||||
// References: cpuCompile_DSLLV_function (0x801356E4)
|
||||
// References: ganMapGPR (0x70BE0E80)
|
||||
}
|
||||
|
||||
void __cpuTest();
|
||||
|
||||
int cpuFreeLink(void (**ppfLink)());
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuMakeLink(_CPU *pCPU, void (**ppfLink)(), void (*pfFunction)())
|
||||
{
|
||||
int iGPR;
|
||||
int *pnCode;
|
||||
int nData;
|
||||
// References: ganMapGPR (0x70BE0E80)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuExecuteLoadStoreF(_CPU *pCPU, int nAddressN64, int nAddressGCN)
|
||||
{
|
||||
unsigned int *opcode;
|
||||
int address;
|
||||
int iRegisterA;
|
||||
int iRegisterB;
|
||||
unsigned char device;
|
||||
int total;
|
||||
int count;
|
||||
int save;
|
||||
int interpret;
|
||||
int *before;
|
||||
int *after;
|
||||
int check2;
|
||||
int *anCode;
|
||||
// References: ganMapGPR (0x70BE0E80)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuExecuteLoadStore(_CPU *pCPU, int nAddressN64, int nAddressGCN)
|
||||
{
|
||||
unsigned int *opcode;
|
||||
int address;
|
||||
int iRegisterA;
|
||||
int iRegisterB;
|
||||
unsigned char device;
|
||||
int total;
|
||||
int count;
|
||||
int save;
|
||||
int interpret;
|
||||
int *before;
|
||||
int *after;
|
||||
int check2;
|
||||
int *anCode;
|
||||
// References: ganMapGPR (0x70BE0E80)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuExecuteCall(_CPU *pCPU, int nCount, int nAddressN64, int nAddressGCN)
|
||||
{
|
||||
int count;
|
||||
int *anCode;
|
||||
int saveGCN;
|
||||
cpu_function *node;
|
||||
cpu_callerID *block;
|
||||
int nDeltaAddress;
|
||||
// References: ganMapGPR (0x70BE0E80)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuExecuteJump(_CPU *pCPU, int nCount, int nAddressN64, int nAddressGCN)
|
||||
{
|
||||
// References: gpSystem (0x561380)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuExecuteIdle(_CPU *pCPU, int nCount, int nAddressN64, int nAddressGCN)
|
||||
{
|
||||
__anon_0x443F6 *pROM;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuExecuteOpcode(_CPU *pCPU, int nCount, int nAddressN64, int nAddressGCN)
|
||||
{
|
||||
unsigned long long save;
|
||||
int restore;
|
||||
unsigned int nOpcode;
|
||||
unsigned int *opcode;
|
||||
__anon_0x3EB4F **apDevice;
|
||||
unsigned char *aiDevice;
|
||||
int iEntry;
|
||||
int nCount;
|
||||
char nData8;
|
||||
signed short nData16;
|
||||
int nData32;
|
||||
signed long long nData64;
|
||||
int nAddress;
|
||||
cpu_function *pFunction;
|
||||
// References: __float_huge (0x7C3E0F80)
|
||||
// References: __float_nan (0x783E0F80)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuExecuteUpdate(_CPU *pCPU, int *pnAddressGCN, unsigned int nCount)
|
||||
{
|
||||
__anon_0x44829 eModeUpdate;
|
||||
__anon_0x3DB14 *pSystem;
|
||||
int nDelta;
|
||||
unsigned int nCounter;
|
||||
unsigned int nCompare;
|
||||
// References: gpSystem (0x561380)
|
||||
// References: nTickMultiplier (0x604E1380)
|
||||
// References: fTickScale (0x644E1380)
|
||||
}
|
||||
|
||||
int cpuRetraceReset();
|
||||
|
||||
int cpuRetraceSetup(_CPU *pCPU);
|
||||
|
||||
// Local to compilation unit
|
||||
static void cpuRetraceCallback(unsigned int nCount)
|
||||
{
|
||||
// References: gpSystem (0x561380)
|
||||
}
|
||||
|
||||
void cpuAlarmCallback(OSAlarm *pAlarm)
|
||||
{
|
||||
_CPU *pCPU;
|
||||
// References: gpSystem (0x561380)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuNextInstruction(_CPU *pCPU, int addressN64, int opcode, int *anCode, int *iCode);
|
||||
|
||||
int cpuStackOffset(_CPU *pCPU, int currentAddress, int *anCode, int source, int target);
|
||||
|
||||
int cpuCutStoreLoadF(_CPU *pCPU, int currentAddress, int source);
|
||||
|
||||
int cpuCutStoreLoad(_CPU *pCPU, int currentAddress, int source);
|
||||
|
||||
int cpuNoBranchTo(cpu_function *pFunction, int currentAddress)
|
||||
{
|
||||
int i;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuFindAddress(_CPU *pCPU, int nAddressN64, int *pnAddressGCN)
|
||||
{
|
||||
int iJump;
|
||||
int iCode;
|
||||
int nAddress;
|
||||
cpu_function *pFunction;
|
||||
}
|
||||
|
||||
int cpuFreeFunction(_CPU *pCPU, cpu_function *pFunction);
|
||||
|
||||
int cpuMakeFunction(_CPU *pCPU, cpu_function **ppFunction, int nAddressN64)
|
||||
{
|
||||
int iCode;
|
||||
int iCode0;
|
||||
int iJump;
|
||||
int iCheck;
|
||||
int firstTime;
|
||||
int kill_value;
|
||||
int memory_used;
|
||||
int codeMemory;
|
||||
int blockMemory;
|
||||
int *chunkMemory;
|
||||
int *anCode;
|
||||
int nAddress;
|
||||
cpu_function *pFunction;
|
||||
__anon_0x3DE78 aJump[1024];
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuGetPPC(_CPU *pCPU, int *pnAddress, cpu_function *pFunction, int *anCode, int *piCode, int bSlot)
|
||||
{
|
||||
int nSize;
|
||||
int iHack;
|
||||
int bInterpret;
|
||||
int iCode;
|
||||
int iJump;
|
||||
int nAddress;
|
||||
int nDeltaAddress;
|
||||
int bFlag;
|
||||
int nAddressJump;
|
||||
int nOffset;
|
||||
unsigned int nOpcode;
|
||||
unsigned int nOpcodePrev;
|
||||
unsigned int nOpcodeNext;
|
||||
unsigned int *pnOpcode;
|
||||
int prev;
|
||||
int iRegisterA;
|
||||
int iRegisterB;
|
||||
int iRegisterC;
|
||||
int nTemp1;
|
||||
int nTemp2;
|
||||
int nTemp3;
|
||||
int update;
|
||||
int iUpdate;
|
||||
int nTarget;
|
||||
// References: ganMapGPR (0x70BE0E80)
|
||||
// References: cpuCompile_SDC_function (0x54571380)
|
||||
// References: cpuCompile_SW_function (0x4C571380)
|
||||
// References: cpuCompile_LDC_function (0x50571380)
|
||||
// References: cpuCompile_LW_function (0x38571380)
|
||||
// References: gpSystem (0x561380)
|
||||
// References: cpuCompile_SH_function (0x48571380)
|
||||
// References: cpuCompile_SB_function (0x44571380)
|
||||
// References: cpuCompile_LWR_function (0x5C571380)
|
||||
// References: cpuCompile_LHU_function (0x40571380)
|
||||
// References: cpuCompile_LBU_function (0x3C571380)
|
||||
// References: cpuCompile_LWL_function (0x58571380)
|
||||
// References: cpuCompile_LH_function (0x34571380)
|
||||
// References: cpuCompile_LB_function (0x30571380)
|
||||
// References: cpuCompile_L_CVT_SD_function (0x1C571380)
|
||||
// References: cpuCompile_W_CVT_SD_function (0x18571380)
|
||||
// References: cpuCompile_TRUNC_W_function (0x2C571380)
|
||||
// References: cpuCompile_FLOOR_W_function (0x24571380)
|
||||
// References: cpuCompile_CEIL_W_function (0x20571380)
|
||||
// References: cpuCompile_ROUND_W_function (0x28571380)
|
||||
// References: cpuCompile_D_SQRT_function (0x14571380)
|
||||
// References: cpuCompile_S_SQRT_function (0x10571380)
|
||||
// References: cpuCompile_DSUBU_function (0xC571380)
|
||||
// References: cpuCompile_DSUB_function (0x8571380)
|
||||
// References: cpuCompile_DADDU_function (0x4571380)
|
||||
// References: cpuCompile_DADD_function (0x571380)
|
||||
// References: cpuCompile_DDIVU_function (0x801356FC)
|
||||
// References: cpuCompile_DDIV_function (0x801356F8)
|
||||
// References: cpuCompile_DMULTU_function (0x801356F4)
|
||||
// References: cpuCompile_DMULT_function (0x801356F0)
|
||||
// References: cpuCompile_DSRAV_function (0x801356EC)
|
||||
// References: cpuCompile_DSRLV_function (0x801356E8)
|
||||
// References: cpuCompile_DSLLV_function (0x801356E4)
|
||||
}
|
||||
|
||||
int cpuRecompileFunction(_CPU *pCPU, cpu_function *pFunction, int nAddressN64);
|
||||
|
||||
void cpuCompileNOP(int *anCode, int *iCode, int number);
|
||||
|
||||
// Local to compilation unit
|
||||
static int cpuCheckDelaySlot(unsigned int opcode)
|
||||
{
|
||||
int flag;
|
||||
}
|
||||
|
||||
int cpuFindBranchOffset(cpu_function *pFunction, int *pnOffset, int nAddress, int *anCode)
|
||||
{
|
||||
int iJump;
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\_cpuGCN.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C89
|
||||
Code range: 0x80036870 -> 0x80068368
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
// Range: 0x80036870 -> 0x800374DC
|
||||
s32 cpuExecute(struct _CPU* pCPU) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r31
|
||||
|
||||
// Local variables
|
||||
s32 iGPR; // r8
|
||||
s32* pnCode; // r1+0x54
|
||||
s32 nData; // r1+0x8
|
||||
struct cpu_function* pFunction; // r1+0x4C
|
||||
void (*pfCode)(); // r1+0x48
|
||||
|
||||
// References
|
||||
// -> static s32 cpuCompile_LWR_function;
|
||||
// -> static s32 cpuCompile_LWL_function;
|
||||
// -> static s32 cpuCompile_SDC_function;
|
||||
// -> static s32 cpuCompile_LDC_function;
|
||||
// -> static s32 cpuCompile_SW_function;
|
||||
// -> static s32 cpuCompile_SH_function;
|
||||
// -> static s32 cpuCompile_SB_function;
|
||||
// -> static s32 cpuCompile_LHU_function;
|
||||
// -> static s32 cpuCompile_LBU_function;
|
||||
// -> static s32 cpuCompile_LW_function;
|
||||
// -> static s32 cpuCompile_LH_function;
|
||||
// -> static s32 cpuCompile_LB_function;
|
||||
// -> static s32 cpuCompile_ROUND_W_function;
|
||||
// -> static s32 cpuCompile_TRUNC_W_function;
|
||||
// -> static s32 cpuCompile_FLOOR_W_function;
|
||||
// -> static s32 cpuCompile_CEIL_W_function;
|
||||
// -> static s32 cpuCompile_L_CVT_SD_function;
|
||||
// -> static s32 cpuCompile_W_CVT_SD_function;
|
||||
// -> static s32 cpuCompile_D_SQRT_function;
|
||||
// -> static s32 cpuCompile_S_SQRT_function;
|
||||
// -> static s32 cpuCompile_DSUBU_function;
|
||||
// -> static s32 cpuCompile_DSUB_function;
|
||||
// -> static s32 cpuCompile_DADDU_function;
|
||||
// -> static s32 cpuCompile_DADD_function;
|
||||
// -> static s32 cpuCompile_DDIVU_function;
|
||||
// -> static s32 cpuCompile_DDIV_function;
|
||||
// -> static s32 cpuCompile_DMULTU_function;
|
||||
// -> static s32 cpuCompile_DMULT_function;
|
||||
// -> static s32 cpuCompile_DSRAV_function;
|
||||
// -> static s32 cpuCompile_DSRLV_function;
|
||||
// -> static s32 cpuCompile_DSLLV_function;
|
||||
// -> s32 ganMapGPR[32];
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void __cpuTest() {}
|
||||
|
||||
// Erased
|
||||
static s32 cpuFreeLink(void (**ppfLink)()) {
|
||||
// Parameters
|
||||
// void (** ppfLink)(); // r1+0xC
|
||||
}
|
||||
|
||||
// Range: 0x800374DC -> 0x8003779C
|
||||
static s32 cpuMakeLink(struct _CPU* pCPU, void (**ppfLink)(), void (*pfFunction)()) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r29
|
||||
// void (** ppfLink)(); // r30
|
||||
// void (* pfFunction)(); // r31
|
||||
|
||||
// Local variables
|
||||
s32 iGPR; // r1+0x8
|
||||
s32* pnCode; // r1+0x18
|
||||
s32 nData; // r1+0x8
|
||||
|
||||
// References
|
||||
// -> s32 ganMapGPR[32];
|
||||
}
|
||||
|
||||
// Range: 0x8003779C -> 0x800382F8
|
||||
static s32 cpuExecuteLoadStoreF(struct _CPU* pCPU, s32 nAddressN64, s32 nAddressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r31
|
||||
// s32 nAddressN64; // r22
|
||||
// s32 nAddressGCN; // r25
|
||||
|
||||
// Local variables
|
||||
u32* opcode; // r1+0x1C
|
||||
s32 address; // r1+0x8
|
||||
s32 iRegisterA; // r6
|
||||
s32 iRegisterB; // r1+0x8
|
||||
u8 device; // r5
|
||||
s32 total; // r30
|
||||
s32 count; // r29
|
||||
s32 save; // r28
|
||||
s32 interpret; // r27
|
||||
s32* before; // r26
|
||||
s32* after; // r25
|
||||
s32 check2; // r24
|
||||
s32* anCode; // r23
|
||||
|
||||
// References
|
||||
// -> s32 ganMapGPR[32];
|
||||
}
|
||||
|
||||
// Range: 0x800382F8 -> 0x80039158
|
||||
static s32 cpuExecuteLoadStore(struct _CPU* pCPU, s32 nAddressN64, s32 nAddressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r24
|
||||
// s32 nAddressN64; // r22
|
||||
// s32 nAddressGCN; // r27
|
||||
|
||||
// Local variables
|
||||
u32* opcode; // r1+0x1C
|
||||
s32 address; // r1+0x8
|
||||
s32 iRegisterA; // r5
|
||||
s32 iRegisterB; // r1+0x8
|
||||
u8 device; // r5
|
||||
s32 total; // r23
|
||||
s32 count; // r31
|
||||
s32 save; // r30
|
||||
s32 interpret; // r29
|
||||
s32* before; // r28
|
||||
s32* after; // r27
|
||||
s32 check2; // r26
|
||||
s32* anCode; // r25
|
||||
|
||||
// References
|
||||
// -> s32 ganMapGPR[32];
|
||||
}
|
||||
|
||||
// Range: 0x80039158 -> 0x800393B8
|
||||
static s32 cpuExecuteCall(struct _CPU* pCPU, s32 nCount, s32 nAddressN64, s32 nAddressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r28
|
||||
// s32 nCount; // r29
|
||||
// s32 nAddressN64; // r30
|
||||
// s32 nAddressGCN; // r1+0x14
|
||||
|
||||
// Local variables
|
||||
s32 count; // r4
|
||||
s32* anCode; // r30
|
||||
s32 saveGCN; // r31
|
||||
struct cpu_function* node; // r1+0x18
|
||||
struct cpu_callerID* block; // r5
|
||||
s32 nDeltaAddress; // r1+0x8
|
||||
|
||||
// References
|
||||
// -> s32 ganMapGPR[32];
|
||||
}
|
||||
|
||||
// Range: 0x800393B8 -> 0x80039488
|
||||
static s32 cpuExecuteJump(struct _CPU* pCPU, s32 nCount, s32 nAddressN64, s32 nAddressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r29
|
||||
// s32 nCount; // r30
|
||||
// s32 nAddressN64; // r31
|
||||
// s32 nAddressGCN; // r1+0x14
|
||||
|
||||
// References
|
||||
// -> struct __anon_0x3DB14* gpSystem;
|
||||
}
|
||||
|
||||
// Range: 0x80039488 -> 0x80039594
|
||||
static s32 cpuExecuteIdle(struct _CPU* pCPU, s32 nCount, s32 nAddressN64, s32 nAddressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r31
|
||||
// s32 nCount; // r28
|
||||
// s32 nAddressN64; // r29
|
||||
// s32 nAddressGCN; // r1+0x14
|
||||
|
||||
// Local variables
|
||||
struct __anon_0x443F6* pROM; // r30
|
||||
}
|
||||
|
||||
// Range: 0x80039594 -> 0x8003DF08
|
||||
static s32 cpuExecuteOpcode(struct _CPU* pCPU, s32 nCount, s32 nAddressN64, s32 nAddressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r31
|
||||
// s32 nCount; // r1+0xC
|
||||
// s32 nAddressN64; // r22
|
||||
// s32 nAddressGCN; // r1+0x14
|
||||
|
||||
// Local variables
|
||||
u64 save; // r25
|
||||
s32 restore; // r27
|
||||
u32 nOpcode; // r30
|
||||
u32* opcode; // r1+0x6C
|
||||
struct __anon_0x3EB4F** apDevice; // r28
|
||||
u8* aiDevice; // r29
|
||||
s32 iEntry; // r4
|
||||
s32 nCount; // r22
|
||||
char nData8; // r1+0x66
|
||||
s16 nData16; // r1+0x64
|
||||
s32 nData32; // r1+0x60
|
||||
s64 nData64; // r1+0x58
|
||||
s32 nAddress; // r23
|
||||
struct cpu_function* pFunction; // r1+0x50
|
||||
|
||||
// References
|
||||
// -> s32 __float_huge[];
|
||||
// -> s32 __float_nan[];
|
||||
}
|
||||
|
||||
// Range: 0x8003DF08 -> 0x8003E204
|
||||
static s32 cpuExecuteUpdate(struct _CPU* pCPU, s32* pnAddressGCN, u32 nCount) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r28
|
||||
// s32* pnAddressGCN; // r29
|
||||
// u32 nCount; // r30
|
||||
|
||||
// Local variables
|
||||
enum __anon_0x44829 eModeUpdate; // r4
|
||||
struct __anon_0x3DB14* pSystem; // r31
|
||||
s32 nDelta; // r1+0x8
|
||||
u32 nCounter; // r1+0x8
|
||||
u32 nCompare; // r1+0x8
|
||||
|
||||
// References
|
||||
// -> struct __anon_0x3DB14* gpSystem;
|
||||
// -> u32 nTickMultiplier;
|
||||
// -> float fTickScale;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuRetraceReset() {}
|
||||
|
||||
// Erased
|
||||
static s32 cpuRetraceSetup(struct _CPU* pCPU) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8003E204 -> 0x8003E214
|
||||
static void cpuRetraceCallback(u32 nCount) {
|
||||
// Parameters
|
||||
// u32 nCount; // r1+0x0
|
||||
|
||||
// References
|
||||
// -> struct __anon_0x3DB14* gpSystem;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void cpuAlarmCallback(struct OSAlarm* pAlarm) {
|
||||
// Parameters
|
||||
// struct OSAlarm* pAlarm; // r3
|
||||
|
||||
// Local variables
|
||||
struct _CPU* pCPU; // r31
|
||||
|
||||
// References
|
||||
// -> struct __anon_0x3DB14* gpSystem;
|
||||
}
|
||||
|
||||
// Range: 0x8003E214 -> 0x8003E4D8
|
||||
static s32 cpuNextInstruction(struct _CPU* pCPU, s32 addressN64, s32 opcode, s32* anCode, s32* iCode) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r1+0x8
|
||||
// s32 addressN64; // r10
|
||||
// s32 opcode; // r5
|
||||
// s32* anCode; // r1+0x14
|
||||
// s32* iCode; // r1+0x18
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuStackOffset(struct _CPU* pCPU, s32 currentAddress, s32* anCode, s32 source, s32 target) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r1+0x0
|
||||
// s32 currentAddress; // r1+0x4
|
||||
// s32* anCode; // r1+0x8
|
||||
// s32 source; // r1+0xC
|
||||
// s32 target; // r1+0x10
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuCutStoreLoadF(struct _CPU* pCPU, s32 currentAddress, s32 source) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r1+0x0
|
||||
// s32 currentAddress; // r1+0x4
|
||||
// s32 source; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuCutStoreLoad(struct _CPU* pCPU, s32 currentAddress, s32 source) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r1+0x0
|
||||
// s32 currentAddress; // r1+0x4
|
||||
// s32 source; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuNoBranchTo(struct cpu_function* pFunction, s32 currentAddress) {
|
||||
// Parameters
|
||||
// struct cpu_function* pFunction; // r1+0x0
|
||||
// s32 currentAddress; // r1+0x4
|
||||
|
||||
// Local variables
|
||||
s32 i; // r1+0x0
|
||||
}
|
||||
|
||||
// Range: 0x8003E4D8 -> 0x8003E974
|
||||
static s32 cpuFindAddress(struct _CPU* pCPU, s32 nAddressN64, s32* pnAddressGCN) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r29
|
||||
// s32 nAddressN64; // r30
|
||||
// s32* pnAddressGCN; // r31
|
||||
|
||||
// Local variables
|
||||
s32 iJump; // r6
|
||||
s32 iCode; // r1+0x20
|
||||
s32 nAddress; // r1+0x1C
|
||||
struct cpu_function* pFunction; // r1+0x18
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuFreeFunction(struct _CPU* pCPU, struct cpu_function* pFunction) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r3
|
||||
// struct cpu_function* pFunction; // r4
|
||||
}
|
||||
|
||||
// Range: 0x8003E974 -> 0x8003EE04
|
||||
s32 cpuMakeFunction(struct _CPU* pCPU, struct cpu_function** ppFunction, s32 nAddressN64) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// struct cpu_function** ppFunction; // r31
|
||||
// s32 nAddressN64; // r5
|
||||
|
||||
// Local variables
|
||||
s32 iCode; // r1+0x2028
|
||||
s32 iCode0; // r1+0x8
|
||||
s32 iJump; // r7
|
||||
s32 iCheck; // r1+0x8
|
||||
s32 firstTime; // r24
|
||||
s32 kill_value; // r23
|
||||
s32 memory_used; // r22
|
||||
s32 codeMemory; // r1+0x8
|
||||
s32 blockMemory; // r21
|
||||
s32* chunkMemory; // r1+0x2020
|
||||
s32* anCode; // r23
|
||||
s32 nAddress; // r1+0x201C
|
||||
struct cpu_function* pFunction; // r1+0x2018
|
||||
struct __anon_0x3DE78 aJump[1024]; // r1+0x18
|
||||
}
|
||||
|
||||
// Range: 0x8003EE04 -> 0x80068238
|
||||
static s32 cpuGetPPC(struct _CPU* pCPU, s32* pnAddress, struct cpu_function* pFunction, s32* anCode, s32* piCode,
|
||||
s32 bSlot) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r30
|
||||
// s32* pnAddress; // r18
|
||||
// struct cpu_function* pFunction; // r27
|
||||
// s32* anCode; // r31
|
||||
// s32* piCode; // r16
|
||||
// s32 bSlot; // r1+0x8C
|
||||
|
||||
// Local variables
|
||||
s32 nSize; // r1+0x88
|
||||
s32 iHack; // r1+0x8
|
||||
s32 bInterpret; // r22
|
||||
s32 iCode; // r1+0x84
|
||||
s32 iJump; // r23
|
||||
s32 nAddress; // r29
|
||||
s32 nDeltaAddress; // r21
|
||||
s32 bFlag; // r15
|
||||
s32 nAddressJump; // r6
|
||||
s32 nOffset; // r25
|
||||
u32 nOpcode; // r28
|
||||
u32 nOpcodePrev; // r23
|
||||
u32 nOpcodeNext; // r24
|
||||
u32* pnOpcode; // r1+0x7C
|
||||
s32 prev; // r19
|
||||
s32 iRegisterA; // r1+0x8
|
||||
s32 iRegisterB; // r9
|
||||
s32 iRegisterC; // r7
|
||||
s32 nTemp1; // r1+0x8
|
||||
s32 nTemp2; // r1+0x8
|
||||
s32 nTemp3; // r3
|
||||
s32 update; // r14
|
||||
s32 iUpdate; // r1+0x90
|
||||
s32 nTarget; // r3
|
||||
|
||||
// References
|
||||
// -> s32 ganMapGPR[32];
|
||||
// -> static s32 cpuCompile_SDC_function;
|
||||
// -> static s32 cpuCompile_SW_function;
|
||||
// -> static s32 cpuCompile_LDC_function;
|
||||
// -> static s32 cpuCompile_LW_function;
|
||||
// -> struct __anon_0x3DB14* gpSystem;
|
||||
// -> static s32 cpuCompile_SH_function;
|
||||
// -> static s32 cpuCompile_SB_function;
|
||||
// -> static s32 cpuCompile_LWR_function;
|
||||
// -> static s32 cpuCompile_LHU_function;
|
||||
// -> static s32 cpuCompile_LBU_function;
|
||||
// -> static s32 cpuCompile_LWL_function;
|
||||
// -> static s32 cpuCompile_LH_function;
|
||||
// -> static s32 cpuCompile_LB_function;
|
||||
// -> static s32 cpuCompile_L_CVT_SD_function;
|
||||
// -> static s32 cpuCompile_W_CVT_SD_function;
|
||||
// -> static s32 cpuCompile_TRUNC_W_function;
|
||||
// -> static s32 cpuCompile_FLOOR_W_function;
|
||||
// -> static s32 cpuCompile_CEIL_W_function;
|
||||
// -> static s32 cpuCompile_ROUND_W_function;
|
||||
// -> static s32 cpuCompile_D_SQRT_function;
|
||||
// -> static s32 cpuCompile_S_SQRT_function;
|
||||
// -> static s32 cpuCompile_DSUBU_function;
|
||||
// -> static s32 cpuCompile_DSUB_function;
|
||||
// -> static s32 cpuCompile_DADDU_function;
|
||||
// -> static s32 cpuCompile_DADD_function;
|
||||
// -> static s32 cpuCompile_DDIVU_function;
|
||||
// -> static s32 cpuCompile_DDIV_function;
|
||||
// -> static s32 cpuCompile_DMULTU_function;
|
||||
// -> static s32 cpuCompile_DMULT_function;
|
||||
// -> static s32 cpuCompile_DSRAV_function;
|
||||
// -> static s32 cpuCompile_DSRLV_function;
|
||||
// -> static s32 cpuCompile_DSLLV_function;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuRecompileFunction(struct _CPU* pCPU, struct cpu_function* pFunction, s32 nAddressN64) {
|
||||
// Parameters
|
||||
// struct _CPU* pCPU; // r31
|
||||
// struct cpu_function* pFunction; // r1+0xC
|
||||
// s32 nAddressN64; // r5
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void cpuCompileNOP(s32* anCode, s32* iCode, s32 number) {
|
||||
// Parameters
|
||||
// s32* anCode; // r1+0x0
|
||||
// s32* iCode; // r1+0x4
|
||||
// s32 number; // r5
|
||||
}
|
||||
|
||||
// Range: 0x80068238 -> 0x80068368
|
||||
static s32 cpuCheckDelaySlot(u32 opcode) {
|
||||
// Parameters
|
||||
// u32 opcode; // r1+0x0
|
||||
|
||||
// Local variables
|
||||
s32 flag; // r5
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 cpuFindBranchOffset(struct cpu_function* pFunction, s32* pnOffset, s32 nAddress, s32* anCode) {
|
||||
// Parameters
|
||||
// struct cpu_function* pFunction; // r1+0x4
|
||||
// s32* pnOffset; // r1+0x8
|
||||
// s32 nAddress; // r1+0xC
|
||||
// s32* anCode; // r1+0x10
|
||||
|
||||
// Local variables
|
||||
s32 iJump; // r8
|
||||
}
|
||||
|
||||
+1162
-721
File diff suppressed because it is too large
Load Diff
+682
-735
File diff suppressed because it is too large
Load Diff
+214
-177
@@ -1,177 +1,214 @@
|
||||
// Local to compilation unit
|
||||
static int rspParseGBI_F3DEX2(__anon_0x5845E *pRSP, unsigned long long **ppnGBI, int *pbDone)
|
||||
{
|
||||
int iVertex;
|
||||
int bDone;
|
||||
float matrix[4][4];
|
||||
__anon_0x5EBE0 primitive;
|
||||
unsigned long long *pnGBI;
|
||||
unsigned int nCommandLo;
|
||||
unsigned int nCommandHi;
|
||||
__anon_0x5A89F *pFrame;
|
||||
unsigned int nData;
|
||||
unsigned int nSize;
|
||||
unsigned int nMove;
|
||||
unsigned int nData;
|
||||
unsigned int nSize;
|
||||
unsigned int nMove;
|
||||
unsigned int nValue;
|
||||
__anon_0x575BD *pTask;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
int nLength;
|
||||
int nOffset;
|
||||
int nId;
|
||||
int nFlag;
|
||||
int nAddress;
|
||||
void *pData;
|
||||
unsigned short *pnData16;
|
||||
signed short nFogStart;
|
||||
signed short nFogEnd;
|
||||
int nDelta;
|
||||
int nStart;
|
||||
char *pLight;
|
||||
unsigned int iIndex;
|
||||
int bFound;
|
||||
void *pData;
|
||||
int nAddress;
|
||||
void *pData;
|
||||
int iLight;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
unsigned int nSid;
|
||||
int nLight;
|
||||
int nAddress;
|
||||
int nMode;
|
||||
int nAddress;
|
||||
int nSet;
|
||||
int nClr;
|
||||
int iMatrix;
|
||||
int nCount;
|
||||
int nVertices;
|
||||
int nSrcAdrs;
|
||||
int nDestAdrs;
|
||||
int iCount;
|
||||
int bFound;
|
||||
unsigned int iVtxIndex;
|
||||
__anon_0x5EC3E destVtx;
|
||||
int nAddress;
|
||||
char *pBuffer;
|
||||
int nCount;
|
||||
int iVertex0;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
int iVertex;
|
||||
int nVal;
|
||||
unsigned int nVertexStart;
|
||||
unsigned int nVertexEnd;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
__anon_0x5F2FB bg;
|
||||
__anon_0x5F2FB bg;
|
||||
char cTempAlpha;
|
||||
int nAddress;
|
||||
char cTempAlpha;
|
||||
int bPush;
|
||||
unsigned char nSid2D;
|
||||
unsigned int nDLAdrs;
|
||||
unsigned int nFlag2D;
|
||||
// References: gpSystem (0x561380)
|
||||
// References: flagBilerp (0x80135790)
|
||||
// References: scissorY1 (0x801352D6)
|
||||
// References: scissorX1 (0x801352D4)
|
||||
// References: scissorY0 (0x8013578E)
|
||||
// References: scissorX0 (0x8013578C)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspGeometryMode(__anon_0x5845E *pRSP, int nSet, int nClr)
|
||||
{
|
||||
int nMode;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspParseGBI_F3DEX1(__anon_0x5845E *pRSP, unsigned long long **ppnGBI, int *pbDone)
|
||||
{
|
||||
float matrix[4][4];
|
||||
__anon_0x5EBE0 primitive;
|
||||
unsigned int iVertex;
|
||||
unsigned int bDone;
|
||||
unsigned long long *pnGBI;
|
||||
unsigned int nCommandLo;
|
||||
unsigned int nCommandHi;
|
||||
__anon_0x5A89F *pFrame;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
int bPush;
|
||||
unsigned char nSid2D;
|
||||
unsigned int nDLAdrs;
|
||||
unsigned int nFlag2D;
|
||||
__anon_0x5F2FB bg;
|
||||
int nAddress;
|
||||
int nMode;
|
||||
int nAddress;
|
||||
int nMode;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
void *pData;
|
||||
int nAddress;
|
||||
void *pData;
|
||||
int nAddress;
|
||||
void *pData;
|
||||
int nAddress;
|
||||
char *pData;
|
||||
int iLight;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
void *pBuffer;
|
||||
int nCount;
|
||||
int iVertex0;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
int nAddress;
|
||||
unsigned int nVertexStart;
|
||||
unsigned int nVertexEnd;
|
||||
int nWhere;
|
||||
int nData1;
|
||||
int nData2;
|
||||
int iRow;
|
||||
int iCol;
|
||||
unsigned int nSid;
|
||||
int nLight;
|
||||
unsigned int nData;
|
||||
unsigned int nSize;
|
||||
unsigned int nMove;
|
||||
unsigned int nData;
|
||||
unsigned int nSize;
|
||||
unsigned int nMove;
|
||||
unsigned int nValue;
|
||||
__anon_0x575BD *pTask;
|
||||
int nAddress;
|
||||
int iVertex;
|
||||
int nVal;
|
||||
// References: flagBilerp (0x80135790)
|
||||
// References: scissorY1 (0x801352D6)
|
||||
// References: scissorX1 (0x801352D4)
|
||||
// References: scissorY0 (0x8013578E)
|
||||
// References: scissorX0 (0x8013578C)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspSetGeometryMode1(__anon_0x5845E *pRSP, int nMode)
|
||||
{
|
||||
int nModeFrame;
|
||||
}
|
||||
|
||||
int MulMatrices(float *aOutMatrix[4], float *aLeftMatrix[4], float *aRightMatrix[4])
|
||||
{
|
||||
int i;
|
||||
int j;
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\_gspF3DEX.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C89
|
||||
Code range: 0x80074454 -> 0x80077850
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
// Range: 0x80074454 -> 0x80076024
|
||||
static s32 rspParseGBI_F3DEX2(struct __anon_0x5845E* pRSP, u64** ppnGBI, s32* pbDone) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r31
|
||||
// u64** ppnGBI; // r27
|
||||
// s32* pbDone; // r25
|
||||
|
||||
// Local variables
|
||||
s32 iVertex; // r4
|
||||
s32 bDone; // r25
|
||||
float matrix[4][4]; // r1+0x410
|
||||
struct __anon_0x5EBE0 primitive; // r1+0x10C
|
||||
u64* pnGBI; // r28
|
||||
u32 nCommandLo; // r6
|
||||
u32 nCommandHi; // r1+0x8
|
||||
struct __anon_0x5A89F* pFrame; // r30
|
||||
u32 nData; // r1+0x8
|
||||
u32 nSize; // r6
|
||||
u32 nMove; // r5
|
||||
u32 nData; // r1+0x8
|
||||
u32 nSize; // r6
|
||||
u32 nMove; // r5
|
||||
u32 nValue; // r1+0x8
|
||||
struct __anon_0x575BD* pTask; // r4
|
||||
s32 nAddress; // r5
|
||||
s32 nAddress; // r5
|
||||
s32 nLength; // r27
|
||||
s32 nOffset; // r28
|
||||
s32 nId; // r25
|
||||
s32 nFlag; // r26
|
||||
s32 nAddress; // r29
|
||||
void* pData; // r1+0x104
|
||||
u16* pnData16; // r3
|
||||
s16 nFogStart; // r1+0x8
|
||||
s16 nFogEnd; // r1+0x8
|
||||
s32 nDelta; // r3
|
||||
s32 nStart; // r4
|
||||
char* pLight; // r1+0x100
|
||||
u32 iIndex; // r25
|
||||
s32 bFound; // r5
|
||||
void* pData; // r1+0xFC
|
||||
s32 nAddress; // r5
|
||||
void* pData; // r1+0xF4
|
||||
s32 iLight; // r25
|
||||
s32 nAddress; // r5
|
||||
s32 nAddress; // r25
|
||||
u32 nSid; // r1+0x8
|
||||
s32 nLight; // r1+0x8
|
||||
s32 nAddress; // r5
|
||||
s32 nMode; // r25
|
||||
s32 nAddress; // r27
|
||||
s32 nSet; // r4
|
||||
s32 nClr; // r5
|
||||
s32 iMatrix; // r25
|
||||
s32 nCount; // r26
|
||||
s32 nVertices; // r26
|
||||
s32 nSrcAdrs; // r1+0x8
|
||||
s32 nDestAdrs; // r27
|
||||
s32 iCount; // r28
|
||||
s32 bFound; // r9
|
||||
u32 iVtxIndex; // r10
|
||||
struct __anon_0x5EC3E destVtx; // r1+0x9C
|
||||
s32 nAddress; // r5
|
||||
char* pBuffer; // r1+0x94
|
||||
s32 nCount; // r25
|
||||
s32 iVertex0; // r26
|
||||
s32 nAddress; // r5
|
||||
s32 nAddress; // r5
|
||||
s32 iVertex; // r4
|
||||
s32 nVal; // r1+0x8
|
||||
u32 nVertexStart; // r4
|
||||
u32 nVertexEnd; // r5
|
||||
s32 nAddress; // r5
|
||||
s32 nAddress; // r25
|
||||
s32 nAddress; // r25
|
||||
s32 nAddress; // r25
|
||||
s32 nAddress; // r25
|
||||
union __anon_0x5F2FB bg; // r1+0x68
|
||||
union __anon_0x5F2FB bg; // r1+0x40
|
||||
char cTempAlpha; // r25
|
||||
s32 nAddress; // r5
|
||||
char cTempAlpha; // r25
|
||||
s32 bPush; // r27
|
||||
u8 nSid2D; // r1+0x8
|
||||
u32 nDLAdrs; // r6
|
||||
u32 nFlag2D; // r1+0x8
|
||||
|
||||
// References
|
||||
// -> struct __anon_0x5E98D* gpSystem;
|
||||
// -> static u8 flagBilerp;
|
||||
// -> static u16 scissorY1;
|
||||
// -> static u16 scissorX1;
|
||||
// -> static u16 scissorY0;
|
||||
// -> static u16 scissorX0;
|
||||
}
|
||||
|
||||
// Range: 0x80076024 -> 0x8007610C
|
||||
static s32 rspGeometryMode(struct __anon_0x5845E* pRSP, s32 nSet, s32 nClr) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// s32 nSet; // r1+0xC
|
||||
// s32 nClr; // r1+0x10
|
||||
|
||||
// Local variables
|
||||
s32 nMode; // r6
|
||||
}
|
||||
|
||||
// Range: 0x8007610C -> 0x80077790
|
||||
static s32 rspParseGBI_F3DEX1(struct __anon_0x5845E* pRSP, u64** ppnGBI, s32* pbDone) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r31
|
||||
// u64** ppnGBI; // r27
|
||||
// s32* pbDone; // r24
|
||||
|
||||
// Local variables
|
||||
float matrix[4][4]; // r1+0x3B0
|
||||
struct __anon_0x5EBE0 primitive; // r1+0xAC
|
||||
u32 iVertex; // r4
|
||||
u32 bDone; // r24
|
||||
u64* pnGBI; // r28
|
||||
u32 nCommandLo; // r6
|
||||
u32 nCommandHi; // r7
|
||||
struct __anon_0x5A89F* pFrame; // r30
|
||||
s32 nAddress; // r5
|
||||
s32 nAddress; // r24
|
||||
s32 nAddress; // r24
|
||||
s32 nAddress; // r24
|
||||
s32 bPush; // r24
|
||||
u8 nSid2D; // r1+0x8
|
||||
u32 nDLAdrs; // r7
|
||||
u32 nFlag2D; // r1+0x8
|
||||
union __anon_0x5F2FB bg; // r1+0x80
|
||||
s32 nAddress; // r4
|
||||
s32 nMode; // r24
|
||||
s32 nAddress; // r26
|
||||
s32 nMode; // r1+0x78
|
||||
s32 nAddress; // r5
|
||||
s32 nAddress; // r5
|
||||
void* pData; // r1+0x74
|
||||
s32 nAddress; // r5
|
||||
void* pData; // r1+0x6C
|
||||
s32 nAddress; // r5
|
||||
void* pData; // r1+0x68
|
||||
s32 nAddress; // r5
|
||||
char* pData; // r1+0x64
|
||||
s32 iLight; // r24
|
||||
s32 nAddress; // r5
|
||||
s32 nAddress; // r24
|
||||
s32 nAddress; // r5
|
||||
void* pBuffer; // r1+0x60
|
||||
s32 nCount; // r6
|
||||
s32 iVertex0; // r5
|
||||
s32 nAddress; // r5
|
||||
s32 nAddress; // r5
|
||||
s32 nAddress; // r5
|
||||
u32 nVertexStart; // r4
|
||||
u32 nVertexEnd; // r5
|
||||
s32 nWhere; // r1+0x8
|
||||
s32 nData1; // r8
|
||||
s32 nData2; // r1+0x8
|
||||
s32 iRow; // r3
|
||||
s32 iCol; // r4
|
||||
u32 nSid; // r1+0x8
|
||||
s32 nLight; // r1+0x8
|
||||
u32 nData; // r1+0x8
|
||||
u32 nSize; // r3
|
||||
u32 nMove; // r5
|
||||
u32 nData; // r1+0x8
|
||||
u32 nSize; // r3
|
||||
u32 nMove; // r5
|
||||
u32 nValue; // r1+0x8
|
||||
struct __anon_0x575BD* pTask; // r4
|
||||
s32 nAddress; // r5
|
||||
s32 iVertex; // r4
|
||||
s32 nVal; // r1+0x8
|
||||
|
||||
// References
|
||||
// -> static u8 flagBilerp;
|
||||
// -> static u16 scissorY1;
|
||||
// -> static u16 scissorX1;
|
||||
// -> static u16 scissorY0;
|
||||
// -> static u16 scissorX0;
|
||||
}
|
||||
|
||||
// Range: 0x80077790 -> 0x80077850
|
||||
static s32 rspSetGeometryMode1(struct __anon_0x5845E* pRSP, s32 nMode) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// s32 nMode; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
s32 nModeFrame; // r5
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 MulMatrices(float (*aOutMatrix)[4], float (*aLeftMatrix)[4], float (*aRightMatrix)[4]) {
|
||||
// Parameters
|
||||
// float (* aOutMatrix)[4]; // r3
|
||||
// float (* aLeftMatrix)[4]; // r4
|
||||
// float (* aRightMatrix)[4]; // r5
|
||||
|
||||
// Local variables
|
||||
s32 i; // r8
|
||||
s32 j; // r1+0x0
|
||||
}
|
||||
|
||||
+348
-211
@@ -1,211 +1,348 @@
|
||||
// Local to compilation unit
|
||||
static int rspParseJPEG_DecodeZ(__anon_0x5845E *pRSP, __anon_0x575BD *pTask)
|
||||
{
|
||||
int y;
|
||||
signed short *temp;
|
||||
signed short *temp2;
|
||||
unsigned long long *system_imb;
|
||||
unsigned int *infoStruct;
|
||||
int size;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspParseJPEG_EncodeZ(__anon_0x5845E *pRSP, __anon_0x575BD *pTask)
|
||||
{
|
||||
int y;
|
||||
signed short *temp;
|
||||
signed short *temp2;
|
||||
unsigned long long *system_imb;
|
||||
unsigned int *infoStruct;
|
||||
int size;
|
||||
}
|
||||
|
||||
int rspRecon420Z(__anon_0x5845E *pRSP, signed short *imgBuf)
|
||||
{
|
||||
int i;
|
||||
int j;
|
||||
int r;
|
||||
int g;
|
||||
int b;
|
||||
int y;
|
||||
int u;
|
||||
int v;
|
||||
}
|
||||
|
||||
int rspLoadColorBufferZ(int *r, int *g, int *b, signed short *imgBuf, int index);
|
||||
|
||||
int rspUndoRecon420Z(__anon_0x5845E *pRSP, signed short *imgBuf)
|
||||
{
|
||||
int i;
|
||||
int j;
|
||||
int r;
|
||||
int g;
|
||||
int b;
|
||||
int y;
|
||||
int u;
|
||||
int v;
|
||||
}
|
||||
|
||||
int rspUndoLoadColorBufferZ(int r, int g, int b, signed short *imgBuf, int index);
|
||||
|
||||
void rspUndoDCTZ(__anon_0x5845E *pRSP)
|
||||
{
|
||||
int c;
|
||||
int i;
|
||||
int j;
|
||||
int dd;
|
||||
signed short t[8][8];
|
||||
}
|
||||
|
||||
void rspUndoZigzagDataZ(__anon_0x5845E *pRSP, signed short *dataBuf)
|
||||
{
|
||||
int c;
|
||||
}
|
||||
|
||||
void rspUndoQuantizeZ(__anon_0x5845E *pRSP, signed short *dataBuf)
|
||||
{
|
||||
int c;
|
||||
int i;
|
||||
}
|
||||
|
||||
void rspZigzagDataZ(__anon_0x5845E *pRSP, signed short *dataBuf)
|
||||
{
|
||||
int c;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static void rspQuantizeZ(__anon_0x5845E *pRSP, signed short *dataBuf)
|
||||
{
|
||||
int c;
|
||||
int i;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static void rspDCTZ(__anon_0x5845E *pRSP)
|
||||
{
|
||||
int c;
|
||||
int i;
|
||||
int j;
|
||||
int dd;
|
||||
signed short t[8][8];
|
||||
}
|
||||
|
||||
int rspDestroyJPEGArraysZ();
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspCreateJPEGArraysZ(__anon_0x5845E *pRSP, int qYAddress, int qCbAddress, int qCrAddress);
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspParseJPEG_Decode(__anon_0x5845E *pRSP, __anon_0x575BD *pTask)
|
||||
{
|
||||
int i;
|
||||
int y;
|
||||
unsigned char *temp;
|
||||
unsigned char *temp2;
|
||||
unsigned long long *system_imb;
|
||||
int size;
|
||||
int scale;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspParseJPEG_Encode(__anon_0x5845E *pRSP, __anon_0x575BD *pTask)
|
||||
{
|
||||
unsigned char *temp;
|
||||
unsigned char *temp2;
|
||||
int i;
|
||||
int j;
|
||||
int x;
|
||||
int y;
|
||||
unsigned char *system_imb;
|
||||
unsigned char *system_cfb;
|
||||
int scale;
|
||||
}
|
||||
|
||||
void rspFormatYUV(__anon_0x5845E *pRSP, char *imgBuf)
|
||||
{
|
||||
int i;
|
||||
int j;
|
||||
}
|
||||
|
||||
void rspUndoYUVtoDCTBuf(__anon_0x5845E *pRSP)
|
||||
{
|
||||
int i;
|
||||
int j;
|
||||
}
|
||||
|
||||
void rspUndoDCT(__anon_0x5845E *pRSP)
|
||||
{
|
||||
int c;
|
||||
int i;
|
||||
int j;
|
||||
int dd;
|
||||
signed short t[8][8];
|
||||
}
|
||||
|
||||
void rspUndoQuantize(__anon_0x5845E *pRSP, int scale)
|
||||
{
|
||||
int c;
|
||||
int i;
|
||||
int j;
|
||||
signed short q;
|
||||
signed short s;
|
||||
}
|
||||
|
||||
void rspUndoZigzagData(__anon_0x5845E *pRSP, unsigned char **databuf, int n, int *preDc)
|
||||
{
|
||||
signed short Dc;
|
||||
signed short Ac;
|
||||
int i;
|
||||
int z;
|
||||
}
|
||||
|
||||
void rspZigzagData(__anon_0x5845E *pRSP, unsigned char **databuf, int n, int *preDc)
|
||||
{
|
||||
signed short Ac;
|
||||
int i;
|
||||
int z;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static void rspQuantize(__anon_0x5845E *pRSP, int scale)
|
||||
{
|
||||
int c;
|
||||
int i;
|
||||
int j;
|
||||
signed short q;
|
||||
signed short s;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static void rspDCT(__anon_0x5845E *pRSP)
|
||||
{
|
||||
int c;
|
||||
int i;
|
||||
int j;
|
||||
int dd;
|
||||
signed short t[8][8];
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static void rspYUVtoDCTBuf(__anon_0x5845E *pRSP)
|
||||
{
|
||||
int i;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static void rspConvertRGBAtoYUV(__anon_0x5845E *pRSP)
|
||||
{
|
||||
int i;
|
||||
int j;
|
||||
long Y;
|
||||
long U;
|
||||
long V;
|
||||
}
|
||||
|
||||
void rspConvertBufferToRGBA(unsigned char *buf, __anon_0x58360 *rgba);
|
||||
|
||||
int rspDestroyJPEGArrays();
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspCreateJPEGArrays(__anon_0x5845E *pRSP);
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\_gspJPEG.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C89
|
||||
Code range: 0x8007AC6C -> 0x80080AA4
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
// Range: 0x8007AC6C -> 0x8007AD68
|
||||
static s32 rspParseJPEG_DecodeZ(struct __anon_0x5845E* pRSP, struct __anon_0x575BD* pTask) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r28
|
||||
// struct __anon_0x575BD* pTask; // r4
|
||||
|
||||
// Local variables
|
||||
s32 y; // r31
|
||||
s16* temp; // r1+0x8
|
||||
s16* temp2; // r30
|
||||
u64* system_imb; // r1+0x20
|
||||
u32* infoStruct; // r1+0x1C
|
||||
s32 size; // r29
|
||||
}
|
||||
|
||||
// Range: 0x8007AD68 -> 0x8007AE64
|
||||
static s32 rspParseJPEG_EncodeZ(struct __anon_0x5845E* pRSP, struct __anon_0x575BD* pTask) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r28
|
||||
// struct __anon_0x575BD* pTask; // r4
|
||||
|
||||
// Local variables
|
||||
s32 y; // r31
|
||||
s16* temp; // r1+0x8
|
||||
s16* temp2; // r30
|
||||
u64* system_imb; // r1+0x20
|
||||
u32* infoStruct; // r1+0x1C
|
||||
s32 size; // r29
|
||||
}
|
||||
|
||||
// Range: 0x8007AE64 -> 0x8007B244
|
||||
s32 rspRecon420Z(struct __anon_0x5845E* pRSP, s16* imgBuf) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// s16* imgBuf; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
s32 i; // r1+0x10
|
||||
s32 j; // r26
|
||||
s32 r; // r10
|
||||
s32 g; // r7
|
||||
s32 b; // r11
|
||||
s32 y; // r6
|
||||
s32 u; // r9
|
||||
s32 v; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 rspLoadColorBufferZ(s32* r, s32* g, s32* b, s16* imgBuf, s32 index) {
|
||||
// Parameters
|
||||
// s32* r; // r1+0x4
|
||||
// s32* g; // r1+0x8
|
||||
// s32* b; // r1+0xC
|
||||
// s16* imgBuf; // r1+0x10
|
||||
// s32 index; // r1+0x14
|
||||
}
|
||||
|
||||
// Range: 0x8007B244 -> 0x8007B64C
|
||||
s32 rspUndoRecon420Z(struct __anon_0x5845E* pRSP, s16* imgBuf) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r30
|
||||
// s16* imgBuf; // r29
|
||||
|
||||
// Local variables
|
||||
s32 i; // r1+0x8
|
||||
s32 j; // r24
|
||||
s32 r; // r1+0x8
|
||||
s32 g; // r1+0x8
|
||||
s32 b; // r1+0x8
|
||||
s32 y; // r7
|
||||
s32 u; // r5
|
||||
s32 v; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8007B64C -> 0x8007B6E0
|
||||
s32 rspUndoLoadColorBufferZ(s32 r, s32 g, s32 b, s16* imgBuf, s32 index) {
|
||||
// Parameters
|
||||
// s32 r; // r3
|
||||
// s32 g; // r1+0x8
|
||||
// s32 b; // r4
|
||||
// s16* imgBuf; // r1+0x10
|
||||
// s32 index; // r1+0x14
|
||||
}
|
||||
|
||||
// Range: 0x8007B6E0 -> 0x8007B9B0
|
||||
void rspUndoDCTZ(struct __anon_0x5845E* pRSP) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
s32 c; // r1+0xA4
|
||||
s32 i; // r1+0xA0
|
||||
s32 j; // r5
|
||||
s32 dd; // r6
|
||||
s16 t[8][8]; // r1+0x1C
|
||||
}
|
||||
|
||||
// Range: 0x8007B9B0 -> 0x8007BDD8
|
||||
void rspUndoZigzagDataZ(struct __anon_0x5845E* pRSP, s16* dataBuf) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// s16* dataBuf; // r4
|
||||
|
||||
// Local variables
|
||||
s32 c; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8007BDD8 -> 0x8007C3A4
|
||||
void rspUndoQuantizeZ(struct __anon_0x5845E* pRSP, s16* dataBuf) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// s16* dataBuf; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
s32 c; // r12
|
||||
s32 i; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8007C3A4 -> 0x8007C8CC
|
||||
void rspZigzagDataZ(struct __anon_0x5845E* pRSP, s16* dataBuf) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// s16* dataBuf; // r4
|
||||
|
||||
// Local variables
|
||||
s32 c; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8007C8CC -> 0x8007CEF8
|
||||
static void rspQuantizeZ(struct __anon_0x5845E* pRSP, s16* dataBuf) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// s16* dataBuf; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
s32 c; // r12
|
||||
s32 i; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8007CEF8 -> 0x8007D1C8
|
||||
static void rspDCTZ(struct __anon_0x5845E* pRSP) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
s32 c; // r1+0xA4
|
||||
s32 i; // r1+0xA0
|
||||
s32 j; // r1+0x8
|
||||
s32 dd; // r6
|
||||
s16 t[8][8]; // r1+0x1C
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 rspDestroyJPEGArraysZ() {}
|
||||
|
||||
// Range: 0x8007D1C8 -> 0x8007D4C0
|
||||
static s32 rspCreateJPEGArraysZ(struct __anon_0x5845E* pRSP, s32 qYAddress, s32 qCbAddress, s32 qCrAddress) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r24
|
||||
// s32 qYAddress; // r4
|
||||
// s32 qCbAddress; // r25
|
||||
// s32 qCrAddress; // r26
|
||||
}
|
||||
|
||||
// Range: 0x8007D4C0 -> 0x8007DD0C
|
||||
static s32 rspParseJPEG_Decode(struct __anon_0x5845E* pRSP, struct __anon_0x575BD* pTask) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r30
|
||||
// struct __anon_0x575BD* pTask; // r20
|
||||
|
||||
// Local variables
|
||||
s32 i; // r3
|
||||
s32 y; // r25
|
||||
u8* temp; // r31
|
||||
u8* temp2; // r26
|
||||
u64* system_imb; // r1+0x1C
|
||||
s32 size; // r21
|
||||
s32 scale; // r22
|
||||
}
|
||||
|
||||
// Range: 0x8007DD0C -> 0x8007E744
|
||||
static s32 rspParseJPEG_Encode(struct __anon_0x5845E* pRSP, struct __anon_0x575BD* pTask) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r19
|
||||
// struct __anon_0x575BD* pTask; // r16
|
||||
|
||||
// Local variables
|
||||
u8* temp; // r24
|
||||
u8* temp2; // r23
|
||||
s32 i; // r10
|
||||
s32 j; // r11
|
||||
s32 x; // r22
|
||||
s32 y; // r21
|
||||
u8* system_imb; // r1+0x30
|
||||
u8* system_cfb; // r1+0x2C
|
||||
s32 scale; // r20
|
||||
}
|
||||
|
||||
// Range: 0x8007E744 -> 0x8007E8F4
|
||||
void rspFormatYUV(struct __anon_0x5845E* pRSP, char* imgBuf) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// char* imgBuf; // r4
|
||||
|
||||
// Local variables
|
||||
s32 i; // r10
|
||||
s32 j; // r11
|
||||
}
|
||||
|
||||
// Range: 0x8007E8F4 -> 0x8007F07C
|
||||
void rspUndoYUVtoDCTBuf(struct __anon_0x5845E* pRSP) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
s32 i; // r1+0x8
|
||||
s32 j; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8007F07C -> 0x8007F368
|
||||
void rspUndoDCT(struct __anon_0x5845E* pRSP) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
s32 c; // r1+0xA4
|
||||
s32 i; // r1+0xA0
|
||||
s32 j; // r5
|
||||
s32 dd; // r6
|
||||
s16 t[8][8]; // r1+0x1C
|
||||
}
|
||||
|
||||
// Range: 0x8007F368 -> 0x8007F4EC
|
||||
void rspUndoQuantize(struct __anon_0x5845E* pRSP, s32 scale) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// s32 scale; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
s32 c; // r29
|
||||
s32 i; // r28
|
||||
s32 j; // r27
|
||||
s16 q; // r6
|
||||
s16 s; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void rspUndoZigzagData(struct __anon_0x5845E* pRSP, u8** databuf, s32 n, s32* preDc) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// u8** databuf; // r1+0xC
|
||||
// s32 n; // r1+0x10
|
||||
// s32* preDc; // r1+0x14
|
||||
|
||||
// Local variables
|
||||
s16 Dc; // r12
|
||||
s16 Ac; // r12
|
||||
s32 i; // r7
|
||||
s32 z; // r31
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void rspZigzagData(struct __anon_0x5845E* pRSP, u8** databuf, s32 n, s32* preDc) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// u8** databuf; // r1+0xC
|
||||
// s32 n; // r1+0x10
|
||||
// s32* preDc; // r1+0x14
|
||||
|
||||
// Local variables
|
||||
s16 Ac; // r30
|
||||
s32 i; // r6
|
||||
s32 z; // r7
|
||||
}
|
||||
|
||||
// Range: 0x8007F4EC -> 0x8007F668
|
||||
static void rspQuantize(struct __anon_0x5845E* pRSP, s32 scale) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// s32 scale; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
s32 c; // r29
|
||||
s32 i; // r28
|
||||
s32 j; // r27
|
||||
s16 q; // r6
|
||||
s16 s; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8007F668 -> 0x8007F938
|
||||
static void rspDCT(struct __anon_0x5845E* pRSP) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
s32 c; // r1+0xA4
|
||||
s32 i; // r1+0xA0
|
||||
s32 j; // r1+0x8
|
||||
s32 dd; // r6
|
||||
s16 t[8][8]; // r1+0x1C
|
||||
}
|
||||
|
||||
// Range: 0x8007F938 -> 0x80080028
|
||||
static void rspYUVtoDCTBuf(struct __anon_0x5845E* pRSP) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x0
|
||||
|
||||
// Local variables
|
||||
s32 i; // r1+0x0
|
||||
}
|
||||
|
||||
// Range: 0x80080028 -> 0x800801C0
|
||||
static void rspConvertRGBAtoYUV(struct __anon_0x5845E* pRSP) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
s32 i; // r30
|
||||
s32 j; // r1+0x8
|
||||
s32 Y; // r20
|
||||
s32 U; // r20
|
||||
s32 V; // r12
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void rspConvertBufferToRGBA(u8* buf, struct __anon_0x58360* rgba) {
|
||||
// Parameters
|
||||
// u8* buf; // r1+0x4
|
||||
// struct __anon_0x58360* rgba; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 rspDestroyJPEGArrays() {}
|
||||
|
||||
// Range: 0x800801C0 -> 0x80080AA4
|
||||
static s32 rspCreateJPEGArrays(struct __anon_0x5845E* pRSP) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
}
|
||||
|
||||
+507
-303
@@ -1,303 +1,507 @@
|
||||
// Local to compilation unit
|
||||
static int rspSetupS2DEX(__anon_0x5845E *pRSP)
|
||||
{
|
||||
float fL;
|
||||
float fR;
|
||||
float fB;
|
||||
float fT;
|
||||
__anon_0x5A89F *pFrame;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspObjMatrix(__anon_0x5845E *pRSP, int nAddress)
|
||||
{
|
||||
unsigned int *pnData32;
|
||||
unsigned short *pnData16;
|
||||
unsigned char *pObjMtx;
|
||||
unsigned short nBaseScaleX;
|
||||
unsigned short nBaseScaleY;
|
||||
int nA;
|
||||
int nB;
|
||||
int nC;
|
||||
int nD;
|
||||
signed short nY;
|
||||
}
|
||||
|
||||
int rspObjSubMatrix(__anon_0x5845E *pRSP, int nAddress)
|
||||
{
|
||||
unsigned short *pnData16;
|
||||
unsigned char *pObjSubMtx;
|
||||
unsigned short nBaseScaleX;
|
||||
unsigned short nBaseScaleY;
|
||||
signed short nY;
|
||||
}
|
||||
|
||||
int rspBgRectCopy(__anon_0x5845E *pRSP, __anon_0x5A89F *pFrame, int nAddress)
|
||||
{
|
||||
__anon_0x5F2FB bg;
|
||||
__anon_0x5F2FB bgScale;
|
||||
unsigned int nOldMode1;
|
||||
unsigned int nOldMode2;
|
||||
// References: flagBilerp (0x80135790)
|
||||
// References: scissorY1 (0x801352D6)
|
||||
// References: scissorX1 (0x801352D4)
|
||||
// References: scissorY0 (0x8013578E)
|
||||
// References: scissorX0 (0x8013578C)
|
||||
}
|
||||
|
||||
int rspObjLoadTxSprite(__anon_0x5845E *pRSP, __anon_0x5A89F *pFrame, int nAddress);
|
||||
|
||||
int rspObjLoadTxRectR(__anon_0x5845E *pRSP, __anon_0x5A89F *pFrame, int nAddress);
|
||||
|
||||
int rspObjLoadTxRect(__anon_0x5845E *pRSP, __anon_0x5A89F *pFrame, int nAddress);
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspObjRectangleR(__anon_0x5845E *pRSP, __anon_0x5A89F *pFrame, int nAddress)
|
||||
{
|
||||
unsigned short nSizLineBytes;
|
||||
float fLeft;
|
||||
float fRight;
|
||||
float fTop;
|
||||
float fBottom;
|
||||
float fTexRight;
|
||||
float fTexBottom;
|
||||
float fTexLeft;
|
||||
float fTexTop;
|
||||
int nTexTrim2;
|
||||
int nTexTrim5;
|
||||
float fSpriteWidth;
|
||||
float fSpriteHeight;
|
||||
int nClampSetting;
|
||||
__anon_0x5F63B objSprite;
|
||||
__anon_0x5A2EC *pTile;
|
||||
__anon_0x5EBE0 primitive;
|
||||
float mtxTransL[3][4];
|
||||
float mtxTransW[3][4];
|
||||
float mtxScale[3][4];
|
||||
float mtxTemp[3][4];
|
||||
float mtxOut[3][4];
|
||||
__anon_0x5F6E9 vecIn;
|
||||
__anon_0x5F6E9 vecOut;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspObjSprite(__anon_0x5845E *pRSP, __anon_0x5A89F *pFrame, int nAddress)
|
||||
{
|
||||
unsigned short nSizLineBytes;
|
||||
float fLeft;
|
||||
float fRight;
|
||||
float fTop;
|
||||
float fBottom;
|
||||
float fTexRight;
|
||||
float fTexBottom;
|
||||
float fTexLeft;
|
||||
float fTexTop;
|
||||
float fScaleX;
|
||||
float fScaleY;
|
||||
float fSpriteWidth;
|
||||
float fSpriteHeight;
|
||||
int nTexTrim2;
|
||||
int nTexTrim5;
|
||||
int nClampSetting;
|
||||
__anon_0x5F63B objSprite;
|
||||
__anon_0x5A2EC *pTile;
|
||||
__anon_0x5EBE0 primitive;
|
||||
float mtxTransL[3][4];
|
||||
float mtxTransW[3][4];
|
||||
float mtxScale[3][4];
|
||||
float mtxTemp[3][4];
|
||||
float mtxOut[3][4];
|
||||
__anon_0x5F6E9 vecIn;
|
||||
__anon_0x5F6E9 vecOut;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspObjRectangle(__anon_0x5845E *pRSP, __anon_0x5A89F *pFrame, int nAddress)
|
||||
{
|
||||
unsigned short nSizLineBytes;
|
||||
float fDeltaS;
|
||||
float fDeltaT;
|
||||
__anon_0x5F63B objSprite;
|
||||
__anon_0x5A2EC *pTile;
|
||||
__anon_0x5F759 primitive;
|
||||
int nClampSetting;
|
||||
int nTexTrim2;
|
||||
int nTexTrim5;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspObjLoadTxtr(__anon_0x5845E *pRSP, __anon_0x5A89F *pFrame, int nAddress)
|
||||
{
|
||||
unsigned int nSizDefine;
|
||||
unsigned int nLoadType;
|
||||
int nAddr;
|
||||
__anon_0x5A2EC *pTile;
|
||||
__anon_0x59558 *pBuffer;
|
||||
__anon_0x5FC1B objTxtr;
|
||||
}
|
||||
|
||||
int rspFillObjTxtr(__anon_0x5845E *pRSP, int nAddress, __anon_0x5FC1B *pTxtr, unsigned int *pLoadType)
|
||||
{
|
||||
unsigned int *pnData32;
|
||||
unsigned short *pnData16;
|
||||
unsigned char *pTxtrBlock;
|
||||
unsigned int nLoadType;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int guS2DEmuBgRect1Cyc(__anon_0x5845E *pRSP, __anon_0x5A89F *pFrame, __anon_0x5F2FB *pBG)
|
||||
{
|
||||
signed short frameX0;
|
||||
signed short frameX1;
|
||||
signed short framePtrY0;
|
||||
signed short frameRemain;
|
||||
signed short imageX0;
|
||||
signed short imageY0;
|
||||
signed short imageSliceW;
|
||||
signed short imageW;
|
||||
int imageYorig;
|
||||
signed short scaleW;
|
||||
signed short scaleH;
|
||||
signed short imageSrcW;
|
||||
signed short imageSrcH;
|
||||
signed short imageSliceLines;
|
||||
int frameSliceLines;
|
||||
int frameSliceCount;
|
||||
unsigned short imageS;
|
||||
unsigned short imageT;
|
||||
unsigned int imagePtr;
|
||||
signed short imageISliceL0;
|
||||
signed short imageIY0;
|
||||
int frameLSliceL0;
|
||||
signed short pixX0;
|
||||
signed short pixY0;
|
||||
signed short pixX1;
|
||||
signed short pixY1;
|
||||
signed short frameY0;
|
||||
signed short frameW;
|
||||
signed short frameH;
|
||||
int frameWmax;
|
||||
int frameHmax;
|
||||
signed short tmemSize;
|
||||
signed short tmemMask;
|
||||
signed short tmemShift;
|
||||
int imageNumSlice;
|
||||
int imageSliceWmax;
|
||||
int imageLYoffset;
|
||||
int frameLYoffset;
|
||||
int imageLHidden;
|
||||
int frameLHidden;
|
||||
int frameLYslice;
|
||||
signed short imageRemain;
|
||||
signed short imageSliceH;
|
||||
signed short frameSliceH;
|
||||
__anon_0x5F759 primitive;
|
||||
signed short nT;
|
||||
signed short framePtrY1;
|
||||
// References: flagBilerp (0x80135790)
|
||||
// References: tmemSrcLines (0x801357A8)
|
||||
// References: imageSrcWsize (0x8013579E)
|
||||
// References: imageTop (0x801357A4)
|
||||
// References: imagePtrX0 (0x801357A2)
|
||||
// References: tmemSliceWmax (0x8013579C)
|
||||
// References: rdpSetTile_w0 (0x80135798)
|
||||
// References: rdpSetTimg_w0 (0x80135794)
|
||||
// References: TMEMSHIFT$3465 (0x801352E0)
|
||||
// References: TMEMMASK$3464 (0x801352D8)
|
||||
// References: TMEMSIZE$3463 (0x70E20E80)
|
||||
// References: flagSplit (0x801357A0)
|
||||
// References: scissorY1 (0x801352D6)
|
||||
// References: scissorX1 (0x801352D4)
|
||||
// References: scissorY0 (0x8013578E)
|
||||
// References: scissorX0 (0x8013578C)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int tmemLoad(__anon_0x5A89F *pFrame, __anon_0x5845E *pRSP, unsigned int *imagePtr, signed short *imageRemain, signed short drawLines, signed short flagBilerp)
|
||||
{
|
||||
signed short loadLines;
|
||||
signed short iLoadable;
|
||||
signed short SubSliceL2;
|
||||
signed short SubSliceD2;
|
||||
signed short SubSliceY2;
|
||||
unsigned int imageTopSeg;
|
||||
unsigned int imagePtr2;
|
||||
unsigned int imagePtr1A;
|
||||
unsigned int imagePtr1B;
|
||||
signed short SubSliceY1;
|
||||
signed short SubSliceL1;
|
||||
signed short tmemSH_A;
|
||||
signed short tmemSH_B;
|
||||
// References: imageSrcWsize (0x8013579E)
|
||||
// References: imageTop (0x801357A4)
|
||||
// References: imagePtrX0 (0x801357A2)
|
||||
// References: tmemSrcLines (0x801357A8)
|
||||
// References: tmemSliceWmax (0x8013579C)
|
||||
// References: flagSplit (0x801357A0)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int tmemLoad_A(__anon_0x5A89F *pFrame, __anon_0x5845E *pRSP, unsigned int imagePtr, signed short loadLines, signed short tmemAdrs, signed short tmemSH)
|
||||
{
|
||||
// References: tmemSliceWmax (0x8013579C)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int tmemLoad_B(__anon_0x5A89F *pFrame, __anon_0x5845E *pRSP, unsigned int imagePtr, signed short loadLines, signed short tmemSH)
|
||||
{
|
||||
__anon_0x59558 *pBuffer;
|
||||
int nAddr;
|
||||
// References: imageSrcWsize (0x8013579E)
|
||||
}
|
||||
|
||||
int guS2DEmuSetScissor(unsigned int ulx, unsigned int uly, unsigned int lrx, unsigned int lry, unsigned char flag)
|
||||
{
|
||||
// References: flagBilerp (0x80135790)
|
||||
// References: scissorY1 (0x801352D6)
|
||||
// References: scissorX1 (0x801352D4)
|
||||
// References: scissorY0 (0x8013578E)
|
||||
// References: scissorX0 (0x8013578C)
|
||||
}
|
||||
|
||||
int rspSetTileSize(__anon_0x5A89F *pFrame, __anon_0x5A2EC *pTile, int nX0, int nY0, int nX1, int nY1);
|
||||
|
||||
int rspLoadTile(__anon_0x5A89F *pFrame, __anon_0x5A2EC *pTile, int nX0, int nY0, int nX1, int nY1);
|
||||
|
||||
int rspLoadBlock(__anon_0x5A89F *pFrame, __anon_0x5A2EC *pTile, int nX0, int nY0, int nX1, int nY1);
|
||||
|
||||
int rspSetImage(__anon_0x5A89F *pFrame, __anon_0x5845E *pRSP, int nFormat, int nWidth, int nSize, int nImage)
|
||||
{
|
||||
int addr;
|
||||
__anon_0x59558 *pBuffer;
|
||||
}
|
||||
|
||||
int rspSetTile(__anon_0x5A89F *pFrame, __anon_0x5A2EC *pTile, int nSize, int nTmem, int nTLUT, int nFormat, int nMaskS, int nMaskT, int nModeS, int nModeT, int nShiftS, int nShiftT);
|
||||
|
||||
int rspFillObjBg(__anon_0x5845E *pRSP, int nAddress, __anon_0x5F2FB *pBg)
|
||||
{
|
||||
unsigned char *pnData8;
|
||||
unsigned char *pObjBg;
|
||||
unsigned short *pnData16;
|
||||
}
|
||||
|
||||
int rspFillObjBgScale(__anon_0x5845E *pRSP, int nAddress, __anon_0x5F2FB *pBg)
|
||||
{
|
||||
unsigned char *pnData8;
|
||||
unsigned char *pObjBg;
|
||||
unsigned short *pnData16;
|
||||
unsigned int *pnData32;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int rspFillObjSprite(__anon_0x5845E *pRSP, int nAddress, __anon_0x5F63B *pSprite)
|
||||
{
|
||||
unsigned short *pnData16;
|
||||
unsigned char *pnData8;
|
||||
unsigned char *pObjSprite;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int Matrix4by4Identity(float *matrix4b4[4]);
|
||||
|
||||
int frameFillVertex(__anon_0x5A89F *pFrame, int nIndex, signed short nX, signed short nY, signed short nZ, float rS, float rT);
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\_gspS2DEX.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C89
|
||||
Code range: 0x80077850 -> 0x8007AC6C
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
// Range: 0x80077850 -> 0x800779B0
|
||||
static s32 rspSetupS2DEX(struct __anon_0x5845E* pRSP) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r31
|
||||
|
||||
// Local variables
|
||||
float fL; // f31
|
||||
float fR; // f30
|
||||
float fB; // f29
|
||||
float fT; // f28
|
||||
struct __anon_0x5A89F* pFrame; // r4
|
||||
}
|
||||
|
||||
// Range: 0x800779B0 -> 0x80077B18
|
||||
static s32 rspObjMatrix(struct __anon_0x5845E* pRSP, s32 nAddress) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r31
|
||||
// s32 nAddress; // r5
|
||||
|
||||
// Local variables
|
||||
u32* pnData32; // r1+0x8
|
||||
u16* pnData16; // r1+0x8
|
||||
u8* pObjMtx; // r1+0x18
|
||||
u16 nBaseScaleX; // r6
|
||||
u16 nBaseScaleY; // r8
|
||||
s32 nA; // r5
|
||||
s32 nB; // r4
|
||||
s32 nC; // r1+0x8
|
||||
s32 nD; // r9
|
||||
s16 nY; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 rspObjSubMatrix(struct __anon_0x5845E* pRSP, s32 nAddress) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r31
|
||||
// s32 nAddress; // r5
|
||||
|
||||
// Local variables
|
||||
u16* pnData16; // r6
|
||||
u8* pObjSubMtx; // r1+0x18
|
||||
u16 nBaseScaleX; // r7
|
||||
u16 nBaseScaleY; // r5
|
||||
s16 nY; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80077B18 -> 0x80077CB8
|
||||
s32 rspBgRectCopy(struct __anon_0x5845E* pRSP, struct __anon_0x5A89F* pFrame, s32 nAddress) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r30
|
||||
// struct __anon_0x5A89F* pFrame; // r31
|
||||
// s32 nAddress; // r5
|
||||
|
||||
// Local variables
|
||||
union __anon_0x5F2FB bg; // r1+0x48
|
||||
union __anon_0x5F2FB bgScale; // r1+0x20
|
||||
u32 nOldMode1; // r1+0x18
|
||||
u32 nOldMode2; // r1+0x14
|
||||
|
||||
// References
|
||||
// -> static u8 flagBilerp;
|
||||
// -> static u16 scissorY1;
|
||||
// -> static u16 scissorX1;
|
||||
// -> static u16 scissorY0;
|
||||
// -> static u16 scissorX0;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 rspObjLoadTxSprite(struct __anon_0x5845E* pRSP, struct __anon_0x5A89F* pFrame, s32 nAddress) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r29
|
||||
// struct __anon_0x5A89F* pFrame; // r30
|
||||
// s32 nAddress; // r31
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 rspObjLoadTxRectR(struct __anon_0x5845E* pRSP, struct __anon_0x5A89F* pFrame, s32 nAddress) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r29
|
||||
// struct __anon_0x5A89F* pFrame; // r30
|
||||
// s32 nAddress; // r31
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 rspObjLoadTxRect(struct __anon_0x5845E* pRSP, struct __anon_0x5A89F* pFrame, s32 nAddress) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r29
|
||||
// struct __anon_0x5A89F* pFrame; // r30
|
||||
// s32 nAddress; // r31
|
||||
}
|
||||
|
||||
// Range: 0x80077CB8 -> 0x8007876C
|
||||
static s32 rspObjRectangleR(struct __anon_0x5845E* pRSP, struct __anon_0x5A89F* pFrame, s32 nAddress) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r29
|
||||
// struct __anon_0x5A89F* pFrame; // r30
|
||||
// s32 nAddress; // r5
|
||||
|
||||
// Local variables
|
||||
u16 nSizLineBytes; // r5
|
||||
float fLeft; // f30
|
||||
float fRight; // f29
|
||||
float fTop; // f28
|
||||
float fBottom; // f27
|
||||
float fTexRight; // f26
|
||||
float fTexBottom; // f25
|
||||
float fTexLeft; // f24
|
||||
float fTexTop; // f23
|
||||
s32 nTexTrim2; // r28
|
||||
s32 nTexTrim5; // r27
|
||||
float fSpriteWidth; // f22
|
||||
float fSpriteHeight; // f1
|
||||
s32 nClampSetting; // r1+0x8
|
||||
union __anon_0x5F63B objSprite; // r1+0x438
|
||||
struct __anon_0x5A2EC* pTile; // r31
|
||||
struct __anon_0x5EBE0 primitive; // r1+0x12C
|
||||
float mtxTransL[3][4]; // r1+0xFC
|
||||
float mtxTransW[3][4]; // r1+0xCC
|
||||
float mtxScale[3][4]; // r1+0x9C
|
||||
float mtxTemp[3][4]; // r1+0x6C
|
||||
float mtxOut[3][4]; // r1+0x3C
|
||||
struct __anon_0x5F6E9 vecIn; // r1+0x30
|
||||
struct __anon_0x5F6E9 vecOut; // r1+0x24
|
||||
}
|
||||
|
||||
// Range: 0x8007876C -> 0x80079234
|
||||
static s32 rspObjSprite(struct __anon_0x5845E* pRSP, struct __anon_0x5A89F* pFrame, s32 nAddress) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r29
|
||||
// struct __anon_0x5A89F* pFrame; // r30
|
||||
// s32 nAddress; // r5
|
||||
|
||||
// Local variables
|
||||
u16 nSizLineBytes; // r5
|
||||
float fLeft; // f29
|
||||
float fRight; // r1+0x8
|
||||
float fTop; // f28
|
||||
float fBottom; // r1+0x8
|
||||
float fTexRight; // f27
|
||||
float fTexBottom; // f26
|
||||
float fTexLeft; // f25
|
||||
float fTexTop; // f24
|
||||
float fScaleX; // f23
|
||||
float fScaleY; // f22
|
||||
float fSpriteWidth; // f2
|
||||
float fSpriteHeight; // f4
|
||||
s32 nTexTrim2; // r28
|
||||
s32 nTexTrim5; // r27
|
||||
s32 nClampSetting; // r1+0x8
|
||||
union __anon_0x5F63B objSprite; // r1+0x438
|
||||
struct __anon_0x5A2EC* pTile; // r31
|
||||
struct __anon_0x5EBE0 primitive; // r1+0x12C
|
||||
float mtxTransL[3][4]; // r1+0xFC
|
||||
float mtxTransW[3][4]; // r1+0xCC
|
||||
float mtxScale[3][4]; // r1+0x9C
|
||||
float mtxTemp[3][4]; // r1+0x6C
|
||||
float mtxOut[3][4]; // r1+0x3C
|
||||
struct __anon_0x5F6E9 vecIn; // r1+0x30
|
||||
struct __anon_0x5F6E9 vecOut; // r1+0x24
|
||||
}
|
||||
|
||||
// Range: 0x80079234 -> 0x800797D0
|
||||
static s32 rspObjRectangle(struct __anon_0x5845E* pRSP, struct __anon_0x5A89F* pFrame, s32 nAddress) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r27
|
||||
// struct __anon_0x5A89F* pFrame; // r30
|
||||
// s32 nAddress; // r5
|
||||
|
||||
// Local variables
|
||||
u16 nSizLineBytes; // r5
|
||||
float fDeltaS; // f3
|
||||
float fDeltaT; // f4
|
||||
union __anon_0x5F63B objSprite; // r1+0x48
|
||||
struct __anon_0x5A2EC* pTile; // r31
|
||||
struct __anon_0x5F759 primitive; // r1+0x1C
|
||||
s32 nClampSetting; // r1+0x8
|
||||
s32 nTexTrim2; // r29
|
||||
s32 nTexTrim5; // r28
|
||||
}
|
||||
|
||||
// Range: 0x800797D0 -> 0x80079C1C
|
||||
static s32 rspObjLoadTxtr(struct __anon_0x5845E* pRSP, struct __anon_0x5A89F* pFrame, s32 nAddress) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r28
|
||||
// struct __anon_0x5A89F* pFrame; // r29
|
||||
// s32 nAddress; // r5
|
||||
|
||||
// Local variables
|
||||
u32 nSizDefine; // r26
|
||||
u32 nLoadType; // r1+0x30
|
||||
s32 nAddr; // r5
|
||||
struct __anon_0x5A2EC* pTile; // r31
|
||||
struct __anon_0x59558* pBuffer; // r30
|
||||
union __anon_0x5FC1B objTxtr; // r1+0x18
|
||||
}
|
||||
|
||||
// Range: 0x80079C1C -> 0x80079D7C
|
||||
s32 rspFillObjTxtr(struct __anon_0x5845E* pRSP, s32 nAddress, union __anon_0x5FC1B* pTxtr, u32* pLoadType) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// s32 nAddress; // r4
|
||||
// union __anon_0x5FC1B* pTxtr; // r30
|
||||
// u32* pLoadType; // r31
|
||||
|
||||
// Local variables
|
||||
u32* pnData32; // r1+0x8
|
||||
u16* pnData16; // r1+0x8
|
||||
u8* pTxtrBlock; // r1+0x18
|
||||
u32 nLoadType; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x80079D7C -> 0x8007A4B8
|
||||
static s32 guS2DEmuBgRect1Cyc(struct __anon_0x5845E* pRSP, struct __anon_0x5A89F* pFrame, union __anon_0x5F2FB* pBG) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r15
|
||||
// struct __anon_0x5A89F* pFrame; // r29
|
||||
// union __anon_0x5F2FB* pBG; // r26
|
||||
|
||||
// Local variables
|
||||
s16 frameX0; // r4
|
||||
s16 frameX1; // r1+0x50
|
||||
s16 framePtrY0; // r23
|
||||
s16 frameRemain; // r31
|
||||
s16 imageX0; // r3
|
||||
s16 imageY0; // r4
|
||||
s16 imageSliceW; // r9
|
||||
s16 imageW; // r21
|
||||
s32 imageYorig; // r5
|
||||
s16 scaleW; // r1+0x8
|
||||
s16 scaleH; // r1+0x8
|
||||
s16 imageSrcW; // r6
|
||||
s16 imageSrcH; // r7
|
||||
s16 imageSliceLines; // r25
|
||||
s32 frameSliceLines; // r22
|
||||
s32 frameSliceCount; // r28
|
||||
u16 imageS; // r18
|
||||
u16 imageT; // r24
|
||||
u32 imagePtr; // r1+0x44
|
||||
s16 imageISliceL0; // r20
|
||||
s16 imageIY0; // r1+0x8
|
||||
s32 frameLSliceL0; // r7
|
||||
s16 pixX0; // r3
|
||||
s16 pixY0; // r4
|
||||
s16 pixX1; // r1+0x8
|
||||
s16 pixY1; // r8
|
||||
s16 frameY0; // r5
|
||||
s16 frameW; // r3
|
||||
s16 frameH; // r7
|
||||
s32 frameWmax; // r1+0x8
|
||||
s32 frameHmax; // r7
|
||||
s16 tmemSize; // r1+0x8
|
||||
s16 tmemMask; // r18
|
||||
s16 tmemShift; // r10
|
||||
s32 imageNumSlice; // r1+0x8
|
||||
s32 imageSliceWmax; // r6
|
||||
s32 imageLYoffset; // r4
|
||||
s32 frameLYoffset; // r4
|
||||
s32 imageLHidden; // r4
|
||||
s32 frameLHidden; // r6
|
||||
s32 frameLYslice; // r6
|
||||
s16 imageRemain; // r1+0x40
|
||||
s16 imageSliceH; // r1+0x8
|
||||
s16 frameSliceH; // r30
|
||||
struct __anon_0x5F759 primitive; // r1+0x18
|
||||
s16 nT; // r3
|
||||
s16 framePtrY1; // r30
|
||||
|
||||
// References
|
||||
// -> static u8 flagBilerp;
|
||||
// -> static s16 tmemSrcLines;
|
||||
// -> static u16 imageSrcWsize;
|
||||
// -> static u32 imageTop;
|
||||
// -> static u16 imagePtrX0;
|
||||
// -> static u16 tmemSliceWmax;
|
||||
// -> static u32 rdpSetTile_w0;
|
||||
// -> static u32 rdpSetTimg_w0;
|
||||
// -> static s16 TMEMSHIFT$3465[4];
|
||||
// -> static s16 TMEMMASK$3464[4];
|
||||
// -> static s16 TMEMSIZE$3463[5];
|
||||
// -> static u16 flagSplit;
|
||||
// -> static u16 scissorY1;
|
||||
// -> static u16 scissorX1;
|
||||
// -> static u16 scissorY0;
|
||||
// -> static u16 scissorX0;
|
||||
}
|
||||
|
||||
// Range: 0x8007A4B8 -> 0x8007A728
|
||||
static s32 tmemLoad(struct __anon_0x5A89F* pFrame, struct __anon_0x5845E* pRSP, u32* imagePtr, s16* imageRemain,
|
||||
s16 drawLines, s16 flagBilerp) {
|
||||
// Parameters
|
||||
// struct __anon_0x5A89F* pFrame; // r21
|
||||
// struct __anon_0x5845E* pRSP; // r22
|
||||
// u32* imagePtr; // r23
|
||||
// s16* imageRemain; // r24
|
||||
// s16 drawLines; // r25
|
||||
// s16 flagBilerp; // r1+0x1A
|
||||
|
||||
// Local variables
|
||||
s16 loadLines; // r6
|
||||
s16 iLoadable; // r29
|
||||
s16 SubSliceL2; // r6
|
||||
s16 SubSliceD2; // r28
|
||||
s16 SubSliceY2; // r7
|
||||
u32 imageTopSeg; // r30
|
||||
u32 imagePtr2; // r5
|
||||
u32 imagePtr1A; // r27
|
||||
u32 imagePtr1B; // r5
|
||||
s16 SubSliceY1; // r4
|
||||
s16 SubSliceL1; // r26
|
||||
s16 tmemSH_A; // r20
|
||||
s16 tmemSH_B; // r8
|
||||
|
||||
// References
|
||||
// -> static u16 imageSrcWsize;
|
||||
// -> static u32 imageTop;
|
||||
// -> static u16 imagePtrX0;
|
||||
// -> static s16 tmemSrcLines;
|
||||
// -> static u16 tmemSliceWmax;
|
||||
// -> static u16 flagSplit;
|
||||
}
|
||||
|
||||
// Range: 0x8007A728 -> 0x8007A7D4
|
||||
static s32 tmemLoad_A(struct __anon_0x5A89F* pFrame, struct __anon_0x5845E* pRSP, u32 imagePtr, s16 loadLines,
|
||||
s16 tmemAdrs, s16 tmemSH) {
|
||||
// Parameters
|
||||
// struct __anon_0x5A89F* pFrame; // r27
|
||||
// struct __anon_0x5845E* pRSP; // r28
|
||||
// u32 imagePtr; // r29
|
||||
// s16 loadLines; // r30
|
||||
// s16 tmemAdrs; // r1+0x16
|
||||
// s16 tmemSH; // r31
|
||||
|
||||
// References
|
||||
// -> static u16 tmemSliceWmax;
|
||||
}
|
||||
|
||||
// Range: 0x8007A7D4 -> 0x8007A8E8
|
||||
static s32 tmemLoad_B(struct __anon_0x5A89F* pFrame, struct __anon_0x5845E* pRSP, u32 imagePtr, s16 loadLines,
|
||||
s16 tmemSH) {
|
||||
// Parameters
|
||||
// struct __anon_0x5A89F* pFrame; // r30
|
||||
// struct __anon_0x5845E* pRSP; // r1+0xC
|
||||
// u32 imagePtr; // r1+0x10
|
||||
// s16 loadLines; // r31
|
||||
// s16 tmemSH; // r28
|
||||
|
||||
// Local variables
|
||||
struct __anon_0x59558* pBuffer; // r8
|
||||
s32 nAddr; // r5
|
||||
|
||||
// References
|
||||
// -> static u16 imageSrcWsize;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 guS2DEmuSetScissor(u32 ulx, u32 uly, u32 lrx, u32 lry, u8 flag) {
|
||||
// Parameters
|
||||
// u32 ulx; // r1+0x0
|
||||
// u32 uly; // r1+0x4
|
||||
// u32 lrx; // r1+0x8
|
||||
// u32 lry; // r1+0xC
|
||||
// u8 flag; // r1+0x10
|
||||
|
||||
// References
|
||||
// -> static u8 flagBilerp;
|
||||
// -> static u16 scissorY1;
|
||||
// -> static u16 scissorX1;
|
||||
// -> static u16 scissorY0;
|
||||
// -> static u16 scissorX0;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 rspSetTileSize(struct __anon_0x5A89F* pFrame, struct __anon_0x5A2EC* pTile, s32 nX0, s32 nY0, s32 nX1,
|
||||
s32 nY1) {
|
||||
// Parameters
|
||||
// struct __anon_0x5A89F* pFrame; // r3
|
||||
// struct __anon_0x5A2EC* pTile; // r1+0xC
|
||||
// s32 nX0; // r1+0x10
|
||||
// s32 nY0; // r1+0x14
|
||||
// s32 nX1; // r1+0x18
|
||||
// s32 nY1; // r1+0x1C
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 rspLoadTile(struct __anon_0x5A89F* pFrame, struct __anon_0x5A2EC* pTile, s32 nX0, s32 nY0, s32 nX1,
|
||||
s32 nY1) {
|
||||
// Parameters
|
||||
// struct __anon_0x5A89F* pFrame; // r3
|
||||
// struct __anon_0x5A2EC* pTile; // r1+0xC
|
||||
// s32 nX0; // r1+0x10
|
||||
// s32 nY0; // r1+0x14
|
||||
// s32 nX1; // r1+0x18
|
||||
// s32 nY1; // r1+0x1C
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 rspLoadBlock(struct __anon_0x5A89F* pFrame, struct __anon_0x5A2EC* pTile, s32 nX0, s32 nY0, s32 nX1,
|
||||
s32 nY1) {
|
||||
// Parameters
|
||||
// struct __anon_0x5A89F* pFrame; // r3
|
||||
// struct __anon_0x5A2EC* pTile; // r1+0xC
|
||||
// s32 nX0; // r1+0x10
|
||||
// s32 nY0; // r1+0x14
|
||||
// s32 nX1; // r1+0x18
|
||||
// s32 nY1; // r1+0x1C
|
||||
}
|
||||
|
||||
// Range: 0x8007A8E8 -> 0x8007A97C
|
||||
s32 rspSetImage(struct __anon_0x5A89F* pFrame, struct __anon_0x5845E* pRSP, s32 nFormat, s32 nWidth, s32 nSize,
|
||||
s32 nImage) {
|
||||
// Parameters
|
||||
// struct __anon_0x5A89F* pFrame; // r31
|
||||
// struct __anon_0x5845E* pRSP; // r1+0xC
|
||||
// s32 nFormat; // r1+0x10
|
||||
// s32 nWidth; // r1+0x14
|
||||
// s32 nSize; // r1+0x18
|
||||
// s32 nImage; // r1+0x1C
|
||||
|
||||
// Local variables
|
||||
s32 addr; // r5
|
||||
struct __anon_0x59558* pBuffer; // r9
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 rspSetTile(struct __anon_0x5A89F* pFrame, struct __anon_0x5A2EC* pTile, s32 nSize, s32 nTmem, s32 nTLUT,
|
||||
s32 nFormat, s32 nMaskS, s32 nMaskT, s32 nModeS, s32 nModeT, s32 nShiftS, s32 nShiftT) {
|
||||
// Parameters
|
||||
// struct __anon_0x5A89F* pFrame; // r3
|
||||
// struct __anon_0x5A2EC* pTile; // r1+0xC
|
||||
// s32 nSize; // r1+0x10
|
||||
// s32 nTmem; // r1+0x14
|
||||
// s32 nTLUT; // r1+0x18
|
||||
// s32 nFormat; // r1+0x20
|
||||
// s32 nMaskS; // r1+0x24
|
||||
// s32 nMaskT; // r1+0x8
|
||||
// s32 nModeS; // r8
|
||||
// s32 nModeT; // r6
|
||||
// s32 nShiftS; // r9
|
||||
// s32 nShiftT; // r8
|
||||
}
|
||||
|
||||
// Range: 0x8007A97C -> 0x8007AA74
|
||||
s32 rspFillObjBg(struct __anon_0x5845E* pRSP, s32 nAddress, union __anon_0x5F2FB* pBg) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// s32 nAddress; // r4
|
||||
// union __anon_0x5F2FB* pBg; // r31
|
||||
|
||||
// Local variables
|
||||
u8* pnData8; // r1+0x8
|
||||
u8* pObjBg; // r1+0x18
|
||||
u16* pnData16; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8007AA74 -> 0x8007AB54
|
||||
s32 rspFillObjBgScale(struct __anon_0x5845E* pRSP, s32 nAddress, union __anon_0x5F2FB* pBg) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// s32 nAddress; // r4
|
||||
// union __anon_0x5F2FB* pBg; // r31
|
||||
|
||||
// Local variables
|
||||
u8* pnData8; // r1+0x8
|
||||
u8* pObjBg; // r1+0x14
|
||||
u16* pnData16; // r1+0x8
|
||||
u32* pnData32; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8007AB54 -> 0x8007AC1C
|
||||
static s32 rspFillObjSprite(struct __anon_0x5845E* pRSP, s32 nAddress, union __anon_0x5F63B* pSprite) {
|
||||
// Parameters
|
||||
// struct __anon_0x5845E* pRSP; // r1+0x8
|
||||
// s32 nAddress; // r4
|
||||
// union __anon_0x5F63B* pSprite; // r31
|
||||
|
||||
// Local variables
|
||||
u16* pnData16; // r1+0x8
|
||||
u8* pnData8; // r1+0x8
|
||||
u8* pObjSprite; // r1+0x14
|
||||
}
|
||||
|
||||
// Range: 0x8007AC1C -> 0x8007AC6C
|
||||
static s32 Matrix4by4Identity(float (*matrix4b4)[4]) {
|
||||
// Parameters
|
||||
// float (* matrix4b4)[4]; // r1+0x0
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 frameFillVertex(struct __anon_0x5A89F* pFrame, s32 nIndex, s16 nX, s16 nY, s16 nZ, float rS, float rT) {
|
||||
// Parameters
|
||||
// struct __anon_0x5A89F* pFrame; // r1+0x8
|
||||
// s32 nIndex; // r1+0xC
|
||||
// s16 nX; // r1+0x10
|
||||
// s16 nY; // r1+0x12
|
||||
// s16 nZ; // r1+0x14
|
||||
// float rS; // r1+0x18
|
||||
// float rT; // r1+0x1C
|
||||
}
|
||||
|
||||
+81
-60
@@ -1,60 +1,81 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x78E70E80
|
||||
_XL_OBJECTTYPE gClassAudio;
|
||||
|
||||
// size: 0x20
|
||||
struct __anon_0x753E7
|
||||
{
|
||||
int nSize; // 0x0
|
||||
int bEnable; // 0x4
|
||||
void *pHost; // 0x8
|
||||
int nControl; // 0xC
|
||||
int nAddress; // 0x10
|
||||
int nRateBit; // 0x14
|
||||
int nRateDAC; // 0x18
|
||||
int nStatus; // 0x1C
|
||||
};
|
||||
|
||||
int audioEvent(__anon_0x753E7 *pAudio, int nEvent, void *pArgument);
|
||||
|
||||
int audioEnable(__anon_0x753E7 *pAudio, int bEnable);
|
||||
|
||||
int audioGet64();
|
||||
|
||||
int audioGet32(__anon_0x753E7 *pAudio, unsigned int nAddress, int *pData);
|
||||
|
||||
int audioGet16();
|
||||
|
||||
int audioGet8();
|
||||
|
||||
int audioPut64();
|
||||
|
||||
int audioPut32(__anon_0x753E7 *pAudio, unsigned int nAddress, int *pData)
|
||||
{
|
||||
void *pBuffer;
|
||||
}
|
||||
|
||||
int audioPut16();
|
||||
|
||||
int audioPut8();
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\audio.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x8008E4A8 -> 0x8008E8A0
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x752F4; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800EE778
|
||||
struct _XL_OBJECTTYPE gClassAudio;
|
||||
|
||||
typedef struct __anon_0x753E7 {
|
||||
/* 0x00 */ s32 nSize;
|
||||
/* 0x04 */ s32 bEnable;
|
||||
/* 0x08 */ void* pHost;
|
||||
/* 0x0C */ s32 nControl;
|
||||
/* 0x10 */ s32 nAddress;
|
||||
/* 0x14 */ s32 nRateBit;
|
||||
/* 0x18 */ s32 nRateDAC;
|
||||
/* 0x1C */ s32 nStatus;
|
||||
} __anon_0x753E7; // size = 0x20
|
||||
|
||||
// Range: 0x8008E4A8 -> 0x8008E5C8
|
||||
s32 audioEvent(struct __anon_0x753E7* pAudio, s32 nEvent, void* pArgument) {
|
||||
// Parameters
|
||||
// struct __anon_0x753E7* pAudio; // r30
|
||||
// s32 nEvent; // r1+0xC
|
||||
// void* pArgument; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8008E5C8 -> 0x8008E620
|
||||
s32 audioEnable(struct __anon_0x753E7* pAudio, s32 bEnable) {
|
||||
// Parameters
|
||||
// struct __anon_0x753E7* pAudio; // r3
|
||||
// s32 bEnable; // r1+0xC
|
||||
}
|
||||
|
||||
// Range: 0x8008E620 -> 0x8008E628
|
||||
s32 audioGet64() {}
|
||||
|
||||
// Range: 0x8008E628 -> 0x8008E730
|
||||
s32 audioGet32(struct __anon_0x753E7* pAudio, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x753E7* pAudio; // r30
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s32* pData; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8008E730 -> 0x8008E738
|
||||
s32 audioGet16() {}
|
||||
|
||||
// Range: 0x8008E738 -> 0x8008E740
|
||||
s32 audioGet8() {}
|
||||
|
||||
// Range: 0x8008E740 -> 0x8008E748
|
||||
s32 audioPut64() {}
|
||||
|
||||
// Range: 0x8008E748 -> 0x8008E890
|
||||
s32 audioPut32(struct __anon_0x753E7* pAudio, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x753E7* pAudio; // r31
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s32* pData; // r1+0x10
|
||||
|
||||
// Local variables
|
||||
void* pBuffer; // r1+0x14
|
||||
}
|
||||
|
||||
// Range: 0x8008E890 -> 0x8008E898
|
||||
s32 audioPut16() {}
|
||||
|
||||
// Range: 0x8008E898 -> 0x8008E8A0
|
||||
s32 audioPut8() {}
|
||||
|
||||
+125
-152
@@ -1,152 +1,125 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x800EA7C8
|
||||
_XL_OBJECTTYPE gClassCode;
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x1F980
|
||||
{
|
||||
XLFT_NONE = 4294967295,
|
||||
XLFT_TEXT = 0,
|
||||
XLFT_BINARY = 1
|
||||
};
|
||||
|
||||
// size: 0x20
|
||||
struct DVDDiskID
|
||||
{
|
||||
char gameName[4]; // 0x0
|
||||
char company[2]; // 0x4
|
||||
unsigned char diskNumber; // 0x6
|
||||
unsigned char gameVersion; // 0x7
|
||||
unsigned char streaming; // 0x8
|
||||
unsigned char streamingBufSize; // 0x9
|
||||
unsigned char padding[22]; // 0xA
|
||||
};
|
||||
|
||||
// size: 0x30
|
||||
struct DVDCommandBlock
|
||||
{
|
||||
DVDCommandBlock *next; // 0x0
|
||||
DVDCommandBlock *prev; // 0x4
|
||||
unsigned long command; // 0x8
|
||||
long state; // 0xC
|
||||
unsigned long offset; // 0x10
|
||||
unsigned long length; // 0x14
|
||||
void *addr; // 0x18
|
||||
unsigned long currTransferSize; // 0x1C
|
||||
unsigned long transferredSize; // 0x20
|
||||
DVDDiskID *id; // 0x24
|
||||
void (*callback)(long /* unknown0 */, DVDCommandBlock */* unknown1 */); // 0x28
|
||||
void *userData; // 0x2C
|
||||
};
|
||||
|
||||
// size: 0x3C
|
||||
struct DVDFileInfo
|
||||
{
|
||||
DVDCommandBlock cb; // 0x0
|
||||
unsigned long startAddr; // 0x30
|
||||
unsigned long length; // 0x34
|
||||
void (*callback)(long /* unknown0 */, DVDFileInfo */* unknown1 */); // 0x38
|
||||
};
|
||||
|
||||
// size: 0x58
|
||||
struct tXL_FILE
|
||||
{
|
||||
int iBuffer; // 0x0
|
||||
void *pData; // 0x4
|
||||
void *pBuffer; // 0x8
|
||||
int nAttributes; // 0xC
|
||||
int nSize; // 0x10
|
||||
int nOffset; // 0x14
|
||||
__anon_0x1F980 eType; // 0x18
|
||||
DVDFileInfo info; // 0x1C
|
||||
};
|
||||
|
||||
// Location: 0x0
|
||||
tXL_FILE *gpFileCode;
|
||||
|
||||
// Location: 0x0
|
||||
unsigned int gnSizeCode;
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x80135680
|
||||
static void *gpBufferFunction;
|
||||
|
||||
// Location: 0x0
|
||||
char gpBufferFunctionCache[65536];
|
||||
|
||||
// Local to compilation unit
|
||||
// Location: 0x80135684
|
||||
static unsigned int *ganDataCode;
|
||||
|
||||
// Location: 0x0
|
||||
unsigned int gnCountFunction;
|
||||
|
||||
// Location: 0x0
|
||||
unsigned int gnLastCountFunction;
|
||||
|
||||
// Location: 0x0
|
||||
int gSizeInARAM;
|
||||
|
||||
// size: 0x10
|
||||
struct _CODE_CACHE_NODE
|
||||
{
|
||||
int checksum; // 0x0
|
||||
int length; // 0x4
|
||||
_CODE_CACHE_NODE *next; // 0x8
|
||||
_CODE_CACHE_NODE *child; // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x0
|
||||
_CODE_CACHE_NODE gCodeCacheHead;
|
||||
|
||||
int codeEvent(int nEvent)
|
||||
{
|
||||
// References: ganDataCode (0x80135684)
|
||||
// References: gpBufferFunction (0x80135680)
|
||||
}
|
||||
|
||||
// Location: 0x0
|
||||
int gCatalogLoaded;
|
||||
|
||||
int codeCheckCatalog(int nAddress0, int nAddress1)
|
||||
{
|
||||
int iFunction;
|
||||
int instruction;
|
||||
unsigned int checksum;
|
||||
// References: gnCountFunction (0x0)
|
||||
// References: ganDataCode (0x80135684)
|
||||
// References: gCatalogLoaded (0x0)
|
||||
}
|
||||
|
||||
int codeSendFilePart();
|
||||
|
||||
int hioInit();
|
||||
|
||||
int hioSendBuffer();
|
||||
|
||||
void hioCallback();
|
||||
|
||||
int hioCallbackDevice();
|
||||
|
||||
int hioInitSend();
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\codeGCN.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x8001C444 -> 0x8001C498
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x1F88E; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800EA7C8
|
||||
struct _XL_OBJECTTYPE gClassCode;
|
||||
|
||||
typedef enum __anon_0x1F980 {
|
||||
XLFT_NONE = -1,
|
||||
XLFT_TEXT = 0,
|
||||
XLFT_BINARY = 1,
|
||||
} __anon_0x1F980;
|
||||
|
||||
typedef struct DVDDiskID {
|
||||
/* 0x0 */ char gameName[4];
|
||||
/* 0x4 */ char company[2];
|
||||
/* 0x6 */ u8 diskNumber;
|
||||
/* 0x7 */ u8 gameVersion;
|
||||
/* 0x8 */ u8 streaming;
|
||||
/* 0x9 */ u8 streamingBufSize;
|
||||
/* 0xA */ u8 padding[22];
|
||||
} __anon_0x1FA38; // size = 0x20
|
||||
|
||||
typedef struct DVDCommandBlock {
|
||||
/* 0x00 */ struct DVDCommandBlock* next;
|
||||
/* 0x04 */ struct DVDCommandBlock* prev;
|
||||
/* 0x08 */ u32 command;
|
||||
/* 0x0C */ s32 state;
|
||||
/* 0x10 */ u32 offset;
|
||||
/* 0x14 */ u32 length;
|
||||
/* 0x18 */ void* addr;
|
||||
/* 0x1C */ u32 currTransferSize;
|
||||
/* 0x20 */ u32 transferredSize;
|
||||
/* 0x24 */ struct DVDDiskID* id;
|
||||
/* 0x28 */ void (*callback)(s32, struct DVDCommandBlock*);
|
||||
/* 0x2C */ void* userData;
|
||||
} __anon_0x1FBA8; // size = 0x30
|
||||
|
||||
typedef struct DVDFileInfo {
|
||||
/* 0x00 */ struct DVDCommandBlock cb;
|
||||
/* 0x30 */ u32 startAddr;
|
||||
/* 0x34 */ u32 length;
|
||||
/* 0x38 */ void (*callback)(s32, struct DVDFileInfo*);
|
||||
} __anon_0x1FDCE; // size = 0x3C
|
||||
|
||||
typedef struct tXL_FILE {
|
||||
/* 0x00 */ s32 iBuffer;
|
||||
/* 0x04 */ void* pData;
|
||||
/* 0x08 */ void* pBuffer;
|
||||
/* 0x0C */ s32 nAttributes;
|
||||
/* 0x10 */ s32 nSize;
|
||||
/* 0x14 */ s32 nOffset;
|
||||
/* 0x18 */ enum __anon_0x1F980 eType;
|
||||
/* 0x1C */ struct DVDFileInfo info;
|
||||
} __anon_0x1FE86; // size = 0x58
|
||||
|
||||
// size = 0x4, address = 0x80135680
|
||||
static void* gpBufferFunction;
|
||||
|
||||
// size = 0x4, address = 0x80135684
|
||||
static u32* ganDataCode;
|
||||
|
||||
typedef struct _CODE_CACHE_NODE {
|
||||
/* 0x0 */ s32 checksum;
|
||||
/* 0x4 */ s32 length;
|
||||
/* 0x8 */ struct _CODE_CACHE_NODE* next;
|
||||
/* 0xC */ struct _CODE_CACHE_NODE* child;
|
||||
} __anon_0x20141; // size = 0x10
|
||||
|
||||
// Range: 0x8001C444 -> 0x8001C498
|
||||
s32 codeEvent(s32 nEvent) {
|
||||
// Parameters
|
||||
// s32 nEvent; // r1+0x4
|
||||
|
||||
// References
|
||||
// -> static u32* ganDataCode;
|
||||
// -> static void* gpBufferFunction;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 codeCheckCatalog(s32 nAddress0, s32 nAddress1) {
|
||||
// Parameters
|
||||
// s32 nAddress0; // r4
|
||||
// s32 nAddress1; // r5
|
||||
|
||||
// Local variables
|
||||
s32 iFunction; // r1+0x8
|
||||
s32 instruction; // r31
|
||||
u32 checksum; // r1+0x14
|
||||
|
||||
// References
|
||||
// -> static u32 gnCountFunction;
|
||||
// -> static u32* ganDataCode;
|
||||
// -> static s32 gCatalogLoaded;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 codeSendFilePart() {}
|
||||
|
||||
// Erased
|
||||
static s32 hioInit() {}
|
||||
|
||||
// Erased
|
||||
static s32 hioSendBuffer() {}
|
||||
|
||||
// Erased
|
||||
static void hioCallback() {}
|
||||
|
||||
// Erased
|
||||
static s32 hioCallbackDevice() {}
|
||||
|
||||
// Erased
|
||||
static s32 hioInitSend() {}
|
||||
|
||||
+1727
-1309
File diff suppressed because it is too large
Load Diff
+97
-80
@@ -1,80 +1,97 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x48E70E80
|
||||
_XL_OBJECTTYPE gClassDisk;
|
||||
|
||||
// size: 0x4
|
||||
struct __anon_0x73B29
|
||||
{
|
||||
void *pHost; // 0x0
|
||||
};
|
||||
|
||||
int diskEvent(__anon_0x73B29 *pDisk, int nEvent, void *pArgument);
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskGetDrive64();
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskGetDrive32(unsigned int nAddress, int *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskGetDrive16();
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskGetDrive8();
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskPutDrive64();
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskPutDrive32(unsigned int nAddress);
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskPutDrive16();
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskPutDrive8();
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskGetROM64(signed long long *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskGetROM32(int *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskGetROM16(signed short *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskGetROM8(char *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskPutROM64();
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskPutROM32();
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskPutROM16();
|
||||
|
||||
// Local to compilation unit
|
||||
static int diskPutROM8();
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\disk.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x8008D788 -> 0x8008DA1C
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x73A37; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800EE748
|
||||
struct _XL_OBJECTTYPE gClassDisk;
|
||||
|
||||
typedef struct __anon_0x73B29 {
|
||||
/* 0x0 */ void* pHost;
|
||||
} __anon_0x73B29; // size = 0x4
|
||||
|
||||
// Range: 0x8008D788 -> 0x8008D924
|
||||
s32 diskEvent(struct __anon_0x73B29* pDisk, s32 nEvent, void* pArgument) {
|
||||
// Parameters
|
||||
// struct __anon_0x73B29* pDisk; // r30
|
||||
// s32 nEvent; // r1+0xC
|
||||
// void* pArgument; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8008D924 -> 0x8008D92C
|
||||
static s32 diskGetDrive64() {}
|
||||
|
||||
// Range: 0x8008D92C -> 0x8008D964
|
||||
static s32 diskGetDrive32(u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0x4
|
||||
// s32* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8008D964 -> 0x8008D96C
|
||||
static s32 diskGetDrive16() {}
|
||||
|
||||
// Range: 0x8008D96C -> 0x8008D974
|
||||
static s32 diskGetDrive8() {}
|
||||
|
||||
// Range: 0x8008D974 -> 0x8008D97C
|
||||
static s32 diskPutDrive64() {}
|
||||
|
||||
// Range: 0x8008D97C -> 0x8008D9A8
|
||||
static s32 diskPutDrive32(u32 nAddress) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0x4
|
||||
}
|
||||
|
||||
// Range: 0x8008D9A8 -> 0x8008D9B0
|
||||
static s32 diskPutDrive16() {}
|
||||
|
||||
// Range: 0x8008D9B0 -> 0x8008D9B8
|
||||
static s32 diskPutDrive8() {}
|
||||
|
||||
// Range: 0x8008D9B8 -> 0x8008D9CC
|
||||
static s32 diskGetROM64(s64* pData) {
|
||||
// Parameters
|
||||
// s64* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8008D9CC -> 0x8008D9DC
|
||||
static s32 diskGetROM32(s32* pData) {
|
||||
// Parameters
|
||||
// s32* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8008D9DC -> 0x8008D9EC
|
||||
static s32 diskGetROM16(s16* pData) {
|
||||
// Parameters
|
||||
// s16* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8008D9EC -> 0x8008D9FC
|
||||
static s32 diskGetROM8(char* pData) {
|
||||
// Parameters
|
||||
// char* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8008D9FC -> 0x8008DA04
|
||||
static s32 diskPutROM64() {}
|
||||
|
||||
// Range: 0x8008DA04 -> 0x8008DA0C
|
||||
static s32 diskPutROM32() {}
|
||||
|
||||
// Range: 0x8008DA0C -> 0x8008DA14
|
||||
static s32 diskPutROM16() {}
|
||||
|
||||
// Range: 0x8008DA14 -> 0x8008DA1C
|
||||
static s32 diskPutROM8() {}
|
||||
|
||||
+93
-74
@@ -1,74 +1,93 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x58E70E80
|
||||
_XL_OBJECTTYPE gClassFlash;
|
||||
|
||||
// size: 0x10
|
||||
struct __anon_0x7428F
|
||||
{
|
||||
void *pHost; // 0x0
|
||||
int flashCommand; // 0x4
|
||||
char *flashBuffer; // 0x8
|
||||
int flashStatus; // 0xC
|
||||
};
|
||||
|
||||
int flashEvent(__anon_0x7428F *pFLASH, int nEvent, void *pArgument);
|
||||
|
||||
// Local to compilation unit
|
||||
static int flashGet64();
|
||||
|
||||
// Local to compilation unit
|
||||
static int flashGet32(__anon_0x7428F *pFLASH, int *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int flashGet16();
|
||||
|
||||
// Local to compilation unit
|
||||
static int flashGet8();
|
||||
|
||||
// Local to compilation unit
|
||||
static int flashPut64();
|
||||
|
||||
// Local to compilation unit
|
||||
static int flashPut32(__anon_0x7428F *pFLASH, int *pData)
|
||||
{
|
||||
int i;
|
||||
char buffer[128];
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int flashPut16();
|
||||
|
||||
// Local to compilation unit
|
||||
static int flashPut8();
|
||||
|
||||
int flashTransferFLASH(__anon_0x7428F *pFLASH, int nOffsetRAM, int nSize)
|
||||
{
|
||||
void *pTarget;
|
||||
int i;
|
||||
}
|
||||
|
||||
int flashCopyFLASH(__anon_0x7428F *pFLASH, int nOffsetRAM, int nOffsetFLASH, int nSize)
|
||||
{
|
||||
void *pTarget;
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\flash.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x8008DA1C -> 0x8008E138
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x7419C; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800EE758
|
||||
struct _XL_OBJECTTYPE gClassFlash;
|
||||
|
||||
typedef struct __anon_0x7428F {
|
||||
/* 0x0 */ void* pHost;
|
||||
/* 0x4 */ s32 flashCommand;
|
||||
/* 0x8 */ char* flashBuffer;
|
||||
/* 0xC */ s32 flashStatus;
|
||||
} __anon_0x7428F; // size = 0x10
|
||||
|
||||
// Range: 0x8008DA1C -> 0x8008DB3C
|
||||
s32 flashEvent(struct __anon_0x7428F* pFLASH, s32 nEvent, void* pArgument) {
|
||||
// Parameters
|
||||
// struct __anon_0x7428F* pFLASH; // r30
|
||||
// s32 nEvent; // r1+0xC
|
||||
// void* pArgument; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8008DB3C -> 0x8008DB44
|
||||
static s32 flashGet64() {}
|
||||
|
||||
// Range: 0x8008DB44 -> 0x8008DBE8
|
||||
static s32 flashGet32(struct __anon_0x7428F* pFLASH, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x7428F* pFLASH; // r1+0x0
|
||||
// s32* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8008DBE8 -> 0x8008DBF0
|
||||
static s32 flashGet16() {}
|
||||
|
||||
// Range: 0x8008DBF0 -> 0x8008DBF8
|
||||
static s32 flashGet8() {}
|
||||
|
||||
// Range: 0x8008DBF8 -> 0x8008DC00
|
||||
static s32 flashPut64() {}
|
||||
|
||||
// Range: 0x8008DC00 -> 0x8008DED0
|
||||
static s32 flashPut32(struct __anon_0x7428F* pFLASH, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x7428F* pFLASH; // r30
|
||||
// s32* pData; // r31
|
||||
|
||||
// Local variables
|
||||
s32 i; // r1+0x8
|
||||
char buffer[128]; // r1+0x1C
|
||||
}
|
||||
|
||||
// Range: 0x8008DED0 -> 0x8008DED8
|
||||
static s32 flashPut16() {}
|
||||
|
||||
// Range: 0x8008DED8 -> 0x8008DEE0
|
||||
static s32 flashPut8() {}
|
||||
|
||||
// Range: 0x8008DEE0 -> 0x8008DFF4
|
||||
s32 flashTransferFLASH(struct __anon_0x7428F* pFLASH, s32 nOffsetRAM, s32 nSize) {
|
||||
// Parameters
|
||||
// struct __anon_0x7428F* pFLASH; // r31
|
||||
// s32 nOffsetRAM; // r4
|
||||
// s32 nSize; // r1+0x14
|
||||
|
||||
// Local variables
|
||||
void* pTarget; // r1+0x18
|
||||
s32 i; // r4
|
||||
}
|
||||
|
||||
// Range: 0x8008DFF4 -> 0x8008E138
|
||||
s32 flashCopyFLASH(struct __anon_0x7428F* pFLASH, s32 nOffsetRAM, s32 nOffsetFLASH, s32 nSize) {
|
||||
// Parameters
|
||||
// struct __anon_0x7428F* pFLASH; // r30
|
||||
// s32 nOffsetRAM; // r4
|
||||
// s32 nOffsetFLASH; // r31
|
||||
// s32 nSize; // r1+0x14
|
||||
|
||||
// Local variables
|
||||
void* pTarget; // r1+0x18
|
||||
}
|
||||
|
||||
+1787
-1772
File diff suppressed because it is too large
Load Diff
+1630
-1476
File diff suppressed because it is too large
Load Diff
+1130
-811
File diff suppressed because it is too large
Load Diff
+100
-76
@@ -1,76 +1,100 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x800EE6D0
|
||||
_XL_OBJECTTYPE gClassMips;
|
||||
|
||||
// size: 0x10
|
||||
struct __anon_0x7331D
|
||||
{
|
||||
int nMask; // 0x0
|
||||
int nMode; // 0x4
|
||||
void *pHost; // 0x8
|
||||
int nInterrupt; // 0xC
|
||||
};
|
||||
|
||||
int mipsEvent(__anon_0x7331D *pMips, int nEvent, void *pArgument);
|
||||
|
||||
int mipsGet64();
|
||||
|
||||
int mipsGet32(__anon_0x7331D *pMips, unsigned int nAddress, int *pData);
|
||||
|
||||
int mipsGet16();
|
||||
|
||||
int mipsGet8();
|
||||
|
||||
int mipsPut64();
|
||||
|
||||
int mipsPut32(__anon_0x7331D *pMips, unsigned int nAddress, int *pData)
|
||||
{
|
||||
int nData;
|
||||
}
|
||||
|
||||
int mipsPut16();
|
||||
|
||||
int mipsPut8();
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x736C0
|
||||
{
|
||||
MIT_NONE = 4294967295,
|
||||
MIT_SP = 0,
|
||||
MIT_SI = 1,
|
||||
MIT_AI = 2,
|
||||
MIT_VI = 3,
|
||||
MIT_PI = 4,
|
||||
MIT_DP = 5
|
||||
};
|
||||
|
||||
int mipsResetInterrupt(__anon_0x7331D *pMips, __anon_0x736C0 eType)
|
||||
{
|
||||
int nInterrupt;
|
||||
}
|
||||
|
||||
int mipsSetInterrupt(__anon_0x7331D *pMips, __anon_0x736C0 eType)
|
||||
{
|
||||
int nInterrupt;
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\mips.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x8008D248 -> 0x8008D788
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x7322B; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800EE6D0
|
||||
struct _XL_OBJECTTYPE gClassMips;
|
||||
|
||||
typedef struct __anon_0x7331D {
|
||||
/* 0x0 */ s32 nMask;
|
||||
/* 0x4 */ s32 nMode;
|
||||
/* 0x8 */ void* pHost;
|
||||
/* 0xC */ s32 nInterrupt;
|
||||
} __anon_0x7331D; // size = 0x10
|
||||
|
||||
// Range: 0x8008D248 -> 0x8008D358
|
||||
s32 mipsEvent(struct __anon_0x7331D* pMips, s32 nEvent, void* pArgument) {
|
||||
// Parameters
|
||||
// struct __anon_0x7331D* pMips; // r30
|
||||
// s32 nEvent; // r1+0xC
|
||||
// void* pArgument; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8008D358 -> 0x8008D360
|
||||
s32 mipsGet64() {}
|
||||
|
||||
// Range: 0x8008D360 -> 0x8008D3C8
|
||||
s32 mipsGet32(struct __anon_0x7331D* pMips, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x7331D* pMips; // r1+0x0
|
||||
// u32 nAddress; // r1+0x4
|
||||
// s32* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8008D3C8 -> 0x8008D3D0
|
||||
s32 mipsGet16() {}
|
||||
|
||||
// Range: 0x8008D3D0 -> 0x8008D3D8
|
||||
s32 mipsGet8() {}
|
||||
|
||||
// Range: 0x8008D3D8 -> 0x8008D3E0
|
||||
s32 mipsPut64() {}
|
||||
|
||||
// Range: 0x8008D3E0 -> 0x8008D5E8
|
||||
s32 mipsPut32(struct __anon_0x7331D* pMips, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x7331D* pMips; // r30
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s32* pData; // r1+0x10
|
||||
|
||||
// Local variables
|
||||
s32 nData; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8008D5E8 -> 0x8008D5F0
|
||||
s32 mipsPut16() {}
|
||||
|
||||
// Range: 0x8008D5F0 -> 0x8008D5F8
|
||||
s32 mipsPut8() {}
|
||||
|
||||
typedef enum __anon_0x736C0 {
|
||||
MIT_NONE = -1,
|
||||
MIT_SP = 0,
|
||||
MIT_SI = 1,
|
||||
MIT_AI = 2,
|
||||
MIT_VI = 3,
|
||||
MIT_PI = 4,
|
||||
MIT_DP = 5,
|
||||
} __anon_0x736C0;
|
||||
|
||||
// Range: 0x8008D5F8 -> 0x8008D69C
|
||||
s32 mipsResetInterrupt(struct __anon_0x7331D* pMips, enum __anon_0x736C0 eType) {
|
||||
// Parameters
|
||||
// struct __anon_0x7331D* pMips; // r1+0x0
|
||||
// enum __anon_0x736C0 eType; // r1+0x4
|
||||
|
||||
// Local variables
|
||||
s32 nInterrupt; // r5
|
||||
}
|
||||
|
||||
// Range: 0x8008D69C -> 0x8008D788
|
||||
s32 mipsSetInterrupt(struct __anon_0x7331D* pMips, enum __anon_0x736C0 eType) {
|
||||
// Parameters
|
||||
// struct __anon_0x7331D* pMips; // r1+0x0
|
||||
// enum __anon_0x736C0 eType; // r1+0x4
|
||||
|
||||
// Local variables
|
||||
s32 nInterrupt; // r5
|
||||
}
|
||||
|
||||
+80
-84
@@ -1,84 +1,80 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// Location: 0x10561380
|
||||
unsigned char *gBufferP;
|
||||
|
||||
// Location: 0x20541380
|
||||
int __OSCurrHeap;
|
||||
|
||||
void MovieDestroy()
|
||||
{
|
||||
// References: gBufferP (0x10561380)
|
||||
// References: __OSCurrHeap (0x20541380)
|
||||
}
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0xEF02
|
||||
{
|
||||
VI_TVMODE_NTSC_INT = 0,
|
||||
VI_TVMODE_NTSC_DS = 1,
|
||||
VI_TVMODE_NTSC_PROG = 2,
|
||||
VI_TVMODE_PAL_INT = 4,
|
||||
VI_TVMODE_PAL_DS = 5,
|
||||
VI_TVMODE_EURGB60_INT = 20,
|
||||
VI_TVMODE_EURGB60_DS = 21,
|
||||
VI_TVMODE_MPAL_INT = 8,
|
||||
VI_TVMODE_MPAL_DS = 9,
|
||||
VI_TVMODE_DEBUG_INT = 12,
|
||||
VI_TVMODE_DEBUG_PAL_INT = 16,
|
||||
VI_TVMODE_DEBUG_PAL_DS = 17
|
||||
};
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0xF04A
|
||||
{
|
||||
VI_XFBMODE_SF = 0,
|
||||
VI_XFBMODE_DF = 1
|
||||
};
|
||||
|
||||
// size: 0x3C
|
||||
struct _GXRenderModeObj
|
||||
{
|
||||
__anon_0xEF02 viTVmode; // 0x0
|
||||
unsigned short fbWidth; // 0x4
|
||||
unsigned short efbHeight; // 0x6
|
||||
unsigned short xfbHeight; // 0x8
|
||||
unsigned short viXOrigin; // 0xA
|
||||
unsigned short viYOrigin; // 0xC
|
||||
unsigned short viWidth; // 0xE
|
||||
unsigned short viHeight; // 0x10
|
||||
__anon_0xF04A xFBmode; // 0x14
|
||||
unsigned char field_rendering; // 0x18
|
||||
unsigned char aa; // 0x19
|
||||
unsigned char sample_pattern[12][2]; // 0x1A
|
||||
unsigned char vfilter[7]; // 0x32
|
||||
};
|
||||
|
||||
// Location: 0x8013559C
|
||||
_GXRenderModeObj *rmode;
|
||||
|
||||
void MovieDraw()
|
||||
{
|
||||
// References: rmode (0x8013559C)
|
||||
}
|
||||
|
||||
void MovieUpdate();
|
||||
|
||||
void MovieInit()
|
||||
{
|
||||
char *szText;
|
||||
unsigned long size;
|
||||
// References: gBufferP (0x10561380)
|
||||
// References: __OSCurrHeap (0x20541380)
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\movie.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x8000F7CC -> 0x8000F890
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
// size = 0x4, address = 0x80135610
|
||||
u8* gBufferP;
|
||||
|
||||
// size = 0x4, address = 0x80135420
|
||||
s32 __OSCurrHeap;
|
||||
|
||||
// Erased
|
||||
static void MovieDestroy() {
|
||||
// References
|
||||
// -> u8* gBufferP;
|
||||
// -> s32 __OSCurrHeap;
|
||||
}
|
||||
|
||||
typedef enum __anon_0xEF02 {
|
||||
VI_TVMODE_NTSC_INT = 0,
|
||||
VI_TVMODE_NTSC_DS = 1,
|
||||
VI_TVMODE_NTSC_PROG = 2,
|
||||
VI_TVMODE_PAL_INT = 4,
|
||||
VI_TVMODE_PAL_DS = 5,
|
||||
VI_TVMODE_EURGB60_INT = 20,
|
||||
VI_TVMODE_EURGB60_DS = 21,
|
||||
VI_TVMODE_MPAL_INT = 8,
|
||||
VI_TVMODE_MPAL_DS = 9,
|
||||
VI_TVMODE_DEBUG_INT = 12,
|
||||
VI_TVMODE_DEBUG_PAL_INT = 16,
|
||||
VI_TVMODE_DEBUG_PAL_DS = 17,
|
||||
} __anon_0xEF02;
|
||||
|
||||
typedef enum __anon_0xF04A {
|
||||
VI_XFBMODE_SF = 0,
|
||||
VI_XFBMODE_DF = 1,
|
||||
} __anon_0xF04A;
|
||||
|
||||
typedef struct _GXRenderModeObj {
|
||||
/* 0x00 */ enum __anon_0xEF02 viTVmode;
|
||||
/* 0x04 */ u16 fbWidth;
|
||||
/* 0x06 */ u16 efbHeight;
|
||||
/* 0x08 */ u16 xfbHeight;
|
||||
/* 0x0A */ u16 viXOrigin;
|
||||
/* 0x0C */ u16 viYOrigin;
|
||||
/* 0x0E */ u16 viWidth;
|
||||
/* 0x10 */ u16 viHeight;
|
||||
/* 0x14 */ enum __anon_0xF04A xFBmode;
|
||||
/* 0x18 */ u8 field_rendering;
|
||||
/* 0x19 */ u8 aa;
|
||||
/* 0x1A */ u8 sample_pattern[12][2];
|
||||
/* 0x32 */ u8 vfilter[7];
|
||||
} __anon_0xF0F9; // size = 0x3C
|
||||
|
||||
// size = 0x4, address = 0x8013559C
|
||||
struct _GXRenderModeObj* rmode;
|
||||
|
||||
// Range: 0x8000F7CC -> 0x8000F804
|
||||
void MovieDraw() {
|
||||
// References
|
||||
// -> struct _GXRenderModeObj* rmode;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void MovieUpdate() {}
|
||||
|
||||
// Range: 0x8000F804 -> 0x8000F890
|
||||
void MovieInit() {
|
||||
// Local variables
|
||||
char* szText; // r1+0x8
|
||||
u32 size; // r4
|
||||
|
||||
// References
|
||||
// -> u8* gBufferP;
|
||||
// -> s32 __OSCurrHeap;
|
||||
}
|
||||
|
||||
+158
-150
@@ -1,150 +1,158 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x800EFFBC
|
||||
_XL_OBJECTTYPE gClassPeripheral;
|
||||
|
||||
// size: 0x38
|
||||
struct __anon_0x83D15
|
||||
{
|
||||
void *pHost; // 0x0
|
||||
int nStatus; // 0x4
|
||||
int nSizeGet; // 0x8
|
||||
int nSizePut; // 0xC
|
||||
int nLatency1; // 0x10
|
||||
int nLatency2; // 0x14
|
||||
int nRelease1; // 0x18
|
||||
int nRelease2; // 0x1C
|
||||
int nSizePage1; // 0x20
|
||||
int nSizePage2; // 0x24
|
||||
int nAddressRAM; // 0x28
|
||||
int nAddressROM; // 0x2C
|
||||
int nWidthPulse1; // 0x30
|
||||
int nWidthPulse2; // 0x34
|
||||
};
|
||||
|
||||
int peripheralEvent(__anon_0x83D15 *pPeripheral, int nEvent, void *pArgument);
|
||||
|
||||
int peripheralGet64();
|
||||
|
||||
int peripheralGet32(__anon_0x83D15 *pPeripheral, unsigned int nAddress, int *pData);
|
||||
|
||||
int peripheralGet16();
|
||||
|
||||
int peripheralGet8();
|
||||
|
||||
int peripheralPut64();
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x8415D
|
||||
{
|
||||
SOT_NONE = 4294967295,
|
||||
SOT_CPU = 0,
|
||||
SOT_PIF = 1,
|
||||
SOT_RAM = 2,
|
||||
SOT_ROM = 3,
|
||||
SOT_RSP = 4,
|
||||
SOT_RDP = 5,
|
||||
SOT_MIPS = 6,
|
||||
SOT_DISK = 7,
|
||||
SOT_FLASH = 8,
|
||||
SOT_SRAM = 9,
|
||||
SOT_AUDIO = 10,
|
||||
SOT_VIDEO = 11,
|
||||
SOT_SERIAL = 12,
|
||||
SOT_LIBRARY = 13,
|
||||
SOT_PERIPHERAL = 14,
|
||||
SOT_RDB = 15,
|
||||
SOT_COUNT = 16
|
||||
};
|
||||
|
||||
int peripheralPut32(__anon_0x83D15 *pPeripheral, unsigned int nAddress, int *pData)
|
||||
{
|
||||
int bFlag;
|
||||
__anon_0x8415D storageDevice;
|
||||
}
|
||||
|
||||
int peripheralPut16();
|
||||
|
||||
int peripheralPut8();
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x843DE
|
||||
{
|
||||
SM_NONE = 4294967295,
|
||||
SM_RUNNING = 0,
|
||||
SM_STOPPED = 1
|
||||
};
|
||||
|
||||
// size: 0x10
|
||||
struct __anon_0x84447
|
||||
{
|
||||
int nSize; // 0x0
|
||||
int nOffsetRAM; // 0x4
|
||||
int nOffsetROM; // 0x8
|
||||
int (*pCallback)(); // 0xC
|
||||
};
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x844F8
|
||||
{
|
||||
SRT_NONE = 4294967295,
|
||||
SRT_MARIO = 0,
|
||||
SRT_WAVERACE = 1,
|
||||
SRT_MARIOKART = 2,
|
||||
SRT_STARFOX = 3,
|
||||
SRT_ZELDA1 = 4,
|
||||
SRT_ZELDA2 = 5,
|
||||
SRT_1080 = 6,
|
||||
SRT_PANEL = 7,
|
||||
SRT_MARIOPARTY1 = 8,
|
||||
SRT_MARIOPARTY2 = 9,
|
||||
SRT_MARIOPARTY3 = 10,
|
||||
SRT_DRMARIO = 11,
|
||||
SRT_UNKNOWN = 12
|
||||
};
|
||||
|
||||
// size: 0x88
|
||||
struct __anon_0x8464B
|
||||
{
|
||||
void *pFrame; // 0x0
|
||||
void *pSound; // 0x4
|
||||
int bException; // 0x8
|
||||
__anon_0x843DE eMode; // 0xC
|
||||
__anon_0x84447 romCopy; // 0x10
|
||||
__anon_0x844F8 eTypeROM; // 0x20
|
||||
void *apObject[16]; // 0x24
|
||||
unsigned long long nAddressBreak; // 0x68
|
||||
__anon_0x8415D storageDevice; // 0x70
|
||||
unsigned char anException[16]; // 0x74
|
||||
int bJapaneseVersion; // 0x84
|
||||
};
|
||||
|
||||
// Location: 0x561380
|
||||
__anon_0x8464B *gpSystem;
|
||||
|
||||
// Local to compilation unit
|
||||
static int peripheralDMA_Complete()
|
||||
{
|
||||
__anon_0x83D15 *pPeripheral;
|
||||
// References: gpSystem (0x561380)
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\peripheral.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x8009779C -> 0x80097D9C
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x83C1D; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800EFFBC
|
||||
struct _XL_OBJECTTYPE gClassPeripheral;
|
||||
|
||||
typedef struct __anon_0x83D15 {
|
||||
/* 0x00 */ void* pHost;
|
||||
/* 0x04 */ s32 nStatus;
|
||||
/* 0x08 */ s32 nSizeGet;
|
||||
/* 0x0C */ s32 nSizePut;
|
||||
/* 0x10 */ s32 nLatency1;
|
||||
/* 0x14 */ s32 nLatency2;
|
||||
/* 0x18 */ s32 nRelease1;
|
||||
/* 0x1C */ s32 nRelease2;
|
||||
/* 0x20 */ s32 nSizePage1;
|
||||
/* 0x24 */ s32 nSizePage2;
|
||||
/* 0x28 */ s32 nAddressRAM;
|
||||
/* 0x2C */ s32 nAddressROM;
|
||||
/* 0x30 */ s32 nWidthPulse1;
|
||||
/* 0x34 */ s32 nWidthPulse2;
|
||||
} __anon_0x83D15; // size = 0x38
|
||||
|
||||
// Range: 0x8009779C -> 0x800978A4
|
||||
s32 peripheralEvent(struct __anon_0x83D15* pPeripheral, s32 nEvent, void* pArgument) {
|
||||
// Parameters
|
||||
// struct __anon_0x83D15* pPeripheral; // r30
|
||||
// s32 nEvent; // r1+0xC
|
||||
// void* pArgument; // r31
|
||||
}
|
||||
|
||||
// Range: 0x800978A4 -> 0x800978AC
|
||||
s32 peripheralGet64() {}
|
||||
|
||||
// Range: 0x800978AC -> 0x800979AC
|
||||
s32 peripheralGet32(struct __anon_0x83D15* pPeripheral, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x83D15* pPeripheral; // r1+0x0
|
||||
// u32 nAddress; // r1+0x4
|
||||
// s32* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x800979AC -> 0x800979B4
|
||||
s32 peripheralGet16() {}
|
||||
|
||||
// Range: 0x800979B4 -> 0x800979BC
|
||||
s32 peripheralGet8() {}
|
||||
|
||||
// Range: 0x800979BC -> 0x800979C4
|
||||
s32 peripheralPut64() {}
|
||||
|
||||
typedef enum __anon_0x8415D {
|
||||
SOT_NONE = -1,
|
||||
SOT_CPU = 0,
|
||||
SOT_PIF = 1,
|
||||
SOT_RAM = 2,
|
||||
SOT_ROM = 3,
|
||||
SOT_RSP = 4,
|
||||
SOT_RDP = 5,
|
||||
SOT_MIPS = 6,
|
||||
SOT_DISK = 7,
|
||||
SOT_FLASH = 8,
|
||||
SOT_SRAM = 9,
|
||||
SOT_AUDIO = 10,
|
||||
SOT_VIDEO = 11,
|
||||
SOT_SERIAL = 12,
|
||||
SOT_LIBRARY = 13,
|
||||
SOT_PERIPHERAL = 14,
|
||||
SOT_RDB = 15,
|
||||
SOT_COUNT = 16,
|
||||
} __anon_0x8415D;
|
||||
|
||||
// Range: 0x800979C4 -> 0x80097D48
|
||||
s32 peripheralPut32(struct __anon_0x83D15* pPeripheral, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x83D15* pPeripheral; // r30
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s32* pData; // r1+0x10
|
||||
|
||||
// Local variables
|
||||
s32 bFlag; // r31
|
||||
enum __anon_0x8415D storageDevice; // r1+0x14
|
||||
}
|
||||
|
||||
// Range: 0x80097D48 -> 0x80097D50
|
||||
s32 peripheralPut16() {}
|
||||
|
||||
// Range: 0x80097D50 -> 0x80097D58
|
||||
s32 peripheralPut8() {}
|
||||
|
||||
typedef enum __anon_0x843DE {
|
||||
SM_NONE = -1,
|
||||
SM_RUNNING = 0,
|
||||
SM_STOPPED = 1,
|
||||
} __anon_0x843DE;
|
||||
|
||||
typedef struct __anon_0x84447 {
|
||||
/* 0x0 */ s32 nSize;
|
||||
/* 0x4 */ s32 nOffsetRAM;
|
||||
/* 0x8 */ s32 nOffsetROM;
|
||||
/* 0xC */ s32 (*pCallback)();
|
||||
} __anon_0x84447; // size = 0x10
|
||||
|
||||
typedef enum __anon_0x844F8 {
|
||||
SRT_NONE = -1,
|
||||
SRT_MARIO = 0,
|
||||
SRT_WAVERACE = 1,
|
||||
SRT_MARIOKART = 2,
|
||||
SRT_STARFOX = 3,
|
||||
SRT_ZELDA1 = 4,
|
||||
SRT_ZELDA2 = 5,
|
||||
SRT_1080 = 6,
|
||||
SRT_PANEL = 7,
|
||||
SRT_MARIOPARTY1 = 8,
|
||||
SRT_MARIOPARTY2 = 9,
|
||||
SRT_MARIOPARTY3 = 10,
|
||||
SRT_DRMARIO = 11,
|
||||
SRT_UNKNOWN = 12,
|
||||
} __anon_0x844F8;
|
||||
|
||||
typedef struct __anon_0x8464B {
|
||||
/* 0x00 */ void* pFrame;
|
||||
/* 0x04 */ void* pSound;
|
||||
/* 0x08 */ s32 bException;
|
||||
/* 0x0C */ enum __anon_0x843DE eMode;
|
||||
/* 0x10 */ struct __anon_0x84447 romCopy;
|
||||
/* 0x20 */ enum __anon_0x844F8 eTypeROM;
|
||||
/* 0x24 */ void* apObject[16];
|
||||
/* 0x68 */ u64 nAddressBreak;
|
||||
/* 0x70 */ enum __anon_0x8415D storageDevice;
|
||||
/* 0x74 */ u8 anException[16];
|
||||
/* 0x84 */ s32 bJapaneseVersion;
|
||||
} __anon_0x8464B; // size = 0x88
|
||||
|
||||
// size = 0x4, address = 0x80135600
|
||||
struct __anon_0x8464B* gpSystem;
|
||||
|
||||
// Range: 0x80097D58 -> 0x80097D9C
|
||||
static s32 peripheralDMA_Complete() {
|
||||
// Local variables
|
||||
struct __anon_0x83D15* pPeripheral; // r3
|
||||
|
||||
// References
|
||||
// -> struct __anon_0x8464B* gpSystem;
|
||||
}
|
||||
|
||||
+272
-146
@@ -1,146 +1,272 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x800ED6B8
|
||||
_XL_OBJECTTYPE gClassPIF;
|
||||
|
||||
// Location: 0x0
|
||||
int counter$295;
|
||||
|
||||
// size: 0x30
|
||||
struct __anon_0x4A974
|
||||
{
|
||||
void *pROM; // 0x0
|
||||
void *pRAM; // 0x4
|
||||
void *pHost; // 0x8
|
||||
unsigned short controllerType[5]; // 0xC
|
||||
char controllerStatus[5]; // 0x16
|
||||
__anon_0x4B3FE eControllerType[5]; // 0x1C
|
||||
};
|
||||
|
||||
int pifEvent(__anon_0x4A974 *pPIF, int nEvent, void *pArgument)
|
||||
{
|
||||
int i;
|
||||
}
|
||||
|
||||
int pifGetData(__anon_0x4A974 *pPIF, unsigned char *acData);
|
||||
|
||||
int pifSetData(__anon_0x4A974 *pPIF, unsigned char *acData);
|
||||
|
||||
int pifProcessOutputData(__anon_0x4A974 *pPIF)
|
||||
{
|
||||
unsigned char *prx;
|
||||
unsigned char *ptx;
|
||||
int iData;
|
||||
int channel;
|
||||
}
|
||||
|
||||
int pifProcessInputData(__anon_0x4A974 *pPIF)
|
||||
{
|
||||
unsigned char *prx;
|
||||
unsigned char *ptx;
|
||||
int iData;
|
||||
int channel;
|
||||
}
|
||||
|
||||
int pifExecuteCommand(__anon_0x4A974 *pPIF, unsigned char *buffer, unsigned char *prx, int channel);
|
||||
|
||||
// Local to compilation unit
|
||||
static int pifGet64(__anon_0x4A974 *pPIF, unsigned int nAddress, signed long long *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int pifGet32(__anon_0x4A974 *pPIF, unsigned int nAddress, int *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int pifGet16(__anon_0x4A974 *pPIF, unsigned int nAddress, signed short *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int pifGet8(__anon_0x4A974 *pPIF, unsigned int nAddress, char *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int pifPut64(__anon_0x4A974 *pPIF, unsigned int nAddress, signed long long *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int pifPut32(__anon_0x4A974 *pPIF, unsigned int nAddress, int *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int pifPut16(__anon_0x4A974 *pPIF, unsigned int nAddress, signed short *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int pifPut8(__anon_0x4A974 *pPIF, unsigned int nAddress, char *pData);
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x4B3FE
|
||||
{
|
||||
CT_NONE = 0,
|
||||
CT_CONTROLLER = 1,
|
||||
CT_CONTROLLER_W_PAK = 2,
|
||||
CT_CONTROLLER_W_RPAK = 3,
|
||||
CT_MOUSE = 4,
|
||||
CT_VOICE = 5,
|
||||
CT_4K = 6,
|
||||
CT_16K = 7,
|
||||
CT_COUNT = 8
|
||||
};
|
||||
|
||||
int pifReadController(__anon_0x4A974 *pPIF, unsigned char *buffer, unsigned char *prx, int channel)
|
||||
{
|
||||
__anon_0x4B3FE type;
|
||||
}
|
||||
|
||||
int pifQueryController(__anon_0x4A974 *pPIF, unsigned char *buffer, unsigned char *prx, int channel);
|
||||
|
||||
int pifGetEEPROMSize(__anon_0x4A974 *pPIF, unsigned int *size);
|
||||
|
||||
int pifGetControllerType(__anon_0x4A974 *pPIF, int channel, unsigned short *type, char *status)
|
||||
{
|
||||
__anon_0x4B3FE eType;
|
||||
}
|
||||
|
||||
int pifGetControllerInput(int channel, unsigned int *controllerInput);
|
||||
|
||||
int pifSetEEPROMType(__anon_0x4A974 *pPIF, __anon_0x4B3FE type);
|
||||
|
||||
int pifGetEControllerType(__anon_0x4A974 *pPIF, int channel, __anon_0x4B3FE *type);
|
||||
|
||||
int pifSetControllerType(__anon_0x4A974 *pPIF, int channel, __anon_0x4B3FE type);
|
||||
|
||||
// Local to compilation unit
|
||||
static unsigned char pifContDataCrc(unsigned char *data)
|
||||
{
|
||||
unsigned int temp;
|
||||
unsigned int i;
|
||||
unsigned int j;
|
||||
}
|
||||
|
||||
int pifWriteRumble(int channel, unsigned short address, unsigned char *data);
|
||||
|
||||
int pifReadRumble(unsigned short address, unsigned char *data)
|
||||
{
|
||||
int i;
|
||||
}
|
||||
|
||||
int pifIdCheckSum(unsigned short *ptr, unsigned short *csum, unsigned short *icsum)
|
||||
{
|
||||
unsigned short data;
|
||||
unsigned int j;
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\pif.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x8006BE68 -> 0x8006CD98
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x4A7FA; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800ED6B8
|
||||
struct _XL_OBJECTTYPE gClassPIF;
|
||||
|
||||
typedef struct __anon_0x4A974 {
|
||||
/* 0x00 */ void* pROM;
|
||||
/* 0x04 */ void* pRAM;
|
||||
/* 0x08 */ void* pHost;
|
||||
/* 0x0C */ u16 controllerType[5];
|
||||
/* 0x16 */ char controllerStatus[5];
|
||||
/* 0x1C */ enum __anon_0x4B3FE eControllerType[5];
|
||||
} __anon_0x4A974; // size = 0x30
|
||||
|
||||
// Range: 0x8006BE68 -> 0x8006C090
|
||||
s32 pifEvent(struct __anon_0x4A974* pPIF, s32 nEvent, void* pArgument) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r30
|
||||
// s32 nEvent; // r1+0xC
|
||||
// void* pArgument; // r31
|
||||
|
||||
// Local variables
|
||||
s32 i; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8006C090 -> 0x8006C0FC
|
||||
s32 pifGetData(struct __anon_0x4A974* pPIF, u8* acData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r30
|
||||
// u8* acData; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8006C0FC -> 0x8006C15C
|
||||
s32 pifSetData(struct __anon_0x4A974* pPIF, u8* acData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r31
|
||||
// u8* acData; // r4
|
||||
}
|
||||
|
||||
// Range: 0x8006C15C -> 0x8006C2F8
|
||||
s32 pifProcessOutputData(struct __anon_0x4A974* pPIF) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r29
|
||||
|
||||
// Local variables
|
||||
u8* prx; // r6
|
||||
u8* ptx; // r5
|
||||
s32 iData; // r31
|
||||
s32 channel; // r30
|
||||
}
|
||||
|
||||
// Range: 0x8006C2F8 -> 0x8006C488
|
||||
s32 pifProcessInputData(struct __anon_0x4A974* pPIF) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r30
|
||||
|
||||
// Local variables
|
||||
u8* prx; // r6
|
||||
u8* ptx; // r5
|
||||
s32 iData; // r29
|
||||
s32 channel; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8006C488 -> 0x8006C72C
|
||||
s32 pifExecuteCommand(struct __anon_0x4A974* pPIF, u8* buffer, u8* prx, s32 channel) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r30
|
||||
// u8* buffer; // r31
|
||||
// u8* prx; // r1+0x14
|
||||
// s32 channel; // r7
|
||||
}
|
||||
|
||||
// Range: 0x8006C72C -> 0x8006C780
|
||||
static s32 pifGet64(struct __anon_0x4A974* pPIF, u32 nAddress, s64* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x0
|
||||
// u32 nAddress; // r1+0x4
|
||||
// s64* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006C780 -> 0x8006C7BC
|
||||
static s32 pifGet32(struct __anon_0x4A974* pPIF, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x0
|
||||
// u32 nAddress; // r1+0x4
|
||||
// s32* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006C7BC -> 0x8006C7F8
|
||||
static s32 pifGet16(struct __anon_0x4A974* pPIF, u32 nAddress, s16* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x0
|
||||
// u32 nAddress; // r1+0x4
|
||||
// s16* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006C7F8 -> 0x8006C82C
|
||||
static s32 pifGet8(struct __anon_0x4A974* pPIF, u32 nAddress, char* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x0
|
||||
// u32 nAddress; // r1+0x4
|
||||
// char* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006C82C -> 0x8006C860
|
||||
static s32 pifPut64(struct __anon_0x4A974* pPIF, u32 nAddress, s64* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x0
|
||||
// u32 nAddress; // r1+0x4
|
||||
// s64* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006C860 -> 0x8006C888
|
||||
static s32 pifPut32(struct __anon_0x4A974* pPIF, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x0
|
||||
// u32 nAddress; // r1+0x4
|
||||
// s32* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006C888 -> 0x8006C8B0
|
||||
static s32 pifPut16(struct __anon_0x4A974* pPIF, u32 nAddress, s16* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x0
|
||||
// u32 nAddress; // r1+0x4
|
||||
// s16* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006C8B0 -> 0x8006C8D4
|
||||
static s32 pifPut8(struct __anon_0x4A974* pPIF, u32 nAddress, char* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x0
|
||||
// u32 nAddress; // r1+0x4
|
||||
// char* pData; // r1+0x8
|
||||
}
|
||||
|
||||
typedef enum __anon_0x4B3FE {
|
||||
CT_NONE = 0,
|
||||
CT_CONTROLLER = 1,
|
||||
CT_CONTROLLER_W_PAK = 2,
|
||||
CT_CONTROLLER_W_RPAK = 3,
|
||||
CT_MOUSE = 4,
|
||||
CT_VOICE = 5,
|
||||
CT_4K = 6,
|
||||
CT_16K = 7,
|
||||
CT_COUNT = 8,
|
||||
} __anon_0x4B3FE;
|
||||
|
||||
// Erased
|
||||
static s32 pifReadController(struct __anon_0x4A974* pPIF, u8* buffer, u8* prx, s32 channel) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x8
|
||||
// u8* buffer; // r4
|
||||
// u8* prx; // r1+0x14
|
||||
// s32 channel; // r7
|
||||
|
||||
// Local variables
|
||||
enum __anon_0x4B3FE type; // r1+0x8
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 pifQueryController(struct __anon_0x4A974* pPIF, u8* buffer, u8* prx, s32 channel) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x0
|
||||
// u8* buffer; // r1+0x4
|
||||
// u8* prx; // r1+0xC
|
||||
// s32 channel; // r1+0x10
|
||||
}
|
||||
|
||||
// Range: 0x8006C8D4 -> 0x8006C918
|
||||
s32 pifGetEEPROMSize(struct __anon_0x4A974* pPIF, u32* size) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x0
|
||||
// u32* size; // r1+0x4
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 pifGetControllerType(struct __anon_0x4A974* pPIF, s32 channel, u16* type, char* status) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x0
|
||||
// s32 channel; // r1+0x4
|
||||
// u16* type; // r1+0x8
|
||||
// char* status; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
enum __anon_0x4B3FE eType; // r1+0x0
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 pifGetControllerInput(s32 channel, u32* controllerInput) {
|
||||
// Parameters
|
||||
// s32 channel; // r4
|
||||
// u32* controllerInput; // r5
|
||||
}
|
||||
|
||||
// Range: 0x8006C918 -> 0x8006C97C
|
||||
s32 pifSetEEPROMType(struct __anon_0x4A974* pPIF, enum __anon_0x4B3FE type) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x0
|
||||
// enum __anon_0x4B3FE type; // r1+0x4
|
||||
}
|
||||
|
||||
// Range: 0x8006C97C -> 0x8006C994
|
||||
s32 pifGetEControllerType(struct __anon_0x4A974* pPIF, s32 channel, enum __anon_0x4B3FE* type) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r1+0x0
|
||||
// s32 channel; // r1+0x4
|
||||
// enum __anon_0x4B3FE* type; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006C994 -> 0x8006CAA4
|
||||
s32 pifSetControllerType(struct __anon_0x4A974* pPIF, s32 channel, enum __anon_0x4B3FE type) {
|
||||
// Parameters
|
||||
// struct __anon_0x4A974* pPIF; // r29
|
||||
// s32 channel; // r30
|
||||
// enum __anon_0x4B3FE type; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8006CAA4 -> 0x8006CC1C
|
||||
static u8 pifContDataCrc(u8* data) {
|
||||
// Parameters
|
||||
// u8* data; // r4
|
||||
|
||||
// Local variables
|
||||
u32 temp; // r3
|
||||
u32 i; // r5
|
||||
u32 j; // r6
|
||||
}
|
||||
|
||||
// Range: 0x8006CC1C -> 0x8006CC74
|
||||
s32 pifWriteRumble(s32 channel, u16 address, u8* data) {
|
||||
// Parameters
|
||||
// s32 channel; // r4
|
||||
// u16 address; // r1+0x10
|
||||
// u8* data; // r1+0x14
|
||||
}
|
||||
|
||||
// Range: 0x8006CC74 -> 0x8006CD98
|
||||
s32 pifReadRumble(u16 address, u8* data) {
|
||||
// Parameters
|
||||
// u16 address; // r1+0x8
|
||||
// u8* data; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
s32 i; // r1+0x0
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 pifIdCheckSum(u16* ptr, u16* csum, u16* icsum) {
|
||||
// Parameters
|
||||
// u16* ptr; // r4
|
||||
// u16* csum; // r1+0x8
|
||||
// u16* icsum; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
u16 data; // r7
|
||||
u32 j; // r1+0x0
|
||||
}
|
||||
|
||||
+185
-114
@@ -1,114 +1,185 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x800ED6C8
|
||||
_XL_OBJECTTYPE gClassRAM;
|
||||
|
||||
// size: 0xC
|
||||
struct __anon_0x4BFE7
|
||||
{
|
||||
void *pHost; // 0x0
|
||||
void *pBuffer; // 0x4
|
||||
unsigned int nSize; // 0x8
|
||||
};
|
||||
|
||||
int ramEvent(__anon_0x4BFE7 *pRAM, int nEvent, void *pArgument);
|
||||
|
||||
int ramGetSize(__anon_0x4BFE7 *pRAM, unsigned int *pnSize);
|
||||
|
||||
int ramSetSize(__anon_0x4BFE7 *pRAM, unsigned int nSize);
|
||||
|
||||
int ramWipe(__anon_0x4BFE7 *pRAM);
|
||||
|
||||
int ramGetBuffer(__anon_0x4BFE7 *pRAM, void *ppRAM, unsigned int nOffset, unsigned int *pnSize);
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramGet64(__anon_0x4BFE7 *pRAM, unsigned int nAddress, signed long long *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramGet32(__anon_0x4BFE7 *pRAM, unsigned int nAddress, int *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramGet16(__anon_0x4BFE7 *pRAM, unsigned int nAddress, signed short *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramGet8(__anon_0x4BFE7 *pRAM, unsigned int nAddress, char *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramPut64(__anon_0x4BFE7 *pRAM, unsigned int nAddress, signed long long *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramPut32(__anon_0x4BFE7 *pRAM, unsigned int nAddress, int *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramPut16(__anon_0x4BFE7 *pRAM, unsigned int nAddress, signed short *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramPut8(__anon_0x4BFE7 *pRAM, unsigned int nAddress, char *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramGetRI64();
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramGetRI32(unsigned int nAddress);
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramGetRI16();
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramGetRI8();
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramPutRI64();
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramPutRI32(unsigned int nAddress);
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramPutRI16();
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramPutRI8();
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramGetControl64();
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramGetControl32(unsigned int nAddress);
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramGetControl16();
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramGetControl8();
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramPutControl64();
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramPutControl32(unsigned int nAddress);
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramPutControl16();
|
||||
|
||||
// Local to compilation unit
|
||||
static int ramPutControl8();
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\ram.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x8006CD98 -> 0x8006D3AC
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x4BEF6; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800ED6C8
|
||||
struct _XL_OBJECTTYPE gClassRAM;
|
||||
|
||||
typedef struct __anon_0x4BFE7 {
|
||||
/* 0x0 */ void* pHost;
|
||||
/* 0x4 */ void* pBuffer;
|
||||
/* 0x8 */ u32 nSize;
|
||||
} __anon_0x4BFE7; // size = 0xC
|
||||
|
||||
// Range: 0x8006CD98 -> 0x8006CFD0
|
||||
s32 ramEvent(struct __anon_0x4BFE7* pRAM, s32 nEvent, void* pArgument) {
|
||||
// Parameters
|
||||
// struct __anon_0x4BFE7* pRAM; // r30
|
||||
// s32 nEvent; // r1+0xC
|
||||
// void* pArgument; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8006CFD0 -> 0x8006CFE8
|
||||
s32 ramGetSize(struct __anon_0x4BFE7* pRAM, u32* pnSize) {
|
||||
// Parameters
|
||||
// struct __anon_0x4BFE7* pRAM; // r1+0x0
|
||||
// u32* pnSize; // r1+0x4
|
||||
}
|
||||
|
||||
// Range: 0x8006CFE8 -> 0x8006D058
|
||||
s32 ramSetSize(struct __anon_0x4BFE7* pRAM, u32 nSize) {
|
||||
// Parameters
|
||||
// struct __anon_0x4BFE7* pRAM; // r30
|
||||
// u32 nSize; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8006D058 -> 0x8006D0A0
|
||||
s32 ramWipe(struct __anon_0x4BFE7* pRAM) {
|
||||
// Parameters
|
||||
// struct __anon_0x4BFE7* pRAM; // r3
|
||||
}
|
||||
|
||||
// Range: 0x8006D0A0 -> 0x8006D0F8
|
||||
s32 ramGetBuffer(struct __anon_0x4BFE7* pRAM, void* ppRAM, u32 nOffset, u32* pnSize) {
|
||||
// Parameters
|
||||
// struct __anon_0x4BFE7* pRAM; // r1+0x0
|
||||
// void* ppRAM; // r1+0x4
|
||||
// u32 nOffset; // r5
|
||||
// u32* pnSize; // r1+0xC
|
||||
}
|
||||
|
||||
// Range: 0x8006D0F8 -> 0x8006D13C
|
||||
static s32 ramGet64(struct __anon_0x4BFE7* pRAM, u32 nAddress, s64* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4BFE7* pRAM; // r1+0x0
|
||||
// u32 nAddress; // r4
|
||||
// s64* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006D13C -> 0x8006D170
|
||||
static s32 ramGet32(struct __anon_0x4BFE7* pRAM, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4BFE7* pRAM; // r1+0x0
|
||||
// u32 nAddress; // r4
|
||||
// s32* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006D170 -> 0x8006D1A4
|
||||
static s32 ramGet16(struct __anon_0x4BFE7* pRAM, u32 nAddress, s16* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4BFE7* pRAM; // r1+0x0
|
||||
// u32 nAddress; // r4
|
||||
// s16* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006D1A4 -> 0x8006D1D4
|
||||
static s32 ramGet8(struct __anon_0x4BFE7* pRAM, u32 nAddress, char* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4BFE7* pRAM; // r1+0x0
|
||||
// u32 nAddress; // r4
|
||||
// char* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006D1D4 -> 0x8006D208
|
||||
static s32 ramPut64(struct __anon_0x4BFE7* pRAM, u32 nAddress, s64* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4BFE7* pRAM; // r1+0x0
|
||||
// u32 nAddress; // r4
|
||||
// s64* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006D208 -> 0x8006D230
|
||||
static s32 ramPut32(struct __anon_0x4BFE7* pRAM, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4BFE7* pRAM; // r1+0x0
|
||||
// u32 nAddress; // r6
|
||||
// s32* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006D230 -> 0x8006D258
|
||||
static s32 ramPut16(struct __anon_0x4BFE7* pRAM, u32 nAddress, s16* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4BFE7* pRAM; // r1+0x0
|
||||
// u32 nAddress; // r6
|
||||
// s16* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006D258 -> 0x8006D27C
|
||||
static s32 ramPut8(struct __anon_0x4BFE7* pRAM, u32 nAddress, char* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x4BFE7* pRAM; // r1+0x0
|
||||
// u32 nAddress; // r6
|
||||
// char* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8006D27C -> 0x8006D284
|
||||
static s32 ramGetRI64() {}
|
||||
|
||||
// Range: 0x8006D284 -> 0x8006D2B8
|
||||
static s32 ramGetRI32(u32 nAddress) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0x4
|
||||
}
|
||||
|
||||
// Range: 0x8006D2B8 -> 0x8006D2C0
|
||||
static s32 ramGetRI16() {}
|
||||
|
||||
// Range: 0x8006D2C0 -> 0x8006D2C8
|
||||
static s32 ramGetRI8() {}
|
||||
|
||||
// Range: 0x8006D2C8 -> 0x8006D2D0
|
||||
static s32 ramPutRI64() {}
|
||||
|
||||
// Range: 0x8006D2D0 -> 0x8006D304
|
||||
static s32 ramPutRI32(u32 nAddress) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0x4
|
||||
}
|
||||
|
||||
// Range: 0x8006D304 -> 0x8006D30C
|
||||
static s32 ramPutRI16() {}
|
||||
|
||||
// Range: 0x8006D30C -> 0x8006D314
|
||||
static s32 ramPutRI8() {}
|
||||
|
||||
// Range: 0x8006D314 -> 0x8006D31C
|
||||
static s32 ramGetControl64() {}
|
||||
|
||||
// Range: 0x8006D31C -> 0x8006D350
|
||||
static s32 ramGetControl32(u32 nAddress) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0x4
|
||||
}
|
||||
|
||||
// Range: 0x8006D350 -> 0x8006D358
|
||||
static s32 ramGetControl16() {}
|
||||
|
||||
// Range: 0x8006D358 -> 0x8006D360
|
||||
static s32 ramGetControl8() {}
|
||||
|
||||
// Range: 0x8006D360 -> 0x8006D368
|
||||
static s32 ramPutControl64() {}
|
||||
|
||||
// Range: 0x8006D368 -> 0x8006D39C
|
||||
static s32 ramPutControl32(u32 nAddress) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0x4
|
||||
}
|
||||
|
||||
// Range: 0x8006D39C -> 0x8006D3A4
|
||||
static s32 ramPutControl16() {}
|
||||
|
||||
// Range: 0x8006D3A4 -> 0x8006D3AC
|
||||
static s32 ramPutControl8() {}
|
||||
|
||||
+70
-64
@@ -1,64 +1,70 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x800EE1B0
|
||||
_XL_OBJECTTYPE gClassRdb;
|
||||
|
||||
// size: 0x110
|
||||
struct __anon_0x56A0F
|
||||
{
|
||||
int nHackCount; // 0x0
|
||||
char szString[256]; // 0x4
|
||||
int nIndexString; // 0x104
|
||||
int nAddress; // 0x108
|
||||
void *pHost; // 0x10C
|
||||
};
|
||||
|
||||
int rdbEvent(__anon_0x56A0F *pRDB, int nEvent, void *pArgument);
|
||||
|
||||
// Local to compilation unit
|
||||
static int rdbGet64();
|
||||
|
||||
// Local to compilation unit
|
||||
static int rdbGet32(unsigned int nAddress);
|
||||
|
||||
// Local to compilation unit
|
||||
static int rdbGet16();
|
||||
|
||||
// Local to compilation unit
|
||||
static int rdbGet8();
|
||||
|
||||
// Local to compilation unit
|
||||
static int rdbPut64();
|
||||
|
||||
// Local to compilation unit
|
||||
static int rdbPut32(__anon_0x56A0F *pRDB, unsigned int nAddress, int *pData)
|
||||
{
|
||||
int nLength;
|
||||
int iCounter;
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int rdbPut16();
|
||||
|
||||
// Local to compilation unit
|
||||
static int rdbPut8();
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\rdb.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x800715D0 -> 0x80071BB8
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x568FE; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800EE1B0
|
||||
struct _XL_OBJECTTYPE gClassRdb;
|
||||
|
||||
typedef struct __anon_0x56A0F {
|
||||
/* 0x000 */ s32 nHackCount;
|
||||
/* 0x004 */ char szString[256];
|
||||
/* 0x104 */ s32 nIndexString;
|
||||
/* 0x108 */ s32 nAddress;
|
||||
/* 0x10C */ void* pHost;
|
||||
} __anon_0x56A0F; // size = 0x110
|
||||
|
||||
// Range: 0x800715D0 -> 0x800716D8
|
||||
s32 rdbEvent(struct __anon_0x56A0F* pRDB, s32 nEvent, void* pArgument) {
|
||||
// Parameters
|
||||
// struct __anon_0x56A0F* pRDB; // r30
|
||||
// s32 nEvent; // r1+0xC
|
||||
// void* pArgument; // r31
|
||||
}
|
||||
|
||||
// Range: 0x800716D8 -> 0x800716E0
|
||||
static s32 rdbGet64() {}
|
||||
|
||||
// Range: 0x800716E0 -> 0x80071714
|
||||
static s32 rdbGet32(u32 nAddress) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0x4
|
||||
}
|
||||
|
||||
// Range: 0x80071714 -> 0x8007171C
|
||||
static s32 rdbGet16() {}
|
||||
|
||||
// Range: 0x8007171C -> 0x80071724
|
||||
static s32 rdbGet8() {}
|
||||
|
||||
// Range: 0x80071724 -> 0x8007172C
|
||||
static s32 rdbPut64() {}
|
||||
|
||||
// Range: 0x8007172C -> 0x80071BA8
|
||||
static s32 rdbPut32(struct __anon_0x56A0F* pRDB, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x56A0F* pRDB; // r3
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s32* pData; // r1+0x10
|
||||
|
||||
// Local variables
|
||||
s32 nLength; // r7
|
||||
s32 iCounter; // r5
|
||||
}
|
||||
|
||||
// Range: 0x80071BA8 -> 0x80071BB0
|
||||
static s32 rdbPut16() {}
|
||||
|
||||
// Range: 0x80071BB0 -> 0x80071BB8
|
||||
static s32 rdbPut8() {}
|
||||
|
||||
+575
-613
File diff suppressed because it is too large
Load Diff
+936
-809
File diff suppressed because it is too large
Load Diff
+1340
-1396
File diff suppressed because it is too large
Load Diff
+1026
-469
File diff suppressed because it is too large
Load Diff
+69
-53
@@ -1,53 +1,69 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x28EA0E80
|
||||
_XL_OBJECTTYPE gClassSerial;
|
||||
|
||||
// size: 0x8
|
||||
struct __anon_0x78791
|
||||
{
|
||||
void *pHost; // 0x0
|
||||
int nAddress; // 0x4
|
||||
};
|
||||
|
||||
int serialEvent(__anon_0x78791 *pSerial, int nEvent, void *pArgument);
|
||||
|
||||
int serialGet64();
|
||||
|
||||
int serialGet32(__anon_0x78791 *pSerial, unsigned int nAddress, int *pData);
|
||||
|
||||
int serialGet16();
|
||||
|
||||
int serialGet8();
|
||||
|
||||
int serialPut64();
|
||||
|
||||
int serialPut32(__anon_0x78791 *pSerial, unsigned int nAddress, int *pData)
|
||||
{
|
||||
int nSize;
|
||||
void *aData;
|
||||
}
|
||||
|
||||
int serialPut16();
|
||||
|
||||
int serialPut8();
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\serial.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x8008EE20 -> 0x8008F0F4
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x7869D; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800EEA28
|
||||
struct _XL_OBJECTTYPE gClassSerial;
|
||||
|
||||
typedef struct __anon_0x78791 {
|
||||
/* 0x0 */ void* pHost;
|
||||
/* 0x4 */ s32 nAddress;
|
||||
} __anon_0x78791; // size = 0x8
|
||||
|
||||
// Range: 0x8008EE20 -> 0x8008EF20
|
||||
s32 serialEvent(struct __anon_0x78791* pSerial, s32 nEvent, void* pArgument) {
|
||||
// Parameters
|
||||
// struct __anon_0x78791* pSerial; // r30
|
||||
// s32 nEvent; // r1+0xC
|
||||
// void* pArgument; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8008EF20 -> 0x8008EF28
|
||||
s32 serialGet64() {}
|
||||
|
||||
// Range: 0x8008EF28 -> 0x8008EF8C
|
||||
s32 serialGet32(struct __anon_0x78791* pSerial, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x78791* pSerial; // r1+0x0
|
||||
// u32 nAddress; // r1+0x4
|
||||
// s32* pData; // r1+0x8
|
||||
}
|
||||
|
||||
// Range: 0x8008EF8C -> 0x8008EF94
|
||||
s32 serialGet16() {}
|
||||
|
||||
// Range: 0x8008EF94 -> 0x8008EF9C
|
||||
s32 serialGet8() {}
|
||||
|
||||
// Range: 0x8008EF9C -> 0x8008EFA4
|
||||
s32 serialPut64() {}
|
||||
|
||||
// Range: 0x8008EFA4 -> 0x8008F0E4
|
||||
s32 serialPut32(struct __anon_0x78791* pSerial, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x78791* pSerial; // r31
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s32* pData; // r1+0x10
|
||||
|
||||
// Local variables
|
||||
s32 nSize; // r1+0x18
|
||||
void* aData; // r1+0x14
|
||||
}
|
||||
|
||||
// Range: 0x8008F0E4 -> 0x8008F0EC
|
||||
s32 serialPut16() {}
|
||||
|
||||
// Range: 0x8008F0EC -> 0x8008F0F4
|
||||
s32 serialPut8() {}
|
||||
|
||||
+1816
-1651
File diff suppressed because it is too large
Load Diff
+359
-321
@@ -1,321 +1,359 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x800EA7D8
|
||||
_XL_OBJECTTYPE gClassSound;
|
||||
|
||||
// Location: 0x0
|
||||
int sCapture$219;
|
||||
|
||||
// Location: 0x80108180
|
||||
long gVolumeCurve[257];
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x2084C
|
||||
{
|
||||
SPM_NONE = 4294967295,
|
||||
SPM_PLAY = 0,
|
||||
SPM_RAMPQUEUED = 1,
|
||||
SPM_RAMPPLAYED = 2
|
||||
};
|
||||
|
||||
// size: 0xD8
|
||||
struct __anon_0x208BA
|
||||
{
|
||||
void *pSrcData; // 0x0
|
||||
int nFrequency; // 0x4
|
||||
int nDacrate; // 0x8
|
||||
int nSndLen; // 0xC
|
||||
void *apBuffer[16]; // 0x10
|
||||
int anSizeBuffer[16]; // 0x50
|
||||
int nCountBeep; // 0x90
|
||||
int anSizeBeep[3]; // 0x94
|
||||
void *apDataBeep[3]; // 0xA0
|
||||
int iBufferPlay; // 0xAC
|
||||
int iBufferMake; // 0xB0
|
||||
__anon_0x2084C eMode; // 0xB4
|
||||
void *pBufferZero; // 0xB8
|
||||
void *pBufferHold; // 0xBC
|
||||
void *pBufferRampUp; // 0xC0
|
||||
void *pBufferRampDown; // 0xC4
|
||||
int nSizePlay; // 0xC8
|
||||
int nSizeZero; // 0xCC
|
||||
int nSizeHold; // 0xD0
|
||||
int nSizeRamp; // 0xD4
|
||||
};
|
||||
|
||||
int soundEvent(__anon_0x208BA *pSound, int nEvent)
|
||||
{
|
||||
int iBuffer;
|
||||
// References: gVolumeCurve (0x80108180)
|
||||
}
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x20C8D
|
||||
{
|
||||
SOUND_BEEP_ACCEPT = 0,
|
||||
SOUND_BEEP_DECLINE = 1,
|
||||
SOUND_BEEP_SELECT = 2,
|
||||
SOUND_BEEP_COUNT = 3
|
||||
};
|
||||
|
||||
int soundFreeBeep(__anon_0x208BA *pSound, __anon_0x20C8D iBeep);
|
||||
|
||||
int soundPlayBeep(__anon_0x208BA *pSound, __anon_0x20C8D iBeep);
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x20E13
|
||||
{
|
||||
XLFT_NONE = 4294967295,
|
||||
XLFT_TEXT = 0,
|
||||
XLFT_BINARY = 1
|
||||
};
|
||||
|
||||
// size: 0x20
|
||||
struct DVDDiskID
|
||||
{
|
||||
char gameName[4]; // 0x0
|
||||
char company[2]; // 0x4
|
||||
unsigned char diskNumber; // 0x6
|
||||
unsigned char gameVersion; // 0x7
|
||||
unsigned char streaming; // 0x8
|
||||
unsigned char streamingBufSize; // 0x9
|
||||
unsigned char padding[22]; // 0xA
|
||||
};
|
||||
|
||||
// size: 0x30
|
||||
struct DVDCommandBlock
|
||||
{
|
||||
DVDCommandBlock *next; // 0x0
|
||||
DVDCommandBlock *prev; // 0x4
|
||||
unsigned long command; // 0x8
|
||||
long state; // 0xC
|
||||
unsigned long offset; // 0x10
|
||||
unsigned long length; // 0x14
|
||||
void *addr; // 0x18
|
||||
unsigned long currTransferSize; // 0x1C
|
||||
unsigned long transferredSize; // 0x20
|
||||
DVDDiskID *id; // 0x24
|
||||
void (*callback)(long /* unknown0 */, DVDCommandBlock */* unknown1 */); // 0x28
|
||||
void *userData; // 0x2C
|
||||
};
|
||||
|
||||
// size: 0x3C
|
||||
struct DVDFileInfo
|
||||
{
|
||||
DVDCommandBlock cb; // 0x0
|
||||
unsigned long startAddr; // 0x30
|
||||
unsigned long length; // 0x34
|
||||
void (*callback)(long /* unknown0 */, DVDFileInfo */* unknown1 */); // 0x38
|
||||
};
|
||||
|
||||
// size: 0x58
|
||||
struct tXL_FILE
|
||||
{
|
||||
int iBuffer; // 0x0
|
||||
void *pData; // 0x4
|
||||
void *pBuffer; // 0x8
|
||||
int nAttributes; // 0xC
|
||||
int nSize; // 0x10
|
||||
int nOffset; // 0x14
|
||||
__anon_0x20E13 eType; // 0x18
|
||||
DVDFileInfo info; // 0x1C
|
||||
};
|
||||
|
||||
int soundLoadBeep(__anon_0x208BA *pSound, __anon_0x20C8D iBeep, char *szNameFile)
|
||||
{
|
||||
tXL_FILE *pFile;
|
||||
}
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x2152F
|
||||
{
|
||||
SM_NONE = 4294967295,
|
||||
SM_RUNNING = 0,
|
||||
SM_STOPPED = 1
|
||||
};
|
||||
|
||||
// size: 0x10
|
||||
struct __anon_0x21596
|
||||
{
|
||||
int nSize; // 0x0
|
||||
int nOffsetRAM; // 0x4
|
||||
int nOffsetROM; // 0x8
|
||||
int (*pCallback)(); // 0xC
|
||||
};
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x21647
|
||||
{
|
||||
SRT_NONE = 4294967295,
|
||||
SRT_MARIO = 0,
|
||||
SRT_WAVERACE = 1,
|
||||
SRT_MARIOKART = 2,
|
||||
SRT_STARFOX = 3,
|
||||
SRT_ZELDA1 = 4,
|
||||
SRT_ZELDA2 = 5,
|
||||
SRT_1080 = 6,
|
||||
SRT_PANEL = 7,
|
||||
SRT_MARIOPARTY1 = 8,
|
||||
SRT_MARIOPARTY2 = 9,
|
||||
SRT_MARIOPARTY3 = 10,
|
||||
SRT_DRMARIO = 11,
|
||||
SRT_UNKNOWN = 12
|
||||
};
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x21778
|
||||
{
|
||||
SOT_NONE = 4294967295,
|
||||
SOT_CPU = 0,
|
||||
SOT_PIF = 1,
|
||||
SOT_RAM = 2,
|
||||
SOT_ROM = 3,
|
||||
SOT_RSP = 4,
|
||||
SOT_RDP = 5,
|
||||
SOT_MIPS = 6,
|
||||
SOT_DISK = 7,
|
||||
SOT_FLASH = 8,
|
||||
SOT_SRAM = 9,
|
||||
SOT_AUDIO = 10,
|
||||
SOT_VIDEO = 11,
|
||||
SOT_SERIAL = 12,
|
||||
SOT_LIBRARY = 13,
|
||||
SOT_PERIPHERAL = 14,
|
||||
SOT_RDB = 15,
|
||||
SOT_COUNT = 16
|
||||
};
|
||||
|
||||
// size: 0x88
|
||||
struct __anon_0x218B8
|
||||
{
|
||||
void *pFrame; // 0x0
|
||||
void *pSound; // 0x4
|
||||
int bException; // 0x8
|
||||
__anon_0x2152F eMode; // 0xC
|
||||
__anon_0x21596 romCopy; // 0x10
|
||||
__anon_0x21647 eTypeROM; // 0x20
|
||||
void *apObject[16]; // 0x24
|
||||
unsigned long long nAddressBreak; // 0x68
|
||||
__anon_0x21778 storageDevice; // 0x70
|
||||
unsigned char anException[16]; // 0x74
|
||||
int bJapaneseVersion; // 0x84
|
||||
};
|
||||
|
||||
// Location: 0x561380
|
||||
__anon_0x218B8 *gpSystem;
|
||||
|
||||
// Local to compilation unit
|
||||
static void soundCallbackBeep()
|
||||
{
|
||||
__anon_0x208BA *pSound;
|
||||
// References: gpSystem (0x561380)
|
||||
}
|
||||
|
||||
void InitVolumeCurve()
|
||||
{
|
||||
long i;
|
||||
// References: gVolumeCurve (0x80108180)
|
||||
}
|
||||
|
||||
int soundSetBufferSize(__anon_0x208BA *pSound, int nSize)
|
||||
{
|
||||
int iBuffer;
|
||||
}
|
||||
|
||||
int soundGetDMABuffer(unsigned int *pnSize);
|
||||
|
||||
int soundSetAddress(__anon_0x208BA *pSound, void *pData);
|
||||
|
||||
int soundSetBitRate();
|
||||
|
||||
int soundSetDACRate(__anon_0x208BA *pSound, int nDacRate);
|
||||
|
||||
int soundSetLength(__anon_0x208BA *pSound, int nSize);
|
||||
|
||||
// Local to compilation unit
|
||||
static int soundMakeBuffer(__anon_0x208BA *pSound)
|
||||
{
|
||||
unsigned long nSamples;
|
||||
signed short *curBufP;
|
||||
unsigned long sampleStep;
|
||||
unsigned long sample;
|
||||
int j;
|
||||
int nSize;
|
||||
int samp;
|
||||
int iBuffer;
|
||||
long vol;
|
||||
int bFlag;
|
||||
int bPlay;
|
||||
long volAdjust;
|
||||
// References: gVolumeCurve (0x80108180)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static void soundCallbackDMA()
|
||||
{
|
||||
// References: gpSystem (0x561380)
|
||||
}
|
||||
|
||||
// Local to compilation unit
|
||||
static int soundPlayBuffer(__anon_0x208BA *pSound)
|
||||
{
|
||||
void *pData;
|
||||
int iBuffer;
|
||||
int nSize;
|
||||
}
|
||||
|
||||
int soundMakeHold();
|
||||
|
||||
int soundMakeZero(__anon_0x208BA *pSound)
|
||||
{
|
||||
int iData;
|
||||
}
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x221A3
|
||||
{
|
||||
SR_NONE = 4294967295,
|
||||
SR_DECREASE = 0,
|
||||
SR_INCREASE = 1
|
||||
};
|
||||
|
||||
// Local to compilation unit
|
||||
static int soundMakeRamp(__anon_0x208BA *pSound, int iBuffer, __anon_0x221A3 eRamp)
|
||||
{
|
||||
int bFlag;
|
||||
int iData;
|
||||
signed short *anData;
|
||||
signed short nData0;
|
||||
signed short nData1;
|
||||
signed short nGoal0;
|
||||
signed short nGoal1;
|
||||
signed short nStep0;
|
||||
signed short nStep1;
|
||||
signed short nLast0;
|
||||
signed short nLast1;
|
||||
}
|
||||
|
||||
int soundWipeBuffers(__anon_0x208BA *pSound)
|
||||
{
|
||||
int iBuffer;
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\soundGCN.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x8001C498 -> 0x8001D34C
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x20667; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800EA7D8
|
||||
struct _XL_OBJECTTYPE gClassSound;
|
||||
|
||||
// size = 0x404, address = 0x80108180
|
||||
s32 gVolumeCurve[257];
|
||||
|
||||
typedef enum __anon_0x2084C {
|
||||
SPM_NONE = -1,
|
||||
SPM_PLAY = 0,
|
||||
SPM_RAMPQUEUED = 1,
|
||||
SPM_RAMPPLAYED = 2,
|
||||
} __anon_0x2084C;
|
||||
|
||||
typedef struct __anon_0x208BA {
|
||||
/* 0x00 */ void* pSrcData;
|
||||
/* 0x04 */ s32 nFrequency;
|
||||
/* 0x08 */ s32 nDacrate;
|
||||
/* 0x0C */ s32 nSndLen;
|
||||
/* 0x10 */ void* apBuffer[16];
|
||||
/* 0x50 */ s32 anSizeBuffer[16];
|
||||
/* 0x90 */ s32 nCountBeep;
|
||||
/* 0x94 */ s32 anSizeBeep[3];
|
||||
/* 0xA0 */ void* apDataBeep[3];
|
||||
/* 0xAC */ s32 iBufferPlay;
|
||||
/* 0xB0 */ s32 iBufferMake;
|
||||
/* 0xB4 */ enum __anon_0x2084C eMode;
|
||||
/* 0xB8 */ void* pBufferZero;
|
||||
/* 0xBC */ void* pBufferHold;
|
||||
/* 0xC0 */ void* pBufferRampUp;
|
||||
/* 0xC4 */ void* pBufferRampDown;
|
||||
/* 0xC8 */ s32 nSizePlay;
|
||||
/* 0xCC */ s32 nSizeZero;
|
||||
/* 0xD0 */ s32 nSizeHold;
|
||||
/* 0xD4 */ s32 nSizeRamp;
|
||||
} __anon_0x208BA; // size = 0xD8
|
||||
|
||||
// Range: 0x8001C498 -> 0x8001C690
|
||||
s32 soundEvent(struct __anon_0x208BA* pSound, s32 nEvent) {
|
||||
// Parameters
|
||||
// struct __anon_0x208BA* pSound; // r3
|
||||
// s32 nEvent; // r1+0xC
|
||||
|
||||
// Local variables
|
||||
s32 iBuffer; // r1+0x8
|
||||
|
||||
// References
|
||||
// -> s32 gVolumeCurve[257];
|
||||
}
|
||||
|
||||
typedef enum __anon_0x20C8D {
|
||||
SOUND_BEEP_ACCEPT = 0,
|
||||
SOUND_BEEP_DECLINE = 1,
|
||||
SOUND_BEEP_SELECT = 2,
|
||||
SOUND_BEEP_COUNT = 3,
|
||||
} __anon_0x20C8D;
|
||||
|
||||
// Erased
|
||||
static s32 soundFreeBeep(struct __anon_0x208BA* pSound, enum __anon_0x20C8D iBeep) {
|
||||
// Parameters
|
||||
// struct __anon_0x208BA* pSound; // r5
|
||||
// enum __anon_0x20C8D iBeep; // r1+0xC
|
||||
}
|
||||
|
||||
// Range: 0x8001C690 -> 0x8001C70C
|
||||
s32 soundPlayBeep(struct __anon_0x208BA* pSound, enum __anon_0x20C8D iBeep) {
|
||||
// Parameters
|
||||
// struct __anon_0x208BA* pSound; // r29
|
||||
// enum __anon_0x20C8D iBeep; // r1+0xC
|
||||
}
|
||||
|
||||
typedef enum __anon_0x20E13 {
|
||||
XLFT_NONE = -1,
|
||||
XLFT_TEXT = 0,
|
||||
XLFT_BINARY = 1,
|
||||
} __anon_0x20E13;
|
||||
|
||||
typedef struct DVDDiskID {
|
||||
/* 0x0 */ char gameName[4];
|
||||
/* 0x4 */ char company[2];
|
||||
/* 0x6 */ u8 diskNumber;
|
||||
/* 0x7 */ u8 gameVersion;
|
||||
/* 0x8 */ u8 streaming;
|
||||
/* 0x9 */ u8 streamingBufSize;
|
||||
/* 0xA */ u8 padding[22];
|
||||
} __anon_0x20ECC; // size = 0x20
|
||||
|
||||
typedef struct DVDCommandBlock {
|
||||
/* 0x00 */ struct DVDCommandBlock* next;
|
||||
/* 0x04 */ struct DVDCommandBlock* prev;
|
||||
/* 0x08 */ u32 command;
|
||||
/* 0x0C */ s32 state;
|
||||
/* 0x10 */ u32 offset;
|
||||
/* 0x14 */ u32 length;
|
||||
/* 0x18 */ void* addr;
|
||||
/* 0x1C */ u32 currTransferSize;
|
||||
/* 0x20 */ u32 transferredSize;
|
||||
/* 0x24 */ struct DVDDiskID* id;
|
||||
/* 0x28 */ void (*callback)(s32, struct DVDCommandBlock*);
|
||||
/* 0x2C */ void* userData;
|
||||
} __anon_0x2103C; // size = 0x30
|
||||
|
||||
typedef struct DVDFileInfo {
|
||||
/* 0x00 */ struct DVDCommandBlock cb;
|
||||
/* 0x30 */ u32 startAddr;
|
||||
/* 0x34 */ u32 length;
|
||||
/* 0x38 */ void (*callback)(s32, struct DVDFileInfo*);
|
||||
} __anon_0x21262; // size = 0x3C
|
||||
|
||||
typedef struct tXL_FILE {
|
||||
/* 0x00 */ s32 iBuffer;
|
||||
/* 0x04 */ void* pData;
|
||||
/* 0x08 */ void* pBuffer;
|
||||
/* 0x0C */ s32 nAttributes;
|
||||
/* 0x10 */ s32 nSize;
|
||||
/* 0x14 */ s32 nOffset;
|
||||
/* 0x18 */ enum __anon_0x20E13 eType;
|
||||
/* 0x1C */ struct DVDFileInfo info;
|
||||
} __anon_0x2131A; // size = 0x58
|
||||
|
||||
// Range: 0x8001C70C -> 0x8001C824
|
||||
s32 soundLoadBeep(struct __anon_0x208BA* pSound, enum __anon_0x20C8D iBeep, char* szNameFile) {
|
||||
// Parameters
|
||||
// struct __anon_0x208BA* pSound; // r28
|
||||
// enum __anon_0x20C8D iBeep; // r1+0xC
|
||||
// char* szNameFile; // r5
|
||||
|
||||
// Local variables
|
||||
struct tXL_FILE* pFile; // r1+0x14
|
||||
}
|
||||
|
||||
typedef enum __anon_0x2152F {
|
||||
SM_NONE = -1,
|
||||
SM_RUNNING = 0,
|
||||
SM_STOPPED = 1,
|
||||
} __anon_0x2152F;
|
||||
|
||||
typedef struct __anon_0x21596 {
|
||||
/* 0x0 */ s32 nSize;
|
||||
/* 0x4 */ s32 nOffsetRAM;
|
||||
/* 0x8 */ s32 nOffsetROM;
|
||||
/* 0xC */ s32 (*pCallback)();
|
||||
} __anon_0x21596; // size = 0x10
|
||||
|
||||
typedef enum __anon_0x21647 {
|
||||
SRT_NONE = -1,
|
||||
SRT_MARIO = 0,
|
||||
SRT_WAVERACE = 1,
|
||||
SRT_MARIOKART = 2,
|
||||
SRT_STARFOX = 3,
|
||||
SRT_ZELDA1 = 4,
|
||||
SRT_ZELDA2 = 5,
|
||||
SRT_1080 = 6,
|
||||
SRT_PANEL = 7,
|
||||
SRT_MARIOPARTY1 = 8,
|
||||
SRT_MARIOPARTY2 = 9,
|
||||
SRT_MARIOPARTY3 = 10,
|
||||
SRT_DRMARIO = 11,
|
||||
SRT_UNKNOWN = 12,
|
||||
} __anon_0x21647;
|
||||
|
||||
typedef enum __anon_0x21778 {
|
||||
SOT_NONE = -1,
|
||||
SOT_CPU = 0,
|
||||
SOT_PIF = 1,
|
||||
SOT_RAM = 2,
|
||||
SOT_ROM = 3,
|
||||
SOT_RSP = 4,
|
||||
SOT_RDP = 5,
|
||||
SOT_MIPS = 6,
|
||||
SOT_DISK = 7,
|
||||
SOT_FLASH = 8,
|
||||
SOT_SRAM = 9,
|
||||
SOT_AUDIO = 10,
|
||||
SOT_VIDEO = 11,
|
||||
SOT_SERIAL = 12,
|
||||
SOT_LIBRARY = 13,
|
||||
SOT_PERIPHERAL = 14,
|
||||
SOT_RDB = 15,
|
||||
SOT_COUNT = 16,
|
||||
} __anon_0x21778;
|
||||
|
||||
typedef struct __anon_0x218B8 {
|
||||
/* 0x00 */ void* pFrame;
|
||||
/* 0x04 */ void* pSound;
|
||||
/* 0x08 */ s32 bException;
|
||||
/* 0x0C */ enum __anon_0x2152F eMode;
|
||||
/* 0x10 */ struct __anon_0x21596 romCopy;
|
||||
/* 0x20 */ enum __anon_0x21647 eTypeROM;
|
||||
/* 0x24 */ void* apObject[16];
|
||||
/* 0x68 */ u64 nAddressBreak;
|
||||
/* 0x70 */ enum __anon_0x21778 storageDevice;
|
||||
/* 0x74 */ u8 anException[16];
|
||||
/* 0x84 */ s32 bJapaneseVersion;
|
||||
} __anon_0x218B8; // size = 0x88
|
||||
|
||||
// size = 0x4, address = 0x80135600
|
||||
struct __anon_0x218B8* gpSystem;
|
||||
|
||||
// Range: 0x8001C824 -> 0x8001C880
|
||||
static void soundCallbackBeep() {
|
||||
// Local variables
|
||||
struct __anon_0x208BA* pSound; // r31
|
||||
|
||||
// References
|
||||
// -> struct __anon_0x218B8* gpSystem;
|
||||
}
|
||||
|
||||
// Erased
|
||||
static void InitVolumeCurve() {
|
||||
// Local variables
|
||||
s32 i; // r29
|
||||
|
||||
// References
|
||||
// -> s32 gVolumeCurve[257];
|
||||
}
|
||||
|
||||
// Range: 0x8001C880 -> 0x8001CA20
|
||||
s32 soundSetBufferSize(struct __anon_0x208BA* pSound, s32 nSize) {
|
||||
// Parameters
|
||||
// struct __anon_0x208BA* pSound; // r31
|
||||
// s32 nSize; // r29
|
||||
|
||||
// Local variables
|
||||
s32 iBuffer; // r29
|
||||
}
|
||||
|
||||
// Range: 0x8001CA20 -> 0x8001CA54
|
||||
s32 soundGetDMABuffer(u32* pnSize) {
|
||||
// Parameters
|
||||
// u32* pnSize; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8001CA54 -> 0x8001CA60
|
||||
s32 soundSetAddress(struct __anon_0x208BA* pSound, void* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x208BA* pSound; // r1+0x0
|
||||
// void* pData; // r1+0x4
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 soundSetBitRate() {}
|
||||
|
||||
// Range: 0x8001CA60 -> 0x8001CA80
|
||||
s32 soundSetDACRate(struct __anon_0x208BA* pSound, s32 nDacRate) {
|
||||
// Parameters
|
||||
// struct __anon_0x208BA* pSound; // r1+0x0
|
||||
// s32 nDacRate; // r1+0x4
|
||||
}
|
||||
|
||||
// Range: 0x8001CA80 -> 0x8001CAB8
|
||||
s32 soundSetLength(struct __anon_0x208BA* pSound, s32 nSize) {
|
||||
// Parameters
|
||||
// struct __anon_0x208BA* pSound; // r3
|
||||
// s32 nSize; // r1+0xC
|
||||
}
|
||||
|
||||
// Range: 0x8001CAB8 -> 0x8001CCA4
|
||||
static s32 soundMakeBuffer(struct __anon_0x208BA* pSound) {
|
||||
// Parameters
|
||||
// struct __anon_0x208BA* pSound; // r29
|
||||
|
||||
// Local variables
|
||||
u32 nSamples; // r5
|
||||
s16* curBufP; // r3
|
||||
u32 sampleStep; // r1+0x8
|
||||
u32 sample; // r6
|
||||
s32 j; // r7
|
||||
s32 nSize; // r4
|
||||
s32 samp; // r11
|
||||
s32 iBuffer; // r31
|
||||
s32 vol; // r8
|
||||
s32 bFlag; // r28
|
||||
s32 bPlay; // r30
|
||||
s32 volAdjust; // r11
|
||||
|
||||
// References
|
||||
// -> s32 gVolumeCurve[257];
|
||||
}
|
||||
|
||||
// Range: 0x8001CCA4 -> 0x8001CCCC
|
||||
static void soundCallbackDMA() {
|
||||
// References
|
||||
// -> struct __anon_0x218B8* gpSystem;
|
||||
}
|
||||
|
||||
// Range: 0x8001CCCC -> 0x8001CD8C
|
||||
static s32 soundPlayBuffer(struct __anon_0x208BA* pSound) {
|
||||
// Parameters
|
||||
// struct __anon_0x208BA* pSound; // r1+0x8
|
||||
|
||||
// Local variables
|
||||
void* pData; // r6
|
||||
s32 iBuffer; // r4
|
||||
s32 nSize; // r4
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 soundMakeHold() {}
|
||||
|
||||
// Erased
|
||||
static s32 soundMakeZero(struct __anon_0x208BA* pSound) {
|
||||
// Parameters
|
||||
// struct __anon_0x208BA* pSound; // r3
|
||||
|
||||
// Local variables
|
||||
s32 iData; // r7
|
||||
}
|
||||
|
||||
typedef enum __anon_0x221A3 {
|
||||
SR_NONE = -1,
|
||||
SR_DECREASE = 0,
|
||||
SR_INCREASE = 1,
|
||||
} __anon_0x221A3;
|
||||
|
||||
// Range: 0x8001CD8C -> 0x8001D250
|
||||
static s32 soundMakeRamp(struct __anon_0x208BA* pSound, s32 iBuffer, enum __anon_0x221A3 eRamp) {
|
||||
// Parameters
|
||||
// struct __anon_0x208BA* pSound; // r1+0x8
|
||||
// s32 iBuffer; // r1+0xC
|
||||
// enum __anon_0x221A3 eRamp; // r1+0x10
|
||||
|
||||
// Local variables
|
||||
s32 bFlag; // r8
|
||||
s32 iData; // r1+0x8
|
||||
s16* anData; // r9
|
||||
s16 nData0; // r10
|
||||
s16 nData1; // r11
|
||||
s16 nGoal0; // r12
|
||||
s16 nGoal1; // r31
|
||||
s16 nStep0; // r5
|
||||
s16 nStep1; // r4
|
||||
s16 nLast0; // r27
|
||||
s16 nLast1; // r27
|
||||
}
|
||||
|
||||
// Range: 0x8001D250 -> 0x8001D34C
|
||||
s32 soundWipeBuffers(struct __anon_0x208BA* pSound) {
|
||||
// Parameters
|
||||
// struct __anon_0x208BA* pSound; // r31
|
||||
|
||||
// Local variables
|
||||
s32 iBuffer; // r30
|
||||
}
|
||||
|
||||
+110
-66
@@ -1,66 +1,110 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x68E70E80
|
||||
_XL_OBJECTTYPE gClassSram;
|
||||
|
||||
// size: 0x4
|
||||
struct __anon_0x74AB9
|
||||
{
|
||||
void *pHost; // 0x0
|
||||
};
|
||||
|
||||
int sramEvent(__anon_0x74AB9 *pSram, int nEvent, void *pArgument);
|
||||
|
||||
// Local to compilation unit
|
||||
static int sramGet64(unsigned int nAddress, signed long long *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int sramGet32(unsigned int nAddress, int *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int sramGet16(unsigned int nAddress, signed short *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int sramGet8(unsigned int nAddress, char *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int sramPut64(unsigned int nAddress, signed long long *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int sramPut32(unsigned int nAddress, int *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int sramPut16(unsigned int nAddress, signed short *pData);
|
||||
|
||||
// Local to compilation unit
|
||||
static int sramPut8(unsigned int nAddress, char *pData);
|
||||
|
||||
int sramTransferSRAM(__anon_0x74AB9 *pSRAM, int nOffsetRAM, int nOffsetSRAM, int nSize)
|
||||
{
|
||||
void *pTarget;
|
||||
}
|
||||
|
||||
int sramCopySRAM(__anon_0x74AB9 *pSRAM, int nOffsetRAM, int nOffsetSRAM, int nSize)
|
||||
{
|
||||
void *pTarget;
|
||||
}
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\sram.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x8008E138 -> 0x8008E4A8
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x749C7; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800EE768
|
||||
struct _XL_OBJECTTYPE gClassSram;
|
||||
|
||||
typedef struct __anon_0x74AB9 {
|
||||
/* 0x0 */ void* pHost;
|
||||
} __anon_0x74AB9; // size = 0x4
|
||||
|
||||
// Range: 0x8008E138 -> 0x8008E238
|
||||
s32 sramEvent(struct __anon_0x74AB9* pSram, s32 nEvent, void* pArgument) {
|
||||
// Parameters
|
||||
// struct __anon_0x74AB9* pSram; // r30
|
||||
// s32 nEvent; // r1+0xC
|
||||
// void* pArgument; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8008E238 -> 0x8008E268
|
||||
static s32 sramGet64(u32 nAddress, s64* pData) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s64* pData; // r5
|
||||
}
|
||||
|
||||
// Range: 0x8008E268 -> 0x8008E298
|
||||
static s32 sramGet32(u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s32* pData; // r5
|
||||
}
|
||||
|
||||
// Range: 0x8008E298 -> 0x8008E2C8
|
||||
static s32 sramGet16(u32 nAddress, s16* pData) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s16* pData; // r5
|
||||
}
|
||||
|
||||
// Range: 0x8008E2C8 -> 0x8008E2F8
|
||||
static s32 sramGet8(u32 nAddress, char* pData) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0xC
|
||||
// char* pData; // r5
|
||||
}
|
||||
|
||||
// Range: 0x8008E2F8 -> 0x8008E328
|
||||
static s32 sramPut64(u32 nAddress, s64* pData) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s64* pData; // r5
|
||||
}
|
||||
|
||||
// Range: 0x8008E328 -> 0x8008E358
|
||||
static s32 sramPut32(u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s32* pData; // r5
|
||||
}
|
||||
|
||||
// Range: 0x8008E358 -> 0x8008E388
|
||||
static s32 sramPut16(u32 nAddress, s16* pData) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s16* pData; // r5
|
||||
}
|
||||
|
||||
// Range: 0x8008E388 -> 0x8008E3B8
|
||||
static s32 sramPut8(u32 nAddress, char* pData) {
|
||||
// Parameters
|
||||
// u32 nAddress; // r1+0xC
|
||||
// char* pData; // r5
|
||||
}
|
||||
|
||||
// Range: 0x8008E3B8 -> 0x8008E430
|
||||
s32 sramTransferSRAM(struct __anon_0x74AB9* pSRAM, s32 nOffsetRAM, s32 nOffsetSRAM, s32 nSize) {
|
||||
// Parameters
|
||||
// struct __anon_0x74AB9* pSRAM; // r1+0x8
|
||||
// s32 nOffsetRAM; // r4
|
||||
// s32 nOffsetSRAM; // r31
|
||||
// s32 nSize; // r1+0x14
|
||||
|
||||
// Local variables
|
||||
void* pTarget; // r1+0x18
|
||||
}
|
||||
|
||||
// Range: 0x8008E430 -> 0x8008E4A8
|
||||
s32 sramCopySRAM(struct __anon_0x74AB9* pSRAM, s32 nOffsetRAM, s32 nOffsetSRAM, s32 nSize) {
|
||||
// Parameters
|
||||
// struct __anon_0x74AB9* pSRAM; // r1+0x8
|
||||
// s32 nOffsetRAM; // r4
|
||||
// s32 nOffsetSRAM; // r31
|
||||
// s32 nSize; // r1+0x14
|
||||
|
||||
// Local variables
|
||||
void* pTarget; // r1+0x18
|
||||
}
|
||||
|
||||
+1258
-1274
File diff suppressed because it is too large
Load Diff
+374
-382
@@ -1,382 +1,374 @@
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrtf__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _half$localstatic0$sqrt__Ff;
|
||||
|
||||
// Location: 0x0
|
||||
long float _three$localstatic1$sqrt__Ff;
|
||||
|
||||
// size: 0x10
|
||||
struct _XL_OBJECTTYPE
|
||||
{
|
||||
char *szName; // 0x0
|
||||
int nSizeObject; // 0x4
|
||||
_XL_OBJECTTYPE *pClassBase; // 0x8
|
||||
int (*pfEvent)(void */* unknown0 */, int /* unknown1 */, void */* unknown2 */); // 0xC
|
||||
};
|
||||
|
||||
// Location: 0x70E80E80
|
||||
_XL_OBJECTTYPE gClassVideo;
|
||||
|
||||
// size: 0x40
|
||||
struct __anon_0x75B37
|
||||
{
|
||||
int nScan; // 0x0
|
||||
int bBlack; // 0x4
|
||||
int nBurst; // 0x8
|
||||
int nSizeX; // 0xC
|
||||
void *pHost; // 0x10
|
||||
int nStatus; // 0x14
|
||||
int nTiming; // 0x18
|
||||
int nAddress; // 0x1C
|
||||
int nScanInterrupt; // 0x20
|
||||
int nScaleX; // 0x24
|
||||
int nScaleY; // 0x28
|
||||
int nStartH; // 0x2C
|
||||
int nStartV; // 0x30
|
||||
int nSyncH; // 0x34
|
||||
int nSyncV; // 0x38
|
||||
int nSyncLeap; // 0x3C
|
||||
};
|
||||
|
||||
int videoEvent(__anon_0x75B37 *pVideo, int nEvent, void *pArgument);
|
||||
|
||||
int videoGetMode(__anon_0x75B37 *pVideo, int *pbBlack, int *pnSizeX, int *pnSizeY)
|
||||
{
|
||||
int nSizeX;
|
||||
int nSizeY;
|
||||
}
|
||||
|
||||
int videoForceRetrace(__anon_0x75B37 *pVideo);
|
||||
|
||||
int videoTickScan();
|
||||
|
||||
int videoGet64();
|
||||
|
||||
int videoGet32(__anon_0x75B37 *pVideo, unsigned int nAddress, int *pData);
|
||||
|
||||
int videoGet16();
|
||||
|
||||
int videoGet8();
|
||||
|
||||
int videoPut64();
|
||||
|
||||
// size: 0x10
|
||||
struct __anon_0x76165
|
||||
{
|
||||
float rX; // 0x0
|
||||
float rY; // 0x4
|
||||
float rSizeX; // 0x8
|
||||
float rSizeY; // 0xC
|
||||
};
|
||||
|
||||
// size: 0x14
|
||||
struct __anon_0x761FF
|
||||
{
|
||||
int nSize; // 0x0
|
||||
int nWidth; // 0x4
|
||||
int nFormat; // 0x8
|
||||
void *pData; // 0xC
|
||||
int nAddress; // 0x10
|
||||
};
|
||||
|
||||
// size: 0xC
|
||||
struct __anon_0x76340
|
||||
{
|
||||
float x; // 0x0
|
||||
float y; // 0x4
|
||||
float z; // 0x8
|
||||
};
|
||||
|
||||
// size: 0x3C
|
||||
struct __anon_0x763B0
|
||||
{
|
||||
int bTransformed; // 0x0
|
||||
__anon_0x76340 rVecOrigTowards; // 0x4
|
||||
float rColorR; // 0x10
|
||||
float rColorG; // 0x14
|
||||
float rColorB; // 0x18
|
||||
float rVectorX; // 0x1C
|
||||
float rVectorY; // 0x20
|
||||
float rVectorZ; // 0x24
|
||||
float kc; // 0x28
|
||||
float kl; // 0x2C
|
||||
float kq; // 0x30
|
||||
signed short coordX; // 0x34
|
||||
signed short coordY; // 0x36
|
||||
signed short coordZ; // 0x38
|
||||
};
|
||||
|
||||
// size: 0x34
|
||||
struct __anon_0x765E0
|
||||
{
|
||||
int bTransformed; // 0x0
|
||||
__anon_0x76340 rS; // 0x4
|
||||
__anon_0x76340 rT; // 0x10
|
||||
__anon_0x76340 rSRaw; // 0x1C
|
||||
__anon_0x76340 rTRaw; // 0x28
|
||||
};
|
||||
|
||||
// size: 0x1C
|
||||
struct __anon_0x766C9
|
||||
{
|
||||
float rSum; // 0x0
|
||||
float rS; // 0x4
|
||||
float rT; // 0x8
|
||||
__anon_0x76340 vec; // 0xC
|
||||
unsigned char anColor[4]; // 0x18
|
||||
};
|
||||
|
||||
// size: 0x1000
|
||||
union __anon_0x76828
|
||||
{
|
||||
unsigned char u8[4096]; // 0x0
|
||||
unsigned short u16[2048]; // 0x0
|
||||
unsigned int u32[1024]; // 0x0
|
||||
unsigned long long u64[512]; // 0x0
|
||||
};
|
||||
|
||||
// size: 0x1000
|
||||
struct __anon_0x768C5
|
||||
{
|
||||
__anon_0x76828 data; // 0x0
|
||||
};
|
||||
|
||||
// size: 0x4
|
||||
enum _GXTexFmt
|
||||
{
|
||||
GX_TF_I4 = 0,
|
||||
GX_TF_I8 = 1,
|
||||
GX_TF_IA4 = 2,
|
||||
GX_TF_IA8 = 3,
|
||||
GX_TF_RGB565 = 4,
|
||||
GX_TF_RGB5A3 = 5,
|
||||
GX_TF_RGBA8 = 6,
|
||||
GX_TF_CMPR = 14,
|
||||
GX_CTF_R4 = 32,
|
||||
GX_CTF_RA4 = 34,
|
||||
GX_CTF_RA8 = 35,
|
||||
GX_CTF_YUVA8 = 38,
|
||||
GX_CTF_A8 = 39,
|
||||
GX_CTF_R8 = 40,
|
||||
GX_CTF_G8 = 41,
|
||||
GX_CTF_B8 = 42,
|
||||
GX_CTF_RG8 = 43,
|
||||
GX_CTF_GB8 = 44,
|
||||
GX_TF_Z8 = 17,
|
||||
GX_TF_Z16 = 19,
|
||||
GX_TF_Z24X8 = 22,
|
||||
GX_CTF_Z4 = 48,
|
||||
GX_CTF_Z8M = 57,
|
||||
GX_CTF_Z8L = 58,
|
||||
GX_CTF_Z16L = 60,
|
||||
GX_TF_A8 = 39
|
||||
};
|
||||
|
||||
// size: 0xC
|
||||
struct _GXTlutObj
|
||||
{
|
||||
unsigned long dummy[3]; // 0x0
|
||||
};
|
||||
|
||||
// size: 0x20
|
||||
struct _GXTexObj
|
||||
{
|
||||
unsigned long dummy[8]; // 0x0
|
||||
};
|
||||
|
||||
// size: 0x4
|
||||
enum _GXTexWrapMode
|
||||
{
|
||||
GX_CLAMP = 0,
|
||||
GX_REPEAT = 1,
|
||||
GX_MIRROR = 2,
|
||||
GX_MAX_TEXWRAPMODE = 3
|
||||
};
|
||||
|
||||
// size: 0x6C
|
||||
struct _FRAME_TEXTURE
|
||||
{
|
||||
int nMode; // 0x0
|
||||
int iPackPixel; // 0x4
|
||||
int iPackColor; // 0x8
|
||||
int nFrameLast; // 0xC
|
||||
signed short nSizeX; // 0x10
|
||||
signed short nSizeY; // 0x12
|
||||
unsigned int nAddress; // 0x14
|
||||
unsigned int nCodePixel; // 0x18
|
||||
unsigned int nCodeColor; // 0x1C
|
||||
_FRAME_TEXTURE *pTextureNext; // 0x20
|
||||
unsigned int nData0; // 0x24
|
||||
unsigned int nData1; // 0x28
|
||||
unsigned int nData2; // 0x2C
|
||||
unsigned int nData3; // 0x30
|
||||
_GXTexFmt eFormat; // 0x34
|
||||
_GXTlutObj objectTLUT; // 0x38
|
||||
_GXTexObj objectTexture; // 0x44
|
||||
_GXTexWrapMode eWrapS; // 0x64
|
||||
_GXTexWrapMode eWrapT; // 0x68
|
||||
};
|
||||
|
||||
// size: 0x2C
|
||||
struct __anon_0x76F93
|
||||
{
|
||||
int nSize; // 0x0
|
||||
int nTMEM; // 0x4
|
||||
int iTLUT; // 0x8
|
||||
int nSizeX; // 0xC
|
||||
int nFormat; // 0x10
|
||||
signed short nMaskS; // 0x14
|
||||
signed short nMaskT; // 0x16
|
||||
signed short nModeS; // 0x18
|
||||
signed short nModeT; // 0x1A
|
||||
signed short nShiftS; // 0x1C
|
||||
signed short nShiftT; // 0x1E
|
||||
signed short nX0; // 0x20
|
||||
signed short nY0; // 0x22
|
||||
signed short nX1; // 0x24
|
||||
signed short nY1; // 0x26
|
||||
unsigned int nCodePixel; // 0x28
|
||||
};
|
||||
|
||||
// size: 0x4
|
||||
enum __anon_0x77275
|
||||
{
|
||||
FMP_NONE = 4294967295,
|
||||
FMP_PERSPECTIVE = 0,
|
||||
FMP_ORTHOGRAPHIC = 1
|
||||
};
|
||||
|
||||
// size: 0x24
|
||||
struct __anon_0x772F8
|
||||
{
|
||||
int nCount; // 0x0
|
||||
float rScale; // 0x4
|
||||
float rAspect; // 0x8
|
||||
float rFieldOfViewY; // 0xC
|
||||
float rClipNear; // 0x10
|
||||
float rClipFar; // 0x14
|
||||
unsigned int nAddressFloat; // 0x18
|
||||
unsigned int nAddressFixed; // 0x1C
|
||||
__anon_0x77275 eProjection; // 0x20
|
||||
};
|
||||
|
||||
// size: 0x4
|
||||
struct _GXColor
|
||||
{
|
||||
unsigned char r; // 0x0
|
||||
unsigned char g; // 0x1
|
||||
unsigned char b; // 0x2
|
||||
unsigned char a; // 0x3
|
||||
};
|
||||
|
||||
// size: 0x3D150
|
||||
struct __anon_0x77548
|
||||
{
|
||||
unsigned int anCIMGAddresses[8]; // 0x0
|
||||
unsigned short nNumCIMGAddresses; // 0x20
|
||||
int bBlurOn; // 0x24
|
||||
int bHackPause; // 0x28
|
||||
int nHackCount; // 0x2C
|
||||
int nFrameCounter; // 0x30
|
||||
int bPauseThisFrame; // 0x34
|
||||
int bCameFromBomberNotes; // 0x38
|
||||
int bInBomberNotes; // 0x3C
|
||||
int bShrinking; // 0x40
|
||||
int bSnapShot; // 0x44
|
||||
int bUsingLens; // 0x48
|
||||
unsigned char cBlurAlpha; // 0x4C
|
||||
int bBlurredThisFrame; // 0x50
|
||||
int nFrameCIMGCalls; // 0x54
|
||||
int bModifyZBuffer; // 0x58
|
||||
int bOverrideDepth; // 0x5C
|
||||
int nZBufferSets; // 0x60
|
||||
int nLastFrameZSets; // 0x64
|
||||
int bPauseBGDrawn; // 0x68
|
||||
int bFrameOn; // 0x6C
|
||||
int bBackBufferDrawn; // 0x70
|
||||
int bGrabbedFrame; // 0x74
|
||||
unsigned long long *pnGBI; // 0x78
|
||||
unsigned int nFlag; // 0x7C
|
||||
float rScaleX; // 0x80
|
||||
float rScaleY; // 0x84
|
||||
unsigned int nCountFrames; // 0x88
|
||||
unsigned int nMode; // 0x8C
|
||||
unsigned int aMode[10]; // 0x90
|
||||
__anon_0x76165 viewport; // 0xB8
|
||||
__anon_0x761FF aBuffer[4]; // 0xC8
|
||||
unsigned int nOffsetDepth0; // 0x118
|
||||
unsigned int nOffsetDepth1; // 0x11C
|
||||
int nWidthLine; // 0x120
|
||||
float rDepth; // 0x124
|
||||
float rDelta; // 0x128
|
||||
int (*aDraw[4])(void */* unknown0 */, void */* unknown1 */); // 0x12C
|
||||
int nCountLight; // 0x13C
|
||||
__anon_0x763B0 aLight[8]; // 0x140
|
||||
__anon_0x765E0 lookAt; // 0x320
|
||||
int nCountVertex; // 0x354
|
||||
__anon_0x766C9 aVertex[80]; // 0x358
|
||||
__anon_0x768C5 TMEM; // 0xC18
|
||||
void *aPixelData; // 0x1C18
|
||||
void *aColorData; // 0x1C1C
|
||||
int nBlocksPixel; // 0x1C20
|
||||
int nBlocksMaxPixel; // 0x1C24
|
||||
int nBlocksColor; // 0x1C28
|
||||
int nBlocksMaxColor; // 0x1C2C
|
||||
int nBlocksTexture; // 0x1C30
|
||||
int nBlocksMaxTexture; // 0x1C34
|
||||
unsigned int anPackPixel[48]; // 0x1C38
|
||||
unsigned int anPackColor[320]; // 0x1CF8
|
||||
unsigned int nAddressLoad; // 0x21F8
|
||||
unsigned int nCodePixel; // 0x21FC
|
||||
unsigned int nTlutCode[16]; // 0x2200
|
||||
_FRAME_TEXTURE aTexture[2048]; // 0x2240
|
||||
unsigned int anTextureUsed[64]; // 0x38240
|
||||
_FRAME_TEXTURE *apTextureCached[4096]; // 0x38340
|
||||
int iTileLoad; // 0x3C340
|
||||
unsigned int n2dLoadTexType; // 0x3C344
|
||||
int nLastX0; // 0x3C348
|
||||
int nLastY0; // 0x3C34C
|
||||
int nLastX1; // 0x3C350
|
||||
int nLastY1; // 0x3C354
|
||||
__anon_0x76F93 aTile[8]; // 0x3C358
|
||||
int anSizeX[2]; // 0x3C4B8
|
||||
int anSizeY[2]; // 0x3C4C0
|
||||
int iHintMatrix; // 0x3C4C8
|
||||
int iMatrixModel; // 0x3C4CC
|
||||
int iHintProjection; // 0x3C4D0
|
||||
float matrixView[4][4]; // 0x3C4D4
|
||||
int iHintLast; // 0x3C514
|
||||
int iHintHack; // 0x3C518
|
||||
__anon_0x77275 eTypeProjection; // 0x3C51C
|
||||
float aMatrixModel[10][4][4]; // 0x3C520
|
||||
float matrixProjection[4][4]; // 0x3C7A0
|
||||
float matrixProjectionExtra[4][4]; // 0x3C7E0
|
||||
__anon_0x772F8 aMatrixHint[64]; // 0x3C820
|
||||
unsigned char primLODmin; // 0x3D120
|
||||
unsigned char primLODfrac; // 0x3D121
|
||||
unsigned char lastTile; // 0x3D122
|
||||
unsigned char iTileDrawn; // 0x3D123
|
||||
_GXColor aColor[5]; // 0x3D124
|
||||
unsigned int nModeVtx; // 0x3D138
|
||||
unsigned short *nTempBuffer; // 0x3D13C
|
||||
unsigned short *nCopyBuffer; // 0x3D140
|
||||
unsigned int *nLensBuffer; // 0x3D144
|
||||
unsigned short *nCameraBuffer; // 0x3D148
|
||||
};
|
||||
|
||||
int videoPut32(__anon_0x75B37 *pVideo, unsigned int nAddress, int *pData)
|
||||
{
|
||||
void *pRAM;
|
||||
__anon_0x77548 *pFrame;
|
||||
__anon_0x761FF *pBuffer;
|
||||
}
|
||||
|
||||
int videoPut16();
|
||||
|
||||
int videoPut8();
|
||||
|
||||
/*
|
||||
Compile unit: C:\HOMEBOY\STEPHEN\Japanese Ocarina\Fire\video.c
|
||||
Producer: MW EABI PPC C-Compiler
|
||||
Language: C++
|
||||
Code range: 0x8008E8A0 -> 0x8008EE20
|
||||
*/
|
||||
|
||||
#include "types.h"
|
||||
|
||||
typedef struct _XL_OBJECTTYPE {
|
||||
/* 0x0 */ char* szName;
|
||||
/* 0x4 */ s32 nSizeObject;
|
||||
/* 0x8 */ struct _XL_OBJECTTYPE* pClassBase;
|
||||
/* 0xC */ s32 (*pfEvent)(void*, s32, void*);
|
||||
} __anon_0x75A44; // size = 0x10
|
||||
|
||||
// size = 0x10, address = 0x800EE870
|
||||
struct _XL_OBJECTTYPE gClassVideo;
|
||||
|
||||
typedef struct __anon_0x75B37 {
|
||||
/* 0x00 */ s32 nScan;
|
||||
/* 0x04 */ s32 bBlack;
|
||||
/* 0x08 */ s32 nBurst;
|
||||
/* 0x0C */ s32 nSizeX;
|
||||
/* 0x10 */ void* pHost;
|
||||
/* 0x14 */ s32 nStatus;
|
||||
/* 0x18 */ s32 nTiming;
|
||||
/* 0x1C */ s32 nAddress;
|
||||
/* 0x20 */ s32 nScanInterrupt;
|
||||
/* 0x24 */ s32 nScaleX;
|
||||
/* 0x28 */ s32 nScaleY;
|
||||
/* 0x2C */ s32 nStartH;
|
||||
/* 0x30 */ s32 nStartV;
|
||||
/* 0x34 */ s32 nSyncH;
|
||||
/* 0x38 */ s32 nSyncV;
|
||||
/* 0x3C */ s32 nSyncLeap;
|
||||
} __anon_0x75B37; // size = 0x40
|
||||
|
||||
// Range: 0x8008E8A0 -> 0x8008E9F4
|
||||
s32 videoEvent(struct __anon_0x75B37* pVideo, s32 nEvent, void* pArgument) {
|
||||
// Parameters
|
||||
// struct __anon_0x75B37* pVideo; // r30
|
||||
// s32 nEvent; // r1+0xC
|
||||
// void* pArgument; // r31
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 videoGetMode(struct __anon_0x75B37* pVideo, s32* pbBlack, s32* pnSizeX, s32* pnSizeY) {
|
||||
// Parameters
|
||||
// struct __anon_0x75B37* pVideo; // r1+0x8
|
||||
// s32* pbBlack; // r1+0xC
|
||||
// s32* pnSizeX; // r1+0x10
|
||||
// s32* pnSizeY; // r1+0x14
|
||||
|
||||
// Local variables
|
||||
s32 nSizeX; // r1+0x8
|
||||
s32 nSizeY; // r3
|
||||
}
|
||||
|
||||
// Range: 0x8008E9F4 -> 0x8008EA60
|
||||
s32 videoForceRetrace(struct __anon_0x75B37* pVideo) {
|
||||
// Parameters
|
||||
// struct __anon_0x75B37* pVideo; // r31
|
||||
}
|
||||
|
||||
// Erased
|
||||
static s32 videoTickScan() {}
|
||||
|
||||
// Range: 0x8008EA60 -> 0x8008EA68
|
||||
s32 videoGet64() {}
|
||||
|
||||
// Range: 0x8008EA68 -> 0x8008EB84
|
||||
s32 videoGet32(struct __anon_0x75B37* pVideo, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x75B37* pVideo; // r30
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s32* pData; // r31
|
||||
}
|
||||
|
||||
// Range: 0x8008EB84 -> 0x8008EB8C
|
||||
s32 videoGet16() {}
|
||||
|
||||
// Range: 0x8008EB8C -> 0x8008EB94
|
||||
s32 videoGet8() {}
|
||||
|
||||
// Range: 0x8008EB94 -> 0x8008EB9C
|
||||
s32 videoPut64() {}
|
||||
|
||||
typedef struct __anon_0x76165 {
|
||||
/* 0x0 */ float rX;
|
||||
/* 0x4 */ float rY;
|
||||
/* 0x8 */ float rSizeX;
|
||||
/* 0xC */ float rSizeY;
|
||||
} __anon_0x76165; // size = 0x10
|
||||
|
||||
typedef struct __anon_0x761FF {
|
||||
/* 0x00 */ s32 nSize;
|
||||
/* 0x04 */ s32 nWidth;
|
||||
/* 0x08 */ s32 nFormat;
|
||||
/* 0x0C */ void* pData;
|
||||
/* 0x10 */ s32 nAddress;
|
||||
} __anon_0x761FF; // size = 0x14
|
||||
|
||||
typedef struct __anon_0x76340 {
|
||||
/* 0x0 */ float x;
|
||||
/* 0x4 */ float y;
|
||||
/* 0x8 */ float z;
|
||||
} __anon_0x76340; // size = 0xC
|
||||
|
||||
typedef struct __anon_0x763B0 {
|
||||
/* 0x00 */ s32 bTransformed;
|
||||
/* 0x04 */ struct __anon_0x76340 rVecOrigTowards;
|
||||
/* 0x10 */ float rColorR;
|
||||
/* 0x14 */ float rColorG;
|
||||
/* 0x18 */ float rColorB;
|
||||
/* 0x1C */ float rVectorX;
|
||||
/* 0x20 */ float rVectorY;
|
||||
/* 0x24 */ float rVectorZ;
|
||||
/* 0x28 */ float kc;
|
||||
/* 0x2C */ float kl;
|
||||
/* 0x30 */ float kq;
|
||||
/* 0x34 */ s16 coordX;
|
||||
/* 0x36 */ s16 coordY;
|
||||
/* 0x38 */ s16 coordZ;
|
||||
} __anon_0x763B0; // size = 0x3C
|
||||
|
||||
typedef struct __anon_0x765E0 {
|
||||
/* 0x00 */ s32 bTransformed;
|
||||
/* 0x04 */ struct __anon_0x76340 rS;
|
||||
/* 0x10 */ struct __anon_0x76340 rT;
|
||||
/* 0x1C */ struct __anon_0x76340 rSRaw;
|
||||
/* 0x28 */ struct __anon_0x76340 rTRaw;
|
||||
} __anon_0x765E0; // size = 0x34
|
||||
|
||||
typedef struct __anon_0x766C9 {
|
||||
/* 0x00 */ float rSum;
|
||||
/* 0x04 */ float rS;
|
||||
/* 0x08 */ float rT;
|
||||
/* 0x0C */ struct __anon_0x76340 vec;
|
||||
/* 0x18 */ u8 anColor[4];
|
||||
} __anon_0x766C9; // size = 0x1C
|
||||
|
||||
typedef union __anon_0x76828 {
|
||||
/* 0x0 */ u8 u8[4096];
|
||||
/* 0x0 */ u16 u16[2048];
|
||||
/* 0x0 */ u32 u32[1024];
|
||||
/* 0x0 */ u64 u64[512];
|
||||
} __anon_0x76828;
|
||||
|
||||
typedef struct __anon_0x768C5 {
|
||||
/* 0x0 */ union __anon_0x76828 data;
|
||||
} __anon_0x768C5; // size = 0x1000
|
||||
|
||||
typedef enum _GXTexFmt {
|
||||
GX_TF_I4 = 0,
|
||||
GX_TF_I8 = 1,
|
||||
GX_TF_IA4 = 2,
|
||||
GX_TF_IA8 = 3,
|
||||
GX_TF_RGB565 = 4,
|
||||
GX_TF_RGB5A3 = 5,
|
||||
GX_TF_RGBA8 = 6,
|
||||
GX_TF_CMPR = 14,
|
||||
GX_CTF_R4 = 32,
|
||||
GX_CTF_RA4 = 34,
|
||||
GX_CTF_RA8 = 35,
|
||||
GX_CTF_YUVA8 = 38,
|
||||
GX_CTF_A8 = 39,
|
||||
GX_CTF_R8 = 40,
|
||||
GX_CTF_G8 = 41,
|
||||
GX_CTF_B8 = 42,
|
||||
GX_CTF_RG8 = 43,
|
||||
GX_CTF_GB8 = 44,
|
||||
GX_TF_Z8 = 17,
|
||||
GX_TF_Z16 = 19,
|
||||
GX_TF_Z24X8 = 22,
|
||||
GX_CTF_Z4 = 48,
|
||||
GX_CTF_Z8M = 57,
|
||||
GX_CTF_Z8L = 58,
|
||||
GX_CTF_Z16L = 60,
|
||||
GX_TF_A8 = 39,
|
||||
} __anon_0x7695E;
|
||||
|
||||
typedef struct _GXTlutObj {
|
||||
/* 0x0 */ u32 dummy[3];
|
||||
} __anon_0x76B20; // size = 0xC
|
||||
|
||||
typedef struct _GXTexObj {
|
||||
/* 0x0 */ u32 dummy[8];
|
||||
} __anon_0x76B87; // size = 0x20
|
||||
|
||||
typedef enum _GXTexWrapMode {
|
||||
GX_CLAMP = 0,
|
||||
GX_REPEAT = 1,
|
||||
GX_MIRROR = 2,
|
||||
GX_MAX_TEXWRAPMODE = 3,
|
||||
} __anon_0x76BCD;
|
||||
|
||||
typedef struct _FRAME_TEXTURE {
|
||||
/* 0x00 */ s32 nMode;
|
||||
/* 0x04 */ s32 iPackPixel;
|
||||
/* 0x08 */ s32 iPackColor;
|
||||
/* 0x0C */ s32 nFrameLast;
|
||||
/* 0x10 */ s16 nSizeX;
|
||||
/* 0x12 */ s16 nSizeY;
|
||||
/* 0x14 */ u32 nAddress;
|
||||
/* 0x18 */ u32 nCodePixel;
|
||||
/* 0x1C */ u32 nCodeColor;
|
||||
/* 0x20 */ struct _FRAME_TEXTURE* pTextureNext;
|
||||
/* 0x24 */ u32 nData0;
|
||||
/* 0x28 */ u32 nData1;
|
||||
/* 0x2C */ u32 nData2;
|
||||
/* 0x30 */ u32 nData3;
|
||||
/* 0x34 */ enum _GXTexFmt eFormat;
|
||||
/* 0x38 */ struct _GXTlutObj objectTLUT;
|
||||
/* 0x44 */ struct _GXTexObj objectTexture;
|
||||
/* 0x64 */ enum _GXTexWrapMode eWrapS;
|
||||
/* 0x68 */ enum _GXTexWrapMode eWrapT;
|
||||
} __anon_0x76C36; // size = 0x6C
|
||||
|
||||
typedef struct __anon_0x76F93 {
|
||||
/* 0x00 */ s32 nSize;
|
||||
/* 0x04 */ s32 nTMEM;
|
||||
/* 0x08 */ s32 iTLUT;
|
||||
/* 0x0C */ s32 nSizeX;
|
||||
/* 0x10 */ s32 nFormat;
|
||||
/* 0x14 */ s16 nMaskS;
|
||||
/* 0x16 */ s16 nMaskT;
|
||||
/* 0x18 */ s16 nModeS;
|
||||
/* 0x1A */ s16 nModeT;
|
||||
/* 0x1C */ s16 nShiftS;
|
||||
/* 0x1E */ s16 nShiftT;
|
||||
/* 0x20 */ s16 nX0;
|
||||
/* 0x22 */ s16 nY0;
|
||||
/* 0x24 */ s16 nX1;
|
||||
/* 0x26 */ s16 nY1;
|
||||
/* 0x28 */ u32 nCodePixel;
|
||||
} __anon_0x76F93; // size = 0x2C
|
||||
|
||||
typedef enum __anon_0x77275 {
|
||||
FMP_NONE = -1,
|
||||
FMP_PERSPECTIVE = 0,
|
||||
FMP_ORTHOGRAPHIC = 1,
|
||||
} __anon_0x77275;
|
||||
|
||||
typedef struct __anon_0x772F8 {
|
||||
/* 0x00 */ s32 nCount;
|
||||
/* 0x04 */ float rScale;
|
||||
/* 0x08 */ float rAspect;
|
||||
/* 0x0C */ float rFieldOfViewY;
|
||||
/* 0x10 */ float rClipNear;
|
||||
/* 0x14 */ float rClipFar;
|
||||
/* 0x18 */ u32 nAddressFloat;
|
||||
/* 0x1C */ u32 nAddressFixed;
|
||||
/* 0x20 */ enum __anon_0x77275 eProjection;
|
||||
} __anon_0x772F8; // size = 0x24
|
||||
|
||||
typedef struct _GXColor {
|
||||
/* 0x0 */ u8 r;
|
||||
/* 0x1 */ u8 g;
|
||||
/* 0x2 */ u8 b;
|
||||
/* 0x3 */ u8 a;
|
||||
} __anon_0x7748D; // size = 0x4
|
||||
|
||||
typedef struct __anon_0x77548 {
|
||||
/* 0x00000 */ u32 anCIMGAddresses[8];
|
||||
/* 0x00020 */ u16 nNumCIMGAddresses;
|
||||
/* 0x00024 */ s32 bBlurOn;
|
||||
/* 0x00028 */ s32 bHackPause;
|
||||
/* 0x0002C */ s32 nHackCount;
|
||||
/* 0x00030 */ s32 nFrameCounter;
|
||||
/* 0x00034 */ s32 bPauseThisFrame;
|
||||
/* 0x00038 */ s32 bCameFromBomberNotes;
|
||||
/* 0x0003C */ s32 bInBomberNotes;
|
||||
/* 0x00040 */ s32 bShrinking;
|
||||
/* 0x00044 */ s32 bSnapShot;
|
||||
/* 0x00048 */ s32 bUsingLens;
|
||||
/* 0x0004C */ u8 cBlurAlpha;
|
||||
/* 0x00050 */ s32 bBlurredThisFrame;
|
||||
/* 0x00054 */ s32 nFrameCIMGCalls;
|
||||
/* 0x00058 */ s32 bModifyZBuffer;
|
||||
/* 0x0005C */ s32 bOverrideDepth;
|
||||
/* 0x00060 */ s32 nZBufferSets;
|
||||
/* 0x00064 */ s32 nLastFrameZSets;
|
||||
/* 0x00068 */ s32 bPauseBGDrawn;
|
||||
/* 0x0006C */ s32 bFrameOn;
|
||||
/* 0x00070 */ s32 bBackBufferDrawn;
|
||||
/* 0x00074 */ s32 bGrabbedFrame;
|
||||
/* 0x00078 */ u64* pnGBI;
|
||||
/* 0x0007C */ u32 nFlag;
|
||||
/* 0x00080 */ float rScaleX;
|
||||
/* 0x00084 */ float rScaleY;
|
||||
/* 0x00088 */ u32 nCountFrames;
|
||||
/* 0x0008C */ u32 nMode;
|
||||
/* 0x00090 */ u32 aMode[10];
|
||||
/* 0x000B8 */ struct __anon_0x76165 viewport;
|
||||
/* 0x000C8 */ struct __anon_0x761FF aBuffer[4];
|
||||
/* 0x00118 */ u32 nOffsetDepth0;
|
||||
/* 0x0011C */ u32 nOffsetDepth1;
|
||||
/* 0x00120 */ s32 nWidthLine;
|
||||
/* 0x00124 */ float rDepth;
|
||||
/* 0x00128 */ float rDelta;
|
||||
/* 0x0012C */ s32 (*aDraw[4])(void*, void*);
|
||||
/* 0x0013C */ s32 nCountLight;
|
||||
/* 0x00140 */ struct __anon_0x763B0 aLight[8];
|
||||
/* 0x00320 */ struct __anon_0x765E0 lookAt;
|
||||
/* 0x00354 */ s32 nCountVertex;
|
||||
/* 0x00358 */ struct __anon_0x766C9 aVertex[80];
|
||||
/* 0x00C18 */ struct __anon_0x768C5 TMEM;
|
||||
/* 0x01C18 */ void* aPixelData;
|
||||
/* 0x01C1C */ void* aColorData;
|
||||
/* 0x01C20 */ s32 nBlocksPixel;
|
||||
/* 0x01C24 */ s32 nBlocksMaxPixel;
|
||||
/* 0x01C28 */ s32 nBlocksColor;
|
||||
/* 0x01C2C */ s32 nBlocksMaxColor;
|
||||
/* 0x01C30 */ s32 nBlocksTexture;
|
||||
/* 0x01C34 */ s32 nBlocksMaxTexture;
|
||||
/* 0x01C38 */ u32 anPackPixel[48];
|
||||
/* 0x01CF8 */ u32 anPackColor[320];
|
||||
/* 0x021F8 */ u32 nAddressLoad;
|
||||
/* 0x021FC */ u32 nCodePixel;
|
||||
/* 0x02200 */ u32 nTlutCode[16];
|
||||
/* 0x02240 */ struct _FRAME_TEXTURE aTexture[2048];
|
||||
/* 0x38240 */ u32 anTextureUsed[64];
|
||||
/* 0x38340 */ struct _FRAME_TEXTURE* apTextureCached[4096];
|
||||
/* 0x3C340 */ s32 iTileLoad;
|
||||
/* 0x3C344 */ u32 n2dLoadTexType;
|
||||
/* 0x3C348 */ s32 nLastX0;
|
||||
/* 0x3C34C */ s32 nLastY0;
|
||||
/* 0x3C350 */ s32 nLastX1;
|
||||
/* 0x3C354 */ s32 nLastY1;
|
||||
/* 0x3C358 */ struct __anon_0x76F93 aTile[8];
|
||||
/* 0x3C4B8 */ s32 anSizeX[2];
|
||||
/* 0x3C4C0 */ s32 anSizeY[2];
|
||||
/* 0x3C4C8 */ s32 iHintMatrix;
|
||||
/* 0x3C4CC */ s32 iMatrixModel;
|
||||
/* 0x3C4D0 */ s32 iHintProjection;
|
||||
/* 0x3C4D4 */ float matrixView[4][4];
|
||||
/* 0x3C514 */ s32 iHintLast;
|
||||
/* 0x3C518 */ s32 iHintHack;
|
||||
/* 0x3C51C */ enum __anon_0x77275 eTypeProjection;
|
||||
/* 0x3C520 */ float aMatrixModel[10][4][4];
|
||||
/* 0x3C7A0 */ float matrixProjection[4][4];
|
||||
/* 0x3C7E0 */ float matrixProjectionExtra[4][4];
|
||||
/* 0x3C820 */ struct __anon_0x772F8 aMatrixHint[64];
|
||||
/* 0x3D120 */ u8 primLODmin;
|
||||
/* 0x3D121 */ u8 primLODfrac;
|
||||
/* 0x3D122 */ u8 lastTile;
|
||||
/* 0x3D123 */ u8 iTileDrawn;
|
||||
/* 0x3D124 */ struct _GXColor aColor[5];
|
||||
/* 0x3D138 */ u32 nModeVtx;
|
||||
/* 0x3D13C */ u16* nTempBuffer;
|
||||
/* 0x3D140 */ u16* nCopyBuffer;
|
||||
/* 0x3D144 */ u32* nLensBuffer;
|
||||
/* 0x3D148 */ u16* nCameraBuffer;
|
||||
} __anon_0x77548; // size = 0x3D150
|
||||
|
||||
// Range: 0x8008EB9C -> 0x8008EE10
|
||||
s32 videoPut32(struct __anon_0x75B37* pVideo, u32 nAddress, s32* pData) {
|
||||
// Parameters
|
||||
// struct __anon_0x75B37* pVideo; // r31
|
||||
// u32 nAddress; // r1+0xC
|
||||
// s32* pData; // r1+0x10
|
||||
|
||||
// Local variables
|
||||
void* pRAM; // r1+0x14
|
||||
struct __anon_0x77548* pFrame; // r30
|
||||
struct __anon_0x761FF* pBuffer; // r29
|
||||
}
|
||||
|
||||
// Range: 0x8008EE10 -> 0x8008EE18
|
||||
s32 videoPut16() {}
|
||||
|
||||
// Range: 0x8008EE18 -> 0x8008EE20
|
||||
s32 videoPut8() {}
|
||||
|
||||
Reference in New Issue
Block a user