wgpu icon indicating copy to clipboard operation
wgpu copied to clipboard

Bind group and layout entries should be optional

Open nical opened this issue 2 years ago • 7 comments

Spec:

  • https://gpuweb.github.io/gpuweb/#gpubindingcommandsmixin-setbindgroup
  • https://www.w3.org/TR/webgpu/#dom-gpupipelinelayoutdescriptor-bindgrouplayouts

Bind group layouts and bind groups should be nullable, which in Rust parlance means we should take an Option of them. This lets app authors “unset” a bind group at an index.

nical avatar Nov 21 '23 15:11 nical

It's unclear what the underlying platform APIs' expectations are around removing bindgroups, so we're going to need to investigate this a bit before we can tell how much work it will be.

jimblandy avatar Dec 15 '23 15:12 jimblandy

Relevant spec PR: https://github.com/gpuweb/gpuweb/pull/3938

teoxoy avatar Dec 15 '23 15:12 teoxoy

this got fixed in

  • https://github.com/gfx-rs/wgpu/pull/6216

Wumpf avatar Nov 19 '24 22:11 Wumpf

ah I spoke too soon, HAL doesn't handle this yet it seems?

Wumpf avatar Nov 19 '24 22:11 Wumpf

Note that this should include optional PipelineLayoutDescriptor::bind_group_layouts.

ETA: Folded into OP.

ErichDonGubler avatar Oct 06 '25 15:10 ErichDonGubler

Firefox downstream tracking: bug 1992771

ErichDonGubler avatar Oct 06 '25 15:10 ErichDonGubler

Also discussed in #1489. (I am not going to mark a duplicate right now because there is some discussion in both issues that might be worth consolidating.)

andyleiserson avatar Dec 05 '25 19:12 andyleiserson