mirror of
https://github.com/yuzu-emu/yuzu-android.git
synced 2024-12-27 06:55:37 +00:00
texture_cache: Reload textures when number of resources mismatch
This commit is contained in:
parent
5b37cecd76
commit
dd70e097cc
|
@ -660,6 +660,15 @@ private:
|
||||||
std::size_t passed_tests = 0;
|
std::size_t passed_tests = 0;
|
||||||
bool modified = false;
|
bool modified = false;
|
||||||
|
|
||||||
|
u32 num_resources = 0;
|
||||||
|
for (auto& surface : overlaps) {
|
||||||
|
const SurfaceParams& src_params = surface->GetSurfaceParams();
|
||||||
|
num_resources += src_params.depth * src_params.num_levels;
|
||||||
|
}
|
||||||
|
if (num_resources != params.depth * params.num_levels) {
|
||||||
|
LoadSurface(new_surface);
|
||||||
|
}
|
||||||
|
|
||||||
for (auto& surface : overlaps) {
|
for (auto& surface : overlaps) {
|
||||||
const SurfaceParams& src_params = surface->GetSurfaceParams();
|
const SurfaceParams& src_params = surface->GetSurfaceParams();
|
||||||
const auto mipmap_layer{new_surface->GetLayerMipmap(surface->GetGpuAddr())};
|
const auto mipmap_layer{new_surface->GetLayerMipmap(surface->GetGpuAddr())};
|
||||||
|
|
Loading…
Reference in a new issue