Flutter Engine
 
Loading...
Searching...
No Matches
sampler_library.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_SAMPLER_LIBRARY_H_
6#define FLUTTER_IMPELLER_RENDERER_SAMPLER_LIBRARY_H_
7
11
12namespace impeller {
13
15 public:
16 virtual ~SamplerLibrary();
17
18 /// @brief Retrieve a backend specific sampler object for the given sampler
19 /// descriptor.
20 ///
21 /// If the descriptor is invalid or there is a loss of rendering
22 /// context, this method may return a nullptr.
23 ///
24 /// The sampler library implementations must cache this sampler object
25 /// and guarantee that the reference will continue to be valid
26 /// throughout the lifetime of the Impeller context.
28 const SamplerDescriptor& descriptor) = 0;
29
30 protected:
32
33 private:
34 SamplerLibrary(const SamplerLibrary&) = delete;
35
36 SamplerLibrary& operator=(const SamplerLibrary&) = delete;
37};
38
39} // namespace impeller
40
41#endif // FLUTTER_IMPELLER_RENDERER_SAMPLER_LIBRARY_H_
virtual raw_ptr< const Sampler > GetSampler(const SamplerDescriptor &descriptor)=0
Retrieve a backend specific sampler object for the given sampler descriptor.
A wrapper around a raw ptr that adds additional unopt mode only checks.
Definition raw_ptr.h:15