| Flutter Impeller |

playground_impl_gles.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_PLAYGROUND_BACKEND_GLES_PLAYGROUND_IMPL_GLES_H_
6 #define FLUTTER_IMPELLER_PLAYGROUND_BACKEND_GLES_PLAYGROUND_IMPL_GLES_H_
7
8 #include "flutter/fml/macros.h"
9 #include "impeller/playground/playground_impl.h"
10
11 namespace impeller {
12
13 class PlaygroundImplGLES final : public PlaygroundImpl {
14 public:
15 explicit PlaygroundImplGLES(PlaygroundSwitches switches);
16
17 ~PlaygroundImplGLES();
18
19 fml::Status SetCapabilities(
20 const std::shared_ptr<Capabilities>& capabilities) override;
21
22 private:
23 class ReactorWorker;
24
25 static void DestroyWindowHandle(WindowHandle handle);
26 using UniqueHandle = std::unique_ptr<void, decltype(&DestroyWindowHandle)>;
27 UniqueHandle handle_;
28 std::shared_ptr<ReactorWorker> worker_;
29
30 // |PlaygroundImpl|
31 std::shared_ptr<Context> GetContext() const override;
32
33 // |PlaygroundImpl|
34 WindowHandle GetWindowHandle() const override;
35
36 // |PlaygroundImpl|
37 std::unique_ptr<Surface> AcquireSurfaceFrame(
38 std::shared_ptr<Context> context) override;
39
40 PlaygroundImplGLES(const PlaygroundImplGLES&) = delete;
41
42 PlaygroundImplGLES& operator=(const PlaygroundImplGLES&) = delete;
43 };
44
45 } // namespace impeller
46
47 #endif // FLUTTER_IMPELLER_PLAYGROUND_BACKEND_GLES_PLAYGROUND_IMPL_GLES_H_
impeller::PlaygroundImplGLES::SetCapabilities
fml::Status SetCapabilities(const std::shared_ptr< Capabilities > &capabilities) override
Definition: playground_impl_gles.cc:159
impeller::PlaygroundImplGLES::~PlaygroundImplGLES
~PlaygroundImplGLES()
impeller::PlaygroundImplGLES
Definition: playground_impl_gles.h:13
impeller::PlaygroundImplGLES::ReactorWorker
Definition: playground_impl_gles.cc:20
impeller::PlaygroundImpl
Definition: playground_impl.h:18
impeller::PlaygroundSwitches
Definition: switches.h:16
impeller::PlaygroundImplGLES::PlaygroundImplGLES
PlaygroundImplGLES(PlaygroundSwitches switches)
Definition: playground_impl_gles.cc:56
playground_impl.h
impeller
Definition: aiks_context.cc:10
impeller::PlaygroundImpl::WindowHandle
void * WindowHandle
Definition: playground_impl.h:25