shader_recompiler: Emulate unnormalized sampler coordinates in shader. (#1762)

* shader_recompiler: Emulate unnormalized sampler coordinates in shader.

* Address review comments.
This commit is contained in:
squidbus
2024-12-13 11:49:07 -08:00
committed by GitHub
parent 306279901f
commit 028be3ba5d
10 changed files with 78 additions and 12 deletions

View File

@@ -25,7 +25,7 @@ Sampler::Sampler(const Vulkan::Instance& instance, const AmdGpu::Sampler& sample
.minLod = sampler.MinLod(),
.maxLod = sampler.MaxLod(),
.borderColor = LiverpoolToVK::BorderColor(sampler.border_color_type),
.unnormalizedCoordinates = bool(sampler.force_unnormalized),
.unnormalizedCoordinates = false, // Handled in shader due to Vulkan limitations.
};
auto [sampler_result, smplr] = instance.GetDevice().createSamplerUnique(sampler_ci);
ASSERT_MSG(sampler_result == vk::Result::eSuccess, "Failed to create sampler: {}",