mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-04-20 11:35:45 +00:00
texture_cache: Don't read max ansio value if not aniso filter (#1942)
Fix Sonic Forces.
This commit is contained in:
parent
f0352d2f7d
commit
99e1e028c0
2 changed files with 3 additions and 2 deletions
|
@ -447,7 +447,7 @@ struct Sampler {
|
|||
}
|
||||
|
||||
float MaxAniso() const {
|
||||
switch (max_aniso) {
|
||||
switch (max_aniso.Value()) {
|
||||
case AnisoRatio::One:
|
||||
return 1.0f;
|
||||
case AnisoRatio::Two:
|
||||
|
|
|
@ -18,7 +18,8 @@ Sampler::Sampler(const Vulkan::Instance& instance, const AmdGpu::Sampler& sample
|
|||
(AmdGpu::IsAnisoFilter(sampler.xy_mag_filter) ||
|
||||
AmdGpu::IsAnisoFilter(sampler.xy_min_filter));
|
||||
const float maxAnisotropy =
|
||||
std::clamp(sampler.MaxAniso(), 1.0f, instance.MaxSamplerAnisotropy());
|
||||
anisotropyEnable ? std::clamp(sampler.MaxAniso(), 1.0f, instance.MaxSamplerAnisotropy())
|
||||
: 1.0f;
|
||||
const vk::SamplerCreateInfo sampler_ci = {
|
||||
.magFilter = LiverpoolToVK::Filter(sampler.xy_mag_filter),
|
||||
.minFilter = LiverpoolToVK::Filter(sampler.xy_min_filter),
|
||||
|
|
Loading…
Add table
Reference in a new issue