refactor(M03): extract M2 mesh resource traversal
Work-Package: M03-RND-M2-MESH-RESOURCE-EXTRACTOR-001 Agent: sindo-main-codex Tests: 36 headless renderer/coordinate contracts pass; checkpoint dry-run 7/7; documentation and coordination gates pass Fidelity: preserves first-Mesh preorder and temporary PackedScene cleanup; no visual parity claim
This commit is contained in:
@@ -33,7 +33,8 @@ flowchart LR
|
||||
Cache -->|cached Mesh or null| Loader
|
||||
Loader --> Pipeline[M2MeshLoadPipelineState]
|
||||
Pipeline --> IO[ResourceLoader]
|
||||
IO --> Prepare[Loader extraction and runtime preparation]
|
||||
IO --> Extract[M2MeshResourceExtractor]
|
||||
Extract --> Prepare[Loader runtime preparation]
|
||||
Prepare --> Cache
|
||||
Loader --> Build[M2 MultiMesh materialization]
|
||||
```
|
||||
@@ -129,7 +130,8 @@ flowchart TB
|
||||
- Renderer main-thread adapters serialize every cache operation.
|
||||
- The cache owns normalized-path Strings and strong Mesh references.
|
||||
- Borrowed Mesh lookups do not transfer ownership or duplicate resources.
|
||||
- The loader owns missing/prototype/animated state and all Nodes/MultiMeshes.
|
||||
- `M2MeshResourceExtractor` owns first-Mesh selection and temporary PackedScene
|
||||
instances. The loader owns missing/prototype/animated state and MultiMeshes.
|
||||
- The loader drains asynchronous work before the final cache clear.
|
||||
|
||||
## Errors, cancellation and recovery
|
||||
@@ -181,7 +183,8 @@ the historical Mesh cache had no queue contribution or log site.
|
||||
|---|---|---|---|
|
||||
| Prepared static M2 Mesh cache | Implemented extraction | Contract/source/timing verifier | Asset-backed memory/leak run pending |
|
||||
| M2 Mesh request lifecycle | Implemented extraction | Pipeline state verifier | ResourceLoader I/O remains loader-owned |
|
||||
| M2 Mesh extraction/preparation | Existing loader-owned | Material/classifier regressions | Separate finalizer extraction next |
|
||||
| M2 Mesh extraction | Implemented extraction | Resource/order/lifetime verifier | Asset-backed corrupt-scene fixture pending |
|
||||
| M2 Mesh preparation | Existing loader-owned | Material/classifier regressions | Separate finalizer extraction next |
|
||||
|
||||
## Known gaps and risks
|
||||
|
||||
@@ -196,6 +199,7 @@ the historical Mesh cache had no queue contribution or log site.
|
||||
| Path | Responsibility |
|
||||
|---|---|
|
||||
| `src/render/m2/m2_mesh_resource_cache_state.gd` | Prepared Mesh references and final clear |
|
||||
| `src/render/m2/m2_mesh_resource_extractor.gd` | First-Mesh selection and temporary PackedScene lifetime |
|
||||
| `src/scenes/streaming/streaming_world_loader.gd` | Normalization, I/O, preparation, missing state and materialization |
|
||||
| `src/render/m2/m2_mesh_load_pipeline_state.gd` | Pending request and terminal finalize records |
|
||||
| `src/tools/verify_m2_mesh_resource_cache_state.gd` | Cache ownership/lifetime/boundary/timing regression |
|
||||
|
||||
Reference in New Issue
Block a user