| Flutter Impeller |

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
8 #include "impeller/base/backend_cast.h"
9 #include "impeller/core/sampler_descriptor.h"
10 #include "impeller/renderer/backend/vulkan/device_holder.h"
11 #include "impeller/renderer/sampler_library.h"
12
13 namespace impeller {
14
15 class SamplerLibraryVK final
16 : public SamplerLibrary,
17 public BackendCast<SamplerLibraryVK, SamplerLibrary> {
18 public:
19 // |SamplerLibrary|
20 ~SamplerLibraryVK() override;
21
22 private:
23 friend class ContextVK;
24
25 std::weak_ptr<DeviceHolder> device_holder_;
26 SamplerMap samplers_;
27
28 explicit SamplerLibraryVK(const std::weak_ptr<DeviceHolder>& device_holder);
29
30 // |SamplerLibrary|
31 std::shared_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_
sampler_library.h
device_holder.h
impeller::SamplerDescriptor
Definition: sampler_descriptor.h:15
impeller::SamplerLibraryVK
Definition: sampler_library_vk.h:15
impeller::SamplerMap
std::unordered_map< SamplerDescriptor, std::shared_ptr< const Sampler >, ComparableHash< SamplerDescriptor >, ComparableEqual< SamplerDescriptor > > SamplerMap
Definition: sampler.h:37
backend_cast.h
impeller::ContextVK
Definition: context_vk.h:40
sampler_descriptor.h
impeller::BackendCast
Definition: backend_cast.h:13
impeller::SamplerLibrary
Definition: sampler_library.h:13
impeller::SamplerLibraryVK::~SamplerLibraryVK
~SamplerLibraryVK() override
impeller
Definition: aiks_context.cc:10