Files
workinf_Blender_Wasm/docs/tasks/WBV2-P1424-001-compute-ssbo/CS09.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

53 lines
3.2 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.
# CS09:Compositor 原生图像 compute 业务闭环
- queueTask: WBV2-P1424-001
- parentTask: WBV2-P1424-000
- packageStatus: planned
- dependsOn: CS08
- validation: NOT_RUN;acceptance: NOT_CLAIMED
## 业务与交付
原生合成节点树求值 → ShaderOperation → compute → Result → Viewer/图像编辑器
第二类完整业务:原生节点计算得到用户可见图像,复用原节点语义及 compute 后端。
## 最小输入与源码依据
- `blender-5.2.0/source/blender/compositor/intern/shader_operation.cc`
- `blender-5.2.0/source/blender/compositor/intern/utilities.cc`
- `blender-5.2.0/source/blender/compositor/intern/result.cc`
- `blender-5.2.0/source/blender/compositor/COM_result.hh`
- `blender-5.2.0/source/blender/gpu/webgl/webgl_texture.cc`
- ShaderOperation 的原生入口调用 compute_dispatch_threads_at_least;utilities.cc:254 转至 GPU_compute_dispatch。
- Result 的原生 texture 绑定/读取依赖 texture/image barriers。
## 实现步骤
1. 从上述原生入口选择已注册的最小单输入图像操作,领取时追加读取该节点唯一实现/ShaderCreateInfo,记录精确节点 ID;不预造一个测试 kernel 代替原节点。
2. 接通输入图像、domain/data_size、默认单值、边界像素、输出 format 与 Result 资源释放。
3. 将真实结果送回现有原生 Viewer/图像编辑器,处理参数修改、取消、重复执行、撤销/重做与重新打开后的重建。
4. 按当前图像业务再扩展多输入、多 pass 与混合 buffer/image 操作;其余 compositor/EEVEE caller 保留明确未完成条目。
## 失败边界
仅 texture upload 成功或前端 Canvas 画图不能计为 compositor 实现。
发生阻塞时记录具体业务、原生函数/create-info、producer/consumer 和下一修复动作;保留既有产物,继续无此依赖的实现卡,不用缺失证据作为实现阻塞。
## 延后的用户场景(当前不执行)
- 同一节点参数改变时 Viewer 更新
- 奇数尺寸/边界/单值输入
- 节点中途取消
- 保存重开保留节点树且重新生产派生资源
没有在本次拆解中创建或运行测试 fixture。原生 shader、现有模板和真实业务数据是实现输入;需要新增用户使用 fixture 时在全项目实现完成后安排。
## 交接
每次报告填写:实际 workflow/route、源码函数与修改、仍未实现接口、产物元数据(仅生成时)、失败/no-mutation 策略、implementation 状态、validation=NOT_RUN、acceptance=NOT_CLAIMED、下一实现动作。记录 unitCount/verifiedUnits/unverifiedUnits/sourceTreeSha256 的来源;未绑定/未验证不增记覆盖。
执行约束:本卡属于 WBV2-P1424-001 / parent WBV2-P1424-000,nextTask=null 保持不变。全部功能实现前不执行测试、回归、冒烟、浏览器验收、类型/语法/上下文检查或证据审计。仅为产物生成进行必要增量编译。源码检索使用 tools/web/search-wbv2-batch-source.mjs 的精确 --source/--unit;GLSL fixture 只读取本卡列出的原文件。不加载完整专项规划、历史日志或源码 inventory。JS 仅承担浏览器 API/传输;几何算法仍使用 OCCT 出口,Three.js 仅显示。