gpu: Default values for BindGroup.Entry (#214)
simplifies creating BindGroup - all resources are null by default and the user sets only the one needed. Helps hexops/mach#182
This commit is contained in:
parent
9ed6f6ca8b
commit
8c8534e609
1 changed files with 4 additions and 4 deletions
|
|
@ -30,11 +30,11 @@ pub inline fn setLabel(group: BindGroup, label: [:0]const u8) void {
|
|||
|
||||
pub const Entry = struct {
|
||||
binding: u32,
|
||||
buffer: ?Buffer,
|
||||
offset: u64,
|
||||
buffer: ?Buffer = null,
|
||||
offset: u64 = 0,
|
||||
size: u64,
|
||||
sampler: ?Sampler,
|
||||
texture_view: ?TextureView,
|
||||
sampler: ?Sampler = null,
|
||||
texture_view: ?TextureView = null,
|
||||
};
|
||||
|
||||
pub const Descriptor = struct {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue