Keep CMake module names and trim switches, but stop flattening editing/editor and runtime bridges as top-level src/modules directories. Parent scans skip nested facets so runtime-3d can drop authoring by directory leaf.
Co-authored-by: Cursor <cursoragent@cursor.com>
Add a systematic C++ wrapper layer for the WebGPU backend, mirroring the
vulkan backend's vkbuilder patterns so invalid API usage is rejected at
compile time / type level instead of via scattered runtime flags.
New layer (src/modules/graphics/webgpu/):
- wgpu_types.h: cross-platform webgpu_cpp.h include + sv() helpers
- Capabilities: read-only snapshot of adapter/device limits (GetLimits),
sample-count/format/bind-group predicates
- InitFlow: typed Instance->Adapter->Device state machine wrapping the async
request + ProcessEvents busy-wait (skipping a step is a compile error)
- SamplerBuilder/BindGroupLayoutBuilder/PipelineBuilder: build the C++ wrapper
descriptors directly (zero-init == WebGPU defaults), eliminating the
writeMask=0 / sampleMask=0 / alphaMode default-mask traps
Graphics.cpp migration:
- initHeadless/initWithWindow now drive InitFlow; drop the 4 std::atomic<bool>
flags, waitForAdapter/Device, createInstanceAndAdapter/requestDevice
- convert 8 bind-group-layout, 7 pipeline-layout, 3 2D-pipeline functions and
makeWgslModule to build C++ wrapper descriptors directly (reinterpret_cast
127 -> 114; remaining texture/buffer/renderpass conversions deferred)
Design spec: docs/dev/superpowers/specs/2026-08-26-webgpu-vkbuilder-style-cpp-layer.md
Verified: build/webgpu-native (native Dawn, MSVC Debug+Ninja) compiles and
links eve.exe (1633/1633). SSAO/decal stub-tightening (PR4) was dropped as
obsolete - dev already has real implementations.