mirror of https://github.com/PCSX2/pcsx2.git
GS: Hardware reset on load state
Stops unnecessary readbacks.
This commit is contained in:
parent
c72329d990
commit
1a16a527b3
|
@ -357,6 +357,17 @@ void GSclose()
|
|||
void GSreset(bool hardware_reset)
|
||||
{
|
||||
g_gs_renderer->Reset(hardware_reset);
|
||||
|
||||
// Restart video capture if it's been started.
|
||||
// Otherwise we get a buildup of audio frames from the CPU thread.
|
||||
if (hardware_reset && GSCapture::IsCapturing())
|
||||
{
|
||||
std::string next_filename = GSCapture::GetNextCaptureFileName();
|
||||
const GSVector2i size = GSCapture::GetSize();
|
||||
Console.Warning(fmt::format("Restarting video capture to {}.", next_filename));
|
||||
g_gs_renderer->EndCapture();
|
||||
g_gs_renderer->BeginCapture(std::move(next_filename), size);
|
||||
}
|
||||
}
|
||||
|
||||
void GSgifSoftReset(u32 mask)
|
||||
|
|
|
@ -2531,7 +2531,7 @@ int GSState::Defrost(const freezeData* fd)
|
|||
|
||||
Flush(GSFlushReason::LOADSTATE);
|
||||
|
||||
Reset(false);
|
||||
Reset(true);
|
||||
|
||||
ReadState(&m_env.PRIM, data);
|
||||
|
||||
|
|
|
@ -80,17 +80,6 @@ void GSRenderer::Reset(bool hardware_reset)
|
|||
g_gs_device->ClearCurrent();
|
||||
|
||||
GSState::Reset(hardware_reset);
|
||||
|
||||
// Restart video capture if it's been started.
|
||||
// Otherwise we get a buildup of audio frames from the CPU thread.
|
||||
if (hardware_reset && GSCapture::IsCapturing())
|
||||
{
|
||||
std::string next_filename = GSCapture::GetNextCaptureFileName();
|
||||
const GSVector2i size = GSCapture::GetSize();
|
||||
Console.Warning(fmt::format("Restarting video capture to {}.", next_filename));
|
||||
EndCapture();
|
||||
BeginCapture(std::move(next_filename), size);
|
||||
}
|
||||
}
|
||||
|
||||
void GSRenderer::Destroy()
|
||||
|
|
Loading…
Reference in New Issue