Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Public Member Functions | Private Member Functions | List of all members
flutter_runner::Surface Class Referencefinal

#include <surface.h>

Inheritance diagram for flutter_runner::Surface:
flutter::Surface

Public Member Functions

 Surface (std::string debug_label, std::shared_ptr< flutter::ExternalViewEmbedder > view_embedder, GrDirectContext *gr_context)
 
 ~Surface () override
 
- Public Member Functions inherited from flutter::Surface
 Surface ()
 
virtual std::unique_ptr< GLContextResultMakeRenderContextCurrent ()
 
virtual bool ClearRenderContext ()
 
virtual bool AllowsDrawingWhenGpuDisabled () const
 
virtual bool EnableRasterCache () const
 
virtual std::shared_ptr< impeller::AiksContextGetAiksContext () const
 
virtual SurfaceData GetSurfaceData () const
 

Private Member Functions

bool IsValid () override
 
std::unique_ptr< flutter::SurfaceFrameAcquireFrame (const SkISize &size) override
 
GrDirectContextGetContext () override
 
SkMatrix GetRootTransformation () const override
 

Detailed Description

Definition at line 17 of file surface.h.

Constructor & Destructor Documentation

◆ Surface()

Surface::Surface ( std::string  debug_label,
std::shared_ptr< flutter::ExternalViewEmbedder view_embedder,
GrDirectContext gr_context 
)

Definition at line 16 of file surface.cc.

19 : debug_label_(std::move(debug_label)),
20 view_embedder_(view_embedder),
21 gr_context_(gr_context) {}

◆ ~Surface()

Surface::~Surface ( )
overridevirtualdefault

Reimplemented from flutter::Surface.

Member Function Documentation

◆ AcquireFrame()

std::unique_ptr< flutter::SurfaceFrame > Surface::AcquireFrame ( const SkISize size)
overrideprivatevirtual

Implements flutter::Surface.

Definition at line 31 of file surface.cc.

32 {
34 framebuffer_info.supports_readback = true;
35 return std::make_unique<flutter::SurfaceFrame>(
36 nullptr, std::move(framebuffer_info),
37 [](const flutter::SurfaceFrame& surface_frame,
38 flutter::DlCanvas* canvas) { return true; },
39 size);
40}
Developer-facing API for rendering anything within the engine.
Definition dl_canvas.h:37
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

◆ GetContext()

GrDirectContext * Surface::GetContext ( )
overrideprivatevirtual

Implements flutter::Surface.

Definition at line 43 of file surface.cc.

43 {
44 return gr_context_;
45}

◆ GetRootTransformation()

SkMatrix Surface::GetRootTransformation ( ) const
overrideprivatevirtual

Implements flutter::Surface.

Definition at line 48 of file surface.cc.

48 {
49 // This backend does not support delegating to the underlying platform to
50 // query for root surface transformations. Just return identity.
52 matrix.reset();
53 return matrix;
54}
unsigned useCenter Optional< SkMatrix > matrix
Definition SkRecords.h:258

◆ IsValid()

bool Surface::IsValid ( )
overrideprivatevirtual

Implements flutter::Surface.

Definition at line 26 of file surface.cc.

26 {
27 return true;
28}

The documentation for this class was generated from the following files: