refactor(render): publish the walk visible-cell set

This commit is contained in:
Erik 2026-08-31 04:15:55 +02:00
parent c9fb7e7d4c
commit 877e935ac4
4 changed files with 29 additions and 46 deletions

View file

@ -180,6 +180,7 @@ public sealed class WorldSceneRendererTests
"flat:clip",
"flat:sky",
"flat:terrain",
"visibility:mark",
"flat:entities",
"frame:clear-cells",
"passes:disable-clip",
@ -188,7 +189,6 @@ public sealed class WorldSceneRendererTests
"diagnostics:signature:OutdoorRoot",
"diagnostics:draw",
"alpha:end",
"visibility:mark",
"visibility:complete",
"selection:complete",
],
@ -206,7 +206,7 @@ public sealed class WorldSceneRendererTests
}
[Fact]
public void PViewWorld_UsesOnePViewProductAndPublishesItsDrawableCells()
public void PViewWorld_PublishesTheWalkVisibleCellsOnce()
{
var root = new LoadedCell
{
@ -233,7 +233,6 @@ public sealed class WorldSceneRendererTests
"diagnostics:signature:RetailPViewInside",
"diagnostics:draw",
"alpha:end",
"visibility:mark",
"visibility:complete",
"selection:complete",
],
@ -267,8 +266,8 @@ public sealed class WorldSceneRendererTests
// @0x0050FE60), and a cell entered through a building portal
// (DrawBuilding @0x0059F2A0 -> PView::ConstructView @0x005A57B0) is
// drawn by the same traversal as a flooded cell. The particle gate and
// the light-candidate scope must therefore receive InViewCells (flood
// plus look-ins), not the flood-only DrawableCells.
// light-candidate scope must therefore receive the walk's one visited
// set, including look-ins.
Assert.Contains(0x01010003u, rig.Visibility.MarkedCells);
Assert.NotNull(rig.Frames.ObservedCells);
Assert.Contains(0x01010003u, rig.Frames.ObservedCells!);