mirror of https://github.com/PCSX2/pcsx2.git
mtgs: make renderswitch save current state
This commit is contained in:
parent
ab65f2ab5e
commit
fa4f4bca73
|
@ -925,6 +925,7 @@ void SysMtgsThread::WaitForOpen()
|
|||
void SysMtgsThread::Freeze(int mode, MTGS_FreezeData& data)
|
||||
{
|
||||
Resume();
|
||||
WaitForOpen();
|
||||
SendPointerPacket(GS_RINGTYPE_FREEZE, mode, &data);
|
||||
Resume();
|
||||
WaitGS();
|
||||
|
|
|
@ -400,9 +400,15 @@ namespace Implementations
|
|||
return;
|
||||
if (renderswitch_delay == 0)
|
||||
{
|
||||
GetMTGS().Suspend();
|
||||
freezeData fP = {0, nullptr};
|
||||
MTGS_FreezeData sstate = {&fP, 0};
|
||||
GetMTGS().Freeze(FREEZE_SIZE, sstate);
|
||||
fP.data = new char[fP.size];
|
||||
GetMTGS().Freeze(FREEZE_SAVE, sstate);
|
||||
GetMTGS().Suspend(true);
|
||||
renderswitch = !renderswitch;
|
||||
GetMTGS().Resume();
|
||||
GetMTGS().Freeze(FREEZE_LOAD, sstate);
|
||||
delete[] fP.data;
|
||||
renderswitch_delay = -1;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue