summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon/TextureCacheBase.cpp
diff options
context:
space:
mode:
authorAdmiral H. Curtiss <pikachu025@gmail.com>2022-11-06 18:58:51 +0100
committerGitHub <noreply@github.com>2022-11-06 18:58:51 +0100
commitc931529e7aa5926b8a21a193bf8f80244b3ae888 (patch)
tree0e82db8a6173fd3034bd77a459e2a25a247510e1 /Source/Core/VideoCommon/TextureCacheBase.cpp
parent134833727770a519d3061dbbbb0c8a7f9c1a3ab7 (diff)
parentea3e133200cda61f2e87a6e942f89e76b2c6f4fc (diff)
Merge pull request #11225 from iwubcode/graphics-mod-textureload-callable
VideoCommon: call texture load graphics mod hook when textures are loaded
Diffstat (limited to 'Source/Core/VideoCommon/TextureCacheBase.cpp')
-rw-r--r--Source/Core/VideoCommon/TextureCacheBase.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/Source/Core/VideoCommon/TextureCacheBase.cpp b/Source/Core/VideoCommon/TextureCacheBase.cpp
index a90efd15be..29f972a67b 100644
--- a/Source/Core/VideoCommon/TextureCacheBase.cpp
+++ b/Source/Core/VideoCommon/TextureCacheBase.cpp
@@ -1243,6 +1243,13 @@ TextureCacheBase::TCacheEntry* TextureCacheBase::Load(const TextureInfo& texture
if (entry->texture_info_name.empty() && g_ActiveConfig.bGraphicMods)
{
entry->texture_info_name = texture_info.CalculateTextureName().GetFullName();
+
+ GraphicsModActionData::TextureLoad texture_load{entry->texture_info_name};
+ for (const auto action :
+ g_renderer->GetGraphicsModManager().GetTextureLoadActions(entry->texture_info_name))
+ {
+ action->OnTextureLoad(&texture_load);
+ }
}
bound_textures[texture_info.GetStage()] = entry;