Attempt to refix the issue solved by r1872 without the performance

impact on the safe texture cache.  This is kind of messy, but it seems 
to work.

(I have a feeling there's something strange going on, but I'm not sure 
how to go about investigating it.)



git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1873 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
magumagu9 2009-01-15 05:24:47 +00:00
parent 27fb636451
commit 4a325d466d
1 changed files with 5 additions and 2 deletions

View File

@ -246,7 +246,10 @@ TextureMngr::TCacheEntry* TextureMngr::Load(int texstage, u32 address, int width
bool skip_texture_create = false;
TexCache::iterator iter = textures.find(address);
TexCache::iterator iter = textures.find(g_Config.bSafeTextureCache ? hash_value : address);
if (g_Config.bSafeTextureCache && iter == textures.end())
iter = textures.find(address);
if (iter != textures.end()) {
TCacheEntry &entry = iter->second;
@ -287,7 +290,7 @@ TextureMngr::TCacheEntry* TextureMngr::Load(int texstage, u32 address, int width
PC_TexFormat dfmt = TexDecoder_Decode(temp, ptr, expandedWidth, height, format, tlutaddr, tlutfmt);
//Make an entry in the table
TCacheEntry& entry = textures[ address ];
TCacheEntry& entry = textures[ g_Config.bSafeTextureCache ? hash_value : address ];
entry.hashoffset = 0;
entry.paletteHash = hashseed;