mirror of
https://github.com/dborth/snes9xgx.git
synced 2024-11-24 03:29:22 +01:00
fix screen flicker when going back to menu
This commit is contained in:
parent
f8caf2e9df
commit
36b33a261c
@ -3782,12 +3782,7 @@ MainMenu (int menu)
|
|||||||
gameScreenImg = new GuiImage(gameScreen);
|
gameScreenImg = new GuiImage(gameScreen);
|
||||||
gameScreenImg->SetAlpha(192);
|
gameScreenImg->SetAlpha(192);
|
||||||
gameScreenImg->ColorStripe(30);
|
gameScreenImg->ColorStripe(30);
|
||||||
|
|
||||||
if (GCSettings.render > 0 && !GCSettings.widescreen)
|
|
||||||
gameScreenImg->SetScaleX(screenwidth/(vmode->fbWidth*0.8));
|
|
||||||
else
|
|
||||||
gameScreenImg->SetScaleX(screenwidth/(float)vmode->fbWidth);
|
gameScreenImg->SetScaleX(screenwidth/(float)vmode->fbWidth);
|
||||||
|
|
||||||
gameScreenImg->SetScaleY(screenheight/(float)vmode->efbHeight);
|
gameScreenImg->SetScaleY(screenheight/(float)vmode->efbHeight);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
@ -569,6 +569,21 @@ InitGCVideo ()
|
|||||||
vheight = 100;
|
vheight = 100;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ResetFbWidth(int width, GXRModeObj *rmode)
|
||||||
|
{
|
||||||
|
if(rmode->fbWidth == width)
|
||||||
|
return;
|
||||||
|
|
||||||
|
rmode->fbWidth = width;
|
||||||
|
|
||||||
|
if(rmode != vmode)
|
||||||
|
return;
|
||||||
|
|
||||||
|
GX_InvVtxCache();
|
||||||
|
VIDEO_Configure(rmode);
|
||||||
|
VIDEO_Flush();
|
||||||
|
}
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* ResetVideo_Emu
|
* ResetVideo_Emu
|
||||||
*
|
*
|
||||||
@ -617,12 +632,10 @@ ResetVideo_Emu ()
|
|||||||
{
|
{
|
||||||
rmode = FindVideoMode();
|
rmode = FindVideoMode();
|
||||||
|
|
||||||
if (!GCSettings.widescreen)
|
if (GCSettings.widescreen)
|
||||||
{
|
ResetFbWidth(640, rmode);
|
||||||
memcpy(&TV_Custom, rmode, sizeof(TV_Custom));
|
else
|
||||||
rmode = &TV_Custom;
|
ResetFbWidth(512, rmode);
|
||||||
rmode->fbWidth = 512;
|
|
||||||
}
|
|
||||||
|
|
||||||
Settings.SoundInputRate = 31953;
|
Settings.SoundInputRate = 31953;
|
||||||
UpdatePlaybackRate();
|
UpdatePlaybackRate();
|
||||||
|
Loading…
Reference in New Issue
Block a user