refactor(render): remove the production portal frame carrier
This commit is contained in:
parent
69e69408e8
commit
cb22691beb
10 changed files with 128 additions and 443 deletions
|
|
@ -14,7 +14,6 @@ namespace AcDream.App.Rendering;
|
|||
internal sealed class RetailPViewRenderer
|
||||
{
|
||||
private readonly RenderSceneShadowRuntime _renderSceneShadow;
|
||||
private readonly PortalVisibilityFrame _mainPortalFrameScratch = new();
|
||||
private readonly ClipFrameAssembly _clipAssemblyScratch = new();
|
||||
private readonly RetailPViewFrameResult _frameResultScratch = new();
|
||||
|
||||
|
|
@ -98,19 +97,8 @@ internal sealed class RetailPViewRenderer
|
|||
RetailPViewPassExecutor walkExecutor = passes as RetailPViewPassExecutor
|
||||
?? throw new InvalidOperationException(
|
||||
"The retail frame walk requires RetailPViewPassExecutor.");
|
||||
// Compatibility carrier only. Production visibility is populated
|
||||
// exclusively by RetailFrameWalk below; this frame supplies the clip
|
||||
// assembler's outdoor full-screen seed until that carrier is removed.
|
||||
PortalVisibilityFrame pvFrame = _mainPortalFrameScratch;
|
||||
pvFrame.ResetForBuild();
|
||||
if (ctx.RootCell.IsOutdoorNode)
|
||||
{
|
||||
pvFrame.OutsideView.SetFullScreen();
|
||||
pvFrame.OrderedVisibleCells.Add(ctx.RootCell.CellId);
|
||||
}
|
||||
|
||||
var clipAssembly = passes.AssembleClipFrame(
|
||||
pvFrame,
|
||||
ClipFrameAssembly clipAssembly = passes.BeginWalkClipFrame(
|
||||
ctx.RootCell.IsOutdoorNode,
|
||||
_clipAssemblyScratch);
|
||||
// FW4 slice 1: PrepareClipFrame (the one clip-region publication)
|
||||
// moved BELOW the walk block — an interior-rooted walk frame
|
||||
|
|
@ -123,8 +111,7 @@ internal sealed class RetailPViewRenderer
|
|||
// (the old clipAssembly.CellIdToSlot.Keys filter silently dropped slot-less cells).
|
||||
// Per-slice trim still applies in DrawEnvCellShells (Task 4 makes it self-contained).
|
||||
_drawableCellsScratch.Clear();
|
||||
_drawableCellsScratch.UnionWith(pvFrame.OrderedVisibleCells);
|
||||
var drawableCells = _drawableCellsScratch;
|
||||
HashSet<uint> drawableCells = _drawableCellsScratch;
|
||||
passes.UseIndoorMembershipOnlyRouting();
|
||||
|
||||
// Campaign FW3.4a: THE ONE WALK. Builds walkContext/walkLandscape/
|
||||
|
|
@ -336,7 +323,6 @@ internal sealed class RetailPViewRenderer
|
|||
RenderFrameDiagnosticCounts counts = WalkDiagnosticCounts(retainedCounts);
|
||||
RenderProjectionCounts sourceCounts = retainedCounts;
|
||||
RetailPViewFrameResult result = _frameResultScratch.Reset(
|
||||
pvFrame,
|
||||
clipAssembly,
|
||||
drawableCells,
|
||||
prepareCells,
|
||||
|
|
@ -695,7 +681,6 @@ public sealed class RetailPViewFrameInput
|
|||
/// </summary>
|
||||
public sealed class RetailPViewFrameResult
|
||||
{
|
||||
public PortalVisibilityFrame PortalFrame { get; private set; } = null!;
|
||||
public ClipFrameAssembly ClipAssembly { get; private set; } = null!;
|
||||
public HashSet<uint> DrawableCells { get; private set; } = null!;
|
||||
|
||||
|
|
@ -712,7 +697,6 @@ public sealed class RetailPViewFrameResult
|
|||
{ get; private set; }
|
||||
|
||||
internal RetailPViewFrameResult Reset(
|
||||
PortalVisibilityFrame portalFrame,
|
||||
ClipFrameAssembly clipAssembly,
|
||||
HashSet<uint> drawableCells,
|
||||
HashSet<uint> visibleCells,
|
||||
|
|
@ -720,7 +704,6 @@ public sealed class RetailPViewFrameResult
|
|||
RenderProjectionCounts sourceCounts,
|
||||
InteriorEntityPartition.Result? diagnosticPartition)
|
||||
{
|
||||
PortalFrame = portalFrame;
|
||||
ClipAssembly = clipAssembly;
|
||||
DrawableCells = drawableCells;
|
||||
VisibleCells = visibleCells;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue