Skip to main content

Module cache

Module cache 

Source
Expand description

Engine-side caches for GPU resources derived from a scene.

Each cache turns a recurring, expensive-to-derive scene input into a bounded, reusable GPU resource, and is maintained at the frame boundary rather than mid-frame so handles handed out during encoding stay valid for that frame. retained is the one whose input is a rendered body rather than a decoded resource: a PushRetained bracket’s pixels, kept so a later frame’s DrawRetained composites them instead of painting the body again.

Re-exports§

pub use gradients::BYTES_PER_TEXEL;
pub use gradients::CachedRamp;
pub use gradients::GradientCache;
pub use gradients::GradientTextureLayout;
pub use gradients::LutUpload;
pub use images::AtlasBudget;
pub use images::AtlasRegion;
pub use images::ImageResidency;
pub use images::ImageSkip;
pub use images::ImageUpload;
pub use images::MAX_UNSEEN_FRAMES;
pub use images::ResidentImage;
pub use retained::RetainedBudget;
pub use retained::RetainedDecision;
pub use retained::RetainedEntry;
pub use retained::RetainedPages;
pub use retained::RetainedPlan;
pub use retained::RetainedRefusal;

Modules§

gradients
Gradient colour-ramp (LUT) cache.
images
Image residency: which decoded images own atlas space, and for how long.
retained
Retained pages: bodies the renderer rasterized once and keeps across frames, so a later frame can composite them instead of painting them again.