diff options
| author | JMC47 <JMC4789@gmail.com> | 2021-10-11 23:11:43 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2021-10-11 23:11:43 -0400 |
| commit | 6987ea059648d1e74cba4aec2e69bba5890239e1 (patch) | |
| tree | 0b7a3481319c9383d2b1c2146299b0db29a99a8a /Source/Core/VideoCommon/BPStructs.cpp | |
| parent | 3bfb3fa52b05868f2b7f3f768a3d80f9c4991158 (diff) | |
| parent | edb66dab8469736e5c2954fd3ffb9704de4542c3 (diff) | |
Merge pull request #8350 from phire/fix-tmem
Extend Minimal TMEM cache implementation.
Diffstat (limited to 'Source/Core/VideoCommon/BPStructs.cpp')
| -rw-r--r-- | Source/Core/VideoCommon/BPStructs.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/Source/Core/VideoCommon/BPStructs.cpp b/Source/Core/VideoCommon/BPStructs.cpp index 110ae5e803..dd23b94da6 100644 --- a/Source/Core/VideoCommon/BPStructs.cpp +++ b/Source/Core/VideoCommon/BPStructs.cpp @@ -32,6 +32,7 @@ #include "VideoCommon/PixelEngine.h" #include "VideoCommon/PixelShaderManager.h" #include "VideoCommon/RenderBase.h" +#include "VideoCommon/TMEM.h" #include "VideoCommon/TextureCacheBase.h" #include "VideoCommon/TextureDecoder.h" #include "VideoCommon/VertexShaderManager.h" @@ -353,7 +354,7 @@ static void BPWritten(const BPCmd& bp) if (OpcodeDecoder::g_record_fifo_data) FifoRecorder::GetInstance().UseMemory(addr, tlutXferCount, MemoryUpdate::TMEM); - TextureCacheBase::InvalidateAllBindPoints(); + TMEM::InvalidateAll(); return; } @@ -459,8 +460,7 @@ static void BPWritten(const BPCmd& bp) } return; case BPMEM_TEXINVALIDATE: - // TODO: Needs some restructuring in TextureCacheBase. - TextureCacheBase::InvalidateAllBindPoints(); + TMEM::Invalidate(bp.newvalue); return; case BPMEM_ZCOMPARE: // Set the Z-Compare and EFB pixel format @@ -568,7 +568,7 @@ static void BPWritten(const BPCmd& bp) if (OpcodeDecoder::g_record_fifo_data) FifoRecorder::GetInstance().UseMemory(src_addr, bytes_read, MemoryUpdate::TMEM); - TextureCacheBase::InvalidateAllBindPoints(); + TMEM::InvalidateAll(); } return; @@ -661,7 +661,7 @@ static void BPWritten(const BPCmd& bp) // ------------------------ case TexUnitAddress::Register::SETMODE0: case TexUnitAddress::Register::SETMODE1: - TextureCacheBase::InvalidateAllBindPoints(); + TMEM::ConfigurationChanged(tex_address, bp.newvalue); return; // -------------------------------------------- @@ -675,7 +675,7 @@ static void BPWritten(const BPCmd& bp) case TexUnitAddress::Register::SETIMAGE1: case TexUnitAddress::Register::SETIMAGE2: case TexUnitAddress::Register::SETIMAGE3: - TextureCacheBase::InvalidateAllBindPoints(); + TMEM::ConfigurationChanged(tex_address, bp.newvalue); return; // ------------------------------- @@ -683,7 +683,7 @@ static void BPWritten(const BPCmd& bp) // BPMEM_TX_SETTLUT - Format, TMEM Offset (offset of TLUT from start of TMEM high bank > > 5) // ------------------------------- case TexUnitAddress::Register::SETTLUT: - TextureCacheBase::InvalidateAllBindPoints(); + TMEM::ConfigurationChanged(tex_address, bp.newvalue); return; case TexUnitAddress::Register::UNKNOWN: break; // Not handled |
