mirror of
https://github.com/dborth/snes9xgx.git
synced 2024-11-30 14:34:22 +01:00
code formatting
This commit is contained in:
parent
72b41f925a
commit
e1feb6ea0b
@ -31,9 +31,9 @@ static unsigned char snes9xgfx[1024 * 512 * 2];
|
||||
extern unsigned int SMBTimer;
|
||||
|
||||
/*** 2D Video ***/
|
||||
unsigned int *xfb[2] = { NULL, NULL }; /*** Double buffered ***/
|
||||
int whichfb = 0; /*** Switch ***/
|
||||
GXRModeObj *vmode; /*** Menu video mode ***/
|
||||
unsigned int *xfb[2] = { NULL, NULL }; // Double buffered
|
||||
int whichfb = 0; // Switch
|
||||
GXRModeObj *vmode; // Menu video mode
|
||||
int screenheight;
|
||||
extern u32* backdrop;
|
||||
|
||||
@ -305,7 +305,6 @@ InitVideoThread ()
|
||||
static void
|
||||
copy_to_xfb (u32 arg)
|
||||
{
|
||||
|
||||
if (copynow == GX_TRUE)
|
||||
{
|
||||
GX_CopyDisp (xfb[whichfb], GX_TRUE);
|
||||
@ -347,7 +346,6 @@ draw_init ()
|
||||
GX_LoadPosMtxImm (view, GX_PNMTX0);
|
||||
|
||||
GX_InvVtxCache (); // update vertex cache
|
||||
|
||||
}
|
||||
|
||||
static void
|
||||
@ -472,7 +470,6 @@ InitGCVideo ()
|
||||
// set VI position
|
||||
TV_224p.viYOrigin = (VI_MAX_HEIGHT_PAL/2 - 448/2)/2;
|
||||
TV_448i.viYOrigin = (VI_MAX_HEIGHT_PAL - 448)/2;
|
||||
|
||||
break;
|
||||
|
||||
case VI_NTSC:
|
||||
@ -491,7 +488,6 @@ InitGCVideo ()
|
||||
TV_224p.viYOrigin = (VI_MAX_HEIGHT_NTSC/2 - 448/2)/2;
|
||||
TV_448i.viYOrigin = (VI_MAX_HEIGHT_NTSC - 448)/2;
|
||||
break;
|
||||
break;
|
||||
|
||||
default:
|
||||
// 480 lines (PAL 60Hz)
|
||||
@ -576,7 +572,8 @@ ResetVideo_Emu ()
|
||||
int i = -1;
|
||||
if (GCSettings.render == 0) // original render mode
|
||||
{
|
||||
for (i=0; i<4; i++) {
|
||||
for (i=0; i<4; i++)
|
||||
{
|
||||
if (tvmodes[i]->efbHeight == vheight)
|
||||
break;
|
||||
}
|
||||
@ -590,8 +587,11 @@ ResetVideo_Emu ()
|
||||
VIDEO_Configure (rmode);
|
||||
VIDEO_Flush();
|
||||
VIDEO_WaitVSync();
|
||||
if (rmode->viTVMode & VI_NON_INTERLACE) VIDEO_WaitVSync();
|
||||
else while (VIDEO_GetNextField()) VIDEO_WaitVSync();
|
||||
if (rmode->viTVMode & VI_NON_INTERLACE)
|
||||
VIDEO_WaitVSync();
|
||||
else
|
||||
while (VIDEO_GetNextField())
|
||||
VIDEO_WaitVSync();
|
||||
|
||||
|
||||
GX_SetViewport (0, 0, rmode->fbWidth, rmode->efbHeight, 0, 1);
|
||||
@ -630,8 +630,11 @@ ResetVideo_Menu ()
|
||||
VIDEO_ClearFrameBuffer (vmode, xfb[whichfb], COLOR_BLACK);
|
||||
VIDEO_Flush();
|
||||
VIDEO_WaitVSync();
|
||||
if (vmode->viTVMode & VI_NON_INTERLACE) VIDEO_WaitVSync();
|
||||
else while (VIDEO_GetNextField()) VIDEO_WaitVSync();
|
||||
if (vmode->viTVMode & VI_NON_INTERLACE)
|
||||
VIDEO_WaitVSync();
|
||||
else
|
||||
while (VIDEO_GetNextField())
|
||||
VIDEO_WaitVSync();
|
||||
|
||||
GX_SetViewport (0, 0, vmode->fbWidth, vmode->efbHeight, 0, 1);
|
||||
GX_SetDispCopyYScale ((f32) vmode->xfbHeight / (f32) vmode->efbHeight);
|
||||
@ -732,7 +735,9 @@ update_video (int width, int height)
|
||||
{
|
||||
xscale = 256;
|
||||
yscale = vheight / 2;
|
||||
} else { // unfiltered and filtered mode
|
||||
}
|
||||
else // unfiltered and filtered mode
|
||||
{
|
||||
xscale = 320;
|
||||
yscale = vheight;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user