FrameCache class final
Persists captured frames on disk so an unchanged render replays from cache instead of re-capturing.
Keys are FNV-1a-64 hex over renderDigest:frameIndex —
hex, so path-safe by construction. The cache is advisory: the digest
covers the render config, composition key and fluvie version, but not the
composition's code, so editing a composition under an unchanged key can
serve stale frames until the digest moves or a --no-cache run bypasses
it. Entries persist across FrameCache instances sharing the same root.
Constructors
- FrameCache(Directory root)
-
Creates a cache rooted at
root(created lazily on first store).
Properties
Methods
-
frameKey(
String renderDigest, int frameIndex) → String -
The cache key of frame
frameIndexwithin the render identified byrenderDigest. -
lookup(
String key) → Future< Uint8List?> -
The cached frame bytes for
key, ornullon a miss. -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
store(
String key, Uint8List bytes) → Future< void> -
Stores
bytesunderkey, creating root when needed. -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited
Static Methods
-
defaultRoot(
) → Directory -
The default cache root shared by the render pipeline and the capture
harness:
fluvie_frame_cacheunder the system temp directory.