Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Classes | Public Member Functions | List of all members
flutter::CompositorContext Class Reference

#include <compositor_context.h>

Classes

class  ScopedFrame
 

Public Member Functions

 CompositorContext ()
 
 CompositorContext (Stopwatch::RefreshRateUpdater &updater)
 
virtual ~CompositorContext ()
 
virtual std::unique_ptr< ScopedFrameAcquireFrame (GrDirectContext *gr_context, DlCanvas *canvas, ExternalViewEmbedder *view_embedder, const SkMatrix &root_surface_transformation, bool instrumentation_enabled, bool surface_supports_readback, fml::RefPtr< fml::RasterThreadMerger > raster_thread_merger, impeller::AiksContext *aiks_context)
 
void OnGrContextCreated ()
 
void OnGrContextDestroyed ()
 
RasterCacheraster_cache ()
 
std::shared_ptr< TextureRegistrytexture_registry ()
 
const Stopwatchraster_time () const
 
Stopwatchui_time ()
 
LayerSnapshotStoresnapshot_store ()
 

Detailed Description

Definition at line 106 of file compositor_context.h.

Constructor & Destructor Documentation

◆ CompositorContext() [1/2]

flutter::CompositorContext::CompositorContext ( )

Definition at line 49 of file compositor_context.cc.

50 : texture_registry_(std::make_shared<TextureRegistry>()),
51 raster_time_(fixed_refresh_rate_updater_),
52 ui_time_(fixed_refresh_rate_updater_) {}

◆ CompositorContext() [2/2]

flutter::CompositorContext::CompositorContext ( Stopwatch::RefreshRateUpdater updater)
explicit

Definition at line 54 of file compositor_context.cc.

55 : texture_registry_(std::make_shared<TextureRegistry>()),
56 raster_time_(updater),
57 ui_time_(updater) {}

◆ ~CompositorContext()

flutter::CompositorContext::~CompositorContext ( )
virtualdefault

Member Function Documentation

◆ AcquireFrame()

std::unique_ptr< CompositorContext::ScopedFrame > flutter::CompositorContext::AcquireFrame ( GrDirectContext gr_context,
DlCanvas canvas,
ExternalViewEmbedder view_embedder,
const SkMatrix root_surface_transformation,
bool  instrumentation_enabled,
bool  surface_supports_readback,
fml::RefPtr< fml::RasterThreadMerger raster_thread_merger,
impeller::AiksContext aiks_context 
)
virtual

Definition at line 75 of file compositor_context.cc.

84 {
85 return std::make_unique<ScopedFrame>(
86 *this, gr_context, canvas, view_embedder, root_surface_transformation,
87 instrumentation_enabled, surface_supports_readback, raster_thread_merger,
88 aiks_context);
89}

◆ OnGrContextCreated()

void flutter::CompositorContext::OnGrContextCreated ( )

Definition at line 225 of file compositor_context.cc.

225 {
226 texture_registry_->OnGrContextCreated();
227 raster_cache_.Clear();
228}

◆ OnGrContextDestroyed()

void flutter::CompositorContext::OnGrContextDestroyed ( )

Definition at line 230 of file compositor_context.cc.

230 {
231 texture_registry_->OnGrContextDestroyed();
232 raster_cache_.Clear();
233}

◆ raster_cache()

RasterCache & flutter::CompositorContext::raster_cache ( )
inline

Definition at line 185 of file compositor_context.h.

185{ return raster_cache_; }

◆ raster_time()

const Stopwatch & flutter::CompositorContext::raster_time ( ) const
inline

Definition at line 191 of file compositor_context.h.

191{ return raster_time_; }

◆ snapshot_store()

LayerSnapshotStore & flutter::CompositorContext::snapshot_store ( )
inline

Definition at line 195 of file compositor_context.h.

195{ return layer_snapshot_store_; }

◆ texture_registry()

std::shared_ptr< TextureRegistry > flutter::CompositorContext::texture_registry ( )
inline

Definition at line 187 of file compositor_context.h.

187 {
188 return texture_registry_;
189 }

◆ ui_time()

Stopwatch & flutter::CompositorContext::ui_time ( )
inline

Definition at line 193 of file compositor_context.h.

193{ return ui_time_; }

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