Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
sampler_library_vk.h
Go to the documentation of this file.
1// Copyright 2013 The Flutter Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#ifndef FLUTTER_IMPELLER_RENDERER_BACKEND_VULKAN_SAMPLER_LIBRARY_VK_H_
6#define FLUTTER_IMPELLER_RENDERER_BACKEND_VULKAN_SAMPLER_LIBRARY_VK_H_
7
12
13namespace impeller {
14
16 : public SamplerLibrary,
17 public BackendCast<SamplerLibraryVK, SamplerLibrary> {
18 public:
19 // |SamplerLibrary|
21
22 private:
23 friend class ContextVK;
24
25 std::weak_ptr<DeviceHolderVK> device_holder_;
26 SamplerMap samplers_;
27
28 explicit SamplerLibraryVK(const std::weak_ptr<DeviceHolderVK>& device_holder);
29
30 // |SamplerLibrary|
31 const std::unique_ptr<const Sampler>& GetSampler(
32 SamplerDescriptor descriptor) override;
33
34 SamplerLibraryVK(const SamplerLibraryVK&) = delete;
35
36 SamplerLibraryVK& operator=(const SamplerLibraryVK&) = delete;
37};
38
39} // namespace impeller
40
41#endif // FLUTTER_IMPELLER_RENDERER_BACKEND_VULKAN_SAMPLER_LIBRARY_VK_H_
const std::unique_ptr< const Sampler > & GetSampler(SamplerDescriptor descriptor) override
Retrieve a backend specific sampler object for the given sampler descriptor.
std::unordered_map< SamplerDescriptor, std::unique_ptr< const Sampler >, ComparableHash< SamplerDescriptor >, ComparableEqual< SamplerDescriptor > > SamplerMap
Definition sampler.h:35