mirror of
https://github.com/blawar/GLideN64.git
synced 2024-07-07 03:13:49 +00:00
Disable rendering when config dialog is open to prevent plugin crash if
new settings are incompatible with the current ones.
This commit is contained in:
parent
831b3410ed
commit
143cee1712
|
@ -9,3 +9,5 @@ u8 *RDRAM;
|
||||||
u32 RDRAMSize;
|
u32 RDRAMSize;
|
||||||
|
|
||||||
N64Regs REG;
|
N64Regs REG;
|
||||||
|
|
||||||
|
bool ConfigOpen = false;
|
||||||
|
|
|
@ -47,6 +47,7 @@ extern u8 *IMEM;
|
||||||
extern u8 *RDRAM;
|
extern u8 *RDRAM;
|
||||||
extern u64 TMEM[TMEM_SIZE];
|
extern u64 TMEM[TMEM_SIZE];
|
||||||
extern u32 RDRAMSize;
|
extern u32 RDRAMSize;
|
||||||
|
extern bool ConfigOpen;
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -137,6 +137,11 @@ void RSP_CheckDLCounter()
|
||||||
|
|
||||||
void RSP_ProcessDList()
|
void RSP_ProcessDList()
|
||||||
{
|
{
|
||||||
|
if (ConfigOpen) {
|
||||||
|
gDPFullSync();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
RSP.PC[0] = *(u32*)&DMEM[0x0FF0];
|
RSP.PC[0] = *(u32*)&DMEM[0x0FF0];
|
||||||
RSP.PCi = 0;
|
RSP.PCi = 0;
|
||||||
RSP.count = -1;
|
RSP.count = -1;
|
||||||
|
|
|
@ -91,6 +91,9 @@ void VI_UpdateScreen()
|
||||||
if (VI.lastOrigin == -1) // Workaround for Mupen64Plus issue with initialization
|
if (VI.lastOrigin == -1) // Workaround for Mupen64Plus issue with initialization
|
||||||
isGLError();
|
isGLError();
|
||||||
|
|
||||||
|
if (ConfigOpen)
|
||||||
|
return;
|
||||||
|
|
||||||
OGLVideo & ogl = video();
|
OGLVideo & ogl = video();
|
||||||
if (ogl.changeWindow())
|
if (ogl.changeWindow())
|
||||||
return;
|
return;
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
#include "GLideN64_Windows.h"
|
#include "GLideN64_Windows.h"
|
||||||
|
#include "../N64.h"
|
||||||
#include "../Config.h"
|
#include "../Config.h"
|
||||||
#include "../RSP.h"
|
#include "../RSP.h"
|
||||||
#include "../PluginAPI.h"
|
#include "../PluginAPI.h"
|
||||||
|
@ -12,11 +13,13 @@ void Config_DoConfig(/*HWND hParent*/)
|
||||||
wchar_t strIniFolderPath[PLUGIN_PATH_SIZE];
|
wchar_t strIniFolderPath[PLUGIN_PATH_SIZE];
|
||||||
api().FindPluginPath(strIniFolderPath);
|
api().FindPluginPath(strIniFolderPath);
|
||||||
|
|
||||||
|
ConfigOpen = true;
|
||||||
const bool bRestart = RunConfig(strIniFolderPath);
|
const bool bRestart = RunConfig(strIniFolderPath);
|
||||||
if (config.generalEmulation.enableCustomSettings != 0)
|
if (config.generalEmulation.enableCustomSettings != 0)
|
||||||
LoadCustomRomSettings(strIniFolderPath, RSP.romname);
|
LoadCustomRomSettings(strIniFolderPath, RSP.romname);
|
||||||
if (bRestart)
|
if (bRestart)
|
||||||
video().restart();
|
video().restart();
|
||||||
|
ConfigOpen = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
void Config_LoadConfig()
|
void Config_LoadConfig()
|
||||||
|
|
Loading…
Reference in New Issue
Block a user