mirror of
https://gitlab.com/suyu-emu/suyu.git
synced 2024-03-15 23:15:44 +00:00
Texture_Cache: Remove some unprecise fallback case and clang format
This commit is contained in:
parent
5818959e54
commit
0f54b541f4
|
@ -294,8 +294,9 @@ std::size_t SurfaceParams::GetInnerMipmapMemorySize(u32 level, bool as_host_size
|
||||||
const u32 height{GetMipmapSize(uncompressed, GetMipHeight(level), GetDefaultBlockHeight())};
|
const u32 height{GetMipmapSize(uncompressed, GetMipHeight(level), GetDefaultBlockHeight())};
|
||||||
const u32 depth{is_layered ? 1U : GetMipDepth(level)};
|
const u32 depth{is_layered ? 1U : GetMipDepth(level)};
|
||||||
if (is_tiled) {
|
if (is_tiled) {
|
||||||
return Tegra::Texture::CalculateSize(!as_host_size, GetBytesPerPixel(), width, height, depth,
|
return Tegra::Texture::CalculateSize(!as_host_size, GetBytesPerPixel(), width, height,
|
||||||
GetMipBlockHeight(level), GetMipBlockDepth(level));
|
depth, GetMipBlockHeight(level),
|
||||||
|
GetMipBlockDepth(level));
|
||||||
} else {
|
} else {
|
||||||
if (as_host_size || IsBuffer()) {
|
if (as_host_size || IsBuffer()) {
|
||||||
return GetBytesPerPixel() * width * height * depth;
|
return GetBytesPerPixel() * width * height * depth;
|
||||||
|
|
|
@ -662,15 +662,6 @@ private:
|
||||||
}
|
}
|
||||||
return {current_surface, *view};
|
return {current_surface, *view};
|
||||||
}
|
}
|
||||||
// The next case is unsafe, so if we r in accurate GPU, just skip it
|
|
||||||
if (Settings::values.use_accurate_gpu_emulation) {
|
|
||||||
return RecycleSurface(overlaps, params, gpu_addr, preserve_contents,
|
|
||||||
MatchTopologyResult::FullMatch);
|
|
||||||
}
|
|
||||||
// This is the case the texture is a part of the parent.
|
|
||||||
if (current_surface->MatchesSubTexture(params, gpu_addr)) {
|
|
||||||
return RebuildSurface(current_surface, params, is_render);
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
// If there are many overlaps, odds are they are subtextures of the candidate
|
// If there are many overlaps, odds are they are subtextures of the candidate
|
||||||
// surface. We try to construct a new surface based on the candidate parameters,
|
// surface. We try to construct a new surface based on the candidate parameters,
|
||||||
|
|
Loading…
Reference in a new issue