refactor(rendering): delete superseded visibility probes
Delete the callerless portal-BFS research graph and spent renderer probe families while retaining the production RetailFrameWalk path, terrain diagnostics, membership invariant, and walk transcript. Mutation evidence (all restored): 1. Restored PortalVisibilityBuilder type -> AppAssembly_ContainsNoSupersededPortalGraphTypes first failed Assert.Empty with AcDream.App.Rendering.PortalVisibilityBuilder. 2. Restored ACDREAM_PROBE_FACILITY_STAIRS -> ProductionSource_ContainsNoDeletedRendererProbe_AndRetainsWalkTranscriptProof first failed Assert.Empty on RenderingDiagnostics.cs. 3. Added a second RetailFrameWalk field -> WalkFrameOwners_AreUnique first failed Assert.Single with _frameWalk and _mutatedSecondFrameWalk. 4. Added OrderBy to OrderedStream -> OrderedWalkStream_HasNoCrossStreamReorder first failed Assert.DoesNotContain on OrderBy(. 5. Added IDatReaderWriter parameter -> FrameTimeWalkOwners_HaveNoRawDatDependency first failed Assert.Empty on RetailFrameWalk.MutatedRawDatParameter.
This commit is contained in:
parent
b77989c323
commit
bf53e2ad6e
82 changed files with 451 additions and 10108 deletions
|
|
@ -1,52 +1,21 @@
|
|||
using System;
|
||||
using System.Numerics;
|
||||
using AcDream.App.Rendering;
|
||||
using Xunit;
|
||||
|
||||
namespace AcDream.App.Tests.Rendering;
|
||||
|
||||
/// <summary>
|
||||
/// The OUTDOOR render root (R-A2, 2026-06-08): a portal-less <see cref="LoadedCell"/> whose only job is
|
||||
/// to root the render outdoors so the flood seeds OutsideView FULL-SCREEN (terrain draws). Buildings are
|
||||
/// flooded SEPARATELY per-building (<see cref="PortalVisibilityBuilder.ConstructViewBuilding"/>), so the
|
||||
/// node carries NO reverse portals — the pre-R-A2 reverse-portal unified flood (which oscillated at the
|
||||
/// doorway) is gone. Its tests moved here; the old <c>UnifiedFloodTests</c> was retired.
|
||||
/// </summary>
|
||||
public class OutdoorCellNodeTests
|
||||
{
|
||||
[Fact]
|
||||
public void Build_ReturnsPortallessOutdoorRoot()
|
||||
{
|
||||
uint outdoorId = 0xA9B40031;
|
||||
var node = OutdoorCellNode.Build(outdoorId);
|
||||
LoadedCell node = OutdoorCellNode.Build(outdoorId);
|
||||
|
||||
Assert.Equal(outdoorId, node.CellId);
|
||||
Assert.True(node.IsOutdoorNode); // the flag PortalVisibilityBuilder keys the full-screen OutsideView on
|
||||
Assert.True(node.IsOutdoorNode);
|
||||
Assert.True(node.SeenOutside);
|
||||
Assert.Equal(Matrix4x4.Identity, node.WorldTransform);
|
||||
Assert.Empty(node.Portals); // R-A2: no reverse portals into buildings (buildings flood per-building)
|
||||
}
|
||||
|
||||
[Fact]
|
||||
public void Build_OutdoorRoot_SeedsFullScreenOutsideView_OnlyNodeVisible()
|
||||
{
|
||||
// The load-bearing outdoor-terrain behavior: rooting at the IsOutdoorNode node seeds OutsideView
|
||||
// with the FULL-SCREEN NDC quad, so ClipFrameAssembler yields TerrainMode != Skip and
|
||||
// DrawLandscapeThroughOutsideView draws terrain/sky/scenery everywhere. The portal-less node
|
||||
// resolves to exactly {node} — no interior cells flooded from the root (those come per-building).
|
||||
var node = OutdoorCellNode.Build(0xA9B40031);
|
||||
|
||||
var eye = new Vector3(0, -3, 1);
|
||||
var view = Matrix4x4.CreateLookAt(eye, new Vector3(0, 5, 1), Vector3.UnitZ);
|
||||
var proj = Matrix4x4.CreatePerspectiveFieldOfView(MathF.PI / 3f, 16f / 9f, 1f, 5000f);
|
||||
|
||||
var frame = PortalVisibilityBuilder.Build(node, eye, _ => null, view * proj);
|
||||
|
||||
Assert.Equal(new[] { 0xA9B40031u }, frame.OrderedVisibleCells); // only the node
|
||||
Assert.False(frame.OutsideView.IsEmpty);
|
||||
Assert.Equal(-1f, frame.OutsideView.MinX, 3);
|
||||
Assert.Equal(-1f, frame.OutsideView.MinY, 3);
|
||||
Assert.Equal(1f, frame.OutsideView.MaxX, 3);
|
||||
Assert.Equal(1f, frame.OutsideView.MaxY, 3);
|
||||
Assert.Empty(node.Portals);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue