mirror of
https://github.com/storytold/wgpu.git
synced 2026-11-21 06:50:59 +01:00
736: Validate sampler type in `create_bind_group` r=kvark a=GabrielMajeri **Connections** Fixes #588 **Description** * Makes `create_bind_group` return a `Result`, and adds a new `binding_model::BindGroupError` enum. * Converts _some_ assertions from `create_bind_group` into `Err`s * Validates that the type of sampler declared in the bind group layout (comparison or not) is the same as the one of the actual sampler. **Testing** Tested locally on the `shadow` example in `wgpu-rs`. ~Will follow up with a PR in that repo with the updated API.~ https://github.com/gfx-rs/wgpu-rs/pull/398 Co-authored-by: Gabriel Majeri <gabriel.majeri6@gmail.com>