Fixed saving states in OGL Linux.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1313 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
XTra.KrazzY
2008-11-27 12:13:15 +00:00
parent 7a72ed3e4a
commit 3b67df1b45
4 changed files with 37 additions and 24 deletions

View File

@ -108,15 +108,17 @@ void TextureMngr::TCacheEntry::SetTextureParameters(TexMode0 &newmode)
void TextureMngr::TCacheEntry::Destroy()
{
if(!texture)
return;
glDeleteTextures(1, &texture);
if (!isRenderTarget) {
if (!g_Config.bSafeTextureCache) {
u32 *ptr = (u32*)g_VideoInitialize.pGetMemoryPointer(addr + hashoffset * 4);
if (*ptr == hash)
*ptr = oldpixel;
}
}
texture = 0;
if (!isRenderTarget) {
if (!g_Config.bSafeTextureCache) {
u32 *ptr = (u32*)g_VideoInitialize.pGetMemoryPointer(addr + hashoffset * 4);
if (*ptr == hash)
*ptr = oldpixel;
}
}
texture = 0;
}
void TextureMngr::Init()