Flutter Engine
embedder_surface.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_SHELL_PLATFORM_EMBEDDER_EMBEDDER_SURFACE_H_
6 #define FLUTTER_SHELL_PLATFORM_EMBEDDER_EMBEDDER_SURFACE_H_
7 
8 #include "flutter/flow/embedded_views.h"
9 #include "flutter/flow/surface.h"
10 #include "flutter/fml/macros.h"
11 
12 namespace flutter {
13 
15  public:
17 
18  virtual ~EmbedderSurface();
19 
20  virtual bool IsValid() const = 0;
21 
22  virtual std::unique_ptr<Surface> CreateGPUSurface() = 0;
23 
24  virtual sk_sp<GrDirectContext> CreateResourceContext() const = 0;
25 
26  private:
27  FML_DISALLOW_COPY_AND_ASSIGN(EmbedderSurface);
28 };
29 
30 } // namespace flutter
31 
32 #endif // FLUTTER_SHELL_PLATFORM_EMBEDDER_EMBEDDER_SURFACE_H_
virtual bool IsValid() const =0
virtual sk_sp< GrDirectContext > CreateResourceContext() const =0
virtual std::unique_ptr< Surface > CreateGPUSurface()=0