From b26bb0605b962456720519b273f171919ebfb65d Mon Sep 17 00:00:00 2001 From: Stenzek Date: Sat, 29 Jun 2019 18:35:12 +1000 Subject: VideoBackendBase: Do save state logic on the GPU thread --- Source/Core/VideoCommon/VertexManagerBase.cpp | 3 --- 1 file changed, 3 deletions(-) (limited to 'Source/Core/VideoCommon/VertexManagerBase.cpp') diff --git a/Source/Core/VideoCommon/VertexManagerBase.cpp b/Source/Core/VideoCommon/VertexManagerBase.cpp index c9fa12f6bb..527a836d63 100644 --- a/Source/Core/VideoCommon/VertexManagerBase.cpp +++ b/Source/Core/VideoCommon/VertexManagerBase.cpp @@ -338,9 +338,6 @@ void VertexManagerBase::Flush() m_is_flushed = true; - // loading a state will invalidate BP, so check for it - g_video_backend->CheckInvalidState(); - #if defined(_DEBUG) || defined(DEBUGFAST) PRIM_LOG("frame%d:\n texgen=%u, numchan=%u, dualtex=%u, ztex=%u, cole=%u, alpe=%u, ze=%u", g_ActiveConfig.iSaveTargetId, xfmem.numTexGen.numTexGens, xfmem.numChan.numColorChans, -- cgit v1.2.3 From 1082468133342586ae2a5986408d163ce5aa14ca Mon Sep 17 00:00:00 2001 From: Stenzek Date: Sat, 29 Jun 2019 19:27:53 +1000 Subject: TextureCache: Support saving cache entries, including EFB copies --- Source/Core/VideoCommon/VertexManagerBase.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'Source/Core/VideoCommon/VertexManagerBase.cpp') diff --git a/Source/Core/VideoCommon/VertexManagerBase.cpp b/Source/Core/VideoCommon/VertexManagerBase.cpp index 527a836d63..f1150dc340 100644 --- a/Source/Core/VideoCommon/VertexManagerBase.cpp +++ b/Source/Core/VideoCommon/VertexManagerBase.cpp @@ -461,6 +461,16 @@ void VertexManagerBase::Flush() void VertexManagerBase::DoState(PointerWrap& p) { + if (p.GetMode() == PointerWrap::MODE_READ) + { + // Flush old vertex data before loading state. + Flush(); + + // Clear all caches that touch RAM + // (? these don't appear to touch any emulation state that gets saved. moved to on load only.) + VertexLoaderManager::MarkAllDirty(); + } + p.Do(m_zslope); } -- cgit v1.2.3