Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
config.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_TOOLKIT_EGL_CONFIG_H_
6#define FLUTTER_IMPELLER_TOOLKIT_EGL_CONFIG_H_
7
8#include "flutter/fml/macros.h"
10
11namespace impeller {
12namespace egl {
13
14enum class API {
15 kOpenGL,
18};
19
20enum class Samples {
21 kOne = 1,
22 kTwo = 2,
23 kFour = 4,
24};
25
26enum class ColorFormat {
28 kRGB565,
29};
30
31enum class StencilBits {
32 kZero = 0,
33 kEight = 8,
34};
35
36enum class DepthBits {
37 kZero = 0,
38 kEight = 8,
39};
40
41enum class SurfaceType {
42 kWindow,
44};
45
54
55class Config {
56 public:
57 Config(ConfigDescriptor descriptor, EGLConfig config);
58
60
61 bool IsValid() const;
62
63 const ConfigDescriptor& GetDescriptor() const;
64
65 const EGLConfig& GetHandle() const;
66
67 private:
68 const ConfigDescriptor desc_;
69 EGLConfig config_ = nullptr;
70
71 Config(const Config&) = delete;
72
73 Config& operator=(const Config&) = delete;
74};
75
76} // namespace egl
77} // namespace impeller
78
79#endif // FLUTTER_IMPELLER_TOOLKIT_EGL_CONFIG_H_
const ConfigDescriptor & GetDescriptor() const
Definition config.cc:17
bool IsValid() const
Definition config.cc:25
const EGLConfig & GetHandle() const
Definition config.cc:21