2015-10-16 09:46:18 +00:00
|
|
|
#include <iostream>
|
|
|
|
#if GEKKO
|
|
|
|
#include <gccore.h>
|
|
|
|
#if HW_RVL
|
|
|
|
#include <wiiuse/wpad.h>
|
|
|
|
#endif
|
|
|
|
|
|
|
|
static void *xfb = nullptr;
|
|
|
|
static GXRModeObj* rmode = nullptr;
|
|
|
|
|
|
|
|
#endif
|
|
|
|
|
2016-03-04 23:00:12 +00:00
|
|
|
#include <athena/MemoryReader.hpp>
|
2015-10-16 09:46:18 +00:00
|
|
|
|
|
|
|
int main()
|
|
|
|
{
|
|
|
|
#if GEKKO
|
|
|
|
VIDEO_Init();
|
|
|
|
#if HW_RVL
|
|
|
|
WPAD_Init();
|
|
|
|
#endif
|
|
|
|
PAD_Init();
|
|
|
|
|
|
|
|
rmode = VIDEO_GetPreferredMode(nullptr);
|
|
|
|
xfb = MEM_K0_TO_K1(SYS_AllocateFramebuffer(rmode));
|
|
|
|
|
|
|
|
CON_Init(xfb, 20, 20, rmode->fbWidth, rmode->xfbHeight, rmode->fbWidth * VI_DISPLAY_PIX_SZ);
|
|
|
|
CON_EnableGecko(CARD_SLOTB, true);
|
|
|
|
|
|
|
|
VIDEO_Configure(rmode);
|
|
|
|
VIDEO_SetBlack(false);
|
|
|
|
|
|
|
|
VIDEO_Flush();
|
|
|
|
|
|
|
|
VIDEO_WaitVSync();
|
|
|
|
if (rmode->viTVMode & VI_NON_INTERLACE)
|
|
|
|
VIDEO_WaitVSync();
|
|
|
|
|
2016-03-04 23:00:12 +00:00
|
|
|
athena::io::MemoryCopyReader test("sd:/test.dat");
|
2015-10-16 09:46:18 +00:00
|
|
|
while(true)
|
|
|
|
{
|
|
|
|
#if HW_RVL
|
|
|
|
WPAD_ScanPads();
|
|
|
|
#endif
|
|
|
|
PAD_ScanPads();
|
|
|
|
if (PAD_ButtonsDown(0) & PAD_BUTTON_START)
|
|
|
|
break;
|
|
|
|
|
|
|
|
#if HW_RVL
|
|
|
|
if (WPAD_ButtonsDown(0) & WPAD_BUTTON_HOME)
|
|
|
|
break;
|
|
|
|
#endif
|
|
|
|
VIDEO_WaitVSync();
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
return 0;
|
|
|
|
}
|
|
|
|
|