mirror of
https://github.com/dborth/vbagx.git
synced 2024-11-26 04:24:16 +01:00
code tidy
This commit is contained in:
parent
e35145ec94
commit
03dea791a1
@ -249,11 +249,9 @@ int main(int argc, char *argv[])
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
InitDeviceThread();
|
InitDeviceThread();
|
||||||
VIDEO_Init();
|
|
||||||
SetupPads();
|
|
||||||
|
|
||||||
InitializeVideo();
|
InitializeVideo();
|
||||||
ResetVideo_Menu (); // change to menu video mode
|
ResetVideo_Menu (); // change to menu video mode
|
||||||
|
SetupPads();
|
||||||
|
|
||||||
#ifdef HW_RVL
|
#ifdef HW_RVL
|
||||||
// Wii Power/Reset buttons
|
// Wii Power/Reset buttons
|
||||||
|
@ -110,15 +110,6 @@ vbgetback (void *arg)
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
|
||||||
* InitVideoThread
|
|
||||||
***************************************************************************/
|
|
||||||
void
|
|
||||||
InitVideoThread ()
|
|
||||||
{
|
|
||||||
LWP_CreateThread (&vbthread, vbgetback, NULL, vbstack, TSTACK, 100);
|
|
||||||
}
|
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* copy_to_xfb
|
* copy_to_xfb
|
||||||
*
|
*
|
||||||
@ -137,7 +128,6 @@ copy_to_xfb (u32 arg)
|
|||||||
FrameTimer++;
|
FrameTimer++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* Scaler Support Functions
|
* Scaler Support Functions
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
@ -261,29 +251,6 @@ static inline void draw_cursor(Mtx v)
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/****************************************************************************
|
|
||||||
* StartGX
|
|
||||||
*
|
|
||||||
* Initialises GX and sets it up for use
|
|
||||||
***************************************************************************/
|
|
||||||
static void StartGX ()
|
|
||||||
{
|
|
||||||
GXColor background = { 0, 0, 0, 0xff };
|
|
||||||
|
|
||||||
/*** Clear out FIFO area ***/
|
|
||||||
memset (gp_fifo, 0, DEFAULT_FIFO_SIZE);
|
|
||||||
|
|
||||||
/*** Initialise GX ***/
|
|
||||||
GX_Init (&gp_fifo, DEFAULT_FIFO_SIZE);
|
|
||||||
GX_SetCopyClear (background, 0x00ffffff);
|
|
||||||
|
|
||||||
GX_SetDispCopyGamma (GX_GM_1_0);
|
|
||||||
GX_SetCullMode (GX_CULL_NONE);
|
|
||||||
|
|
||||||
GX_CopyDisp (xfb[whichfb], GX_TRUE); // reset xfb
|
|
||||||
GX_Flush();
|
|
||||||
}
|
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* StopGX
|
* StopGX
|
||||||
*
|
*
|
||||||
@ -420,10 +387,21 @@ static void SetupVideoMode(GXRModeObj * mode)
|
|||||||
void
|
void
|
||||||
InitializeVideo ()
|
InitializeVideo ()
|
||||||
{
|
{
|
||||||
|
VIDEO_Init();
|
||||||
GXRModeObj *rmode = FindVideoMode();
|
GXRModeObj *rmode = FindVideoMode();
|
||||||
SetupVideoMode(rmode);
|
SetupVideoMode(rmode);
|
||||||
StartGX ();
|
|
||||||
InitVideoThread ();
|
LWP_CreateThread (&vbthread, vbgetback, NULL, vbstack, TSTACK, 68);
|
||||||
|
|
||||||
|
// Initialise GX
|
||||||
|
GXColor background = { 0, 0, 0, 0xff };
|
||||||
|
memset (gp_fifo, 0, DEFAULT_FIFO_SIZE);
|
||||||
|
GX_Init (&gp_fifo, DEFAULT_FIFO_SIZE);
|
||||||
|
GX_SetCopyClear (background, 0x00ffffff);
|
||||||
|
GX_SetDispCopyGamma (GX_GM_1_0);
|
||||||
|
GX_SetCullMode (GX_CULL_NONE);
|
||||||
|
GX_CopyDisp (xfb[whichfb], GX_TRUE); // reset xfb
|
||||||
|
GX_Flush();
|
||||||
|
|
||||||
#ifdef HW_RVL
|
#ifdef HW_RVL
|
||||||
pointer[0] = new GuiImageData(player1_point_png);
|
pointer[0] = new GuiImageData(player1_point_png);
|
||||||
|
Loading…
Reference in New Issue
Block a user