diff --git a/gpu/TODO-webgpu.h b/gpu/TODO-webgpu.h index 59c2f836..69750609 100644 --- a/gpu/TODO-webgpu.h +++ b/gpu/TODO-webgpu.h @@ -1,8 +1,3 @@ -typedef struct WGPUDawnTextureInternalUsageDescriptor { - WGPUChainedStruct chain; - WGPUTextureUsageFlags internalUsage; -} WGPUDawnTextureInternalUsageDescriptor; - typedef struct WGPUDawnTogglesDeviceDescriptor { WGPUChainedStruct chain; uint32_t forceEnabledTogglesCount; diff --git a/gpu/src/dawn.zig b/gpu/src/dawn.zig index fd44ae7a..7b485334 100644 --- a/gpu/src/dawn.zig +++ b/gpu/src/dawn.zig @@ -1,4 +1,5 @@ const ChainedStruct = @import("types.zig").ChainedStruct; +const Texture = @import("texture.zig").Texture; pub const CacheDeviceDescriptor = struct { // TODO: file an issue on Dawn: why not named nextInChain? @@ -18,3 +19,9 @@ pub const InstanceDescriptor = extern struct { additional_runtime_search_paths_count: u32, additional_runtime_search_paths: [*]const u8, }; + +pub const TextureInternalUsageDescriptor = extern struct { + // TODO: file an issue on Dawn: why not named nextInChain? + chain: ChainedStruct, + internal_usage: Texture.UsageFlags, +};