Files
tp/include/JSystem/JUtility/JUTGraphFifo.h
T

42 lines
892 B
C++
Raw Normal View History

2021-03-28 22:49:05 +02:00
#ifndef JUTGRAPHFIFO_H
#define JUTGRAPHFIFO_H
2024-01-19 16:22:19 -08:00
#include "dolphin/gx.h"
2021-03-28 22:49:05 +02:00
2024-04-12 00:10:30 -06:00
/**
* @ingroup jsystem-jutility
*
*/
2022-01-10 06:10:00 -08:00
class JUTGraphFifo {
public:
2025-11-30 14:23:42 -08:00
JUTGraphFifo(u32);
2022-01-10 06:10:00 -08:00
2025-11-30 14:23:42 -08:00
virtual ~JUTGraphFifo();
2022-01-10 06:10:00 -08:00
2026-01-05 04:07:04 -08:00
static bool* getGpStatus() {
2022-01-10 06:10:00 -08:00
GXGetGPStatus((GXBool*)&mGpStatus[0], (GXBool*)&mGpStatus[1], (GXBool*)&mGpStatus[2],
(GXBool*)&mGpStatus[3], (GXBool*)&mGpStatus[4]);
2026-01-05 04:07:04 -08:00
return mGpStatus;
2022-01-10 06:10:00 -08:00
}
2026-01-05 04:07:04 -08:00
static bool isGPActive() {
2022-01-10 06:10:00 -08:00
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];
};
inline JUTGraphFifo* JUTCreateFifo(u32 bufSize) { return new JUTGraphFifo(bufSize); }
2023-07-24 01:30:24 +03:00
2021-03-28 22:49:05 +02:00
#endif /* JUTGRAPHFIFO_H */