diff --git a/gpu/src/RenderBundleEncoder.zig b/gpu/src/RenderBundleEncoder.zig index a4a5ecdd..44a0face 100644 --- a/gpu/src/RenderBundleEncoder.zig +++ b/gpu/src/RenderBundleEncoder.zig @@ -1,3 +1,5 @@ +const Texture = @import("Texture.zig"); + const RenderBundleEncoder = @This(); /// The type erased pointer to the RenderBundleEncoder implementation @@ -36,8 +38,18 @@ pub inline fn setLabel(enc: RenderBundleEncoder, label: [:0]const u8) void { enc.vtable.setLabel(enc.ptr, label); } +pub const Descriptor = struct { + label: ?[*:0]const u8 = null, + color_formats: []Texture.Format, + depth_stencil_format: Texture.Format, + sample_count: u32, + depth_read_only: bool, + stencil_read_only: bool, +}; + test "syntax" { _ = VTable; _ = reference; _ = release; + _ = Descriptor; } diff --git a/gpu/src/TODO b/gpu/src/TODO index f4dc4bee..2455d226 100644 --- a/gpu/src/TODO +++ b/gpu/src/TODO @@ -57,17 +57,6 @@ typedef struct WGPUDawnTogglesDeviceDescriptor { -typedef struct WGPURenderBundleEncoderDescriptor { - WGPUChainedStruct const * nextInChain; - char const * label; - uint32_t colorFormatsCount; - WGPUTextureFormat const * colorFormats; - WGPUTextureFormat depthStencilFormat; - uint32_t sampleCount; - bool depthReadOnly; - bool stencilReadOnly; -} WGPURenderBundleEncoderDescriptor; - typedef struct WGPUSamplerDescriptor { WGPUChainedStruct const * nextInChain; char const * label;