gpu: update to latest webgpu.h API

Signed-off-by: Stephen Gutekanst <stephen@hexops.com>
This commit is contained in:
Stephen Gutekanst 2023-06-18 20:18:39 -07:00 committed by Stephen Gutekanst
parent 74067bebed
commit fdd3270a0f
22 changed files with 201 additions and 161 deletions

View file

@ -13,12 +13,10 @@ pub const SwapChain = opaque {
width: u32,
height: u32,
present_mode: PresentMode,
/// deprecated
implementation: u64 = 0,
};
pub inline fn configure(swap_chain: *SwapChain, format: Texture.Format, allowed_usage: Texture.UsageFlags, width: u32, height: u32) void {
Impl.swapChainConfigure(swap_chain, format, allowed_usage, width, height);
pub inline fn getCurrentTexture(swap_chain: *SwapChain) ?*Texture {
return Impl.swapChainGetCurrentTexture(swap_chain);
}
pub inline fn getCurrentTextureView(swap_chain: *SwapChain) ?*TextureView {