Twilight Princess
Decompilation of The Legend of Zelda: Twilight Princess
Loading...
Searching...
No Matches
JKRAram.h
Go to the documentation of this file.
1#ifndef JKRARAM_H
2#define JKRARAM_H
3
7
8class JKRHeap;
9class JKRAMCommand;
10class JKRAramBlock;
11
16class JKRAram : public JKRThread {
17private:
18 JKRAram(u32, u32, s32);
19 virtual ~JKRAram();
20
21 /* vt[03] */ void* run(void); /* override */
22
23public:
28//private:
29 /* 0x00 */ // vtable
30 /* 0x04 */ // JKRThread
31 /* 0x7C */ u32 mAudioMemoryPtr;
33 /* 0x84 */ u32 mGraphMemoryPtr;
35 /* 0x8C */ u32 mAramMemoryPtr;
36 /* 0x90 */ u32 mAramMemorySize;
38 /* 0x98 */ u32 mStackArray[3];
39
40public:
41 static JKRAram* create(u32, u32, s32, s32, s32);
42 static void checkOkAddress(u8*, u32, JKRAramBlock*, u32);
43 static void changeGroupIdIfNeed(u8*, int);
46 static void dump(void);
47
48 static JKRAram* getManager() { return sAramObject; }
51
53 JKRAramHeap* heap;
55
56 if (groupId < 0) {
58 }
59
60 return (u8)groupId;
61 }
62
63 static u32 getSZSBufferSize() { return sSZSBufferSize; }
64 static void setSZSBufferSize(u32 size) { sSZSBufferSize = size; }
65
67
68private:
71 static OSMessage sMessageBuffer[4];
73};
74
78
82
84 int p7, u32* p8) {
85 return JKRAram::aramToMainRam(p1, p2, p3, p4, p5, p6, p7, p8);
86}
87
91
92// void JKRDecompressFromAramToMainRam(u32, void*, u32, u32, u32, u32*);
93
94#endif /* JKRARAM_H */
JKRAramBlock * JKRMainRamToAram(u8 *buf, u32 bufSize, u32 alignedSize, JKRExpandSwitch expandSwitch, u32 fileSize, JKRHeap *heap, int id, u32 *pSize)
Definition JKRAram.h:88
void JKRFreeToAram(JKRAramBlock *block)
Definition JKRAram.h:79
JKRAramBlock * JKRAllocFromAram(u32 size, JKRAramHeap::EAllocMode allocMode)
Definition JKRAram.h:75
u8 * JKRAramToMainRam(u32 p1, u8 *p2, u32 p3, JKRExpandSwitch p4, u32 p5, JKRHeap *p6, int p7, u32 *p8)
Definition JKRAram.h:83
JKRExpandSwitch
Definition JKRDvdRipper.h:7
void * OSMessage
Definition OSMessage.h:10
T cLib_calcTimer(T *value)
Definition c_lib.h:74
Definition JKRAramPiece.h:16
Definition JKRAramBlock.h:12
Definition JKRAramHeap.h:12
EAllocMode
Definition JKRAramHeap.h:14
u8 getCurrentGroupID() const
Definition JKRAramHeap.h:37
JKRAramBlock * alloc(u32, EAllocMode)
Definition JKRAramHeap.cpp:33
void free(JKRAramBlock *block)
Definition JKRAramHeap.h:33
Definition JKRAram.h:16
static void changeGroupIdIfNeed(u8 *, int)
Definition JKRAram.cpp:117
u32 getGraphMemory() const
Definition JKRAram.h:26
static void checkOkAddress(u8 *, u32, JKRAramBlock *, u32)
Definition JKRAram.cpp:105
void * run(void)
Definition JKRAram.cpp:84
static OSMessageQueue sMessageQueue
Definition JKRAram.h:45
static JSUList< JKRAMCommand > & getCommandList()
Definition JKRAram.h:50
u32 getAudioMemory() const
Definition JKRAram.h:24
static JKRAram * sAramObject
Definition JKRAram.h:69
u32 mAramMemoryPtr
Definition JKRAram.h:35
static u32 sSZSBufferSize
Definition JKRAram.h:70
static JKRAram * create(u32, u32, s32, s32, s32)
Definition JKRAram.cpp:22
u32 mAudioMemoryPtr
Definition JKRAram.h:31
static JKRAramBlock * mainRamToAram(u8 *, u32, u32, JKRExpandSwitch, u32, JKRHeap *, int, u32 *)
Definition JKRAram.cpp:127
static u32 getSZSBufferSize()
Definition JKRAram.h:63
u32 mAudioMemorySize
Definition JKRAram.h:32
u32 mGraphMemoryPtr
Definition JKRAram.h:33
static JKRAram * getManager()
Definition JKRAram.h:48
static void setSZSBufferSize(u32 size)
Definition JKRAram.h:64
u32 mStackArray[3]
Definition JKRAram.h:38
u32 mAramMemorySize
Definition JKRAram.h:36
u32 mGraphMemorySize
Definition JKRAram.h:34
static void dump(void)
static u8 * aramToMainRam(u32, u8 *, u32, JKRExpandSwitch, u32, JKRHeap *, int, u32 *)
Definition JKRAram.cpp:197
static u8 decideAramGroupId(int groupId)
Definition JKRAram.h:52
u32 getGraphMemSize() const
Definition JKRAram.h:27
static OSMessage sMessageBuffer[4]
Definition JKRAram.h:37
JKRAramHeap * mAramHeap
Definition JKRAram.h:37
virtual ~JKRAram()
Definition JKRAram.cpp:77
u32 getAudioMemSize() const
Definition JKRAram.h:25
static JKRAramHeap * getAramHeap()
Definition JKRAram.h:49
static JSUList< JKRAMCommand > sAramCommandList
Definition JKRAram.h:72
Definition JKRHeap.h:16
Definition JKRThread.h:23
Definition JSUList.h:96
static u8 block[48]
Definition fstload.c:39
Definition OSMessage.h:12
unsigned long u32
Definition types.h:10
signed long s32
Definition types.h:6
unsigned char u8
Definition types.h:8