Files
workinf_Blender_Wasm/docs/tasks/WBV2-P1424-001-desktop-completion/DW03.md
mes123456 f3e21c6b98
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
chore: checkpoint web Blender migration source, tools and docs
Accumulated uncommitted work: GHOST Web backend, WebGL/GPU web layer,
web workflow engine and protocol, tooling, docs and task records.
Large generated evidence, user-testing archives, build snapshots and
imported test assets remain untracked.

Co-Authored-By: Claude Code <noreply@anthropic.com>
2026-11-10 11:18:01 +08:00

62 lines
3.9 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# DW03:通用 buffer compute/SSBO 与原生视口消费
- stage: `main-desktop`
- queueTask: `WBV2-P1424-001`;parent: `WBV2-P1424-000`;nextTask: `null`
- 包状态:`planned_gap_closure`(并不表示已有源码尚未实现)
- 完整交付依赖:DW01, DW02
- 工作量级:XL;不表示日期承诺
- validation: `NOT_RUN`;acceptance: `NOT_CLAIMED`
## 优先复用的十多天成果
复用 Naga/WebGPU Worker、native ShaderCreateInfo、owner token、buffer/VBO commit、曲线分支和 cycle 157 command generation;不得从 Python demo 重做。
相关交接仅作按需引用:
- `tests/golden/WBV2-P1424-001/general-webgpu-compute-implementation.md`
- `tests/golden/WBV2-P1424-001/general-webgpu-compute-result.json`
- `tests/golden/WBV2-P1424-001/native-curves-evaluation-implementation.md`
- `tests/golden/WBV2-P1424-001/unattended-implementation/cycle-000157/result.json`
先对照当前小范围源码和最新交接保留已实现子项;只有缺功能、缺接线或缺必要依赖才新增实现。历史状态不自动当作当前缺口。
## 操作者工作流与交付
原生工作区重绘 → 原 shader compute → StorageBuf/VBO → 可见性/命令/原生 draw
buffer compute 全链生产实现及其原生视口消费者;具体 shader、owner、barrier 支持范围和剩余边界。
## 最小生产入口
- `blender-5.2.0/source/blender/gpu/webgl/webgl_backend.cc`
- `blender-5.2.0/source/blender/gpu/webgl/webgl_shader.cc`
- `blender-5.2.0/source/blender/gpu/webgl/webgl_draw.cc`
- `blender-5.2.0/source/blender/draw/intern/draw_command.cc`
- `tests/golden/WBV2-P1424-001/unattended-implementation/cycle-000157/result.json`
- `tests/golden/WBV2-P1424-001/compute-ssbo-manifest.json`
以上为聚焦入口,非要求全文加载。使用源码聚焦工具、精确 --source/--unit 和函数片段;接入新 operator 时追加其具体原生文件,单次最多 8 个精确源码文件。没有默认测试入口或要运行的 fixture;功能完成前不执行任何验证。
## 只补未完成部分
1. 按 CS01→CS07 的依赖逐卡领取,只加载当前一张卡;先定位 issue_barrier 的真实消费者。
2. 补齐 buffer barrier、ShaderCreateInfo ABI、数组/共享类型、资源 binding 和实际设备限制。
3. 补齐 owner 生命周期、dirty/version、CPU/GPU 内容同步、resize/copy/clear、多输出原子提交及别名限制。
4. 将 GPU_compute_dispatch_indirect 接到现有 broker;与已经实现的 GPU_batch_draw_indirect 明确区分。
5. 补齐光栅 SSBO 消费和曲线生产,并贯通 Manager resource finalize/visibility/command generation;保留可复用原生分支。
6. 只扩展真实工作流所需 shader/resource,记录每个尚不能表达的消费者;图像 compute 由 DW16 接续。
compute 专项引用:`CS01`, `CS02`, `CS03`, `CS04`, `CS05`, `CS06`, `CS07`。卡位于 `docs/tasks/WBV2-P1424-001-compute-ssbo/`;一次只读当前一张,既有实现不重复,状态依据后续真实交接更新。CS09 在 DW19 负责消费者,CS12 在 DW26 负责原生 Python 入口,CS13/CS14 分别归 DW31/USER01;不要另起平行路线。
## 失败边界
不能清空 guard 伪造 GPU 支持。几何算法继续统一 OCCT;显示缓存的原生 shader 移植不能扩张为另一套建模内核。
## 实现交接与后续使用
交付前必须具有实际入口→原生执行→消费者/结果→错误/取消→适用 history/save 的生产代码。这里是实现交付条件,不运行验收;编译成功不能替代功能。旧的已完成子项可引用并保留,不能声称本轮重新实现。
用户使用阶段的场景(现在不执行):编辑曲线/对象后视口连续重绘,资源更新、可见性和实例绘制均来自实际原生生产者。
每次记录保留成果、补齐断点、仍有缺口、必要构件与下一动作。共同规则见同目录 `EXECUTION.md`,首次领取时阅读;不要将完整计划作为后续执行上下文。