acdream/tests/AcDream.App.Tests/Rendering
Erik c2cb83d11f perf(render): gate EnvCellRenderer visibility-snapshot rebuilds on real input changes (2026-07-24 audit review)
PrepareRenderBatches rebuilt the full EnvCell visibility snapshot every
frame any indoor/building root was resolved: a Parallel.ForEach dispatch
over every GpuReady EnvCell landblock (with per-landblock locks), a fresh
outer dictionary plus one fresh inner dictionary per visible cell, a new
snapshot object, and a complete transparency rescan - all while standing
perfectly still. The NeedsPrepare flag existed since Phase A8 as the
intended rebuild gate but was never read by production code.

This wires the gate on the snapshot's actual inputs:
- landblock commits/removals (the existing NeedsPrepare flag),
- the visible-cell filter (content-compared; the caller reuses one
  scratch HashSet across frames),
- the trim window (center/radius),
- mesh render-data availability - new
  ObjectMeshManager.RenderDataAvailabilityVersion, bumped at publish,
  pending-release hide, release completion, and teardown, because the
  snapshot bakes per-cell transparency from TryGetRenderData and a
  late-arriving transparent shell must reclassify its cell,
- the camera: eye position under a 1 mm ABSOLUTE epsilon (swallows the
  documented ~36 um rest jitter, dirties on any real movement; the VP
  translation row scales with AC's ~5e4 world coordinates where a
  relative tolerance would mask sub-meter motion) plus rows 1-3 of
  view*projection (position-independent rotation x projection) under
  relative 1e-5.

Skipping is pool-safe: RenderCore re-anchors _poolIndex to the active
snapshot's PostPreparePoolIndex on every call, so consecutive Renders
without an intervening Prepare reuse scratch lists past the snapshot's
owned region exactly as within-frame passes already do. The empty-filter
branch is now also idempotent instead of allocating a fresh empty
snapshot per frame. Render still receives the current frame's
view-projection every frame (the U.4 stale-matrix rule) - only the
snapshot rebuild is gated.

Pixels must be identical; needs the standard user visual pass (dungeon +
town-near-buildings) before the change is considered accepted.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-07-24 11:49:40 +02:00
..
Vfx refactor(app): compose content effects and audio startup 2026-07-22 15:36:05 +02:00
Wb perf(render): gate EnvCellRenderer visibility-snapshot rebuilds on real input changes (2026-07-24 audit review) 2026-07-24 11:49:40 +02:00
AttachmentUpdateOrderTests.cs feat(vfx): port retail hidden and teleport presentation 2026-07-14 14:59:48 +02:00
BoundedUnownedResourceCacheTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
BuildingGroupScratchTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
CameraCollisionIndoorTests.cs T6 (BR-7) C3: per-cell shadow architecture - flood registration, building channel, per-cell query; b3ce505 stopgap DELETED (closes #99) 2026-06-11 14:37:50 +02:00
CameraCollisionUpdateViewerTests.cs feat(A): wire SweepEye to the verbatim update_viewer (start-cell + fallbacks) 2026-06-05 11:10:32 +02:00
CameraControllerTests.cs refactor(runtime): extract local teleport and player mode 2026-07-22 02:50:15 +02:00
CameraFrameControllerTests.cs refactor(camera): extract the update frame 2026-07-22 03:08:58 +02:00
CellViewDedupTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
CellVisibilityCommitTests.cs fix(streaming): commit EnvCell landblocks atomically (#214) 2026-07-13 18:45:24 +02:00
CellVisibilityFromRootTests.cs refactor(render): Stage 3 T3.1 — delete FindCameraCell AABB grace-frame fallback 2026-06-02 15:36:47 +02:00
CellVisibilityPortalPolygonsTests.cs fix(streaming): commit EnvCell landblocks atomically (#214) 2026-07-13 18:45:24 +02:00
ClipFrameAssemblerTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
ClipFrameLayoutTests.cs feat(render): Phase U.3 — GPU clip-plane gate (gl_ClipDistance), no-clip default 2026-05-30 17:27:30 +02:00
ClipFrameUploadTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
ClipPlaneSetTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
CompositeTextureArrayCachePolicyTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
CornerFloodReplayTests.cs fix(streaming): commit EnvCell landblocks atomically (#214) 2026-07-13 18:45:24 +02:00
CreatureAppraisalPresentationTests.cs feat(ui): port retail creature appraisal presentation 2026-07-23 12:55:24 +02:00
DebugVmRenderFactsPublisherTests.cs refactor(render): extract frame presentation diagnostics 2026-07-22 05:02:31 +02:00
DevToolsFramePresenterTests.cs refactor(app): compose session and player startup 2026-07-22 18:28:32 +02:00
DevToolsRuntimeSourcesTests.cs refactor(app): compose session and player startup 2026-07-22 18:28:32 +02:00
DisplayFramePacingControllerTests.cs refactor(render): extract frame resource preparation 2026-07-22 05:23:46 +02:00
DollCameraTests.cs fix(D.2b): Slice 2 — retail-exact doll pose, camera + heading (visual gate) 2026-06-25 13:16:27 +02:00
DollEntityBuilderTests.cs feat(D.2b): Slice 2 — DollEntityBuilder (player Setup+ObjDesc -> doll WorldEntity) 2026-06-23 09:07:02 +02:00
DynamicBufferCapacityTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
EntityClipTests.cs fix(render): R1 — repurpose the ParentCellId==null cell-gate bypass (#78) 2026-06-02 20:10:26 +02:00
EntityPhysicsHostTests.cs refactor(world): canonicalize live physics host ownership 2026-07-21 14:05:34 +02:00
EquippedChildProjectionWithdrawalTests.cs refactor(world): extract live appearance and parenting 2026-07-21 18:10:07 +02:00
FixedEntityTextureOwnerLeaseTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
FramebufferResizeControllerTests.cs refactor(app): compose settings and developer tools 2026-07-22 16:11:34 +02:00
FramePacingControllerTests.cs fix #225: stabilize render pacing and frame CPU 2026-07-19 06:29:30 +02:00
FramePacingPolicyTests.cs fix #225: stabilize render pacing and frame CPU 2026-07-19 06:29:30 +02:00
GameWindowLifetimeTests.cs refactor(app): extract focused window lifetime 2026-07-22 19:43:52 +02:00
GameWindowRenderLeafCompositionTests.cs feat(ui): port retail creature appraisal presentation 2026-07-23 12:55:24 +02:00
GameWindowSlice8BoundaryTests.cs refactor(app): extract focused window lifetime 2026-07-22 19:43:52 +02:00
GlTextureOwnershipTests.cs refactor(lifetime): own render resource prefixes 2026-07-22 14:42:14 +02:00
GpuFrameFlightControllerTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
GpuResourceRetirementTransactionTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
GpuRetiredTerrainSlotAllocatorTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
HostQuiescenceGateTests.cs refactor(app): own native window callback lifetime 2026-07-22 09:59:10 +02:00
HouseExitWalkReplayTests.cs refactor(render): extract typed retail pview passes 2026-07-22 06:40:09 +02:00
IndoorDrawPlanTests.cs feat(render): IndoorDrawPlan.ShellPass — every visible cell, no drawable filter (R1) 2026-06-06 21:59:26 +02:00
InteriorEntityPartitionTests.cs T1 (fused BR-2/3): retail frame order - dynamics last, punch+seal, shell chop deleted 2026-06-11 11:16:27 +02:00
Issue95DungeonFloodDiagnosticTests.cs test(#95): headless dungeon-flood diagnostic — measure visible-cell count on 0x0007 2026-06-13 18:52:00 +02:00
Issue113DrawingBspFilterTests.cs fix(render): #113 root cause #2 - GfxObj meshes draw only DrawingBSP-referenced polys (the REAL phantom staircase) 2026-06-10 20:52:52 +02:00
Issue113MeetingHallFloodTests.cs fix(streaming): commit EnvCell landblocks atomically (#214) 2026-07-13 18:45:24 +02:00
Issue120ReciprocalPingPongTests.cs #119-residual: tower-ascent harness pins the roof-lip flood gap; barrel claim RETRACTED (user axiom: not in retail) 2026-06-11 18:34:45 +02:00
Issue124LookInSeedRegionTests.cs fix #124: interior-root building look-ins as a landscape-stage sub-pass 2026-06-12 15:59:29 +02:00
Issue127FloodFlipReplayTests.cs close #127 (user-gated + desk pin): distant-building flood flap died with the W=0 clip port 2026-06-13 10:03:33 +02:00
Issue129PunchBiasTests.cs fix #129: cap the punch mark bias's eye-space reach (was unbounded at distance) 2026-06-12 13:38:59 +02:00
Issue130DoorwayStripTests.cs fix #130 (the real strip): drawn-shell lift vs draw-space portal consumers 2026-06-12 14:28:16 +02:00
Issue131SetupProbeTests.cs fix #131 (root cause 4, structurally forced): look-in cells draw their DYNAMICS - the town portal is a server object in the hall's porch cell 2026-06-12 20:52:34 +02:00
Issue177StairDescentCameraFloodTests.cs park #177: retail cdb trace DISPROVES the portal-flood theory 2026-07-07 08:43:21 +02:00
Issue181CameraParkStabilityTests.cs diag #181: root-cause chain complete - flapping cell 0x0181, wall-press excitation, and the REAL defect: camera-flood-scoped light application 2026-07-06 21:04:34 +02:00
Issue181VisFlapReplayTests.cs diag #181 (refined): 0x0181's region is a zero-area sliver; the amplifier is per-drawn-cell state shifting with the cell list, not light-pool scoping 2026-07-06 21:46:49 +02:00
Issue181WallPressEquilibriumTests.cs port #181: retail viewer step subdivision (calc_num_steps 0x0050a0b0) - radius-anchored steps + remainder final step + viewer-exempt small-offset abort 2026-07-06 22:30:37 +02:00
Issue176177FacilityHubFloodReplayTests.cs docs+test #176/#177: 12 mechanisms refuted, apparatus shipped, probe protocol staged 2026-07-05 21:20:03 +02:00
LiveAppearanceAnimationTests.cs refactor(world): extract live projection mechanics 2026-07-21 16:17:03 +02:00
LiveEntityAnimationPresenterTests.cs refactor(runtime): extract the live object frame 2026-07-22 00:42:26 +02:00
LiveEntityAnimationSchedulerTests.cs refactor(runtime): extract the live object frame 2026-07-22 00:42:26 +02:00
LiveEntityCreateSupersessionRecoveryTests.cs refactor(world): extract live entity hydration 2026-07-21 17:32:45 +02:00
NdcScissorRectTests.cs fix #130: doorway-slice scissor cut the aperture's top/right pixel row 2026-06-12 13:31:43 +02:00
OrderedResourceTeardownTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
OutdoorCellNodeTests.cs feat(render): R-A2 — per-building floods (the flap fix) 2026-06-08 18:44:43 +02:00
OwnerScopedResourceRegistryTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
PaperdollFramePresenterTests.cs refactor(render): compose render frame orchestrator 2026-07-22 08:03:49 +02:00
ParticleBindlessInstanceTests.cs perf(rendering): preserve alpha order with bindless particles 2026-07-18 08:32:21 +02:00
ParticleEmitterRetirementTrackerTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
PhysicsCameraCollisionProbeTests.cs feat(A): wire SweepEye to the verbatim update_viewer (start-cell + fallbacks) 2026-06-05 11:10:32 +02:00
PortalMeshReferenceOwnerTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
PortalProjectionTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
PortalTunnelAssetTests.cs fix(runtime): align portal and movement presentation 2026-07-17 08:48:27 +02:00
PortalViewTests.cs feat(render): Phase A8.F — ViewPolygon + CellView clip-region data model 2026-05-29 11:30:28 +02:00
PortalVisibilityBuilderTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
PortalVisibilityRobustnessTests.cs feat(render): R-A2 — per-building floods (the flap fix) 2026-06-08 18:44:43 +02:00
PrivatePresentationRendererTests.cs feat(ui): port retail creature appraisal presentation 2026-07-23 12:55:24 +02:00
RendererResourceDisposalLedgerTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
RenderFrameDiagnosticsControllerTests.cs refactor(render): extract frame presentation diagnostics 2026-07-22 05:02:31 +02:00
RenderFrameGlStateControllerTests.cs refactor(render): extract world scene frame owner 2026-07-22 07:22:09 +02:00
RenderFrameOrchestratorTests.cs test(app): add canonical connected soak snapshots 2026-07-22 20:01:06 +02:00
RenderFramePreparationControllerTests.cs refactor(render): compose render frame orchestrator 2026-07-22 08:03:49 +02:00
RenderFrameRecoveryIntegrationTests.cs feat(ui): port retail creature appraisal presentation 2026-07-23 12:55:24 +02:00
RenderFrameResourceControllerTests.cs refactor(render): extract world scene frame owner 2026-07-22 07:22:09 +02:00
ResourceCleanupGroupTests.cs refactor(app): compose world rendering startup 2026-07-22 16:46:05 +02:00
ResourceShutdownTransactionTests.cs refactor(app): extract focused window lifetime 2026-07-22 19:43:52 +02:00
RetailAlphaQueueTests.cs refactor(render): extract world scene frame owner 2026-07-22 07:22:09 +02:00
RetailChaseCameraTests.cs fix(world): match retail portal passage and exit warp 2026-07-15 22:14:21 +02:00
RetailParticleGeometryClassifierTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
RetailPViewPassExecutorTests.cs refactor(app): compose atomic frame roots 2026-07-22 19:02:08 +02:00
RetailSelectionAssetTests.cs feat(selection): port retail offscreen target indicator 2026-07-18 07:41:12 +02:00
RetailSelectionLightingPulseTests.cs fix(interaction): bind selection to live incarnations 2026-07-21 07:07:58 +02:00
RetailSelectionSceneTests.cs refactor(render): extract world scene frame owner 2026-07-22 07:22:09 +02:00
RetailStaticAnimatingObjectSchedulerTests.cs refactor(streaming): compose landblock presentation transaction 2026-07-21 21:45:16 +02:00
RollingTimingSampleWindowTests.cs refactor(render): extract frame presentation diagnostics 2026-07-22 05:02:31 +02:00
RuntimeResourceSlotTests.cs refactor(app): compose atomic frame roots 2026-07-22 19:02:08 +02:00
ScreenPolygonClipTests.cs feat(render): Phase A8.F — ScreenPolygonClip 2D convex-polygon intersection 2026-05-29 11:37:30 +02:00
ShaderProgramConstructionTests.cs refactor(lifetime): own render resource prefixes 2026-07-22 14:42:14 +02:00
SilkWindowCallbackBindingTests.cs refactor(app): own native window callback lifetime 2026-07-22 09:59:10 +02:00
SkyProjectionTests.cs fix(runtime): align portal and movement presentation 2026-07-17 08:48:27 +02:00
SpawnMotionInitializerTests.cs fix(animation): preserve wire motion on every spawn path 2026-07-12 14:27:44 +02:00
StandaloneBindlessTextureCacheTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
TerrainCullOrientationTests.cs fix #108-residual (root cause): terrain drew DOUBLE-SIDED - port retail landPolysDraw eye-side gate as terrain backface cull 2026-06-12 22:05:31 +02:00
TerrainDrawDiagnosticsControllerTests.cs refactor(render): extract typed retail pview passes 2026-07-22 06:40:09 +02:00
TerrainParticleCellVisibilityTests.cs perf(vfx): port retail particle visibility degradation 2026-07-17 15:27:36 +02:00
TerrainTextureTilingTableTests.cs fix(rendering): restore retail terrain texture tiling 2026-07-13 21:04:22 +02:00
TextRendererFailureSafetyTests.cs refactor(render): compose render frame orchestrator 2026-07-22 08:03:49 +02:00
TowerAscentReplayTests.cs #119-residual ROOT CAUSE: the +0.02 m render lift leaked into the portal-visibility graph - horizontal portals side-culled anyone standing on them 2026-06-11 19:26:06 +02:00
ViewconeCullerReuseTests.cs fix(rendering): bound portal resource lifetime 2026-07-18 21:35:16 +02:00
WorldRenderDiagnosticsTests.cs refactor(render): extract frame presentation diagnostics 2026-07-22 05:02:31 +02:00
WorldRenderFrameBuilderTests.cs refactor(app): extract focused window lifetime 2026-07-22 19:43:52 +02:00
WorldSceneRendererTests.cs refactor(app): compose atomic frame roots 2026-07-22 19:02:08 +02:00