Flutter Engine
flutter::Surface Class Referenceabstract

Abstract Base Class that represents where we will be rendering content. More...

#include <surface.h>

Inheritance diagram for flutter::Surface:
flutter::GPUSurfaceGL flutter::GPUSurfaceMetal flutter::GPUSurfaceSoftware flutter::GPUSurfaceVulkan flutter::testing::SurfaceMock flutter_runner::Surface

Public Member Functions

 Surface ()
 
virtual ~Surface ()
 
virtual bool IsValid ()=0
 
virtual std::unique_ptr< SurfaceFrameAcquireFrame (const SkISize &size)=0
 
virtual SkMatrix GetRootTransformation () const =0
 
virtual GrDirectContext * GetContext ()=0
 
virtual flutter::ExternalViewEmbedderGetExternalViewEmbedder ()
 
virtual std::unique_ptr< GLContextResultMakeRenderContextCurrent ()
 
virtual bool ClearRenderContext ()
 

Detailed Description

Abstract Base Class that represents where we will be rendering content.

Definition at line 18 of file surface.h.

Constructor & Destructor Documentation

◆ Surface()

flutter::Surface::Surface ( )
default

◆ ~Surface()

flutter::Surface::~Surface ( )
virtualdefault

Reimplemented in flutter_runner::Surface.

Member Function Documentation

◆ AcquireFrame()

virtual std::unique_ptr<SurfaceFrame> flutter::Surface::AcquireFrame ( const SkISize &  size)
pure virtual

◆ ClearRenderContext()

bool flutter::Surface::ClearRenderContext ( )
virtual

Reimplemented in flutter::GPUSurfaceGL.

Definition at line 21 of file surface.cc.

21  {
22  return false;
23 }

◆ GetContext()

virtual GrDirectContext* flutter::Surface::GetContext ( )
pure virtual

◆ GetExternalViewEmbedder()

flutter::ExternalViewEmbedder * flutter::Surface::GetExternalViewEmbedder ( )
virtual

Reimplemented in flutter::GPUSurfaceGL, flutter::GPUSurfaceVulkan, and flutter::GPUSurfaceSoftware.

Definition at line 13 of file surface.cc.

13  {
14  return nullptr;
15 }

◆ GetRootTransformation()

virtual SkMatrix flutter::Surface::GetRootTransformation ( ) const
pure virtual

◆ IsValid()

virtual bool flutter::Surface::IsValid ( )
pure virtual

◆ MakeRenderContextCurrent()

std::unique_ptr< GLContextResult > flutter::Surface::MakeRenderContextCurrent ( )
virtual

Reimplemented in flutter::GPUSurfaceGL.

Definition at line 17 of file surface.cc.

17  {
18  return std::make_unique<GLContextDefaultResult>(true);
19 }

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