public interface IPageStoreWhat a residency service needs of whoever owns the memory.
No guide page documents this yet — the page shows what the code says about itself.
Remarks
The seam that keeps PageResidency from being geometry-shaped — improvement 6 of docs/plan/22-virtualized-geometry.md. Unreal runs Nanite streaming, virtual texture streaming and the shadow page pool as three systems with three budgets and three eviction policies; Vixen has none of them yet, which is an advantage exactly once. What is common to all three is a request queue, a byte budget and an eviction order, and what differs is where the bytes go and how they are read — so those two are here and nothing else is.
Loading is asynchronous because the asset system's I/O is, and because the alternative is a frame that blocks on a disk. Placing is synchronous because it is a copy into memory the pool already owns.
Fields and properties (2)
int PageSizeHow many bytes one page occupies in the pool.
int SlotCountHow many slots the pool has.
Methods (3)
ValueTask<int> LoadAsync(PageKey key, Memory<byte> destination, CancellationToken cancellation)Reads a page's bytes.
bool Place(PageKey key, int slot, ReadOnlySpan<byte> bytes)Puts a loaded page's bytes into a slot.
void Evict(PageKey key, int slot)Says a page is no longer resident, and its slot is about to be reused.
Used by (7)
- FakeStoreVixen.Rendering.Tests
- FoliageCellPagesVixen.Rendering.Terrain
- InstantStoreVixen.Rendering.Tests
- MeshletPagePoolVixen.Rendering
- PageResidencyVixen.Rendering
- TerrainTilePagesVixen.Rendering.Terrain
- VirtualShadowPagesVixen.Rendering