summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon/Src/TextureCacheBase.cpp
diff options
context:
space:
mode:
authorNeoBrainX <NeoBrainX@gmail.com>2012-05-28 11:37:14 +0200
committerNeoBrainX <NeoBrainX@gmail.com>2012-06-20 18:18:17 +0200
commit8bed27a3d1e3044d8e3ce02c17b6bd07b8130e80 (patch)
treef46a4985d32d74bf19bda8198e58ee206dd8de60 /Source/Core/VideoCommon/Src/TextureCacheBase.cpp
parent8d30ac462a499d0bde615c260bf9c69146859b9a (diff)
Enable hires textures even when texture dumping is enabled.
Remove some deprecated code.
Diffstat (limited to 'Source/Core/VideoCommon/Src/TextureCacheBase.cpp')
-rw-r--r--Source/Core/VideoCommon/Src/TextureCacheBase.cpp20
1 files changed, 9 insertions, 11 deletions
diff --git a/Source/Core/VideoCommon/Src/TextureCacheBase.cpp b/Source/Core/VideoCommon/Src/TextureCacheBase.cpp
index cc5a0f29b4..69e4bffff8 100644
--- a/Source/Core/VideoCommon/Src/TextureCacheBase.cpp
+++ b/Source/Core/VideoCommon/Src/TextureCacheBase.cpp
@@ -61,28 +61,19 @@ TextureCache::TextureCache()
SetHash64Function(g_ActiveConfig.bHiresTextures || g_ActiveConfig.bDumpTextures);
}
-// TODO: Kill shutdown parameter...
-void TextureCache::Invalidate(bool shutdown)
+void TextureCache::Invalidate()
{
TexCache::iterator
iter = textures.begin(),
tcend = textures.end();
for (; iter != tcend; ++iter)
- {
- if (shutdown)
- iter->second->addr = 0;
delete iter->second;
- }
textures.clear();
- if(g_ActiveConfig.bHiresTextures && !g_ActiveConfig.bDumpTextures)
- HiresTextures::Init(SConfig::GetInstance().m_LocalCoreStartupParameter.m_strUniqueID.c_str());
- SetHash64Function(g_ActiveConfig.bHiresTextures || g_ActiveConfig.bDumpTextures);
}
TextureCache::~TextureCache()
{
- Invalidate(true);
if (temp)
{
FreeAlignedMemory(temp);
@@ -100,7 +91,14 @@ void TextureCache::OnConfigChanged(VideoConfig& config)
config.bTexFmtOverlayEnable != backup_config.s_texfmt_overlay ||
config.bTexFmtOverlayCenter != backup_config.s_texfmt_overlay_center ||
config.bHiresTextures != backup_config.s_hires_textures)
- g_texture_cache->Invalidate(false);
+ {
+ g_texture_cache->Invalidate();
+
+ if(g_ActiveConfig.bHiresTextures)
+ HiresTextures::Init(SConfig::GetInstance().m_LocalCoreStartupParameter.m_strUniqueID.c_str());
+
+ SetHash64Function(g_ActiveConfig.bHiresTextures || g_ActiveConfig.bDumpTextures);
+ }
// TODO: Probably shouldn't clear all render targets here, just mark them dirty or something.
if (config.bEFBCopyCacheEnable != backup_config.s_copy_cache_enable || // TODO: not sure if this is needed?