Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
offscreen_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_FLOW_LAYERS_OFFSCREEN_SURFACE_H_
6#define FLUTTER_FLOW_LAYERS_OFFSCREEN_SURFACE_H_
7
8#include "flutter/fml/logging.h"
9#include "flutter/fml/macros.h"
10
11#include "flutter/display_list/dl_canvas.h"
12#include "flutter/display_list/skia/dl_sk_canvas.h"
17
18class GrDirectContext;
19
20namespace flutter {
21
23 public:
24 explicit OffscreenSurface(GrDirectContext* surface_context,
25 const SkISize& size);
26
27 ~OffscreenSurface() = default;
28
29 sk_sp<SkData> GetRasterData(bool compressed) const;
30
32
33 bool IsValid() const;
34
35 private:
36 sk_sp<SkSurface> offscreen_surface_;
37 DlSkCanvasAdapter adapter_;
38
40};
41
42} // namespace flutter
43
44#endif // FLUTTER_FLOW_LAYERS_OFFSCREEN_SURFACE_H_
Developer-facing API for rendering anything within the engine.
Definition dl_canvas.h:37
Backend implementation of |DlCanvas| for |SkCanvas|.
sk_sp< SkData > GetRasterData(bool compressed) const
#define FML_DISALLOW_COPY_AND_ASSIGN(TypeName)
Definition macros.h:27
it will be possible to load the file into Perfetto s trace viewer disable asset Prevents usage of any non test fonts unless they were explicitly Loaded via prefetched default font Indicates whether the embedding started a prefetch of the default font manager before creating the engine run In non interactive keep the shell running after the Dart script has completed enable serial On low power devices with low core running concurrent GC tasks on threads can cause them to contend with the UI thread which could potentially lead to jank This option turns off all concurrent GC activities domain network JSON encoded network policy per domain This overrides the DisallowInsecureConnections switch Embedder can specify whether to allow or disallow insecure connections at a domain level old gen heap size
Definition switches.h:259