Harbor

Changelog be0ab34d13d5

test and document stencil contract

@sky · 1 month ago · parent deb9b627f663
0 added 2 modified 0 deleted
docs/gpu_intent_api.md +2 -2 modified
207 unchanged lines hidden
208 208
209 209 Targets can be present or offscreen. Target desc owns size, format, load/store, clear values, and sample/present usage.
210 210
211 - Clips start with rect/scissor. Mask/stencil clips can be added later behind the same `Clip_Handle`.
211 + Clips start with rect/scissor. Mask clips are semantic `Clip_Handle` records whose source is geometry coverage rendered into stencil. The backend stencil contract exists below the IR: render pass descriptors carry stencil load/store, packed depth-stencil formats expose a stencil aspect, pipeline state carries front/back compare/ops/masks/ref, and each backend maps that state to native stencil state. Planned mask lowering and proof scenes are still pending.
212 212
213 213 `gpu` may drop packets fully outside target bounds or clip bounds. It must not decide semantic hidden state.
214 214
15 unchanged lines hidden
230 230
231 231 - `max_color_targets` reports the implemented color attachment count. Vulkan, D3D11, D3D12, and OpenGL currently report `8` because planned IR lowering, render pass/framebuffer arrays, pipeline color-attachment metadata, and backend RTV/FBO/render-pass binding support are implemented across all targets.
232 232 - `max_push_constant_size` reports the implemented push-constant byte limit for the selected backend. Pipeline and compute-shader creation must reject sizes above this limit.
233 - - `Multiple_Render_Targets` and `Indirect_Draws` are implemented for the planned backend path. Mask clip IR exists as a semantic model for geometry coverage rendered into stencil, but `Stencil_Clips` remains false until stencil attachment/state plumbing, backend lowering, and parity proof exist across all backends. Texture-alpha/discard masking does not count as stencil clipping.
233 + - `Multiple_Render_Targets` and `Indirect_Draws` are implemented for the planned backend path. Mask clip IR and backend stencil descriptor/state plumbing exist, but `Stencil_Clips` remains false until planned mask lowering, synchronization diagnostics, visual proof scenes, and runtime matrix rows pass across all required backends. Texture-alpha/discard masking does not count as stencil clipping.
234 234
235 235 Public API must not expose Vulkan/D3D-specific terms except through backend-only layers.
236 236
28 unchanged lines hidden
tests/compiler_executor_test.odin modified

Diff hidden because this file has more than 800 lines.