Files
workinf_Blender_Wasm/docs/status/WEB-OPFS-SAVE-REOPEN-20261122.md
mes123456 63db6caf1f
Some checks failed
M6 deployable RC / quick (push) Has been cancelled
M6 deployable RC / chromium (push) Has been cancelled
M6 deployable RC / release (push) Has been cancelled
feat(web): studio worlds, camera-view/offscreen environment parity, material and undo coverage
Environment lighting:
- ship all eight desktop studiolights/world datasets (WBENV1 float32) and a
  shared loader used by both the main viewport and the offscreen worker
- add the N-panel "studio 环境" selector
- rotate the world background together with the environment
  (backgroundRotation/backgroundIntensity), so camera view and offscreen
  renders match the desktop Mapping-node behaviour

Verification (Chromium, OPFS, NOT_CLAIMED):
- environment lighting + 8 world pixel identity
- camera-view rotation correspondence (camera matrices, 207 samples)
- offscreen vs on-screen background parity after hiding geometry (1305 samples)
- metals case extended with material-field OPFS roundtrip
- material Principled edits and rename undo/redo
- eight studio worlds: pairwise frame differences + luminance rank correlation
- undo history depth capped at 64 steps and undo across OPFS save/reopen

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-23 09:27:47 +08:00

2.8 KiB
Raw Blame History

WEB-OPFS-SAVE-REOPEN-20261122 status

  • case: WEB-OPFS-SAVE-REOPEN-20261122(世界环境经 OPFS 保存 → 刷新 → 最近项目重开的一致性)
  • 类型:用户案例补缺(用户要求“OPFS 保存/重开后一致性断言”);不是队列任务
  • 改动文件(当前哈希):
    • web/tests/e2e/wbv2-opfs-save-reopen-production.spec.ts(55a54ed9…94f51e,新增)
    • 被断言的产品路径(App.tsx saveProjectOpfs/recoverCachedProject、原生 world 环境序列化与读回)见 WEB-ENVIRONMENT-LIGHTING-20261122
  • 流程(全部经产品入口,fixture tests/files/web/basic_scene.blend):
    1. 打开 .blend,等 SceneIR rN;
    2. 「世界环境」面板:环境强度 2.5、颜色 #ff8000(回读线性 1, 0.216, 0 后才继续)、加载并选择 m12_obj_texture、环境旋转 90°;
    3. 顶部「保存项目」(OPFS,aria-label="保存项目")→ data-save-transaction-status=SUCCEEDED,记录 committed revision/hash,脏状态变「已保存」;
    4. 全程监听 download 事件:[](保存不产生自动下载);
    5. page.reload() → 等「最近项目」出现本 projectId → 选择重开 → data-project-id 一致、状态 Recovery: baseline rN;
    6. 重开后读回 worlds[0]:颜色 [1, 0.2159, 0]、强度 2.5、旋转 1.5708、environmentImageId 解析到 m12_obj_texture;场景节点集合与保存前一致;仍无 download 事件。
  • 结果:1 passed (12.7s);证据 tests/golden/WEB-OPFS-SAVE-REOPEN-20261122/opfs-save-reopen.json(含 worldBefore/worldAfter、committed revision/hash、downloads: [])。
  • 过程中修复:用例曾出现颜色编辑未落盘的偶发竞态(保存前读到默认灰色);现加“保存前回读颜色必须为 1,0.216,0”的门禁,之后每次运行都稳定落盘。
  • 2026-11-22 增补:材质字段 OPFS 往返
    • 保存前经产品入口新增猴头,新增槽 → 材质名称 OPFS Gold → 基础色 #ffd700 → 粗糙度 0.2 → 金属度 1 → 「应用 Principled」(与四金属案例同一 UI 流)。
    • 重开后 materials 中按名称找回 OPFS Gold,材质 id 一致、metallic≈1、roughness≈0.2、baseColor 三分量与保存前逐项相等(1e-3);节点集合仍一致,downloads: []。
    • 复跑:1 passed (16.1s);与 metals / 环境光照 / 相机视图三条用例合并运行 4 passed (1.5m);npm run typecheck exit 0。
    • 证据 tests/golden/WEB-OPFS-SAVE-REOPEN-20261122/opfs-save-reopen.json 现含 materialBefore/materialAfter。
  • 未验证 / 剩余缺口:
    • 撤销操作日志重放(非 baseline 恢复)路径未覆盖;
    • 大场景/多项目并发保存的容量与冲突行为未验证。
  • 验收:NOT_CLAIMED。
  • 下一动作:如需继续,覆盖撤销日志重放路径。