fix(rendering): bound portal resource lifetime
Separate logical ownership, render publication, and GPU retirement across live entities, landblocks, particles, textures, mesh arenas, portal/UI teardown, and per-frame scratch storage. Add bounded DAT/texture caches, upload budgets, three-frame fence retirement, exact-incarnation appearance reconciliation, frame pacing, and extensive lifetime conformance coverage.\n\nThe seven-destination connected route now cuts peak working/private memory roughly in half, returns Caul to 125-153 FPS locally, and produces no WER or AMD reset.\n\nCo-authored-by: OpenAI Codex <codex@openai.com>
This commit is contained in:
parent
3971997689
commit
749e8ceeb1
225 changed files with 29107 additions and 3914 deletions
|
|
@ -1,5 +1,6 @@
|
|||
using System;
|
||||
using System.IO;
|
||||
using AcDream.Content;
|
||||
using DatReaderWriter;
|
||||
using DatReaderWriter.DBObjs;
|
||||
using DatReaderWriter.Options;
|
||||
|
|
@ -100,6 +101,7 @@ public class Issue93TownNetworkFountainRoomLightInspectionTests
|
|||
var datDir = ResolveDatDir();
|
||||
if (datDir is null) { _out.WriteLine("SKIP: no dat dir"); return; }
|
||||
using var dats = new DatCollection(datDir, DatAccessType.Read);
|
||||
using var boundedDats = new DatCollectionAdapter(dats);
|
||||
|
||||
const uint setupId = 0x02000365u;
|
||||
var setup = dats.Get<Setup>(setupId);
|
||||
|
|
@ -115,7 +117,7 @@ public class Issue93TownNetworkFountainRoomLightInspectionTests
|
|||
int survivors = 0, markerSkipped = 0, gfxNull = 0;
|
||||
foreach (var mr in flat)
|
||||
{
|
||||
if (AcDream.Core.Meshing.GfxObjDegradeResolver.IsRuntimeHiddenMarker(dats, mr.GfxObjId))
|
||||
if (AcDream.Core.Meshing.GfxObjDegradeResolver.IsRuntimeHiddenMarker(boundedDats, mr.GfxObjId))
|
||||
{
|
||||
markerSkipped++;
|
||||
_out.WriteLine($" part gfx=0x{mr.GfxObjId:X8} -> MARKER (skipped)");
|
||||
|
|
@ -164,6 +166,7 @@ public class Issue93TownNetworkFountainRoomLightInspectionTests
|
|||
var datDir = ResolveDatDir();
|
||||
if (datDir is null) { _out.WriteLine("SKIP: no dat dir"); return; }
|
||||
using var dats = new DatCollection(datDir, DatAccessType.Read);
|
||||
using var boundedDats = new DatCollectionAdapter(dats);
|
||||
|
||||
var setup = dats.Get<Setup>(setupId);
|
||||
Assert.NotNull(setup);
|
||||
|
|
@ -174,7 +177,7 @@ public class Issue93TownNetworkFountainRoomLightInspectionTests
|
|||
int survivors = 0;
|
||||
foreach (var mr in flat)
|
||||
{
|
||||
if (AcDream.Core.Meshing.GfxObjDegradeResolver.IsRuntimeHiddenMarker(dats, mr.GfxObjId)) continue;
|
||||
if (AcDream.Core.Meshing.GfxObjDegradeResolver.IsRuntimeHiddenMarker(boundedDats, mr.GfxObjId)) continue;
|
||||
if (dats.Get<GfxObj>(mr.GfxObjId) is null) continue;
|
||||
survivors++;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue