acdream/tests/AcDream.Core.Tests/Rendering
Erik c55acdc3d5 fix(render #53): skip cache populate when classification is incomplete
User reported: the drudge statue on top of the Foundry (a multi-part
live-spawned entity with AnimPartChange + texChanges) renders only
PARTIALLY — some parts visible, some missing.

Root cause: the dispatcher's slow path skips a MeshRef when
_meshAdapter.TryGetRenderData returns null (mesh still async-decoding
via ObjectMeshManager.PrepareMeshDataAsync). The classified-batches
collector accumulates only the MeshRefs that DID resolve. At entity
boundary, the cache populates with the PARTIAL set. Frame-2 cache hits
serve that partial entry forever — even after the missing mesh loads,
the cache continues to skip those parts because classification never
reruns for cached entities.

Fix: track currentEntityIncomplete during the foreach. Set it true on
any null renderData. At entity boundary (and at end-of-loop), if the
flag is set, DROP the accumulated populate scratch instead of writing
it to the cache. The slow path retries on the next frame; once all
meshes have loaded, the populate fires correctly with the complete
classification.

Adds a regression test pinning the contract — incomplete entities
produce zero cache entries.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-10 23:42:46 +02:00
..
Wb fix(render #53): skip cache populate when classification is incomplete 2026-05-10 23:42:46 +02:00
ChaseCameraTests.cs feat(app): Phase B.2 — ChaseCamera (third-person follow camera) 2026-04-12 14:26:20 +02:00
FrustumCullerTests.cs feat(app): Phase A.2 — FrustumCuller + FrustumPlanes (Gribb-Hartmann) 2026-04-12 08:49:17 +02:00
TextureCacheBindlessTests.cs phase(N.5) Task 3: TextureCache bindless GetOrUpload + parallel cache 2026-05-08 19:53:10 +02:00