WebGPU bindings are broken in 2.21.0
- Dominant language
- C#
- Stars
- 5.2k
- Forks
- 477
- Avg merge
- 3d 16h
- Merged PRs (30d)
- 2
Description
# Summary
As far as I can tell, the WebGPU bindings are not correctly marshalling `RenderPassColorAttachment.LoadOp` (and possibly others, like `StoreOp`).
On 2.20.0, it works as expected.
On 2.21.0, the WGPU implementation panics with:
```
thread '' panicked at src/lib.rs:1184:38:
invalid load op for render pass color attachment: 0
stack backtrace:
0: _rust_begin_unwind
1: core::panicking::panic_fmt
2: core::result::unwrap_failed
3: as core::iter::traits::iterator::Iterator>::fold
4: as alloc::vec::spec_from_iter::SpecFromIter>::from_iter
5: _wgpuCommandEncoderBeginRenderPass
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
fatal runtime error: failed to initiate panic, error 5
```
# Steps to reproduce
Here is a minimal reproduction, which is supposed to clear the backbuffer with a magenta colour: https://gist.github.com/smoogipoo/0e248fe961cc3f42930c6091eb1bd18e
- Platform: macOS, desktop
- Framework Version: .NET Core 8
- API: WebGPU / WGPU
Contributor guide
Assessment
This issue has not been assessed yet.