13 const std::weak_ptr<DeviceHolderVK>& device_holder)
14 : device_holder_(device_holder) {}
25 if (mips_disabled_workaround_) {
30 for (
const auto& [key,
value] : samplers_) {
32 return raw_ptr(
value);
35 auto device_holder = device_holder_.lock();
36 if (!device_holder || !device_holder->GetDevice()) {
37 return raw_ptr<const Sampler>(
nullptr);
39 samplers_.push_back(std::make_pair(
41 std::make_shared<SamplerVK>(device_holder->GetDevice(), desc_copy)));
42 return raw_ptr(samplers_.back().second);
~SamplerLibraryVK() override
SamplerLibraryVK(const std::weak_ptr< DeviceHolderVK > &device_holder)
void ApplyWorkarounds(const WorkaroundsVK &workarounds)
A wrapper around a raw ptr that adds additional unopt mode only checks.
@ kBase
The texture is sampled as if it only had a single mipmap level.
static uint64_t ToKey(const SamplerDescriptor &d)
A non-exhaustive set of driver specific workarounds.
bool broken_mipmap_generation