Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
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"
10
11namespace impeller {
12
13class PlaygroundImplGLES final : public PlaygroundImpl {
14 public:
15 explicit PlaygroundImplGLES(PlaygroundSwitches switches);
16
18
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 const bool use_angle_;
30 void* angle_glesv2_;
31
32 // |PlaygroundImpl|
33 std::shared_ptr<Context> GetContext() const override;
34
35 // |PlaygroundImpl|
36 WindowHandle GetWindowHandle() const override;
37
38 // |PlaygroundImpl|
39 std::unique_ptr<Surface> AcquireSurfaceFrame(
40 std::shared_ptr<Context> context) override;
41
43
44 PlaygroundImplGLES& operator=(const PlaygroundImplGLES&) = delete;
45};
46
47} // namespace impeller
48
49#endif // FLUTTER_IMPELLER_PLAYGROUND_BACKEND_GLES_PLAYGROUND_IMPL_GLES_H_
std::unique_ptr< Surface > AcquireSurfaceFrame(std::shared_ptr< Context > context) override
fml::Status SetCapabilities(const std::shared_ptr< Capabilities > &capabilities) override
std::shared_ptr< Context > GetContext() const override
WindowHandle GetWindowHandle() const override
fuchsia::ui::composition::ParentViewportWatcherHandle handle_