From 5345c98a9c9e35d5eaf668f685d1228f333040f1 Mon Sep 17 00:00:00 2001 From: hrydgard Date: Fri, 4 Sep 2009 06:43:46 +0000 Subject: [PATCH] quickfix slowness caused by 4193 git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4195 8ced0084-cf51-0410-be5f-012b33b47a6e --- Source/Plugins/Plugin_VideoDX9/Src/TextureCache.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Source/Plugins/Plugin_VideoDX9/Src/TextureCache.cpp b/Source/Plugins/Plugin_VideoDX9/Src/TextureCache.cpp index 8a8d0e10d2..c4f68add5a 100644 --- a/Source/Plugins/Plugin_VideoDX9/Src/TextureCache.cpp +++ b/Source/Plugins/Plugin_VideoDX9/Src/TextureCache.cpp @@ -135,12 +135,12 @@ TextureCache::TCacheEntry *TextureCache::Load(int stage, u32 address, int width, int bs = TexDecoder_GetBlockWidthInTexels(format)-1; //TexelSizeInNibbles(format)*width*height/16; int expandedWidth = (width+bs) & (~bs); - u32 hash_value; - u32 tex_hash; + u32 hash_value = TexDecoder_GetSafeTextureHash(ptr, expandedWidth, height, format, 0); + u32 tex_hash = 0; - if(g_Config.bDumpTextures) + if (g_Config.bDumpTextures) { - tex_hash = TexDecoder_GetSafeTextureHash(ptr, expandedWidth, height, format, 0); + tex_hash = hash_value; if ((format == GX_TF_C4) || (format == GX_TF_C8) || (format == GX_TF_C14X2)) { u32 tlutHash = TexDecoder_GetTlutHash(&texMem[tlutaddr], (format == GX_TF_C4) ? 32 : 128);