gpu: add QuerySet.Descriptor

Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
Stephen Gutekanst 2022-03-11 16:27:16 -07:00 committed by Stephen Gutekanst
parent d19c868fb6
commit 4ae4ef4e14
2 changed files with 10 additions and 9 deletions

View file

@ -1,3 +1,5 @@
const PipelineStatistic = @import("enums.zig").PipelineStatistic;
const QuerySet = @This();
/// The type erased pointer to the QuerySet implementation
@ -28,9 +30,17 @@ pub inline fn destroy(qset: QuerySet) void {
qset.vtable.destroy(qset.ptr);
}
pub const Descriptor = struct {
label: ?[*:0]const u8 = null,
type: QueryType,
count: u32,
pipeline_statistics: []PipelineStatistic,
};
test "syntax" {
_ = VTable;
_ = reference;
_ = release;
_ = destroy;
_ = Descriptor;
}

View file

@ -57,15 +57,6 @@ typedef struct WGPUDawnTogglesDeviceDescriptor {
typedef struct WGPUQuerySetDescriptor {
WGPUChainedStruct const * nextInChain;
char const * label;
WGPUQueryType type;
uint32_t count;
WGPUPipelineStatisticName const * pipelineStatistics;
uint32_t pipelineStatisticsCount;
} WGPUQuerySetDescriptor;
typedef struct WGPURenderBundleEncoderDescriptor {
WGPUChainedStruct const * nextInChain;
char const * label;