summaryrefslogtreecommitdiff
path: root/include/JSystem
diff options
context:
space:
mode:
authorTakaRikka <38417346+TakaRikka@users.noreply.github.com>2022-01-10 06:10:00 -0800
committerTakaRikka <38417346+TakaRikka@users.noreply.github.com>2022-01-10 06:10:00 -0800
commita08f84abd508ddf6cbdddcd994a300a16be0e46f (patch)
tree12d8f1fa732b7c7910088442ff91e3250faaaa52 /include/JSystem
parent32fc4e2944b053485b03845d387bd28ffe267cbb (diff)
JUTGraphFifo
Diffstat (limited to 'include/JSystem')
-rw-r--r--include/JSystem/JUtility/JUTGraphFifo.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/include/JSystem/JUtility/JUTGraphFifo.h b/include/JSystem/JUtility/JUTGraphFifo.h
index 393b232adb..8dae2c7b90 100644
--- a/include/JSystem/JUtility/JUTGraphFifo.h
+++ b/include/JSystem/JUtility/JUTGraphFifo.h
@@ -1,6 +1,35 @@
#ifndef JUTGRAPHFIFO_H
#define JUTGRAPHFIFO_H
+#include "dolphin/gx/GX.h"
#include "dolphin/types.h"
+class JUTGraphFifo {
+public:
+ /* 802DEB58 */ JUTGraphFifo(u32);
+
+ /* 802DEC34 */ virtual ~JUTGraphFifo();
+
+ void getGpStatus() {
+ GXGetGPStatus((GXBool*)&mGpStatus[0], (GXBool*)&mGpStatus[1], (GXBool*)&mGpStatus[2],
+ (GXBool*)&mGpStatus[3], (GXBool*)&mGpStatus[4]);
+ }
+
+ bool isGPActive() {
+ getGpStatus();
+ return mGpStatus[2] == false;
+ }
+
+ void save() { GXSaveCPUFifo(this->mFifo); }
+
+ static JUTGraphFifo* sCurrentFifo;
+ static bool mGpStatus[5];
+
+private:
+ /* 0x04 */ GXFifoObj* mFifo;
+ /* 0x08 */ void* mBase;
+ /* 0x0C */ u32 mSize;
+ /* 0x10 */ u8 field_0x10[0xC];
+};
+
#endif /* JUTGRAPHFIFO_H */