mirror of
https://github.com/zeldaret/tp
synced 2026-07-09 23:01:41 -04:00
Merge branch 'master' of https://github.com/zeldaret/tp into pr___
This commit is contained in:
@@ -22,6 +22,8 @@ public:
|
||||
|
||||
/* 802E4240 */ static JUTDirectPrint* start();
|
||||
|
||||
static JUTDirectPrint* getManager() { return sDirectPrint; }
|
||||
|
||||
private:
|
||||
static u8 sAsciiTable[128];
|
||||
static u32 sFontData[64];
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
|
||||
#include "JSystem/JKernel/JKRThread.h"
|
||||
#include "JSystem/JUtility/JUTGamePad.h"
|
||||
#include "Runtime.PPCEABI.H/__va_arg.h"
|
||||
#include "dolphin/gx/GX.h"
|
||||
#include "dolphin/os/OS.h"
|
||||
#include "dolphin/types.h"
|
||||
@@ -26,7 +27,7 @@ public:
|
||||
/* 802E1D5C */ JUTException(JUTDirectPrint*);
|
||||
/* 802E1E40 */ void create(JUTDirectPrint*);
|
||||
/* 802E1FCC */ void errorHandler(u16, OSContext*, u32, u32);
|
||||
/* 802E20C0 */ void panic_f_va(char const*, int, char const*, __va_list_struct*);
|
||||
/* 802E20C0 */ void panic_f_va(char const*, int, char const*, va_list);
|
||||
/* 802E21FC */ static void panic_f(char const*, int, char const*, ...);
|
||||
/* 802E227C */ void setFPException(u32);
|
||||
/* 802E22C4 */ void showFloatSub(int, f32);
|
||||
|
||||
@@ -8,28 +8,30 @@
|
||||
|
||||
class JUTVideo {
|
||||
public:
|
||||
typedef void (*CallbackFn)(void);
|
||||
typedef void (*Callback)(u32);
|
||||
|
||||
JUTVideo(_GXRenderModeObj const*);
|
||||
JUTVideo(GXRenderModeObj const*);
|
||||
virtual ~JUTVideo();
|
||||
|
||||
// TODO: return types not confirmed
|
||||
/* 802E4C54 */ static JUTVideo* createManager(_GXRenderModeObj const*);
|
||||
/* 802E4C54 */ static JUTVideo* createManager(GXRenderModeObj const*);
|
||||
/* 802E4CAC */ static void destroyManager();
|
||||
/* 802E4E50 */ void preRetraceProc(u32);
|
||||
/* 802E5088 */ void drawDoneStart();
|
||||
/* 802E50B0 */ void dummyNoDrawWait();
|
||||
/* 802E50BC */ void drawDoneCallback();
|
||||
/* 802E5144 */ void postRetraceProc(u32);
|
||||
/* 802E5198 */ void setRenderMode(_GXRenderModeObj const*);
|
||||
/* 802E5198 */ void setRenderMode(GXRenderModeObj const*);
|
||||
/* 802E5210 */ void waitRetraceIfNeed();
|
||||
|
||||
static JUTVideo* getManager() { return sManager; }
|
||||
_GXRenderModeObj* getRenderMode() const { return mRenderObj; }
|
||||
/* 802E4E50 */ static void preRetraceProc(u32);
|
||||
/* 802E5144 */ static void postRetraceProc(u32);
|
||||
/* 802E50BC */ static void drawDoneCallback();
|
||||
|
||||
static JUTVideo* getManager() { return sManager; }
|
||||
GXRenderModeObj* getRenderMode() const { return mRenderObj; }
|
||||
|
||||
private:
|
||||
static JUTVideo* sManager;
|
||||
static u32 sVideoLastTick;
|
||||
static u32 sVideoInterval;
|
||||
static OSTick sVideoLastTick;
|
||||
static OSTick sVideoInterval;
|
||||
|
||||
private:
|
||||
/* 0x04 */ _GXRenderModeObj* mRenderObj;
|
||||
@@ -40,12 +42,16 @@ private:
|
||||
/* 0x18 */ u32 field_0x18;
|
||||
/* 0x1C */ VIRetraceCallback mPreRetraceCallback;
|
||||
/* 0x20 */ VIRetraceCallback mPostRetraceCallback;
|
||||
/* 0x24 */ CallbackFn unknown_callback_1;
|
||||
/* 0x28 */ CallbackFn unknown_callback_2;
|
||||
/* 0x24 */ Callback mPreCallback;
|
||||
/* 0x28 */ Callback mPostCallback;
|
||||
/* 0x2C */ bool mSetBlack;
|
||||
/* 0x30 */ s32 mSetBlackFrameCount;
|
||||
/* 0x34 */ OSMessage mMessage;
|
||||
/* 0x38 */ OSMessageQueue mMessageQueue;
|
||||
};
|
||||
|
||||
inline JUTVideo* JUTGetVideoManager() {
|
||||
return JUTVideo::getManager();
|
||||
}
|
||||
|
||||
#endif /* JUTVIDEO_H */
|
||||
|
||||
@@ -23,6 +23,36 @@ public:
|
||||
/* 802E5424 */ static void destroyManager();
|
||||
/* 802E5454 */ void initiate(u16, u16, JKRHeap*, JUTXfb::EXfbNumber);
|
||||
|
||||
s32 getBufferNum() const { return mBufferNum; }
|
||||
s16 getDrawnXfbIndex() const { return mDrawnXfbIndex; }
|
||||
s16 getDrawningXfbIndex() const { return mDrawingXfbIndex; }
|
||||
s16 getDisplayingXfbIndex() const { return mDisplayingXfbIndex; }
|
||||
s32 getSDrawingFlag() const { return mSDrawingFlag; }
|
||||
|
||||
void* getDrawnXfb() const {
|
||||
if (mDrawnXfbIndex >= 0)
|
||||
return mBuffer[mDrawnXfbIndex];
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void* getDrawningXfb() const {
|
||||
if (mDrawingXfbIndex >= 0)
|
||||
return mBuffer[mDrawingXfbIndex];
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void* getDisplayingXfb() const {
|
||||
if (mDisplayingXfbIndex >= 0)
|
||||
return mBuffer[mDisplayingXfbIndex];
|
||||
return NULL;
|
||||
}
|
||||
|
||||
void setDisplayingXfbIndex(s16 index) { mDisplayingXfbIndex = index; }
|
||||
void setSDrawingFlag(s32 flag) { mSDrawingFlag = flag; }
|
||||
|
||||
static JUTXfb* getManager() { return sManager; }
|
||||
|
||||
private:
|
||||
static JUTXfb* sManager;
|
||||
|
||||
private:
|
||||
|
||||
@@ -291,7 +291,7 @@ typedef enum _GXTevAlphaArg {
|
||||
/* 0x6 */ GX_CA_ZERO,
|
||||
} GXTevAlphaArg;
|
||||
|
||||
struct _GXRenderModeObj {
|
||||
typedef struct _GXRenderModeObj {
|
||||
s32 vi_tv_mode;
|
||||
u16 fb_width;
|
||||
u16 efb_height;
|
||||
@@ -305,7 +305,7 @@ struct _GXRenderModeObj {
|
||||
u8 antialiasing;
|
||||
u8 sample_pattern[12][2];
|
||||
u8 vfilter[7];
|
||||
};
|
||||
} GXRenderModeObj;
|
||||
|
||||
struct _GXTexObj {
|
||||
u32 texture_filter;
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
#ifndef OS_H_
|
||||
#define OS_H_
|
||||
|
||||
#include "Runtime.PPCEABI.H/__va_arg.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
/* TODO: more structs, and get rid of the ones that are faked! */
|
||||
@@ -122,8 +123,6 @@ struct OSThread {
|
||||
void* data[2];
|
||||
};
|
||||
|
||||
struct __va_list_struct;
|
||||
|
||||
extern "C" {
|
||||
s32 OSEnableScheduler(void);
|
||||
s32 OSDisableScheduler(void);
|
||||
@@ -165,7 +164,7 @@ void OSReportDisable(void);
|
||||
void OSReportEnable(void);
|
||||
void OSReportForceEnableOff(void);
|
||||
void OSReportForceEnableOn(void);
|
||||
void OSVReport(const char* format, __va_list_struct* list);
|
||||
void OSVReport(const char* format, va_list list);
|
||||
|
||||
void OSTicksToCalendarTime(OSTime ticks, OSCalendarTime* out_time);
|
||||
OSTime OSGetTime(void);
|
||||
@@ -202,7 +201,7 @@ u8* OSGetStackPointer(void);
|
||||
|
||||
void OSSwitchFiberEx(u32, u32, u32, u32, u32, u32);
|
||||
|
||||
void OSVAttention(const char* fmt, __va_list_struct* va_list);
|
||||
void OSVAttention(const char* fmt, va_list args);
|
||||
|
||||
void OSReportInit(void);
|
||||
|
||||
|
||||
@@ -1,10 +1,21 @@
|
||||
#ifndef VI_H
|
||||
#define VI_H
|
||||
|
||||
#include "dolphin/gx/GX.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
typedef void (*VIRetraceCallback)(u32);
|
||||
|
||||
extern "C" void VIWaitForRetrace(void);
|
||||
extern "C" void VISetNextFrameBuffer(void*);
|
||||
extern "C" VIRetraceCallback VISetPreRetraceCallback(VIRetraceCallback);
|
||||
extern "C" VIRetraceCallback VISetPostRetraceCallback(VIRetraceCallback);
|
||||
extern "C" void VIInit();
|
||||
extern "C" void VIConfigure(GXRenderModeObj*);
|
||||
extern "C" void VIFlush();
|
||||
extern "C" void* VIGetNextFrameBuffer();
|
||||
extern "C" void* VIGetCurrentFrameBuffer();
|
||||
extern "C" void VISetBlack(BOOL);
|
||||
extern "C" u32 VIGetRetraceCount();
|
||||
|
||||
#endif /* VI_H */
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#ifndef MSL_STRING_H_
|
||||
#define MSL_STRING_H_
|
||||
|
||||
#include "Runtime.PPCEABI.H/__va_arg.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
// TODO: move to MSL_C.PPCEABI.bare.H/
|
||||
@@ -20,9 +21,7 @@ int tolower(int);
|
||||
int sprintf(char*, const char*, ...);
|
||||
int printf(const char*, ...);
|
||||
int snprintf(char*, u32, const char*, ...);
|
||||
|
||||
struct __va_list_struct;
|
||||
size_t vsnprintf(char* buffer, size_t buffer_size, const char* format, __va_list_struct* args);
|
||||
size_t vsnprintf(char* buffer, size_t buffer_size, const char* format, va_list args);
|
||||
}
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user