gpu: add QuerySet.setLabel
Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
parent
e128d38e86
commit
48907f4404
2 changed files with 10 additions and 1 deletions
|
|
@ -671,6 +671,11 @@ const query_set_vtable = QuerySet.VTable{
|
|||
c.wgpuQuerySetRelease(@ptrCast(c.WGPUQuerySet, ptr));
|
||||
}
|
||||
}).release,
|
||||
.setLabel = (struct {
|
||||
pub fn setLabel(ptr: *anyopaque, label: [:0]const u8) void {
|
||||
c.wgpuQuerySetSetLabel(@ptrCast(c.WGPUQuerySet, ptr), label);
|
||||
}
|
||||
}).setLabel,
|
||||
};
|
||||
|
||||
fn wrapPipelineLayout(layout: c.WGPUPipelineLayout) PipelineLayout {
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@ pub const VTable = struct {
|
|||
release: fn (ptr: *anyopaque) void,
|
||||
// TODO:
|
||||
// WGPU_EXPORT void wgpuQuerySetDestroy(WGPUQuerySet querySet);
|
||||
// WGPU_EXPORT void wgpuQuerySetSetLabel(WGPUQuerySet querySet, char const * label);
|
||||
setLabel: fn (ptr: *anyopaque, label: [:0]const u8) void,
|
||||
};
|
||||
|
||||
pub inline fn reference(qset: QuerySet) void {
|
||||
|
|
@ -21,6 +21,10 @@ pub inline fn release(qset: QuerySet) void {
|
|||
qset.vtable.release(qset.ptr);
|
||||
}
|
||||
|
||||
pub inline fn setLabel(qset: QuerySet, label: [:0]const u8) void {
|
||||
qset.vtable.setLabel(qset.ptr, label);
|
||||
}
|
||||
|
||||
test "syntax" {
|
||||
_ = VTable;
|
||||
_ = reference;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue