diff --git a/Source/Core/VideoCommon/TextureCacheBase.cpp b/Source/Core/VideoCommon/TextureCacheBase.cpp index 31701e6bc0..d6290001a9 100644 --- a/Source/Core/VideoCommon/TextureCacheBase.cpp +++ b/Source/Core/VideoCommon/TextureCacheBase.cpp @@ -406,8 +406,11 @@ TextureCacheBase::DoPartialTextureUpdates(TCacheEntry* entry_to_update, u8* pale dstrect.top = dst_y; dstrect.right = (dst_x + copy_width); dstrect.bottom = (dst_y + copy_height); - entry_to_update->texture->CopyRectangleFromTexture(entry->texture.get(), srcrect, 0, 0, - dstrect, 0, 0); + for (u32 layer = 0; layer < entry->texture->GetConfig().layers; layer++) + { + entry_to_update->texture->CopyRectangleFromTexture(entry->texture.get(), srcrect, layer, + 0, dstrect, layer, 0); + } if (isPaletteTexture) { @@ -1367,34 +1370,16 @@ bool TextureCacheBase::LoadTextureFromOverlappingTextures(TCacheEntry* entry_to_ srcrect.right = (src_x + copy_width); srcrect.bottom = (src_y + copy_height); - if (static_cast(entry->GetWidth()) == srcrect.GetWidth()) - { - srcrect.right -= 1; - } - - if (static_cast(entry->GetHeight()) == srcrect.GetHeight()) - { - srcrect.bottom -= 1; - } - dstrect.left = dst_x; dstrect.top = dst_y; dstrect.right = (dst_x + copy_width); dstrect.bottom = (dst_y + copy_height); - if (static_cast(entry_to_update->GetWidth()) == dstrect.GetWidth()) + for (u32 layer = 0; layer < entry->texture->GetConfig().layers; layer++) { - dstrect.right -= 1; + entry_to_update->texture->CopyRectangleFromTexture(entry->texture.get(), srcrect, layer, + 0, dstrect, layer, 0); } - - if (static_cast(entry_to_update->GetHeight()) == dstrect.GetHeight()) - { - dstrect.bottom -= 1; - } - - entry_to_update->texture->CopyRectangleFromTexture(entry->texture.get(), srcrect, 0, 0, - dstrect, 0, 0); - updated_entry = true; if (tex_info.is_palette_texture)