Route tube fields through reservoir resolve
This commit is contained in:
parent
050c9aa8e6
commit
181e7df607
9 changed files with 304 additions and 108 deletions
|
|
@ -79,7 +79,7 @@ Fensalir has a GPU-resident fractal/field lane:
|
|||
- Form/Appearance/Transport reservoirs keep stable temporal evidence;
|
||||
- opaque signed-distance splats and transparent density/extinction splats render
|
||||
through separate pipeline states over shared packed buffers;
|
||||
- guide output follows the TAA schema: confidence, sample age, domain validity,
|
||||
- guide output follows the reservoir guide schema: confidence, sample age, domain validity,
|
||||
invalidation code.
|
||||
|
||||
The receipt harness lives in `tools/Aquarium.Fractal.Receipt`.
|
||||
|
|
@ -92,7 +92,7 @@ normal, coverage, and control signals stay coherent.
|
|||
|
||||
Debug modes include final color, raw current scene, history, history age,
|
||||
history weight, coverage/step ratio, field identity, bloom contribution,
|
||||
exposed luminance, proxy identity, proxy step count, and reservoir/TAA guide
|
||||
exposed luminance, proxy identity, proxy step count, and reservoir guide
|
||||
views. Startup mode can be set with `--render-debug` or
|
||||
`AQUARIUM_RENDER_DEBUG_MODE`.
|
||||
|
||||
|
|
|
|||
|
|
@ -42,6 +42,15 @@ This architecture is not invented from the floorboards:
|
|||
friendly, but Aquarium should preserve deterministic summaries and bounds as
|
||||
safety authority.
|
||||
|
||||
Aquarium diverges from pure ReSTIR at the primary-visibility boundary. ReSTIR
|
||||
usually reuses lighting or path candidates after a visible surface is known.
|
||||
Aquarium/Fensalir often samples the visible field candidate itself. Local Form
|
||||
producers therefore generate candidate visibility first, and the reservoir owns
|
||||
the temporal-antialiasing-shaped decision about which field candidate persists
|
||||
into presentation. There is no separate TAA organ in the target architecture:
|
||||
reservoir resolve reconstructs smooth presentation directly from selected field
|
||||
evidence.
|
||||
|
||||
## Prime Invariants
|
||||
|
||||
- Authored semantic domains are the source of truth.
|
||||
|
|
@ -55,7 +64,8 @@ This architecture is not invented from the floorboards:
|
|||
visibility safety, or calibration safety.
|
||||
- Missing children render through parent summaries. A frame does not wait for
|
||||
SSD.
|
||||
- TAA owns pixel history, not producer identity.
|
||||
- Reservoir resolve owns temporal antialiasing and reconstruction; no separate
|
||||
TAA pass owns producer identity or temporally reused field presentation.
|
||||
- Mimir sensor fusion and fractal rendering share the evidence machinery; they
|
||||
do not share client policy.
|
||||
|
||||
|
|
@ -73,7 +83,7 @@ Authored intent, resident mesh, direct SDF field, or live sensor input
|
|||
-> Residency/page scheduling
|
||||
-> Backend packet lowering
|
||||
-> direct SDF, mesh, volume, and/or field splat passes
|
||||
-> Temporal resolve guide buffers
|
||||
-> Reservoir resolve guide buffers
|
||||
-> Debug/evidence telemetry
|
||||
```
|
||||
|
||||
|
|
@ -99,7 +109,7 @@ Aquarium.Engine.SensorFusion
|
|||
|
||||
Aquarium.Engine.Render
|
||||
D3D12 resources, page tables, structured buffers, field splat passes,
|
||||
surface/volume resolves, TAA guide buffers, debug visualization.
|
||||
surface/volume resolves, reservoir guide buffers, debug visualization.
|
||||
|
||||
Aquarium.Zyphos
|
||||
World policy, cube-sphere/tile roots, planet grammar seeds, setting-safe
|
||||
|
|
@ -225,8 +235,9 @@ SampleAge
|
|||
DomainKey
|
||||
```
|
||||
|
||||
The reservoir owns resampling math. It does not own stable tracks, packet
|
||||
lowering, or TAA history.
|
||||
The reservoir owns resampling math. It does not own stable tracks or packet
|
||||
lowering. Reservoir resolve history is the presentation side of the same
|
||||
spatiotemporal organ, not a separate TAA owner.
|
||||
|
||||
### Occupancy Graph
|
||||
|
||||
|
|
@ -440,9 +451,9 @@ the direct representation has become too expensive. Future mesh lowering fits
|
|||
the same contract; it is another backend for the same evidence, not another
|
||||
authoring language.
|
||||
|
||||
### 10. TAA Guide Integration
|
||||
### 10. Reservoir Resolve Integration
|
||||
|
||||
TAA consumes guide signals:
|
||||
Reservoir resolve consumes guide signals:
|
||||
|
||||
- reservoir confidence;
|
||||
- sample age;
|
||||
|
|
@ -451,7 +462,11 @@ TAA consumes guide signals:
|
|||
- invalidation reason;
|
||||
- field id and motion.
|
||||
|
||||
TAA does not own reservoirs. It only decides how much pixel history may survive.
|
||||
There is no separate TAA owner. Reservoir resolve decides how much temporal
|
||||
history may survive after the field reservoir has selected and validated
|
||||
presentation candidates. If downstream pixel filtering is required to make an
|
||||
unstable field look stable, the Form producer or reservoir validation has
|
||||
failed upstream.
|
||||
|
||||
## Resource Tradeoffs
|
||||
|
||||
|
|
@ -493,7 +508,7 @@ views. It must not walk the authored grammar tree.
|
|||
10. Queue missing pages; keep parent summaries active.
|
||||
11. Lower selected evidence to direct SDF, mesh, volume, or field-splat packets.
|
||||
12. Render surface and/or transparent field passes into scene and guide targets.
|
||||
13. Resolve with TAA guide buffers.
|
||||
13. Resolve with reservoir guide buffers.
|
||||
14. Emit debug telemetry and evidence logs.
|
||||
```
|
||||
|
||||
|
|
@ -543,7 +558,7 @@ Performance fixtures:
|
|||
### Phase A: Architecture Freeze
|
||||
|
||||
Deliver this document, the public thesis article, updated memory, and a cut
|
||||
line for the TAA guide-buffer fork.
|
||||
line for the reservoir guide-buffer fork.
|
||||
|
||||
### Phase B: Explicit Reservoir Guide Layout
|
||||
|
||||
|
|
|
|||
|
|
@ -43,6 +43,10 @@ Owner:
|
|||
|
||||
- `FieldEvidenceMachine` owns the decision that something is visible,
|
||||
reusable, resident, or temporally valid.
|
||||
- The spatiotemporal field reservoir is the shared rendering organ for
|
||||
reusable claims. Tube fields, direct SDF envelopes, meshes, heightfields,
|
||||
volumes, splats, and sensor-fusion fields are claim producers or lowerings;
|
||||
none of them own final composition as a private renderer.
|
||||
|
||||
Inputs:
|
||||
|
||||
|
|
@ -58,6 +62,8 @@ Outputs:
|
|||
- canonical field-claim streams grouped by Form, Appearance, and Transport;
|
||||
- selected candidate reservoirs and stable track updates where persistent
|
||||
identity exists;
|
||||
- temporally reused field presentation decisions for claims whose visible
|
||||
surface or volume candidate is itself the sampled value;
|
||||
- residency/page requests and selected cuts;
|
||||
- backend packet streams for direct SDF, mesh, splat, height/tile, volume,
|
||||
tube, debug, and future paths;
|
||||
|
|
@ -70,16 +76,20 @@ Derived state:
|
|||
postprocess targets are compiled lowerings or diagnostics.
|
||||
- The old `SDF/PBR/Radiosity` reservoir naming is backend vocabulary. The
|
||||
architectural layers are `Form`, `Appearance`, and `Transport`.
|
||||
- TAA history is pixel memory. It is not producer identity and not stable
|
||||
spatial evidence.
|
||||
- Legacy TAA history is demoted to reservoir resolve history. It is not
|
||||
producer identity, stable spatial evidence, or a separate owner of temporally
|
||||
reused field presentation.
|
||||
|
||||
Forbidden writers:
|
||||
|
||||
- alpha blending, quad UVs, screen-space strips, billboard radii, or debug draw
|
||||
geometry deciding visible truth;
|
||||
- client repos submitting backend packets as if they were semantic claims;
|
||||
- payload-specific paths such as TubeField naming themselves as the reservoir
|
||||
renderer instead of feeding candidate claims into the shared field reservoir;
|
||||
- Mimir owning a render graph or a second stable evidence cache;
|
||||
- TAA repairing missing identity after the fact;
|
||||
- any downstream pixel-history/TAA pass repairing missing identity after the
|
||||
fact;
|
||||
- backend-specific payload conventions when a typed lowering contract exists.
|
||||
|
||||
Shared paths:
|
||||
|
|
@ -89,6 +99,10 @@ Shared paths:
|
|||
density/extinction volumes, mesh geometry, sensor fusion, and debug overlays
|
||||
all use the same claim -> candidate -> validation -> lowering contract when
|
||||
they want temporal reuse.
|
||||
- Payload-specific code may own intersection, envelope evaluation, geometry
|
||||
expansion, material sampling, and proposal PDFs for its own claim family. It
|
||||
may not own final field visibility or bypass the reservoir when the output is
|
||||
meant to participate in temporally reused presentation.
|
||||
|
||||
Deletion line:
|
||||
|
||||
|
|
@ -104,7 +118,7 @@ Deletion line:
|
|||
Authored intent / direct field / mesh / Mimir observation
|
||||
-> Domain binding
|
||||
-> Field claim normalization
|
||||
-> Candidate generation
|
||||
-> Local visibility candidate generation
|
||||
-> Target evaluation
|
||||
-> Resampled-importance reservoir
|
||||
-> Temporal reuse validation
|
||||
|
|
@ -113,7 +127,7 @@ Authored intent / direct field / mesh / Mimir observation
|
|||
-> Occupancy graph and residency/page scheduling
|
||||
-> Backend lowering
|
||||
-> Evidence-writing render/compute passes
|
||||
-> TAA guide validation
|
||||
-> Reservoir resolve/reconstruction
|
||||
-> Presentation and debug telemetry
|
||||
```
|
||||
|
||||
|
|
@ -157,6 +171,19 @@ tempted to smuggle authority inside its vertex layout.
|
|||
|
||||
Candidate generators propose work. They do not own final visibility.
|
||||
|
||||
For ReSTIR-style lighting, primary surface visibility is usually already known.
|
||||
Fensalir's Form fields often do not have that luxury: the candidate being
|
||||
sampled is the visible field surface or volume itself. In that case, the
|
||||
producer must generate local visibility candidates first, with stable identity,
|
||||
support bounds, depth/travel, coverage, material encoding, target value, and
|
||||
source/proposal policy. The shared reservoir then owns reuse and final
|
||||
presentation membership.
|
||||
|
||||
This is the sanctioned divergence from pure ReSTIR and the reason there is no
|
||||
separate TAA owner. Reservoir update and reservoir resolve own temporal
|
||||
stability, antialiasing, and reconstruction. A downstream pixel-history pass
|
||||
may not decide which field candidate existed.
|
||||
|
||||
Targets are scalar contribution estimates: projected form error, curvature,
|
||||
material delta, extinction contribution, radiance contribution, sensor
|
||||
information gain, visible coverage, or calibration confidence. Probabilistic
|
||||
|
|
@ -211,10 +238,10 @@ depth when depth participates in validation
|
|||
If a lowering cannot provide these, it is a fallback draw. It can help humans
|
||||
debug. It cannot claim to be the Perfect Machine.
|
||||
|
||||
### 6. Resolve And Presentation
|
||||
### 6. Reservoir Resolve And Presentation
|
||||
|
||||
TAA consumes guide data and validates pixel history. It does not recover truth
|
||||
from broken producers.
|
||||
Reservoir resolve consumes guide data and reconstructs presentation from the
|
||||
selected field evidence. It does not recover truth from broken producers.
|
||||
|
||||
Post, bloom, tonemapping, debug overlays, and output publication operate after
|
||||
the evidence lanes are coherent. Glow is allowed to make strong evidence look
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ Fensalir owns a renderer-native blue-noise threshold tile. Shaders that make
|
|||
stochastic coverage decisions should sample that tile with frame-varying offsets
|
||||
instead of substituting hash noise. Hashes are acceptable for deterministic ids
|
||||
and cheap decorrelation, but not as the visual sampling distribution for
|
||||
coverage that is meant to feed TAA or reservoirs.
|
||||
coverage that is meant to feed reservoir resolve.
|
||||
|
||||
Spline tubes follow this contract directly: CPU geometry emits conservative
|
||||
segment envelopes, while the spline shader samples the renderer blue-noise tile,
|
||||
|
|
|
|||
|
|
@ -59,8 +59,9 @@ contract for already-derived point claims.
|
|||
|
||||
## Invariants
|
||||
|
||||
- Field accumulation happens in world space before pixel history. TAA is the
|
||||
resolver, not the owner of sensor identity.
|
||||
- Field accumulation happens in world space before pixel history. Reservoir
|
||||
resolve reconstructs presentation; no separate TAA pass owns sensor identity
|
||||
or temporal smoothing.
|
||||
- Stable keys belong to the producer/accumulator boundary; shader packets are
|
||||
backend output and do not invent identity.
|
||||
- The compact support kernel has a finite bound. Renderer cost must scale from
|
||||
|
|
@ -96,7 +97,7 @@ Mimir calibration/device metadata
|
|||
-> D3D12 GPU sensor fusion compute shader
|
||||
-> RWStructuredBuffer<TemporalGaussian>
|
||||
-> instanced SDF Gaussian draw
|
||||
-> TAA/resolve
|
||||
-> reservoir resolve
|
||||
```
|
||||
|
||||
Ownership:
|
||||
|
|
|
|||
|
|
@ -11,7 +11,8 @@ Fensalir owns the shared temporal evidence machine for two customers:
|
|||
|
||||
The old stable-key accumulator was useful, but it was not ReSTIR. The live
|
||||
architecture now splits the problem into a small resampled-importance core, a
|
||||
spatial evidence track layer, typed lowerings, renderer passes, and TAA history.
|
||||
spatial evidence track layer, typed lowerings, renderer passes, and reservoir
|
||||
resolve history.
|
||||
|
||||
## Engine Identity
|
||||
|
||||
|
|
@ -31,6 +32,13 @@ color, let post handle the rest" is violating the engine body. That path may
|
|||
exist only as an explicitly named fallback/debug draw with no authority over
|
||||
field evidence.
|
||||
|
||||
The reservoir is the organ. Payload families are not. A TubeField path may bind
|
||||
a rolling buffer, evaluate Catmull-Rom tube envelopes, generate proxy geometry,
|
||||
march a tube SDF, sample a blackbody ramp, and emit candidate weights. Those
|
||||
are TubeField producer responsibilities. Final visibility, temporal reuse,
|
||||
spatial reuse, validation, contribution weight, and presentation membership
|
||||
belong to the shared spatiotemporal field reservoir.
|
||||
|
||||
## Research Spine
|
||||
|
||||
- NVIDIA ReSTIR DI repeatedly resamples candidate light samples, then applies
|
||||
|
|
@ -54,11 +62,36 @@ field evidence.
|
|||
https://github.com/NVIDIA-RTX/RTXDI/blob/main/Doc/RestirGI.md
|
||||
https://github.com/NVIDIA-RTX/RTXDI/blob/main/Doc/RestirPT.md
|
||||
|
||||
## Fensalir Divergence
|
||||
|
||||
Pure ReSTIR usually starts after primary visibility is known: a ray or G-buffer
|
||||
surface exists, then the reservoir chooses and reuses lighting or path
|
||||
candidates for that surface. Fensalir cannot assume that order for field
|
||||
claims. In many Fensalir scenes, the thing being sampled is the visible field
|
||||
candidate itself: tube surface, SDF envelope, splat support, volume boundary,
|
||||
sensor confidence surface, or mesh summary.
|
||||
|
||||
That makes the shared field reservoir responsible for the job normally assigned
|
||||
to TAA. Claim producers must first generate local visibility
|
||||
candidates with stable identity, support, depth/travel, coverage, material
|
||||
encoding, target value, and proposal policy. The reservoir then selects and
|
||||
reuses those field candidates across time and space. Material and transport
|
||||
evaluation ride on the selected field candidate; they do not repair missing
|
||||
Form identity after the fact.
|
||||
|
||||
There is no separate TAA organ in the target architecture. Any temporal
|
||||
stability, history validation, antialiasing, or reconstruction happens inside
|
||||
reservoir update and reservoir resolve. The final presentation pass samples or
|
||||
filters the resolved reservoir; it does not repair it. If a field surface only
|
||||
becomes stable because a downstream pixel-history pass smears unstable pixels
|
||||
until they look acceptable, the field producer or reservoir validation is
|
||||
wrong.
|
||||
|
||||
## Pipeline Map
|
||||
|
||||
```text
|
||||
producer observations
|
||||
-> candidate generator
|
||||
-> local visibility candidate generator
|
||||
-> target evaluator
|
||||
-> ResampledImportanceReservoir<TSample>
|
||||
-> temporal reuse pass
|
||||
|
|
@ -68,7 +101,7 @@ producer observations
|
|||
-> TemporalSpatialEvidenceLowering
|
||||
-> backend packet stream
|
||||
-> renderer/fusion passes
|
||||
-> TAA guide/history buffers
|
||||
-> reservoir resolve/history buffers
|
||||
```
|
||||
|
||||
## Ownership
|
||||
|
|
@ -87,6 +120,13 @@ tiles, or resident children. Mimir may propose visual/audio feature candidates
|
|||
from sensor confidence and calibration state. The reservoir does not know these
|
||||
domains; it only receives target and source-PDF values.
|
||||
|
||||
For opaque Form fields, local candidate generation owns primary visibility
|
||||
discovery before reservoir reuse. It may be deterministic when sparse stochastic
|
||||
sampling would leave holes in the visible surface. This is not a fallback to a
|
||||
private renderer; it is the producer side of the shared reservoir contract.
|
||||
TubeField's bounded tile-local candidate enumeration is the current concrete
|
||||
example.
|
||||
|
||||
Every evidence sample should state its layer and encoding before lowering:
|
||||
Form, Appearance, or Transport; then SDF, height, density, extinction,
|
||||
material, phase, emission, radiance, feature, or confidence as appropriate.
|
||||
|
|
@ -134,9 +174,11 @@ candidate selection when the output is a field with persistent identity:
|
|||
`TemporalSpatialEvidenceLowering` owns packet conversion. Consumers do not pack
|
||||
payload vectors by private convention when a lowering helper exists.
|
||||
|
||||
TAA owns pixel history validation and temporal guide buffers. It may consume
|
||||
reservoir confidence, sample age, domain id, motion, and temporal-detail lanes,
|
||||
but it does not own producer identity or stable spatial evidence.
|
||||
Reservoir resolve owns temporal antialiasing and reconstruction over the
|
||||
resolved field output. It consumes reservoir confidence, sample age, domain id,
|
||||
motion, and temporal-detail lanes. No separate TAA pass owns producer identity,
|
||||
stable spatial evidence, or the decision that a field candidate persists across
|
||||
frames.
|
||||
|
||||
## Contributor Paths
|
||||
|
||||
|
|
@ -162,10 +204,16 @@ depth where depth participates in validation. The exact producer can be a
|
|||
compute pass, a proxy draw, a mesh draw, or a future volume pass. The invariant
|
||||
is the evidence contract, not the producer's religion.
|
||||
|
||||
When a contributor needs specialized candidate generation, the specialization
|
||||
stops at the candidate boundary. `TubeField` is therefore a claim/candidate
|
||||
producer for rolling-buffer tube surfaces, not a separate TubeField reservoir
|
||||
renderer. The same rule applies to meshes, volumes, fractal probes, surface
|
||||
pages, and future sensor-derived fields.
|
||||
|
||||
Traditional meshes therefore do not bypass the machine. They are accepted when
|
||||
they can provide stable identity, motion or previous-frame mapping where needed,
|
||||
material/field encoding, conservative bounds, and guide data sufficient for TAA
|
||||
and reservoir validation. A mesh that only paints pixels is a fallback draw. A
|
||||
material/field encoding, conservative bounds, and guide data sufficient for
|
||||
reservoir validation. A mesh that only paints pixels is a fallback draw. A
|
||||
mesh that emits field evidence is a first-class contributor.
|
||||
|
||||
The `.aquafield` script surface follows the same boundary. A script declares
|
||||
|
|
@ -222,15 +270,15 @@ Not built yet:
|
|||
- camera/disocclusion/material validation for fractal form/appearance reservoirs;
|
||||
- spatial neighbor reuse across screen tiles and cube-sphere neighbor domains;
|
||||
- GRIS-style domain shift mappings for nested `.aquageo` domains;
|
||||
- expanded TAA guide-buffer storage for previous-frame reservoir confidence,
|
||||
- expanded reservoir guide-buffer storage for previous-frame reservoir confidence,
|
||||
sample age, domain validity, and invalidation reason;
|
||||
- SSD/RAM residency queues driven by reservoir contribution estimates.
|
||||
|
||||
## TAA Guide Layout
|
||||
## Reservoir Guide Layout
|
||||
|
||||
Reservoir/TAA guide data has a dedicated current scene target and ping-ponged
|
||||
history target. It is deliberately separate from `history-control.w`, which
|
||||
continues to own pixel history age.
|
||||
Reservoir guide data has a dedicated current scene target and ping-ponged
|
||||
history target. It is deliberately separate from legacy `history-control.w`.
|
||||
Pixel history age is a reservoir resolve signal, not a separate TAA authority.
|
||||
|
||||
```text
|
||||
x: reservoir confidence
|
||||
|
|
@ -242,9 +290,10 @@ w: invalidation code
|
|||
The first live producers are SDF surfaces and temporal Gaussian splats, but the
|
||||
schema is not surface-only. Resolve reads the current and previous guide
|
||||
textures, folds confidence and domain validity into history validation, then
|
||||
writes the next history guide. Future ReSTIR/GRIS passes should extend the
|
||||
producer side of this schema with explicit Form/Appearance/Transport fields
|
||||
rather than packing more reservoir folklore into scene-control channels.
|
||||
writes the next history guide. This resolve is the first reservoir resolve
|
||||
implementation, not an independent TAA owner. Future ReSTIR/GRIS passes should
|
||||
extend the producer side of this schema with explicit Form/Appearance/Transport
|
||||
fields rather than packing more reservoir folklore into scene-control channels.
|
||||
|
||||
## Implementation Roadmap
|
||||
|
||||
|
|
@ -261,8 +310,8 @@ rather than packing more reservoir folklore into scene-control channels.
|
|||
surface encoding; density/extinction packets are the transparent/sensor
|
||||
volume encoding. Expose debug views for weight sum, selected target,
|
||||
candidate count, confidence, age, and invalidation reason.
|
||||
7. Weave reservoir confidence and temporal detail into TAA guide buffers so the
|
||||
history filter can distinguish stable reused evidence from fresh stochastic
|
||||
7. Weave reservoir confidence and temporal detail into reservoir guide buffers
|
||||
so reservoir resolve can distinguish stable reused evidence from fresh stochastic
|
||||
noise. The first pass uses current scene-control.w for reservoir confidence
|
||||
and keeps history-control.w as age; full previous-frame reservoir validity
|
||||
still needs an expanded guide layout.
|
||||
|
|
@ -276,5 +325,5 @@ rather than packing more reservoir folklore into scene-control channels.
|
|||
|
||||
If a new subsystem stores temporal candidates, it must state whether it owns raw
|
||||
producer retention, resampled candidate selection, stable resolved tracks,
|
||||
packet lowering, or TAA history. If it cannot name that authority, it is not an
|
||||
architecture. It is a decorative leak.
|
||||
packet lowering, or reservoir resolve history. If it cannot name that authority,
|
||||
it is not an architecture. It is a decorative leak.
|
||||
|
|
|
|||
Loading…
Reference in a new issue