Flutter Engine
The Flutter Engine
Public Member Functions | List of all members
flutter::AutoCache Class Reference

#include <cacheable_layer.h>

Public Member Functions

 AutoCache (RasterCacheItem *raster_cache_item, PrerollContext *context, const SkMatrix &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 SkMatrix 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}
unsigned useCenter Optional< SkMatrix > matrix
Definition: SkRecords.h:258

◆ ~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 SkMatrix &matrix)=0

Member Function Documentation

◆ ShouldNotBeCached()

void flutter::AutoCache::ShouldNotBeCached ( )
inline

Definition at line 22 of file cacheable_layer.h.

22{ raster_cache_item_ = nullptr; }

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