Flutter Engine
 
Loading...
Searching...
No Matches
flutter::AutoCache Class Reference

#include <cacheable_layer.h>

Public Member Functions

 AutoCache (RasterCacheItem *raster_cache_item, PrerollContext *context, const DlMatrix &matrix)
 
void ShouldNotBeCached ()
 
 ~AutoCache ()
 

Detailed Description

Definition at line 16 of file cacheable_layer.h.

Constructor & Destructor Documentation

◆ AutoCache()

flutter::AutoCache::AutoCache ( RasterCacheItem raster_cache_item,
PrerollContext context,
const DlMatrix matrix 
)

Definition at line 9 of file cacheable_layer.cc.

12 : raster_cache_item_(raster_cache_item),
13 context_(context),
14 matrix_(matrix) {
15#if !SLIMPELLER
16 if (IsCacheEnabled()) {
17 raster_cache_item->PrerollSetup(context, matrix);
18 }
19#endif // !SLIMPELLER
20}

References flutter::RasterCacheItem::PrerollSetup().

◆ ~AutoCache()

flutter::AutoCache::~AutoCache ( )

Definition at line 30 of file cacheable_layer.cc.

30 {
31#if !SLIMPELLER
32 if (IsCacheEnabled()) {
33 raster_cache_item_->PrerollFinalize(context_, matrix_);
34 }
35#endif // !SLIMPELLER
36}
virtual void PrerollFinalize(PrerollContext *context, const DlMatrix &matrix)=0

References flutter::RasterCacheItem::PrerollFinalize().

Member Function Documentation

◆ ShouldNotBeCached()

void flutter::AutoCache::ShouldNotBeCached ( )
inline

Definition at line 22 of file cacheable_layer.h.

22{ raster_cache_item_ = nullptr; }

Referenced by flutter::OpacityLayer::Preroll().


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