5#ifndef FLUTTER_FLOW_LAYERS_LAYER_RASTER_CACHE_ITEM_H_
6#define FLUTTER_FLOW_LAYERS_LAYER_RASTER_CACHE_ITEM_H_
13#include "flutter/flow/raster_cache_item.h"
20 int layer_cached_threshold = 1,
21 bool can_cache_children =
false);
31 static std::unique_ptr<LayerRasterCacheItem>
32 Make(
Layer*,
int layer_cache_threshold,
bool can_cache_children =
false);
34 std::optional<RasterCacheKeyID>
GetId()
const override;
48 bool parent_cached =
false)
const override;
Developer-facing API for rendering anything within the engine.
bool IsCacheChildren() const
int layer_cached_threshold_
std::optional< RasterCacheKeyID > layer_children_id_
static std::unique_ptr< LayerRasterCacheItem > Make(Layer *, int layer_cache_threshold, bool can_cache_children=false)
Create a LayerRasterCacheItem, connect a layer and manage the Layer's raster cache.
std::optional< RasterCacheKeyID > GetId() const override
void MarkNotCacheChildren()
void PrerollSetup(PrerollContext *context, const SkMatrix &matrix) override
LayerRasterCacheItem(Layer *layer, int layer_cached_threshold=1, bool can_cache_children=false)
bool Draw(const PaintContext &context, const DlPaint *paint) const override
bool TryToPrepareRasterCache(const PaintContext &context, bool parent_cached=false) const override
const SkRect * GetPaintBoundsFromLayer() const
void PrerollFinalize(PrerollContext *context, const SkMatrix &matrix) override
unsigned useCenter Optional< SkMatrix > matrix