diff --git a/CHANGELOG.md b/CHANGELOG.md
new file mode 100644
--- /dev/null
+++ b/CHANGELOG.md
@@ -0,0 +1,8 @@
+# Revision history for wgpu-raw-hs
+
+## 0.1.0.0 -- 2021-08-15
+
+- Initial version. 
+  - Mostly auto-generated bindings to the raw C API.
+  - Surface creation for Metal on macOS.
+  - Basic triangle example is kind-of working.
diff --git a/cbits/surface-macos.m b/cbits/surface-macos.m
new file mode 100644
--- /dev/null
+++ b/cbits/surface-macos.m
@@ -0,0 +1,15 @@
+/*
+ * Surface handling for Metal on macOS.
+ */
+
+#include <AppKit/AppKit.h>
+#include <Foundation/Foundation.h>
+#include <QuartzCore/CAMetalLayer.h>
+
+void *wgpuhs_metal_layer(NSWindow *ns_window) {
+  id metal_layer = NULL;
+  [ns_window.contentView setWantsLayer:YES];
+  metal_layer = [CAMetalLayer layer];
+  [ns_window.contentView setLayer:metal_layer];
+  return metal_layer;
+}
diff --git a/cbits/webgpu-headers/webgpu.h b/cbits/webgpu-headers/webgpu.h
new file mode 100644
--- /dev/null
+++ b/cbits/webgpu-headers/webgpu.h
@@ -0,0 +1,1214 @@
+// BSD 3-Clause License
+//
+// Copyright (c) 2019, "WebGPU native" developers
+// All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without
+// modification, are permitted provided that the following conditions are met:
+//
+// 1. Redistributions of source code must retain the above copyright notice, this
+//    list of conditions and the following disclaimer.
+//
+// 2. Redistributions in binary form must reproduce the above copyright notice,
+//    this list of conditions and the following disclaimer in the documentation
+//    and/or other materials provided with the distribution.
+//
+// 3. Neither the name of the copyright holder nor the names of its
+//    contributors may be used to endorse or promote products derived from
+//    this software without specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+// AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
+// FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+// DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+// CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+// OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#ifndef WEBGPU_H_
+#define WEBGPU_H_
+
+#if defined(WGPU_SHARED_LIBRARY)
+#    if defined(_WIN32)
+#        if defined(WGPU_IMPLEMENTATION)
+#            define WGPU_EXPORT __declspec(dllexport)
+#        else
+#            define WGPU_EXPORT __declspec(dllimport)
+#        endif
+#    else  // defined(_WIN32)
+#        if defined(WGPU_IMPLEMENTATION)
+#            define WGPU_EXPORT __attribute__((visibility("default")))
+#        else
+#            define WGPU_EXPORT
+#        endif
+#    endif  // defined(_WIN32)
+#else       // defined(WGPU_SHARED_LIBRARY)
+#    define WGPU_EXPORT
+#endif  // defined(WGPU_SHARED_LIBRARY)
+
+#include <stdint.h>
+#include <stddef.h>
+#include <stdbool.h>
+
+#define WGPU_WHOLE_SIZE (0xffffffffffffffffULL)
+#define WGPU_COPY_STRIDE_UNDEFINED (0xffffffffUL)
+
+typedef uint32_t WGPUFlags;
+
+typedef struct WGPUAdapterImpl* WGPUAdapter;
+typedef struct WGPUBindGroupImpl* WGPUBindGroup;
+typedef struct WGPUBindGroupLayoutImpl* WGPUBindGroupLayout;
+typedef struct WGPUBufferImpl* WGPUBuffer;
+typedef struct WGPUCommandBufferImpl* WGPUCommandBuffer;
+typedef struct WGPUCommandEncoderImpl* WGPUCommandEncoder;
+typedef struct WGPUComputePassEncoderImpl* WGPUComputePassEncoder;
+typedef struct WGPUComputePipelineImpl* WGPUComputePipeline;
+typedef struct WGPUDeviceImpl* WGPUDevice;
+typedef struct WGPUInstanceImpl* WGPUInstance;
+typedef struct WGPUPipelineLayoutImpl* WGPUPipelineLayout;
+typedef struct WGPUQuerySetImpl* WGPUQuerySet;
+typedef struct WGPUQueueImpl* WGPUQueue;
+typedef struct WGPURenderBundleImpl* WGPURenderBundle;
+typedef struct WGPURenderBundleEncoderImpl* WGPURenderBundleEncoder;
+typedef struct WGPURenderPassEncoderImpl* WGPURenderPassEncoder;
+typedef struct WGPURenderPipelineImpl* WGPURenderPipeline;
+typedef struct WGPUSamplerImpl* WGPUSampler;
+typedef struct WGPUShaderModuleImpl* WGPUShaderModule;
+typedef struct WGPUSurfaceImpl* WGPUSurface;
+typedef struct WGPUSwapChainImpl* WGPUSwapChain;
+typedef struct WGPUTextureImpl* WGPUTexture;
+typedef struct WGPUTextureViewImpl* WGPUTextureView;
+
+typedef enum WGPUAdapterType {
+    WGPUAdapterType_DiscreteGPU = 0x00000000,
+    WGPUAdapterType_IntegratedGPU = 0x00000001,
+    WGPUAdapterType_CPU = 0x00000002,
+    WGPUAdapterType_Unknown = 0x00000003,
+    WGPUAdapterType_Force32 = 0x7FFFFFFF
+} WGPUAdapterType;
+
+typedef enum WGPUAddressMode {
+    WGPUAddressMode_Repeat = 0x00000000,
+    WGPUAddressMode_MirrorRepeat = 0x00000001,
+    WGPUAddressMode_ClampToEdge = 0x00000002,
+    WGPUAddressMode_Force32 = 0x7FFFFFFF
+} WGPUAddressMode;
+
+typedef enum WGPUBackendType {
+    WGPUBackendType_Null = 0x00000000,
+    WGPUBackendType_D3D11 = 0x00000001,
+    WGPUBackendType_D3D12 = 0x00000002,
+    WGPUBackendType_Metal = 0x00000003,
+    WGPUBackendType_Vulkan = 0x00000004,
+    WGPUBackendType_OpenGL = 0x00000005,
+    WGPUBackendType_OpenGLES = 0x00000006,
+    WGPUBackendType_Force32 = 0x7FFFFFFF
+} WGPUBackendType;
+
+typedef enum WGPUBlendFactor {
+    WGPUBlendFactor_Zero = 0x00000000,
+    WGPUBlendFactor_One = 0x00000001,
+    WGPUBlendFactor_Src = 0x00000002,
+    WGPUBlendFactor_OneMinusSrc = 0x00000003,
+    WGPUBlendFactor_SrcAlpha = 0x00000004,
+    WGPUBlendFactor_OneMinusSrcAlpha = 0x00000005,
+    WGPUBlendFactor_Dst = 0x00000006,
+    WGPUBlendFactor_OneMinusDst = 0x00000007,
+    WGPUBlendFactor_DstAlpha = 0x00000008,
+    WGPUBlendFactor_OneMinusDstAlpha = 0x00000009,
+    WGPUBlendFactor_SrcAlphaSaturated = 0x0000000A,
+    WGPUBlendFactor_Constant = 0x0000000B,
+    WGPUBlendFactor_OneMinusConstant = 0x0000000C,
+    WGPUBlendFactor_Force32 = 0x7FFFFFFF
+} WGPUBlendFactor;
+
+typedef enum WGPUBlendOperation {
+    WGPUBlendOperation_Add = 0x00000000,
+    WGPUBlendOperation_Subtract = 0x00000001,
+    WGPUBlendOperation_ReverseSubtract = 0x00000002,
+    WGPUBlendOperation_Min = 0x00000003,
+    WGPUBlendOperation_Max = 0x00000004,
+    WGPUBlendOperation_Force32 = 0x7FFFFFFF
+} WGPUBlendOperation;
+
+typedef enum WGPUBufferBindingType {
+    WGPUBufferBindingType_Undefined = 0x00000000,
+    WGPUBufferBindingType_Uniform = 0x00000001,
+    WGPUBufferBindingType_Storage = 0x00000002,
+    WGPUBufferBindingType_ReadOnlyStorage = 0x00000003,
+    WGPUBufferBindingType_Force32 = 0x7FFFFFFF
+} WGPUBufferBindingType;
+
+typedef enum WGPUBufferMapAsyncStatus {
+    WGPUBufferMapAsyncStatus_Success = 0x00000000,
+    WGPUBufferMapAsyncStatus_Error = 0x00000001,
+    WGPUBufferMapAsyncStatus_Unknown = 0x00000002,
+    WGPUBufferMapAsyncStatus_DeviceLost = 0x00000003,
+    WGPUBufferMapAsyncStatus_DestroyedBeforeCallback = 0x00000004,
+    WGPUBufferMapAsyncStatus_UnmappedBeforeCallback = 0x00000005,
+    WGPUBufferMapAsyncStatus_Force32 = 0x7FFFFFFF
+} WGPUBufferMapAsyncStatus;
+
+typedef enum WGPUCompareFunction {
+    WGPUCompareFunction_Undefined = 0x00000000,
+    WGPUCompareFunction_Never = 0x00000001,
+    WGPUCompareFunction_Less = 0x00000002,
+    WGPUCompareFunction_LessEqual = 0x00000003,
+    WGPUCompareFunction_Greater = 0x00000004,
+    WGPUCompareFunction_GreaterEqual = 0x00000005,
+    WGPUCompareFunction_Equal = 0x00000006,
+    WGPUCompareFunction_NotEqual = 0x00000007,
+    WGPUCompareFunction_Always = 0x00000008,
+    WGPUCompareFunction_Force32 = 0x7FFFFFFF
+} WGPUCompareFunction;
+
+typedef enum WGPUCreatePipelineAsyncStatus {
+    WGPUCreatePipelineAsyncStatus_Success = 0x00000000,
+    WGPUCreatePipelineAsyncStatus_Error = 0x00000001,
+    WGPUCreatePipelineAsyncStatus_DeviceLost = 0x00000002,
+    WGPUCreatePipelineAsyncStatus_DeviceDestroyed = 0x00000003,
+    WGPUCreatePipelineAsyncStatus_Unknown = 0x00000004,
+    WGPUCreatePipelineAsyncStatus_Force32 = 0x7FFFFFFF
+} WGPUCreatePipelineAsyncStatus;
+
+typedef enum WGPUCullMode {
+    WGPUCullMode_None = 0x00000000,
+    WGPUCullMode_Front = 0x00000001,
+    WGPUCullMode_Back = 0x00000002,
+    WGPUCullMode_Force32 = 0x7FFFFFFF
+} WGPUCullMode;
+
+typedef enum WGPUErrorFilter {
+    WGPUErrorFilter_None = 0x00000000,
+    WGPUErrorFilter_Validation = 0x00000001,
+    WGPUErrorFilter_OutOfMemory = 0x00000002,
+    WGPUErrorFilter_Force32 = 0x7FFFFFFF
+} WGPUErrorFilter;
+
+typedef enum WGPUErrorType {
+    WGPUErrorType_NoError = 0x00000000,
+    WGPUErrorType_Validation = 0x00000001,
+    WGPUErrorType_OutOfMemory = 0x00000002,
+    WGPUErrorType_Unknown = 0x00000003,
+    WGPUErrorType_DeviceLost = 0x00000004,
+    WGPUErrorType_Force32 = 0x7FFFFFFF
+} WGPUErrorType;
+
+typedef enum WGPUFilterMode {
+    WGPUFilterMode_Nearest = 0x00000000,
+    WGPUFilterMode_Linear = 0x00000001,
+    WGPUFilterMode_Force32 = 0x7FFFFFFF
+} WGPUFilterMode;
+
+typedef enum WGPUFrontFace {
+    WGPUFrontFace_CCW = 0x00000000,
+    WGPUFrontFace_CW = 0x00000001,
+    WGPUFrontFace_Force32 = 0x7FFFFFFF
+} WGPUFrontFace;
+
+typedef enum WGPUIndexFormat {
+    WGPUIndexFormat_Undefined = 0x00000000,
+    WGPUIndexFormat_Uint16 = 0x00000001,
+    WGPUIndexFormat_Uint32 = 0x00000002,
+    WGPUIndexFormat_Force32 = 0x7FFFFFFF
+} WGPUIndexFormat;
+
+typedef enum WGPUInputStepMode {
+    WGPUInputStepMode_Vertex = 0x00000000,
+    WGPUInputStepMode_Instance = 0x00000001,
+    WGPUInputStepMode_Force32 = 0x7FFFFFFF
+} WGPUInputStepMode;
+
+typedef enum WGPULoadOp {
+    WGPULoadOp_Clear = 0x00000000,
+    WGPULoadOp_Load = 0x00000001,
+    WGPULoadOp_Force32 = 0x7FFFFFFF
+} WGPULoadOp;
+
+typedef enum WGPUPipelineStatisticName {
+    WGPUPipelineStatisticName_VertexShaderInvocations = 0x00000000,
+    WGPUPipelineStatisticName_ClipperInvocations = 0x00000001,
+    WGPUPipelineStatisticName_ClipperPrimitivesOut = 0x00000002,
+    WGPUPipelineStatisticName_FragmentShaderInvocations = 0x00000003,
+    WGPUPipelineStatisticName_ComputeShaderInvocations = 0x00000004,
+    WGPUPipelineStatisticName_Force32 = 0x7FFFFFFF
+} WGPUPipelineStatisticName;
+
+typedef enum WGPUPresentMode {
+    WGPUPresentMode_Immediate = 0x00000000,
+    WGPUPresentMode_Mailbox = 0x00000001,
+    WGPUPresentMode_Fifo = 0x00000002,
+    WGPUPresentMode_Force32 = 0x7FFFFFFF
+} WGPUPresentMode;
+
+typedef enum WGPUPrimitiveTopology {
+    WGPUPrimitiveTopology_PointList = 0x00000000,
+    WGPUPrimitiveTopology_LineList = 0x00000001,
+    WGPUPrimitiveTopology_LineStrip = 0x00000002,
+    WGPUPrimitiveTopology_TriangleList = 0x00000003,
+    WGPUPrimitiveTopology_TriangleStrip = 0x00000004,
+    WGPUPrimitiveTopology_Force32 = 0x7FFFFFFF
+} WGPUPrimitiveTopology;
+
+typedef enum WGPUQueryType {
+    WGPUQueryType_Occlusion = 0x00000000,
+    WGPUQueryType_PipelineStatistics = 0x00000001,
+    WGPUQueryType_Timestamp = 0x00000002,
+    WGPUQueryType_Force32 = 0x7FFFFFFF
+} WGPUQueryType;
+
+typedef enum WGPUQueueWorkDoneStatus {
+    WGPUQueueWorkDoneStatus_Success = 0x00000000,
+    WGPUQueueWorkDoneStatus_Error = 0x00000001,
+    WGPUQueueWorkDoneStatus_Unknown = 0x00000002,
+    WGPUQueueWorkDoneStatus_DeviceLost = 0x00000003,
+    WGPUQueueWorkDoneStatus_Force32 = 0x7FFFFFFF
+} WGPUQueueWorkDoneStatus;
+
+typedef enum WGPUSType {
+    WGPUSType_Invalid = 0x00000000,
+    WGPUSType_SurfaceDescriptorFromMetalLayer = 0x00000001,
+    WGPUSType_SurfaceDescriptorFromWindowsHWND = 0x00000002,
+    WGPUSType_SurfaceDescriptorFromXlib = 0x00000003,
+    WGPUSType_SurfaceDescriptorFromCanvasHTMLSelector = 0x00000004,
+    WGPUSType_ShaderModuleSPIRVDescriptor = 0x00000005,
+    WGPUSType_ShaderModuleWGSLDescriptor = 0x00000006,
+    WGPUSType_PrimitiveDepthClampingState = 0x00000007,
+    WGPUSType_Force32 = 0x7FFFFFFF
+} WGPUSType;
+
+typedef enum WGPUSamplerBindingType {
+    WGPUSamplerBindingType_Undefined = 0x00000000,
+    WGPUSamplerBindingType_Filtering = 0x00000001,
+    WGPUSamplerBindingType_NonFiltering = 0x00000002,
+    WGPUSamplerBindingType_Comparison = 0x00000003,
+    WGPUSamplerBindingType_Force32 = 0x7FFFFFFF
+} WGPUSamplerBindingType;
+
+typedef enum WGPUStencilOperation {
+    WGPUStencilOperation_Keep = 0x00000000,
+    WGPUStencilOperation_Zero = 0x00000001,
+    WGPUStencilOperation_Replace = 0x00000002,
+    WGPUStencilOperation_Invert = 0x00000003,
+    WGPUStencilOperation_IncrementClamp = 0x00000004,
+    WGPUStencilOperation_DecrementClamp = 0x00000005,
+    WGPUStencilOperation_IncrementWrap = 0x00000006,
+    WGPUStencilOperation_DecrementWrap = 0x00000007,
+    WGPUStencilOperation_Force32 = 0x7FFFFFFF
+} WGPUStencilOperation;
+
+typedef enum WGPUStorageTextureAccess {
+    WGPUStorageTextureAccess_Undefined = 0x00000000,
+    WGPUStorageTextureAccess_ReadOnly = 0x00000001,
+    WGPUStorageTextureAccess_WriteOnly = 0x00000002,
+    WGPUStorageTextureAccess_Force32 = 0x7FFFFFFF
+} WGPUStorageTextureAccess;
+
+typedef enum WGPUStoreOp {
+    WGPUStoreOp_Store = 0x00000000,
+    WGPUStoreOp_Clear = 0x00000001,
+    WGPUStoreOp_Force32 = 0x7FFFFFFF
+} WGPUStoreOp;
+
+typedef enum WGPUTextureAspect {
+    WGPUTextureAspect_All = 0x00000000,
+    WGPUTextureAspect_StencilOnly = 0x00000001,
+    WGPUTextureAspect_DepthOnly = 0x00000002,
+    WGPUTextureAspect_Force32 = 0x7FFFFFFF
+} WGPUTextureAspect;
+
+typedef enum WGPUTextureComponentType {
+    WGPUTextureComponentType_Float = 0x00000000,
+    WGPUTextureComponentType_Sint = 0x00000001,
+    WGPUTextureComponentType_Uint = 0x00000002,
+    WGPUTextureComponentType_DepthComparison = 0x00000003,
+    WGPUTextureComponentType_Force32 = 0x7FFFFFFF
+} WGPUTextureComponentType;
+
+typedef enum WGPUTextureDimension {
+    WGPUTextureDimension_1D = 0x00000000,
+    WGPUTextureDimension_2D = 0x00000001,
+    WGPUTextureDimension_3D = 0x00000002,
+    WGPUTextureDimension_Force32 = 0x7FFFFFFF
+} WGPUTextureDimension;
+
+typedef enum WGPUTextureFormat {
+    WGPUTextureFormat_Undefined = 0x00000000,
+    WGPUTextureFormat_R8Unorm = 0x00000001,
+    WGPUTextureFormat_R8Snorm = 0x00000002,
+    WGPUTextureFormat_R8Uint = 0x00000003,
+    WGPUTextureFormat_R8Sint = 0x00000004,
+    WGPUTextureFormat_R16Uint = 0x00000005,
+    WGPUTextureFormat_R16Sint = 0x00000006,
+    WGPUTextureFormat_R16Float = 0x00000007,
+    WGPUTextureFormat_RG8Unorm = 0x00000008,
+    WGPUTextureFormat_RG8Snorm = 0x00000009,
+    WGPUTextureFormat_RG8Uint = 0x0000000A,
+    WGPUTextureFormat_RG8Sint = 0x0000000B,
+    WGPUTextureFormat_R32Float = 0x0000000C,
+    WGPUTextureFormat_R32Uint = 0x0000000D,
+    WGPUTextureFormat_R32Sint = 0x0000000E,
+    WGPUTextureFormat_RG16Uint = 0x0000000F,
+    WGPUTextureFormat_RG16Sint = 0x00000010,
+    WGPUTextureFormat_RG16Float = 0x00000011,
+    WGPUTextureFormat_RGBA8Unorm = 0x00000012,
+    WGPUTextureFormat_RGBA8UnormSrgb = 0x00000013,
+    WGPUTextureFormat_RGBA8Snorm = 0x00000014,
+    WGPUTextureFormat_RGBA8Uint = 0x00000015,
+    WGPUTextureFormat_RGBA8Sint = 0x00000016,
+    WGPUTextureFormat_BGRA8Unorm = 0x00000017,
+    WGPUTextureFormat_BGRA8UnormSrgb = 0x00000018,
+    WGPUTextureFormat_RGB10A2Unorm = 0x00000019,
+    WGPUTextureFormat_RG11B10Ufloat = 0x0000001A,
+    WGPUTextureFormat_RGB9E5Ufloat = 0x0000001B,
+    WGPUTextureFormat_RG32Float = 0x0000001C,
+    WGPUTextureFormat_RG32Uint = 0x0000001D,
+    WGPUTextureFormat_RG32Sint = 0x0000001E,
+    WGPUTextureFormat_RGBA16Uint = 0x0000001F,
+    WGPUTextureFormat_RGBA16Sint = 0x00000020,
+    WGPUTextureFormat_RGBA16Float = 0x00000021,
+    WGPUTextureFormat_RGBA32Float = 0x00000022,
+    WGPUTextureFormat_RGBA32Uint = 0x00000023,
+    WGPUTextureFormat_RGBA32Sint = 0x00000024,
+    WGPUTextureFormat_Depth32Float = 0x00000025,
+    WGPUTextureFormat_Depth24Plus = 0x00000026,
+    WGPUTextureFormat_Depth24PlusStencil8 = 0x00000027,
+    WGPUTextureFormat_Stencil8 = 0x00000028,
+    WGPUTextureFormat_BC1RGBAUnorm = 0x00000029,
+    WGPUTextureFormat_BC1RGBAUnormSrgb = 0x0000002A,
+    WGPUTextureFormat_BC2RGBAUnorm = 0x0000002B,
+    WGPUTextureFormat_BC2RGBAUnormSrgb = 0x0000002C,
+    WGPUTextureFormat_BC3RGBAUnorm = 0x0000002D,
+    WGPUTextureFormat_BC3RGBAUnormSrgb = 0x0000002E,
+    WGPUTextureFormat_BC4RUnorm = 0x0000002F,
+    WGPUTextureFormat_BC4RSnorm = 0x00000030,
+    WGPUTextureFormat_BC5RGUnorm = 0x00000031,
+    WGPUTextureFormat_BC5RGSnorm = 0x00000032,
+    WGPUTextureFormat_BC6HRGBUfloat = 0x00000033,
+    WGPUTextureFormat_BC6HRGBFloat = 0x00000034,
+    WGPUTextureFormat_BC7RGBAUnorm = 0x00000035,
+    WGPUTextureFormat_BC7RGBAUnormSrgb = 0x00000036,
+    WGPUTextureFormat_Force32 = 0x7FFFFFFF
+} WGPUTextureFormat;
+
+typedef enum WGPUTextureSampleType {
+    WGPUTextureSampleType_Undefined = 0x00000000,
+    WGPUTextureSampleType_Float = 0x00000001,
+    WGPUTextureSampleType_UnfilterableFloat = 0x00000002,
+    WGPUTextureSampleType_Depth = 0x00000003,
+    WGPUTextureSampleType_Sint = 0x00000004,
+    WGPUTextureSampleType_Uint = 0x00000005,
+    WGPUTextureSampleType_Force32 = 0x7FFFFFFF
+} WGPUTextureSampleType;
+
+typedef enum WGPUTextureViewDimension {
+    WGPUTextureViewDimension_Undefined = 0x00000000,
+    WGPUTextureViewDimension_1D = 0x00000001,
+    WGPUTextureViewDimension_2D = 0x00000002,
+    WGPUTextureViewDimension_2DArray = 0x00000003,
+    WGPUTextureViewDimension_Cube = 0x00000004,
+    WGPUTextureViewDimension_CubeArray = 0x00000005,
+    WGPUTextureViewDimension_3D = 0x00000006,
+    WGPUTextureViewDimension_Force32 = 0x7FFFFFFF
+} WGPUTextureViewDimension;
+
+typedef enum WGPUVertexFormat {
+    WGPUVertexFormat_Undefined = 0x00000000,
+    WGPUVertexFormat_Uint8x2 = 0x00000001,
+    WGPUVertexFormat_Uint8x4 = 0x00000002,
+    WGPUVertexFormat_Sint8x2 = 0x00000003,
+    WGPUVertexFormat_Sint8x4 = 0x00000004,
+    WGPUVertexFormat_Unorm8x2 = 0x00000005,
+    WGPUVertexFormat_Unorm8x4 = 0x00000006,
+    WGPUVertexFormat_Snorm8x2 = 0x00000007,
+    WGPUVertexFormat_Snorm8x4 = 0x00000008,
+    WGPUVertexFormat_Uint16x2 = 0x00000009,
+    WGPUVertexFormat_Uint16x4 = 0x0000000A,
+    WGPUVertexFormat_Sint16x2 = 0x0000000B,
+    WGPUVertexFormat_Sint16x4 = 0x0000000C,
+    WGPUVertexFormat_Unorm16x2 = 0x0000000D,
+    WGPUVertexFormat_Unorm16x4 = 0x0000000E,
+    WGPUVertexFormat_Snorm16x2 = 0x0000000F,
+    WGPUVertexFormat_Snorm16x4 = 0x00000010,
+    WGPUVertexFormat_Float16x2 = 0x00000011,
+    WGPUVertexFormat_Float16x4 = 0x00000012,
+    WGPUVertexFormat_Float32 = 0x00000013,
+    WGPUVertexFormat_Float32x2 = 0x00000014,
+    WGPUVertexFormat_Float32x3 = 0x00000015,
+    WGPUVertexFormat_Float32x4 = 0x00000016,
+    WGPUVertexFormat_Uint32 = 0x00000017,
+    WGPUVertexFormat_Uint32x2 = 0x00000018,
+    WGPUVertexFormat_Uint32x3 = 0x00000019,
+    WGPUVertexFormat_Uint32x4 = 0x0000001A,
+    WGPUVertexFormat_Sint32 = 0x0000001B,
+    WGPUVertexFormat_Sint32x2 = 0x0000001C,
+    WGPUVertexFormat_Sint32x3 = 0x0000001D,
+    WGPUVertexFormat_Sint32x4 = 0x0000001E,
+    WGPUVertexFormat_Force32 = 0x7FFFFFFF
+} WGPUVertexFormat;
+
+typedef enum WGPUBufferUsage {
+    WGPUBufferUsage_None = 0x00000000,
+    WGPUBufferUsage_MapRead = 0x00000001,
+    WGPUBufferUsage_MapWrite = 0x00000002,
+    WGPUBufferUsage_CopySrc = 0x00000004,
+    WGPUBufferUsage_CopyDst = 0x00000008,
+    WGPUBufferUsage_Index = 0x00000010,
+    WGPUBufferUsage_Vertex = 0x00000020,
+    WGPUBufferUsage_Uniform = 0x00000040,
+    WGPUBufferUsage_Storage = 0x00000080,
+    WGPUBufferUsage_Indirect = 0x00000100,
+    WGPUBufferUsage_QueryResolve = 0x00000200,
+    WGPUBufferUsage_Force32 = 0x7FFFFFFF
+} WGPUBufferUsage;
+typedef WGPUFlags WGPUBufferUsageFlags;
+
+typedef enum WGPUColorWriteMask {
+    WGPUColorWriteMask_None = 0x00000000,
+    WGPUColorWriteMask_Red = 0x00000001,
+    WGPUColorWriteMask_Green = 0x00000002,
+    WGPUColorWriteMask_Blue = 0x00000004,
+    WGPUColorWriteMask_Alpha = 0x00000008,
+    WGPUColorWriteMask_All = 0x0000000F,
+    WGPUColorWriteMask_Force32 = 0x7FFFFFFF
+} WGPUColorWriteMask;
+typedef WGPUFlags WGPUColorWriteMaskFlags;
+
+typedef enum WGPUMapMode {
+    WGPUMapMode_Read = 0x00000001,
+    WGPUMapMode_Write = 0x00000002,
+    WGPUMapMode_Force32 = 0x7FFFFFFF
+} WGPUMapMode;
+typedef WGPUFlags WGPUMapModeFlags;
+
+typedef enum WGPUShaderStage {
+    WGPUShaderStage_None = 0x00000000,
+    WGPUShaderStage_Vertex = 0x00000001,
+    WGPUShaderStage_Fragment = 0x00000002,
+    WGPUShaderStage_Compute = 0x00000004,
+    WGPUShaderStage_Force32 = 0x7FFFFFFF
+} WGPUShaderStage;
+typedef WGPUFlags WGPUShaderStageFlags;
+
+typedef enum WGPUTextureUsage {
+    WGPUTextureUsage_None = 0x00000000,
+    WGPUTextureUsage_CopySrc = 0x00000001,
+    WGPUTextureUsage_CopyDst = 0x00000002,
+    WGPUTextureUsage_Sampled = 0x00000004,
+    WGPUTextureUsage_Storage = 0x00000008,
+    WGPUTextureUsage_RenderAttachment = 0x00000010,
+    WGPUTextureUsage_Force32 = 0x7FFFFFFF
+} WGPUTextureUsage;
+typedef WGPUFlags WGPUTextureUsageFlags;
+
+
+typedef struct WGPUChainedStruct {
+    struct WGPUChainedStruct const * next;
+    WGPUSType sType;
+} WGPUChainedStruct;
+
+typedef struct WGPUAdapterProperties {
+    WGPUChainedStruct const * nextInChain;
+    uint32_t deviceID;
+    uint32_t vendorID;
+    char const * name;
+    char const * driverDescription;
+    WGPUAdapterType adapterType;
+    WGPUBackendType backendType;
+} WGPUAdapterProperties;
+
+typedef struct WGPUBindGroupEntry {
+    uint32_t binding;
+    WGPUBuffer buffer;
+    uint64_t offset;
+    uint64_t size;
+    WGPUSampler sampler;
+    WGPUTextureView textureView;
+} WGPUBindGroupEntry;
+
+typedef struct WGPUBlendComponent {
+    WGPUBlendFactor srcFactor;
+    WGPUBlendFactor dstFactor;
+    WGPUBlendOperation operation;
+} WGPUBlendComponent;
+
+typedef struct WGPUBufferBindingLayout {
+    WGPUChainedStruct const * nextInChain;
+    WGPUBufferBindingType type;
+    bool hasDynamicOffset;
+    uint64_t minBindingSize;
+} WGPUBufferBindingLayout;
+
+typedef struct WGPUBufferDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+    WGPUBufferUsageFlags usage;
+    uint64_t size;
+    bool mappedAtCreation;
+} WGPUBufferDescriptor;
+
+typedef struct WGPUColor {
+    double r;
+    double g;
+    double b;
+    double a;
+} WGPUColor;
+
+typedef struct WGPUCommandBufferDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+} WGPUCommandBufferDescriptor;
+
+typedef struct WGPUCommandEncoderDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+} WGPUCommandEncoderDescriptor;
+
+typedef struct WGPUComputePassDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+} WGPUComputePassDescriptor;
+
+typedef struct WGPUDeviceDescriptor {
+    WGPUChainedStruct const * nextInChain;
+} WGPUDeviceDescriptor;
+
+typedef struct WGPUExtent3D {
+    uint32_t width;
+    uint32_t height;
+    uint32_t depthOrArrayLayers;
+} WGPUExtent3D;
+
+typedef struct WGPUInstanceDescriptor {
+    WGPUChainedStruct const * nextInChain;
+} WGPUInstanceDescriptor;
+
+typedef struct WGPUMultisampleState {
+    WGPUChainedStruct const * nextInChain;
+    uint32_t count;
+    uint32_t mask;
+    bool alphaToCoverageEnabled;
+} WGPUMultisampleState;
+
+typedef struct WGPUOrigin3D {
+    uint32_t x;
+    uint32_t y;
+    uint32_t z;
+} WGPUOrigin3D;
+
+typedef struct WGPUPipelineLayoutDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+    uint32_t bindGroupLayoutCount;
+    WGPUBindGroupLayout const * bindGroupLayouts;
+} WGPUPipelineLayoutDescriptor;
+
+typedef struct WGPUPrimitiveDepthClampingState {
+    WGPUChainedStruct chain;
+    bool clampDepth;
+} WGPUPrimitiveDepthClampingState;
+
+typedef struct WGPUPrimitiveState {
+    WGPUChainedStruct const * nextInChain;
+    WGPUPrimitiveTopology topology;
+    WGPUIndexFormat stripIndexFormat;
+    WGPUFrontFace frontFace;
+    WGPUCullMode cullMode;
+} WGPUPrimitiveState;
+
+typedef struct WGPUProgrammableStageDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    WGPUShaderModule module;
+    char const * entryPoint;
+} WGPUProgrammableStageDescriptor;
+
+typedef struct WGPUQuerySetDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+    WGPUQueryType type;
+    uint32_t count;
+    WGPUPipelineStatisticName const * pipelineStatistics;
+    uint32_t pipelineStatisticsCount;
+} WGPUQuerySetDescriptor;
+
+typedef struct WGPURenderBundleDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+} WGPURenderBundleDescriptor;
+
+typedef struct WGPURenderBundleEncoderDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+    uint32_t colorFormatsCount;
+    WGPUTextureFormat const * colorFormats;
+    WGPUTextureFormat depthStencilFormat;
+    uint32_t sampleCount;
+} WGPURenderBundleEncoderDescriptor;
+
+typedef struct WGPURenderPassDepthStencilAttachment {
+    WGPUTextureView view;
+    WGPULoadOp depthLoadOp;
+    WGPUStoreOp depthStoreOp;
+    float clearDepth;
+    bool depthReadOnly;
+    WGPULoadOp stencilLoadOp;
+    WGPUStoreOp stencilStoreOp;
+    uint32_t clearStencil;
+    bool stencilReadOnly;
+} WGPURenderPassDepthStencilAttachment;
+
+typedef struct WGPURequestAdapterOptions {
+    WGPUChainedStruct const * nextInChain;
+    WGPUSurface compatibleSurface;
+} WGPURequestAdapterOptions;
+
+typedef struct WGPUSamplerBindingLayout {
+    WGPUChainedStruct const * nextInChain;
+    WGPUSamplerBindingType type;
+} WGPUSamplerBindingLayout;
+
+typedef struct WGPUSamplerDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+    WGPUAddressMode addressModeU;
+    WGPUAddressMode addressModeV;
+    WGPUAddressMode addressModeW;
+    WGPUFilterMode magFilter;
+    WGPUFilterMode minFilter;
+    WGPUFilterMode mipmapFilter;
+    float lodMinClamp;
+    float lodMaxClamp;
+    WGPUCompareFunction compare;
+    uint16_t maxAnisotropy;
+} WGPUSamplerDescriptor;
+
+typedef struct WGPUShaderModuleDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+} WGPUShaderModuleDescriptor;
+
+typedef struct WGPUShaderModuleSPIRVDescriptor {
+    WGPUChainedStruct chain;
+    uint32_t codeSize;
+    uint32_t const * code;
+} WGPUShaderModuleSPIRVDescriptor;
+
+typedef struct WGPUShaderModuleWGSLDescriptor {
+    WGPUChainedStruct chain;
+    char const * source;
+} WGPUShaderModuleWGSLDescriptor;
+
+typedef struct WGPUStencilFaceState {
+    WGPUCompareFunction compare;
+    WGPUStencilOperation failOp;
+    WGPUStencilOperation depthFailOp;
+    WGPUStencilOperation passOp;
+} WGPUStencilFaceState;
+
+typedef struct WGPUStorageTextureBindingLayout {
+    WGPUChainedStruct const * nextInChain;
+    WGPUStorageTextureAccess access;
+    WGPUTextureFormat format;
+    WGPUTextureViewDimension viewDimension;
+} WGPUStorageTextureBindingLayout;
+
+typedef struct WGPUSurfaceDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+} WGPUSurfaceDescriptor;
+
+typedef struct WGPUSurfaceDescriptorFromCanvasHTMLSelector {
+    WGPUChainedStruct chain;
+    char const * selector;
+} WGPUSurfaceDescriptorFromCanvasHTMLSelector;
+
+typedef struct WGPUSurfaceDescriptorFromMetalLayer {
+    WGPUChainedStruct chain;
+    void * layer;
+} WGPUSurfaceDescriptorFromMetalLayer;
+
+typedef struct WGPUSurfaceDescriptorFromWindowsHWND {
+    WGPUChainedStruct chain;
+    void * hinstance;
+    void * hwnd;
+} WGPUSurfaceDescriptorFromWindowsHWND;
+
+typedef struct WGPUSurfaceDescriptorFromXlib {
+    WGPUChainedStruct chain;
+    void * display;
+    uint32_t window;
+} WGPUSurfaceDescriptorFromXlib;
+
+typedef struct WGPUSwapChainDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+    WGPUTextureUsageFlags usage;
+    WGPUTextureFormat format;
+    uint32_t width;
+    uint32_t height;
+    WGPUPresentMode presentMode;
+} WGPUSwapChainDescriptor;
+
+typedef struct WGPUTextureBindingLayout {
+    WGPUChainedStruct const * nextInChain;
+    WGPUTextureSampleType sampleType;
+    WGPUTextureViewDimension viewDimension;
+    bool multisampled;
+} WGPUTextureBindingLayout;
+
+typedef struct WGPUTextureDataLayout {
+    WGPUChainedStruct const * nextInChain;
+    uint64_t offset;
+    uint32_t bytesPerRow;
+    uint32_t rowsPerImage;
+} WGPUTextureDataLayout;
+
+typedef struct WGPUTextureViewDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+    WGPUTextureFormat format;
+    WGPUTextureViewDimension dimension;
+    uint32_t baseMipLevel;
+    uint32_t mipLevelCount;
+    uint32_t baseArrayLayer;
+    uint32_t arrayLayerCount;
+    WGPUTextureAspect aspect;
+} WGPUTextureViewDescriptor;
+
+typedef struct WGPUVertexAttribute {
+    WGPUVertexFormat format;
+    uint64_t offset;
+    uint32_t shaderLocation;
+} WGPUVertexAttribute;
+
+typedef struct WGPUBindGroupDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+    WGPUBindGroupLayout layout;
+    uint32_t entryCount;
+    WGPUBindGroupEntry const * entries;
+} WGPUBindGroupDescriptor;
+
+typedef struct WGPUBindGroupLayoutEntry {
+    WGPUChainedStruct const * nextInChain;
+    uint32_t binding;
+    WGPUShaderStageFlags visibility;
+    WGPUBufferBindingLayout buffer;
+    WGPUSamplerBindingLayout sampler;
+    WGPUTextureBindingLayout texture;
+    WGPUStorageTextureBindingLayout storageTexture;
+} WGPUBindGroupLayoutEntry;
+
+typedef struct WGPUBlendState {
+    WGPUBlendComponent color;
+    WGPUBlendComponent alpha;
+} WGPUBlendState;
+
+typedef struct WGPUComputePipelineDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+    WGPUPipelineLayout layout;
+    WGPUProgrammableStageDescriptor computeStage;
+} WGPUComputePipelineDescriptor;
+
+typedef struct WGPUDepthStencilState {
+    WGPUChainedStruct const * nextInChain;
+    WGPUTextureFormat format;
+    bool depthWriteEnabled;
+    WGPUCompareFunction depthCompare;
+    WGPUStencilFaceState stencilFront;
+    WGPUStencilFaceState stencilBack;
+    uint32_t stencilReadMask;
+    uint32_t stencilWriteMask;
+    int32_t depthBias;
+    float depthBiasSlopeScale;
+    float depthBiasClamp;
+} WGPUDepthStencilState;
+
+typedef struct WGPUImageCopyBuffer {
+    WGPUChainedStruct const * nextInChain;
+    WGPUTextureDataLayout layout;
+    WGPUBuffer buffer;
+} WGPUImageCopyBuffer;
+
+typedef struct WGPUImageCopyTexture {
+    WGPUChainedStruct const * nextInChain;
+    WGPUTexture texture;
+    uint32_t mipLevel;
+    WGPUOrigin3D origin;
+    WGPUTextureAspect aspect;
+} WGPUImageCopyTexture;
+
+typedef struct WGPURenderPassColorAttachment {
+    WGPUTextureView view;
+    WGPUTextureView resolveTarget;
+    WGPULoadOp loadOp;
+    WGPUStoreOp storeOp;
+    WGPUColor clearColor;
+} WGPURenderPassColorAttachment;
+
+typedef struct WGPUTextureDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+    WGPUTextureUsageFlags usage;
+    WGPUTextureDimension dimension;
+    WGPUExtent3D size;
+    WGPUTextureFormat format;
+    uint32_t mipLevelCount;
+    uint32_t sampleCount;
+} WGPUTextureDescriptor;
+
+typedef struct WGPUVertexBufferLayout {
+    uint64_t arrayStride;
+    WGPUInputStepMode stepMode;
+    uint32_t attributeCount;
+    WGPUVertexAttribute const * attributes;
+} WGPUVertexBufferLayout;
+
+typedef struct WGPUBindGroupLayoutDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+    uint32_t entryCount;
+    WGPUBindGroupLayoutEntry const * entries;
+} WGPUBindGroupLayoutDescriptor;
+
+typedef struct WGPUColorTargetState {
+    WGPUChainedStruct const * nextInChain;
+    WGPUTextureFormat format;
+    WGPUBlendState const * blend;
+    WGPUColorWriteMaskFlags writeMask;
+} WGPUColorTargetState;
+
+typedef struct WGPURenderPassDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+    uint32_t colorAttachmentCount;
+    WGPURenderPassColorAttachment const * colorAttachments;
+    WGPURenderPassDepthStencilAttachment const * depthStencilAttachment;
+    WGPUQuerySet occlusionQuerySet;
+} WGPURenderPassDescriptor;
+
+typedef struct WGPUVertexState {
+    WGPUChainedStruct const * nextInChain;
+    WGPUShaderModule module;
+    char const * entryPoint;
+    uint32_t bufferCount;
+    WGPUVertexBufferLayout const * buffers;
+} WGPUVertexState;
+
+typedef struct WGPUFragmentState {
+    WGPUChainedStruct const * nextInChain;
+    WGPUShaderModule module;
+    char const * entryPoint;
+    uint32_t targetCount;
+    WGPUColorTargetState const * targets;
+} WGPUFragmentState;
+
+typedef struct WGPURenderPipelineDescriptor {
+    WGPUChainedStruct const * nextInChain;
+    char const * label;
+    WGPUPipelineLayout layout;
+    WGPUVertexState vertex;
+    WGPUPrimitiveState primitive;
+    WGPUDepthStencilState const * depthStencil;
+    WGPUMultisampleState multisample;
+    WGPUFragmentState const * fragment;
+} WGPURenderPipelineDescriptor;
+
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+typedef void (*WGPUBufferMapCallback)(WGPUBufferMapAsyncStatus status, void * userdata);
+typedef void (*WGPUCreateComputePipelineAsyncCallback)(WGPUCreatePipelineAsyncStatus status, WGPUComputePipeline pipeline, char const * message, void * userdata);
+typedef void (*WGPUCreateRenderPipelineAsyncCallback)(WGPUCreatePipelineAsyncStatus status, WGPURenderPipeline pipeline, char const * message, void * userdata);
+typedef void (*WGPUDeviceLostCallback)(char const * message, void * userdata);
+typedef void (*WGPUErrorCallback)(WGPUErrorType type, char const * message, void * userdata);
+typedef void (*WGPUQueueWorkDoneCallback)(WGPUQueueWorkDoneStatus status, void * userdata);
+typedef void (*WGPURequestAdapterCallback)(WGPUAdapter result, void * userdata);
+typedef void (*WGPURequestDeviceCallback)(WGPUDevice result, void * userdata);
+typedef void (*WGPUSurfaceGetPreferredFormatCallback)(WGPUTextureFormat format, void * userdata);
+
+typedef void (*WGPUProc)(void);
+
+#if !defined(WGPU_SKIP_PROCS)
+
+typedef WGPUInstance (*WGPUProcCreateInstance)(WGPUInstanceDescriptor const * descriptor);
+typedef WGPUProc (*WGPUProcGetProcAddress)(WGPUDevice device, char const * procName);
+
+// Procs of Adapter
+typedef void (*WGPUProcAdapterGetProperties)(WGPUAdapter adapter, WGPUAdapterProperties * properties);
+typedef void (*WGPUProcAdapterRequestDevice)(WGPUAdapter adapter, WGPUDeviceDescriptor const * descriptor, WGPURequestDeviceCallback callback, void * userdata);
+
+// Procs of Buffer
+typedef void (*WGPUProcBufferDestroy)(WGPUBuffer buffer);
+typedef void const * (*WGPUProcBufferGetConstMappedRange)(WGPUBuffer buffer, size_t offset, size_t size);
+typedef void * (*WGPUProcBufferGetMappedRange)(WGPUBuffer buffer, size_t offset, size_t size);
+typedef void (*WGPUProcBufferMapAsync)(WGPUBuffer buffer, WGPUMapModeFlags mode, size_t offset, size_t size, WGPUBufferMapCallback callback, void * userdata);
+typedef void (*WGPUProcBufferUnmap)(WGPUBuffer buffer);
+
+// Procs of CommandEncoder
+typedef WGPUComputePassEncoder (*WGPUProcCommandEncoderBeginComputePass)(WGPUCommandEncoder commandEncoder, WGPUComputePassDescriptor const * descriptor);
+typedef WGPURenderPassEncoder (*WGPUProcCommandEncoderBeginRenderPass)(WGPUCommandEncoder commandEncoder, WGPURenderPassDescriptor const * descriptor);
+typedef void (*WGPUProcCommandEncoderCopyBufferToBuffer)(WGPUCommandEncoder commandEncoder, WGPUBuffer source, uint64_t sourceOffset, WGPUBuffer destination, uint64_t destinationOffset, uint64_t size);
+typedef void (*WGPUProcCommandEncoderCopyBufferToTexture)(WGPUCommandEncoder commandEncoder, WGPUImageCopyBuffer const * source, WGPUImageCopyTexture const * destination, WGPUExtent3D const * copySize);
+typedef void (*WGPUProcCommandEncoderCopyTextureToBuffer)(WGPUCommandEncoder commandEncoder, WGPUImageCopyTexture const * source, WGPUImageCopyBuffer const * destination, WGPUExtent3D const * copySize);
+typedef void (*WGPUProcCommandEncoderCopyTextureToTexture)(WGPUCommandEncoder commandEncoder, WGPUImageCopyTexture const * source, WGPUImageCopyTexture const * destination, WGPUExtent3D const * copySize);
+typedef WGPUCommandBuffer (*WGPUProcCommandEncoderFinish)(WGPUCommandEncoder commandEncoder, WGPUCommandBufferDescriptor const * descriptor);
+typedef void (*WGPUProcCommandEncoderInsertDebugMarker)(WGPUCommandEncoder commandEncoder, char const * markerLabel);
+typedef void (*WGPUProcCommandEncoderPopDebugGroup)(WGPUCommandEncoder commandEncoder);
+typedef void (*WGPUProcCommandEncoderPushDebugGroup)(WGPUCommandEncoder commandEncoder, char const * groupLabel);
+typedef void (*WGPUProcCommandEncoderResolveQuerySet)(WGPUCommandEncoder commandEncoder, WGPUQuerySet querySet, uint32_t firstQuery, uint32_t queryCount, WGPUBuffer destination, uint64_t destinationOffset);
+typedef void (*WGPUProcCommandEncoderWriteTimestamp)(WGPUCommandEncoder commandEncoder, WGPUQuerySet querySet, uint32_t queryIndex);
+
+// Procs of ComputePassEncoder
+typedef void (*WGPUProcComputePassEncoderBeginPipelineStatisticsQuery)(WGPUComputePassEncoder computePassEncoder, WGPUQuerySet querySet, uint32_t queryIndex);
+typedef void (*WGPUProcComputePassEncoderDispatch)(WGPUComputePassEncoder computePassEncoder, uint32_t x, uint32_t y, uint32_t z);
+typedef void (*WGPUProcComputePassEncoderDispatchIndirect)(WGPUComputePassEncoder computePassEncoder, WGPUBuffer indirectBuffer, uint64_t indirectOffset);
+typedef void (*WGPUProcComputePassEncoderEndPass)(WGPUComputePassEncoder computePassEncoder);
+typedef void (*WGPUProcComputePassEncoderEndPipelineStatisticsQuery)(WGPUComputePassEncoder computePassEncoder);
+typedef void (*WGPUProcComputePassEncoderInsertDebugMarker)(WGPUComputePassEncoder computePassEncoder, char const * markerLabel);
+typedef void (*WGPUProcComputePassEncoderPopDebugGroup)(WGPUComputePassEncoder computePassEncoder);
+typedef void (*WGPUProcComputePassEncoderPushDebugGroup)(WGPUComputePassEncoder computePassEncoder, char const * groupLabel);
+typedef void (*WGPUProcComputePassEncoderSetBindGroup)(WGPUComputePassEncoder computePassEncoder, uint32_t groupIndex, WGPUBindGroup group, uint32_t dynamicOffsetCount, uint32_t const * dynamicOffsets);
+typedef void (*WGPUProcComputePassEncoderSetPipeline)(WGPUComputePassEncoder computePassEncoder, WGPUComputePipeline pipeline);
+typedef void (*WGPUProcComputePassEncoderWriteTimestamp)(WGPUComputePassEncoder computePassEncoder, WGPUQuerySet querySet, uint32_t queryIndex);
+
+// Procs of ComputePipeline
+typedef WGPUBindGroupLayout (*WGPUProcComputePipelineGetBindGroupLayout)(WGPUComputePipeline computePipeline, uint32_t groupIndex);
+
+// Procs of Device
+typedef WGPUBindGroup (*WGPUProcDeviceCreateBindGroup)(WGPUDevice device, WGPUBindGroupDescriptor const * descriptor);
+typedef WGPUBindGroupLayout (*WGPUProcDeviceCreateBindGroupLayout)(WGPUDevice device, WGPUBindGroupLayoutDescriptor const * descriptor);
+typedef WGPUBuffer (*WGPUProcDeviceCreateBuffer)(WGPUDevice device, WGPUBufferDescriptor const * descriptor);
+typedef WGPUCommandEncoder (*WGPUProcDeviceCreateCommandEncoder)(WGPUDevice device, WGPUCommandEncoderDescriptor const * descriptor);
+typedef WGPUComputePipeline (*WGPUProcDeviceCreateComputePipeline)(WGPUDevice device, WGPUComputePipelineDescriptor const * descriptor);
+typedef void (*WGPUProcDeviceCreateComputePipelineAsync)(WGPUDevice device, WGPUComputePipelineDescriptor const * descriptor, WGPUCreateComputePipelineAsyncCallback callback, void * userdata);
+typedef WGPUPipelineLayout (*WGPUProcDeviceCreatePipelineLayout)(WGPUDevice device, WGPUPipelineLayoutDescriptor const * descriptor);
+typedef WGPUQuerySet (*WGPUProcDeviceCreateQuerySet)(WGPUDevice device, WGPUQuerySetDescriptor const * descriptor);
+typedef WGPURenderBundleEncoder (*WGPUProcDeviceCreateRenderBundleEncoder)(WGPUDevice device, WGPURenderBundleEncoderDescriptor const * descriptor);
+typedef WGPURenderPipeline (*WGPUProcDeviceCreateRenderPipeline)(WGPUDevice device, WGPURenderPipelineDescriptor const * descriptor);
+typedef void (*WGPUProcDeviceCreateRenderPipelineAsync)(WGPUDevice device, WGPURenderPipelineDescriptor const * descriptor, WGPUCreateRenderPipelineAsyncCallback callback, void * userdata);
+typedef WGPUSampler (*WGPUProcDeviceCreateSampler)(WGPUDevice device, WGPUSamplerDescriptor const * descriptor);
+typedef WGPUShaderModule (*WGPUProcDeviceCreateShaderModule)(WGPUDevice device, WGPUShaderModuleDescriptor const * descriptor);
+typedef WGPUSwapChain (*WGPUProcDeviceCreateSwapChain)(WGPUDevice device, WGPUSurface surface, WGPUSwapChainDescriptor const * descriptor);
+typedef WGPUTexture (*WGPUProcDeviceCreateTexture)(WGPUDevice device, WGPUTextureDescriptor const * descriptor);
+typedef WGPUQueue (*WGPUProcDeviceGetQueue)(WGPUDevice device);
+typedef bool (*WGPUProcDevicePopErrorScope)(WGPUDevice device, WGPUErrorCallback callback, void * userdata);
+typedef void (*WGPUProcDevicePushErrorScope)(WGPUDevice device, WGPUErrorFilter filter);
+typedef void (*WGPUProcDeviceSetDeviceLostCallback)(WGPUDevice device, WGPUDeviceLostCallback callback, void * userdata);
+typedef void (*WGPUProcDeviceSetUncapturedErrorCallback)(WGPUDevice device, WGPUErrorCallback callback, void * userdata);
+
+// Procs of Instance
+typedef WGPUSurface (*WGPUProcInstanceCreateSurface)(WGPUInstance instance, WGPUSurfaceDescriptor const * descriptor);
+typedef void (*WGPUProcInstanceProcessEvents)(WGPUInstance instance);
+typedef void (*WGPUProcInstanceRequestAdapter)(WGPUInstance instance, WGPURequestAdapterOptions const * options, WGPURequestAdapterCallback callback, void * userdata);
+
+// Procs of QuerySet
+typedef void (*WGPUProcQuerySetDestroy)(WGPUQuerySet querySet);
+
+// Procs of Queue
+typedef void (*WGPUProcQueueOnSubmittedWorkDone)(WGPUQueue queue, uint64_t signalValue, WGPUQueueWorkDoneCallback callback, void * userdata);
+typedef void (*WGPUProcQueueSubmit)(WGPUQueue queue, uint32_t commandCount, WGPUCommandBuffer const * commands);
+typedef void (*WGPUProcQueueWriteBuffer)(WGPUQueue queue, WGPUBuffer buffer, uint64_t bufferOffset, void const * data, size_t size);
+typedef void (*WGPUProcQueueWriteTexture)(WGPUQueue queue, WGPUImageCopyTexture const * destination, void const * data, size_t dataSize, WGPUTextureDataLayout const * dataLayout, WGPUExtent3D const * writeSize);
+
+// Procs of RenderBundleEncoder
+typedef void (*WGPUProcRenderBundleEncoderDraw)(WGPURenderBundleEncoder renderBundleEncoder, uint32_t vertexCount, uint32_t instanceCount, uint32_t firstVertex, uint32_t firstInstance);
+typedef void (*WGPUProcRenderBundleEncoderDrawIndexed)(WGPURenderBundleEncoder renderBundleEncoder, uint32_t indexCount, uint32_t instanceCount, uint32_t firstIndex, int32_t baseVertex, uint32_t firstInstance);
+typedef void (*WGPUProcRenderBundleEncoderDrawIndexedIndirect)(WGPURenderBundleEncoder renderBundleEncoder, WGPUBuffer indirectBuffer, uint64_t indirectOffset);
+typedef void (*WGPUProcRenderBundleEncoderDrawIndirect)(WGPURenderBundleEncoder renderBundleEncoder, WGPUBuffer indirectBuffer, uint64_t indirectOffset);
+typedef WGPURenderBundle (*WGPUProcRenderBundleEncoderFinish)(WGPURenderBundleEncoder renderBundleEncoder, WGPURenderBundleDescriptor const * descriptor);
+typedef void (*WGPUProcRenderBundleEncoderInsertDebugMarker)(WGPURenderBundleEncoder renderBundleEncoder, char const * markerLabel);
+typedef void (*WGPUProcRenderBundleEncoderPopDebugGroup)(WGPURenderBundleEncoder renderBundleEncoder);
+typedef void (*WGPUProcRenderBundleEncoderPushDebugGroup)(WGPURenderBundleEncoder renderBundleEncoder, char const * groupLabel);
+typedef void (*WGPUProcRenderBundleEncoderSetBindGroup)(WGPURenderBundleEncoder renderBundleEncoder, uint32_t groupIndex, WGPUBindGroup group, uint32_t dynamicOffsetCount, uint32_t const * dynamicOffsets);
+typedef void (*WGPUProcRenderBundleEncoderSetIndexBuffer)(WGPURenderBundleEncoder renderBundleEncoder, WGPUBuffer buffer, WGPUIndexFormat format, uint64_t offset, uint64_t size);
+typedef void (*WGPUProcRenderBundleEncoderSetPipeline)(WGPURenderBundleEncoder renderBundleEncoder, WGPURenderPipeline pipeline);
+typedef void (*WGPUProcRenderBundleEncoderSetVertexBuffer)(WGPURenderBundleEncoder renderBundleEncoder, uint32_t slot, WGPUBuffer buffer, uint64_t offset, uint64_t size);
+
+// Procs of RenderPassEncoder
+typedef void (*WGPUProcRenderPassEncoderBeginOcclusionQuery)(WGPURenderPassEncoder renderPassEncoder, uint32_t queryIndex);
+typedef void (*WGPUProcRenderPassEncoderBeginPipelineStatisticsQuery)(WGPURenderPassEncoder renderPassEncoder, WGPUQuerySet querySet, uint32_t queryIndex);
+typedef void (*WGPUProcRenderPassEncoderDraw)(WGPURenderPassEncoder renderPassEncoder, uint32_t vertexCount, uint32_t instanceCount, uint32_t firstVertex, uint32_t firstInstance);
+typedef void (*WGPUProcRenderPassEncoderDrawIndexed)(WGPURenderPassEncoder renderPassEncoder, uint32_t indexCount, uint32_t instanceCount, uint32_t firstIndex, int32_t baseVertex, uint32_t firstInstance);
+typedef void (*WGPUProcRenderPassEncoderDrawIndexedIndirect)(WGPURenderPassEncoder renderPassEncoder, WGPUBuffer indirectBuffer, uint64_t indirectOffset);
+typedef void (*WGPUProcRenderPassEncoderDrawIndirect)(WGPURenderPassEncoder renderPassEncoder, WGPUBuffer indirectBuffer, uint64_t indirectOffset);
+typedef void (*WGPUProcRenderPassEncoderEndOcclusionQuery)(WGPURenderPassEncoder renderPassEncoder);
+typedef void (*WGPUProcRenderPassEncoderEndPass)(WGPURenderPassEncoder renderPassEncoder);
+typedef void (*WGPUProcRenderPassEncoderEndPipelineStatisticsQuery)(WGPURenderPassEncoder renderPassEncoder);
+typedef void (*WGPUProcRenderPassEncoderExecuteBundles)(WGPURenderPassEncoder renderPassEncoder, uint32_t bundlesCount, WGPURenderBundle const * bundles);
+typedef void (*WGPUProcRenderPassEncoderInsertDebugMarker)(WGPURenderPassEncoder renderPassEncoder, char const * markerLabel);
+typedef void (*WGPUProcRenderPassEncoderPopDebugGroup)(WGPURenderPassEncoder renderPassEncoder);
+typedef void (*WGPUProcRenderPassEncoderPushDebugGroup)(WGPURenderPassEncoder renderPassEncoder, char const * groupLabel);
+typedef void (*WGPUProcRenderPassEncoderSetBindGroup)(WGPURenderPassEncoder renderPassEncoder, uint32_t groupIndex, WGPUBindGroup group, uint32_t dynamicOffsetCount, uint32_t const * dynamicOffsets);
+typedef void (*WGPUProcRenderPassEncoderSetBlendConstant)(WGPURenderPassEncoder renderPassEncoder, WGPUColor const * color);
+typedef void (*WGPUProcRenderPassEncoderSetIndexBuffer)(WGPURenderPassEncoder renderPassEncoder, WGPUBuffer buffer, WGPUIndexFormat format, uint64_t offset, uint64_t size);
+typedef void (*WGPUProcRenderPassEncoderSetPipeline)(WGPURenderPassEncoder renderPassEncoder, WGPURenderPipeline pipeline);
+typedef void (*WGPUProcRenderPassEncoderSetScissorRect)(WGPURenderPassEncoder renderPassEncoder, uint32_t x, uint32_t y, uint32_t width, uint32_t height);
+typedef void (*WGPUProcRenderPassEncoderSetStencilReference)(WGPURenderPassEncoder renderPassEncoder, uint32_t reference);
+typedef void (*WGPUProcRenderPassEncoderSetVertexBuffer)(WGPURenderPassEncoder renderPassEncoder, uint32_t slot, WGPUBuffer buffer, uint64_t offset, uint64_t size);
+typedef void (*WGPUProcRenderPassEncoderSetViewport)(WGPURenderPassEncoder renderPassEncoder, float x, float y, float width, float height, float minDepth, float maxDepth);
+typedef void (*WGPUProcRenderPassEncoderWriteTimestamp)(WGPURenderPassEncoder renderPassEncoder, WGPUQuerySet querySet, uint32_t queryIndex);
+
+// Procs of RenderPipeline
+typedef WGPUBindGroupLayout (*WGPUProcRenderPipelineGetBindGroupLayout)(WGPURenderPipeline renderPipeline, uint32_t groupIndex);
+
+// Procs of Surface
+typedef void (*WGPUProcSurfaceGetPreferredFormat)(WGPUSurface surface, WGPUAdapter adapter, WGPUSurfaceGetPreferredFormatCallback callback, void * userdata);
+
+// Procs of SwapChain
+typedef WGPUTextureView (*WGPUProcSwapChainGetCurrentTextureView)(WGPUSwapChain swapChain);
+typedef void (*WGPUProcSwapChainPresent)(WGPUSwapChain swapChain);
+
+// Procs of Texture
+typedef WGPUTextureView (*WGPUProcTextureCreateView)(WGPUTexture texture, WGPUTextureViewDescriptor const * descriptor);
+typedef void (*WGPUProcTextureDestroy)(WGPUTexture texture);
+
+#endif  // !defined(WGPU_SKIP_PROCS)
+
+#if !defined(WGPU_SKIP_DECLARATIONS)
+
+WGPU_EXPORT WGPUInstance wgpuCreateInstance(WGPUInstanceDescriptor const * descriptor);
+WGPU_EXPORT WGPUProc wgpuGetProcAddress(WGPUDevice device, char const * procName);
+
+// Methods of Adapter
+WGPU_EXPORT void wgpuAdapterGetProperties(WGPUAdapter adapter, WGPUAdapterProperties * properties);
+WGPU_EXPORT void wgpuAdapterRequestDevice(WGPUAdapter adapter, WGPUDeviceDescriptor const * descriptor, WGPURequestDeviceCallback callback, void * userdata);
+
+// Methods of Buffer
+WGPU_EXPORT void wgpuBufferDestroy(WGPUBuffer buffer);
+WGPU_EXPORT void const * wgpuBufferGetConstMappedRange(WGPUBuffer buffer, size_t offset, size_t size);
+WGPU_EXPORT void * wgpuBufferGetMappedRange(WGPUBuffer buffer, size_t offset, size_t size);
+WGPU_EXPORT void wgpuBufferMapAsync(WGPUBuffer buffer, WGPUMapModeFlags mode, size_t offset, size_t size, WGPUBufferMapCallback callback, void * userdata);
+WGPU_EXPORT void wgpuBufferUnmap(WGPUBuffer buffer);
+
+// Methods of CommandEncoder
+WGPU_EXPORT WGPUComputePassEncoder wgpuCommandEncoderBeginComputePass(WGPUCommandEncoder commandEncoder, WGPUComputePassDescriptor const * descriptor);
+WGPU_EXPORT WGPURenderPassEncoder wgpuCommandEncoderBeginRenderPass(WGPUCommandEncoder commandEncoder, WGPURenderPassDescriptor const * descriptor);
+WGPU_EXPORT void wgpuCommandEncoderCopyBufferToBuffer(WGPUCommandEncoder commandEncoder, WGPUBuffer source, uint64_t sourceOffset, WGPUBuffer destination, uint64_t destinationOffset, uint64_t size);
+WGPU_EXPORT void wgpuCommandEncoderCopyBufferToTexture(WGPUCommandEncoder commandEncoder, WGPUImageCopyBuffer const * source, WGPUImageCopyTexture const * destination, WGPUExtent3D const * copySize);
+WGPU_EXPORT void wgpuCommandEncoderCopyTextureToBuffer(WGPUCommandEncoder commandEncoder, WGPUImageCopyTexture const * source, WGPUImageCopyBuffer const * destination, WGPUExtent3D const * copySize);
+WGPU_EXPORT void wgpuCommandEncoderCopyTextureToTexture(WGPUCommandEncoder commandEncoder, WGPUImageCopyTexture const * source, WGPUImageCopyTexture const * destination, WGPUExtent3D const * copySize);
+WGPU_EXPORT WGPUCommandBuffer wgpuCommandEncoderFinish(WGPUCommandEncoder commandEncoder, WGPUCommandBufferDescriptor const * descriptor);
+WGPU_EXPORT void wgpuCommandEncoderInsertDebugMarker(WGPUCommandEncoder commandEncoder, char const * markerLabel);
+WGPU_EXPORT void wgpuCommandEncoderPopDebugGroup(WGPUCommandEncoder commandEncoder);
+WGPU_EXPORT void wgpuCommandEncoderPushDebugGroup(WGPUCommandEncoder commandEncoder, char const * groupLabel);
+WGPU_EXPORT void wgpuCommandEncoderResolveQuerySet(WGPUCommandEncoder commandEncoder, WGPUQuerySet querySet, uint32_t firstQuery, uint32_t queryCount, WGPUBuffer destination, uint64_t destinationOffset);
+WGPU_EXPORT void wgpuCommandEncoderWriteTimestamp(WGPUCommandEncoder commandEncoder, WGPUQuerySet querySet, uint32_t queryIndex);
+
+// Methods of ComputePassEncoder
+WGPU_EXPORT void wgpuComputePassEncoderBeginPipelineStatisticsQuery(WGPUComputePassEncoder computePassEncoder, WGPUQuerySet querySet, uint32_t queryIndex);
+WGPU_EXPORT void wgpuComputePassEncoderDispatch(WGPUComputePassEncoder computePassEncoder, uint32_t x, uint32_t y, uint32_t z);
+WGPU_EXPORT void wgpuComputePassEncoderDispatchIndirect(WGPUComputePassEncoder computePassEncoder, WGPUBuffer indirectBuffer, uint64_t indirectOffset);
+WGPU_EXPORT void wgpuComputePassEncoderEndPass(WGPUComputePassEncoder computePassEncoder);
+WGPU_EXPORT void wgpuComputePassEncoderEndPipelineStatisticsQuery(WGPUComputePassEncoder computePassEncoder);
+WGPU_EXPORT void wgpuComputePassEncoderInsertDebugMarker(WGPUComputePassEncoder computePassEncoder, char const * markerLabel);
+WGPU_EXPORT void wgpuComputePassEncoderPopDebugGroup(WGPUComputePassEncoder computePassEncoder);
+WGPU_EXPORT void wgpuComputePassEncoderPushDebugGroup(WGPUComputePassEncoder computePassEncoder, char const * groupLabel);
+WGPU_EXPORT void wgpuComputePassEncoderSetBindGroup(WGPUComputePassEncoder computePassEncoder, uint32_t groupIndex, WGPUBindGroup group, uint32_t dynamicOffsetCount, uint32_t const * dynamicOffsets);
+WGPU_EXPORT void wgpuComputePassEncoderSetPipeline(WGPUComputePassEncoder computePassEncoder, WGPUComputePipeline pipeline);
+WGPU_EXPORT void wgpuComputePassEncoderWriteTimestamp(WGPUComputePassEncoder computePassEncoder, WGPUQuerySet querySet, uint32_t queryIndex);
+
+// Methods of ComputePipeline
+WGPU_EXPORT WGPUBindGroupLayout wgpuComputePipelineGetBindGroupLayout(WGPUComputePipeline computePipeline, uint32_t groupIndex);
+
+// Methods of Device
+WGPU_EXPORT WGPUBindGroup wgpuDeviceCreateBindGroup(WGPUDevice device, WGPUBindGroupDescriptor const * descriptor);
+WGPU_EXPORT WGPUBindGroupLayout wgpuDeviceCreateBindGroupLayout(WGPUDevice device, WGPUBindGroupLayoutDescriptor const * descriptor);
+WGPU_EXPORT WGPUBuffer wgpuDeviceCreateBuffer(WGPUDevice device, WGPUBufferDescriptor const * descriptor);
+WGPU_EXPORT WGPUCommandEncoder wgpuDeviceCreateCommandEncoder(WGPUDevice device, WGPUCommandEncoderDescriptor const * descriptor);
+WGPU_EXPORT WGPUComputePipeline wgpuDeviceCreateComputePipeline(WGPUDevice device, WGPUComputePipelineDescriptor const * descriptor);
+WGPU_EXPORT void wgpuDeviceCreateComputePipelineAsync(WGPUDevice device, WGPUComputePipelineDescriptor const * descriptor, WGPUCreateComputePipelineAsyncCallback callback, void * userdata);
+WGPU_EXPORT WGPUPipelineLayout wgpuDeviceCreatePipelineLayout(WGPUDevice device, WGPUPipelineLayoutDescriptor const * descriptor);
+WGPU_EXPORT WGPUQuerySet wgpuDeviceCreateQuerySet(WGPUDevice device, WGPUQuerySetDescriptor const * descriptor);
+WGPU_EXPORT WGPURenderBundleEncoder wgpuDeviceCreateRenderBundleEncoder(WGPUDevice device, WGPURenderBundleEncoderDescriptor const * descriptor);
+WGPU_EXPORT WGPURenderPipeline wgpuDeviceCreateRenderPipeline(WGPUDevice device, WGPURenderPipelineDescriptor const * descriptor);
+WGPU_EXPORT void wgpuDeviceCreateRenderPipelineAsync(WGPUDevice device, WGPURenderPipelineDescriptor const * descriptor, WGPUCreateRenderPipelineAsyncCallback callback, void * userdata);
+WGPU_EXPORT WGPUSampler wgpuDeviceCreateSampler(WGPUDevice device, WGPUSamplerDescriptor const * descriptor);
+WGPU_EXPORT WGPUShaderModule wgpuDeviceCreateShaderModule(WGPUDevice device, WGPUShaderModuleDescriptor const * descriptor);
+WGPU_EXPORT WGPUSwapChain wgpuDeviceCreateSwapChain(WGPUDevice device, WGPUSurface surface, WGPUSwapChainDescriptor const * descriptor);
+WGPU_EXPORT WGPUTexture wgpuDeviceCreateTexture(WGPUDevice device, WGPUTextureDescriptor const * descriptor);
+WGPU_EXPORT WGPUQueue wgpuDeviceGetQueue(WGPUDevice device);
+WGPU_EXPORT bool wgpuDevicePopErrorScope(WGPUDevice device, WGPUErrorCallback callback, void * userdata);
+WGPU_EXPORT void wgpuDevicePushErrorScope(WGPUDevice device, WGPUErrorFilter filter);
+WGPU_EXPORT void wgpuDeviceSetDeviceLostCallback(WGPUDevice device, WGPUDeviceLostCallback callback, void * userdata);
+WGPU_EXPORT void wgpuDeviceSetUncapturedErrorCallback(WGPUDevice device, WGPUErrorCallback callback, void * userdata);
+
+// Methods of Instance
+WGPU_EXPORT WGPUSurface wgpuInstanceCreateSurface(WGPUInstance instance, WGPUSurfaceDescriptor const * descriptor);
+WGPU_EXPORT void wgpuInstanceProcessEvents(WGPUInstance instance);
+WGPU_EXPORT void wgpuInstanceRequestAdapter(WGPUInstance instance, WGPURequestAdapterOptions const * options, WGPURequestAdapterCallback callback, void * userdata);
+
+// Methods of QuerySet
+WGPU_EXPORT void wgpuQuerySetDestroy(WGPUQuerySet querySet);
+
+// Methods of Queue
+WGPU_EXPORT void wgpuQueueOnSubmittedWorkDone(WGPUQueue queue, uint64_t signalValue, WGPUQueueWorkDoneCallback callback, void * userdata);
+WGPU_EXPORT void wgpuQueueSubmit(WGPUQueue queue, uint32_t commandCount, WGPUCommandBuffer const * commands);
+WGPU_EXPORT void wgpuQueueWriteBuffer(WGPUQueue queue, WGPUBuffer buffer, uint64_t bufferOffset, void const * data, size_t size);
+WGPU_EXPORT void wgpuQueueWriteTexture(WGPUQueue queue, WGPUImageCopyTexture const * destination, void const * data, size_t dataSize, WGPUTextureDataLayout const * dataLayout, WGPUExtent3D const * writeSize);
+
+// Methods of RenderBundleEncoder
+WGPU_EXPORT void wgpuRenderBundleEncoderDraw(WGPURenderBundleEncoder renderBundleEncoder, uint32_t vertexCount, uint32_t instanceCount, uint32_t firstVertex, uint32_t firstInstance);
+WGPU_EXPORT void wgpuRenderBundleEncoderDrawIndexed(WGPURenderBundleEncoder renderBundleEncoder, uint32_t indexCount, uint32_t instanceCount, uint32_t firstIndex, int32_t baseVertex, uint32_t firstInstance);
+WGPU_EXPORT void wgpuRenderBundleEncoderDrawIndexedIndirect(WGPURenderBundleEncoder renderBundleEncoder, WGPUBuffer indirectBuffer, uint64_t indirectOffset);
+WGPU_EXPORT void wgpuRenderBundleEncoderDrawIndirect(WGPURenderBundleEncoder renderBundleEncoder, WGPUBuffer indirectBuffer, uint64_t indirectOffset);
+WGPU_EXPORT WGPURenderBundle wgpuRenderBundleEncoderFinish(WGPURenderBundleEncoder renderBundleEncoder, WGPURenderBundleDescriptor const * descriptor);
+WGPU_EXPORT void wgpuRenderBundleEncoderInsertDebugMarker(WGPURenderBundleEncoder renderBundleEncoder, char const * markerLabel);
+WGPU_EXPORT void wgpuRenderBundleEncoderPopDebugGroup(WGPURenderBundleEncoder renderBundleEncoder);
+WGPU_EXPORT void wgpuRenderBundleEncoderPushDebugGroup(WGPURenderBundleEncoder renderBundleEncoder, char const * groupLabel);
+WGPU_EXPORT void wgpuRenderBundleEncoderSetBindGroup(WGPURenderBundleEncoder renderBundleEncoder, uint32_t groupIndex, WGPUBindGroup group, uint32_t dynamicOffsetCount, uint32_t const * dynamicOffsets);
+WGPU_EXPORT void wgpuRenderBundleEncoderSetIndexBuffer(WGPURenderBundleEncoder renderBundleEncoder, WGPUBuffer buffer, WGPUIndexFormat format, uint64_t offset, uint64_t size);
+WGPU_EXPORT void wgpuRenderBundleEncoderSetPipeline(WGPURenderBundleEncoder renderBundleEncoder, WGPURenderPipeline pipeline);
+WGPU_EXPORT void wgpuRenderBundleEncoderSetVertexBuffer(WGPURenderBundleEncoder renderBundleEncoder, uint32_t slot, WGPUBuffer buffer, uint64_t offset, uint64_t size);
+
+// Methods of RenderPassEncoder
+WGPU_EXPORT void wgpuRenderPassEncoderBeginOcclusionQuery(WGPURenderPassEncoder renderPassEncoder, uint32_t queryIndex);
+WGPU_EXPORT void wgpuRenderPassEncoderBeginPipelineStatisticsQuery(WGPURenderPassEncoder renderPassEncoder, WGPUQuerySet querySet, uint32_t queryIndex);
+WGPU_EXPORT void wgpuRenderPassEncoderDraw(WGPURenderPassEncoder renderPassEncoder, uint32_t vertexCount, uint32_t instanceCount, uint32_t firstVertex, uint32_t firstInstance);
+WGPU_EXPORT void wgpuRenderPassEncoderDrawIndexed(WGPURenderPassEncoder renderPassEncoder, uint32_t indexCount, uint32_t instanceCount, uint32_t firstIndex, int32_t baseVertex, uint32_t firstInstance);
+WGPU_EXPORT void wgpuRenderPassEncoderDrawIndexedIndirect(WGPURenderPassEncoder renderPassEncoder, WGPUBuffer indirectBuffer, uint64_t indirectOffset);
+WGPU_EXPORT void wgpuRenderPassEncoderDrawIndirect(WGPURenderPassEncoder renderPassEncoder, WGPUBuffer indirectBuffer, uint64_t indirectOffset);
+WGPU_EXPORT void wgpuRenderPassEncoderEndOcclusionQuery(WGPURenderPassEncoder renderPassEncoder);
+WGPU_EXPORT void wgpuRenderPassEncoderEndPass(WGPURenderPassEncoder renderPassEncoder);
+WGPU_EXPORT void wgpuRenderPassEncoderEndPipelineStatisticsQuery(WGPURenderPassEncoder renderPassEncoder);
+WGPU_EXPORT void wgpuRenderPassEncoderExecuteBundles(WGPURenderPassEncoder renderPassEncoder, uint32_t bundlesCount, WGPURenderBundle const * bundles);
+WGPU_EXPORT void wgpuRenderPassEncoderInsertDebugMarker(WGPURenderPassEncoder renderPassEncoder, char const * markerLabel);
+WGPU_EXPORT void wgpuRenderPassEncoderPopDebugGroup(WGPURenderPassEncoder renderPassEncoder);
+WGPU_EXPORT void wgpuRenderPassEncoderPushDebugGroup(WGPURenderPassEncoder renderPassEncoder, char const * groupLabel);
+WGPU_EXPORT void wgpuRenderPassEncoderSetBindGroup(WGPURenderPassEncoder renderPassEncoder, uint32_t groupIndex, WGPUBindGroup group, uint32_t dynamicOffsetCount, uint32_t const * dynamicOffsets);
+WGPU_EXPORT void wgpuRenderPassEncoderSetBlendConstant(WGPURenderPassEncoder renderPassEncoder, WGPUColor const * color);
+WGPU_EXPORT void wgpuRenderPassEncoderSetIndexBuffer(WGPURenderPassEncoder renderPassEncoder, WGPUBuffer buffer, WGPUIndexFormat format, uint64_t offset, uint64_t size);
+WGPU_EXPORT void wgpuRenderPassEncoderSetPipeline(WGPURenderPassEncoder renderPassEncoder, WGPURenderPipeline pipeline);
+WGPU_EXPORT void wgpuRenderPassEncoderSetScissorRect(WGPURenderPassEncoder renderPassEncoder, uint32_t x, uint32_t y, uint32_t width, uint32_t height);
+WGPU_EXPORT void wgpuRenderPassEncoderSetStencilReference(WGPURenderPassEncoder renderPassEncoder, uint32_t reference);
+WGPU_EXPORT void wgpuRenderPassEncoderSetVertexBuffer(WGPURenderPassEncoder renderPassEncoder, uint32_t slot, WGPUBuffer buffer, uint64_t offset, uint64_t size);
+WGPU_EXPORT void wgpuRenderPassEncoderSetViewport(WGPURenderPassEncoder renderPassEncoder, float x, float y, float width, float height, float minDepth, float maxDepth);
+WGPU_EXPORT void wgpuRenderPassEncoderWriteTimestamp(WGPURenderPassEncoder renderPassEncoder, WGPUQuerySet querySet, uint32_t queryIndex);
+
+// Methods of RenderPipeline
+WGPU_EXPORT WGPUBindGroupLayout wgpuRenderPipelineGetBindGroupLayout(WGPURenderPipeline renderPipeline, uint32_t groupIndex);
+
+// Methods of Surface
+WGPU_EXPORT void wgpuSurfaceGetPreferredFormat(WGPUSurface surface, WGPUAdapter adapter, WGPUSurfaceGetPreferredFormatCallback callback, void * userdata);
+
+// Methods of SwapChain
+WGPU_EXPORT WGPUTextureView wgpuSwapChainGetCurrentTextureView(WGPUSwapChain swapChain);
+WGPU_EXPORT void wgpuSwapChainPresent(WGPUSwapChain swapChain);
+
+// Methods of Texture
+WGPU_EXPORT WGPUTextureView wgpuTextureCreateView(WGPUTexture texture, WGPUTextureViewDescriptor const * descriptor);
+WGPU_EXPORT void wgpuTextureDestroy(WGPUTexture texture);
+
+#endif  // !defined(WGPU_SKIP_DECLARATIONS)
+
+#ifdef __cplusplus
+} // extern "C"
+#endif
+
+#endif // WEBGPU_H_
diff --git a/cbits/wgpu.h b/cbits/wgpu.h
new file mode 100644
--- /dev/null
+++ b/cbits/wgpu.h
@@ -0,0 +1,63 @@
+#ifndef WGPU_H_
+#define WGPU_H_
+
+#include "webgpu-headers/webgpu.h"
+
+typedef enum WGPUNativeSType {
+    // Start at 6 to prevent collisions with webgpu STypes
+    WGPUSType_DeviceExtras = 0x60000001,
+    WGPUSType_AdapterExtras = 0x60000002,
+    WGPUNativeSType_Force32 = 0x7FFFFFFF
+} WGPUNativeSType;
+
+typedef enum WGPUNativeFeature {
+    WGPUNativeFeature_TEXTURE_ADAPTER_SPECIFIC_FORMAT_FEATURES = 0x10000000
+} WGPUNativeFeature;
+
+typedef enum WGPULogLevel {
+    WGPULogLevel_Off = 0x00000000,
+    WGPULogLevel_Error = 0x00000001,
+    WGPULogLevel_Warn = 0x00000002,
+    WGPULogLevel_Info = 0x00000003,
+    WGPULogLevel_Debug = 0x00000004,
+    WGPULogLevel_Trace = 0x00000005,
+    WGPULogLevel_Force32 = 0x7FFFFFFF
+} WGPULogLevel;
+
+typedef struct WGPUAdapterExtras {
+    WGPUChainedStruct chain;
+    WGPUBackendType backend;
+} WGPUAdapterExtras;
+
+typedef struct WGPUDeviceExtras {
+    WGPUChainedStruct chain;
+    uint32_t maxTextureDimension1D;
+    uint32_t maxTextureDimension2D;
+    uint32_t maxTextureDimension3D;
+    uint32_t maxTextureArrayLayers;
+    uint32_t maxBindGroups;
+    uint32_t maxDynamicStorageBuffersPerPipelineLayout;
+    uint32_t maxStorageBuffersPerShaderStage;
+    uint32_t maxStorageBufferBindingSize;
+
+    WGPUNativeFeature nativeFeatures;
+
+    const char* label;
+    const char* tracePath;
+} WGPUDeviceExtras;
+
+
+
+typedef void (*WGPULogCallback)(WGPULogLevel level, const char *msg);
+
+void wgpuDevicePoll(WGPUDevice device, bool force_wait);
+
+void wgpuSetLogCallback(WGPULogCallback callback);
+
+void wgpuSetLogLevel(WGPULogLevel level);
+
+uint32_t wgpuGetVersion(void);
+
+void wgpuRenderPassEncoderSetPushConstants(WGPURenderPassEncoder encoder, WGPUShaderStage stages, uint32_t offset, uint32_t sizeBytes, void* const data);
+
+#endif
diff --git a/examples/triangle/Triangle.hs b/examples/triangle/Triangle.hs
new file mode 100644
--- /dev/null
+++ b/examples/triangle/Triangle.hs
@@ -0,0 +1,601 @@
+{-# LANGUAGE DisambiguateRecordFields #-}
+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE OverloadedStrings #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+
+-- | Create an SDL window and draw a triangle using WGPU.
+--
+-- Please note: This is more of a proof-of-concept test for the Raw API. The
+-- intent is to create a much nicer API on top of the Raw API. So this example
+-- isn't intended as a template for an actual application.
+module Triangle where
+
+import Control.Concurrent (MVar, newEmptyMVar, putMVar, takeMVar)
+import Control.Monad (unless)
+import Data.List (intersperse)
+import Data.Word (Word32)
+import Foreign (Ptr, alloca, castPtr, freeHaskellFunPtr, nullPtr, poke)
+import Foreign.C (CChar, peekCString, withCString)
+import Foreign.C.Types (CBool (CBool))
+import qualified Graphics.UI.GLFW as GLFW
+import System.Exit (exitFailure)
+import WGPU.Raw.Dynamic (withWGPU)
+import WGPU.Raw.GLFWSurface (createSurface)
+import qualified WGPU.Raw.Generated.Enum.WGPUBlendFactor as WGPUBlendFactor
+import qualified WGPU.Raw.Generated.Enum.WGPUBlendOperation as WGPUBlendOperation
+import qualified WGPU.Raw.Generated.Enum.WGPUColorWriteMask as WGPUColorWriteMask
+import qualified WGPU.Raw.Generated.Enum.WGPUCullMode as WGPUCullMode
+import qualified WGPU.Raw.Generated.Enum.WGPUFrontFace as WGPUFrontFace
+import qualified WGPU.Raw.Generated.Enum.WGPUIndexFormat as WGPUIndexFormat
+import WGPU.Raw.Generated.Enum.WGPULogLevel (WGPULogLevel)
+import qualified WGPU.Raw.Generated.Enum.WGPULogLevel as WGPULogLevel
+import qualified WGPU.Raw.Generated.Enum.WGPUNativeSType as WGPUSType
+import qualified WGPU.Raw.Generated.Enum.WGPUPresentMode as WGPUPresentMode
+import qualified WGPU.Raw.Generated.Enum.WGPUPrimitiveTopology as WGPUPrimitiveTopology
+import qualified WGPU.Raw.Generated.Enum.WGPUSType as WGPUSType
+import qualified WGPU.Raw.Generated.Enum.WGPUStoreOp as WGPULoadOp
+import qualified WGPU.Raw.Generated.Enum.WGPUStoreOp as WGPUStoreOp
+import WGPU.Raw.Generated.Enum.WGPUTextureFormat (WGPUTextureFormat (WGPUTextureFormat))
+import qualified WGPU.Raw.Generated.Enum.WGPUTextureUsage as WGPUTextureUsage
+import WGPU.Raw.Generated.Fun
+  ( WGPUHsInstance,
+    wgpuAdapterRequestDevice,
+    wgpuCommandEncoderBeginRenderPass,
+    wgpuCommandEncoderFinish,
+    wgpuDeviceCreateCommandEncoder,
+    wgpuDeviceCreatePipelineLayout,
+    wgpuDeviceCreateRenderPipeline,
+    wgpuDeviceCreateShaderModule,
+    wgpuDeviceCreateSwapChain,
+    wgpuDeviceGetQueue,
+    wgpuInstanceRequestAdapter,
+    wgpuQueueSubmit,
+    wgpuRenderPassEncoderDraw,
+    wgpuRenderPassEncoderEndPass,
+    wgpuRenderPassEncoderSetPipeline,
+    wgpuSetLogCallback,
+    wgpuSetLogLevel,
+    wgpuSurfaceGetPreferredFormat,
+    wgpuSwapChainGetCurrentTextureView,
+    wgpuSwapChainPresent,
+  )
+import WGPU.Raw.Generated.Struct.WGPUBlendComponent
+import WGPU.Raw.Generated.Struct.WGPUBlendState
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUColor
+import WGPU.Raw.Generated.Struct.WGPUColorTargetState
+import WGPU.Raw.Generated.Struct.WGPUCommandBufferDescriptor
+import WGPU.Raw.Generated.Struct.WGPUCommandEncoderDescriptor
+import WGPU.Raw.Generated.Struct.WGPUDeviceDescriptor
+import WGPU.Raw.Generated.Struct.WGPUDeviceExtras
+import WGPU.Raw.Generated.Struct.WGPUFragmentState
+import WGPU.Raw.Generated.Struct.WGPUMultisampleState
+import WGPU.Raw.Generated.Struct.WGPUPipelineLayoutDescriptor
+import WGPU.Raw.Generated.Struct.WGPUPrimitiveState
+import WGPU.Raw.Generated.Struct.WGPURenderPassColorAttachment
+import WGPU.Raw.Generated.Struct.WGPURenderPassDescriptor
+import WGPU.Raw.Generated.Struct.WGPURenderPipelineDescriptor
+import WGPU.Raw.Generated.Struct.WGPURequestAdapterOptions
+import WGPU.Raw.Generated.Struct.WGPUShaderModuleDescriptor
+import WGPU.Raw.Generated.Struct.WGPUShaderModuleWGSLDescriptor
+import WGPU.Raw.Generated.Struct.WGPUSwapChainDescriptor
+import WGPU.Raw.Generated.Struct.WGPUVertexState
+import WGPU.Raw.Types
+  ( WGPUAdapter (WGPUAdapter),
+    WGPUCommandBuffer,
+    WGPUCommandEncoder,
+    WGPUDevice (WGPUDevice),
+    WGPUInstance (WGPUInstance),
+    WGPULogCallback,
+    WGPUPipelineLayout,
+    WGPUQuerySet (WGPUQuerySet),
+    WGPUQueue,
+    WGPURenderPassEncoder,
+    WGPURenderPipeline,
+    WGPURequestAdapterCallback,
+    WGPURequestDeviceCallback,
+    WGPUShaderModule,
+    WGPUSurface,
+    WGPUSurfaceGetPreferredFormatCallback,
+    WGPUSwapChain,
+    WGPUTextureView (WGPUTextureView),
+  )
+
+main :: IO ()
+main = do
+  putStrLn "Triangle example"
+
+  let wwidth, wheight :: Int
+      wwidth = 640
+      wheight = 480
+
+  initResult <- GLFW.init
+  unless initResult $ do
+    putStrLn "GLFW initialization failed"
+    exitFailure
+
+  GLFW.windowHint (GLFW.WindowHint'ClientAPI GLFW.ClientAPI'NoAPI)
+  window <- do
+    mWindow <- GLFW.createWindow wwidth wheight "Triangle" Nothing Nothing
+    case mWindow of
+      Just w -> pure w
+      Nothing -> do
+        putStrLn "Could not create GLFW window"
+        exitFailure
+
+  withWGPU "libwgpu_native.dylib" $ \inst -> do
+    withLog inst WGPULogLevel.Warn $ do
+      surface <- createSurface inst window
+      adapter <- getAdapterForSurface inst surface
+      device <- getDevice inst adapter
+      shader <- compileWGSL inst device "shader" shaderSrc
+      pipelineLayout <- createPipelineLayout inst device
+      swapChainFormat <- getSwapChainFormat inst surface adapter
+      pipeline <-
+        createRenderPipeline inst device pipelineLayout shader swapChainFormat
+      swapChain <-
+        createSwapChain inst device surface swapChainFormat wwidth wheight
+
+      let loop = do
+            -- render
+            nextTexture <- wgpuSwapChainGetCurrentTextureView inst swapChain
+            encoder <- createCommandEncoder inst device
+            renderPass <- beginRenderPass inst encoder nextTexture
+            wgpuRenderPassEncoderSetPipeline inst renderPass pipeline
+            wgpuRenderPassEncoderDraw inst renderPass 3 1 0 0
+            wgpuRenderPassEncoderEndPass inst renderPass
+            queue <- wgpuDeviceGetQueue inst device
+            cmdBuffer <- commandEncoderFinish inst encoder
+            queueSubmit inst queue 1 cmdBuffer
+            wgpuSwapChainPresent inst swapChain
+
+            -- handle quit event
+            GLFW.pollEvents
+            shouldClose <- GLFW.windowShouldClose window
+            unless shouldClose loop
+      loop
+
+  GLFW.destroyWindow window
+  GLFW.terminate
+
+shaderSrc :: String
+shaderSrc =
+  mconcat $
+    intersperse
+      "\n"
+      [ "[[stage(vertex)]]",
+        "fn vs_main([[builtin(vertex_index)]] in_vertex_index: u32) -> [[builtin(position)]] vec4<f32> {",
+        "  let x = f32(i32(in_vertex_index) - 1);",
+        "  let y = f32(i32(in_vertex_index & 1u) * 2 - 1);",
+        "  return vec4<f32>(x, y, 0.0, 1.0);",
+        "}",
+        "",
+        "[[stage(fragment)]]",
+        "fn fs_main([[builtin(position)]] in: vec4<f32>) -> [[location(0)]] vec4<f32> {",
+        "  return vec4<f32>(in.x/640.0, in.y/480.0, 1.0, 1.0);",
+        "}"
+      ]
+
+-------------------------------------------------------------------------------
+
+withLog :: WGPUHsInstance -> WGPULogLevel -> IO a -> IO a
+withLog inst logLevel action = do
+  let logCallback :: WGPULogLevel -> Ptr CChar -> IO ()
+      logCallback lLvl cMsg = do
+        let prefix =
+              case lLvl of
+                WGPULogLevel.Error -> "Error"
+                WGPULogLevel.Warn -> "Warn"
+                WGPULogLevel.Info -> "Info"
+                WGPULogLevel.Debug -> "Debug"
+                WGPULogLevel.Trace -> "Trace"
+                _ -> "Unknown"
+        msg <- peekCString cMsg
+        putStrLn $ "[" <> prefix <> "] " <> msg
+
+  logCallback_c :: WGPULogCallback <- mkLogCallback logCallback
+  wgpuSetLogCallback inst logCallback_c
+  wgpuSetLogLevel inst logLevel
+  result <- action
+
+  freeHaskellFunPtr logCallback_c
+
+  pure result
+
+foreign import ccall "wrapper"
+  mkLogCallback ::
+    (WGPULogLevel -> Ptr CChar -> IO ()) ->
+    IO WGPULogCallback
+
+-------------------------------------------------------------------------------
+
+-- | Get a WGPU Adapter which matches the supplied surface.
+getAdapterForSurface :: WGPUHsInstance -> WGPUSurface -> IO WGPUAdapter
+getAdapterForSurface inst surface = do
+  adapterMVar :: MVar WGPUAdapter <- newEmptyMVar
+
+  let adapterCallback :: WGPUAdapter -> Ptr () -> IO ()
+      adapterCallback adapter _ = putMVar adapterMVar adapter
+
+  adapterCallback_c :: WGPURequestAdapterCallback <-
+    mkAdapterCallback adapterCallback
+
+  alloca $ \requestAdapterOptions_ptr -> do
+    let requestAdapterOptions =
+          WGPURequestAdapterOptions
+            { nextInChain = nullPtr,
+              compatibleSurface = surface
+            }
+    poke requestAdapterOptions_ptr requestAdapterOptions
+    wgpuInstanceRequestAdapter
+      inst
+      (WGPUInstance nullPtr)
+      requestAdapterOptions_ptr
+      adapterCallback_c
+      nullPtr
+
+  adapter :: WGPUAdapter <- takeMVar adapterMVar
+  freeHaskellFunPtr adapterCallback_c
+  pure adapter
+
+foreign import ccall "wrapper"
+  mkAdapterCallback ::
+    (WGPUAdapter -> Ptr () -> IO ()) -> IO WGPURequestAdapterCallback
+
+-------------------------------------------------------------------------------
+
+-- | Get a WGPU Device.
+getDevice :: WGPUHsInstance -> WGPUAdapter -> IO WGPUDevice
+getDevice inst adapter = do
+  deviceMVar :: MVar WGPUDevice <- newEmptyMVar
+
+  let deviceCallback :: WGPUDevice -> Ptr () -> IO ()
+      deviceCallback device _ = putMVar deviceMVar device
+
+  deviceCallback_c :: WGPURequestDeviceCallback <-
+    mkDeviceCallback deviceCallback
+
+  alloca $ \deviceDescriptor_ptr -> do
+    alloca $ \chainedStruct_ptr -> do
+      alloca $ \deviceExtras_ptr -> do
+        let deviceExtras =
+              WGPUDeviceExtras
+                { chain =
+                    WGPUChainedStruct
+                      { next = nullPtr,
+                        sType = WGPUSType.DeviceExtras
+                      },
+                  maxTextureDimension1D = 0,
+                  maxTextureDimension2D = 0,
+                  maxTextureDimension3D = 0,
+                  maxTextureArrayLayers = 0,
+                  maxBindGroups = 1,
+                  maxDynamicStorageBuffersPerPipelineLayout = 0,
+                  maxStorageBuffersPerShaderStage = 0,
+                  maxStorageBufferBindingSize = 0,
+                  nativeFeatures = 0,
+                  label = nullPtr,
+                  tracePath = nullPtr
+                }
+        poke deviceExtras_ptr deviceExtras
+
+        let chainedStruct =
+              WGPUChainedStruct
+                { next = castPtr deviceExtras_ptr,
+                  sType = WGPUSType.DeviceExtras
+                }
+        poke chainedStruct_ptr chainedStruct
+
+        let deviceDescriptor =
+              WGPUDeviceDescriptor
+                { nextInChain = chainedStruct_ptr
+                }
+        poke deviceDescriptor_ptr deviceDescriptor
+
+        wgpuAdapterRequestDevice
+          inst
+          adapter
+          deviceDescriptor_ptr
+          deviceCallback_c
+          nullPtr
+
+  device :: WGPUDevice <- takeMVar deviceMVar
+  freeHaskellFunPtr deviceCallback_c
+  pure device
+
+foreign import ccall "wrapper"
+  mkDeviceCallback ::
+    (WGPUDevice -> Ptr () -> IO ()) -> IO WGPURequestDeviceCallback
+
+-------------------------------------------------------------------------------
+
+-- | Compile a shader.
+compileWGSL ::
+  -- | WGPUHs instance.
+  WGPUHsInstance ->
+  -- | WGPU Device.
+  WGPUDevice ->
+  -- | Name of the shader.
+  String ->
+  -- | Shader source.
+  String ->
+  -- | Compiled shader module.
+  IO WGPUShaderModule
+compileWGSL inst device name src = do
+  withCString name $ \name_ptr -> do
+    withCString src $ \src_ptr -> do
+      alloca $ \shaderModuleDescriptor_ptr -> do
+        alloca $ \chainedStruct_ptr -> do
+          alloca $ \shaderModuleWGSLDescriptor_ptr -> do
+            let shaderModuleWGSLDescriptor =
+                  WGPUShaderModuleWGSLDescriptor
+                    { chain =
+                        WGPUChainedStruct
+                          { next = nullPtr,
+                            sType = WGPUSType.ShaderModuleWGSLDescriptor
+                          },
+                      source = src_ptr
+                    }
+            poke shaderModuleWGSLDescriptor_ptr shaderModuleWGSLDescriptor
+
+            let chainedStruct =
+                  WGPUChainedStruct
+                    { next = castPtr shaderModuleWGSLDescriptor_ptr,
+                      sType = WGPUSType.ShaderModuleWGSLDescriptor
+                    }
+            poke chainedStruct_ptr chainedStruct
+
+            let shaderModuleDescriptor =
+                  WGPUShaderModuleDescriptor
+                    { nextInChain = chainedStruct_ptr,
+                      label = name_ptr
+                    }
+            poke shaderModuleDescriptor_ptr shaderModuleDescriptor
+
+            wgpuDeviceCreateShaderModule inst device shaderModuleDescriptor_ptr
+
+-------------------------------------------------------------------------------
+
+-- | Create pipeline layout.
+createPipelineLayout :: WGPUHsInstance -> WGPUDevice -> IO WGPUPipelineLayout
+createPipelineLayout inst device = do
+  alloca $ \pipelineLayoutDescriptor_ptr -> do
+    let pipelineLayoutDescriptor =
+          WGPUPipelineLayoutDescriptor
+            { nextInChain = nullPtr,
+              label = nullPtr,
+              bindGroupLayoutCount = 0,
+              bindGroupLayouts = nullPtr
+            }
+    poke pipelineLayoutDescriptor_ptr pipelineLayoutDescriptor
+
+    wgpuDeviceCreatePipelineLayout inst device pipelineLayoutDescriptor_ptr
+
+-------------------------------------------------------------------------------
+
+-- | Get preferred format for the swapchain
+getSwapChainFormat ::
+  WGPUHsInstance ->
+  WGPUSurface ->
+  WGPUAdapter ->
+  IO WGPUTextureFormat
+getSwapChainFormat inst surface adapter = do
+  textureFormatMVar :: MVar WGPUTextureFormat <- newEmptyMVar
+
+  let textureFormatCallback :: WGPUTextureFormat -> Ptr () -> IO ()
+      textureFormatCallback tf _ = putMVar textureFormatMVar tf
+
+  textureFormatCallback_c :: WGPUSurfaceGetPreferredFormatCallback <-
+    mkSurfaceGetPreferredFormatCallback textureFormatCallback
+
+  wgpuSurfaceGetPreferredFormat
+    inst
+    surface
+    adapter
+    textureFormatCallback_c
+    nullPtr
+
+  textureFormat :: WGPUTextureFormat <- takeMVar textureFormatMVar
+  freeHaskellFunPtr textureFormatCallback_c
+  pure textureFormat
+
+foreign import ccall "wrapper"
+  mkSurfaceGetPreferredFormatCallback ::
+    (WGPUTextureFormat -> Ptr () -> IO ()) ->
+    IO WGPUSurfaceGetPreferredFormatCallback
+
+-------------------------------------------------------------------------------
+
+createRenderPipeline ::
+  WGPUHsInstance ->
+  WGPUDevice ->
+  WGPUPipelineLayout ->
+  WGPUShaderModule ->
+  WGPUTextureFormat ->
+  IO WGPURenderPipeline
+createRenderPipeline inst device pipelineLayout shader swapChainFormat = do
+  withCString "vs_main" $ \vsEntryPoint_ptr -> do
+    withCString "fs_main" $ \fsEntryPoint_ptr -> do
+      alloca $ \blendState_ptr -> do
+        alloca $ \colorTargetState_ptr -> do
+          alloca $ \fragmentState_ptr -> do
+            alloca $ \renderPipelineDescriptor_ptr -> do
+              let blendState =
+                    WGPUBlendState
+                      { color =
+                          WGPUBlendComponent
+                            { srcFactor = WGPUBlendFactor.One,
+                              dstFactor = WGPUBlendFactor.Zero,
+                              operation = WGPUBlendOperation.Add
+                            },
+                        alpha =
+                          WGPUBlendComponent
+                            { srcFactor = WGPUBlendFactor.One,
+                              dstFactor = WGPUBlendFactor.Zero,
+                              operation = WGPUBlendOperation.Add
+                            }
+                      }
+              poke blendState_ptr blendState
+
+              let colorTargetState =
+                    WGPUColorTargetState
+                      { nextInChain = nullPtr,
+                        format = swapChainFormat,
+                        blend = blendState_ptr,
+                        writeMask = WGPUColorWriteMask.All
+                      }
+              poke colorTargetState_ptr colorTargetState
+
+              let fragmentState =
+                    WGPUFragmentState
+                      { nextInChain = nullPtr,
+                        shaderModule = shader,
+                        entryPoint = fsEntryPoint_ptr,
+                        targetCount = 1,
+                        targets = colorTargetState_ptr
+                      }
+              poke fragmentState_ptr fragmentState
+
+              let renderPipelineDescriptor =
+                    WGPURenderPipelineDescriptor
+                      { nextInChain = nullPtr,
+                        label = nullPtr,
+                        layout = pipelineLayout,
+                        vertex =
+                          WGPUVertexState
+                            { nextInChain = nullPtr,
+                              shaderModule = shader,
+                              entryPoint = vsEntryPoint_ptr,
+                              bufferCount = 0,
+                              buffers = nullPtr
+                            },
+                        primitive =
+                          WGPUPrimitiveState
+                            { nextInChain = nullPtr,
+                              topology = WGPUPrimitiveTopology.TriangleList,
+                              stripIndexFormat = WGPUIndexFormat.Undefined,
+                              frontFace = WGPUFrontFace.CCW,
+                              cullMode = WGPUCullMode.None
+                            },
+                        depthStencil = nullPtr,
+                        multisample =
+                          WGPUMultisampleState
+                            { nextInChain = nullPtr,
+                              count = 1,
+                              mask = 0xFFFFFFFF,
+                              alphaToCoverageEnabled = CBool 0
+                            },
+                        fragment = fragmentState_ptr
+                      }
+              poke renderPipelineDescriptor_ptr renderPipelineDescriptor
+
+              wgpuDeviceCreateRenderPipeline
+                inst
+                device
+                renderPipelineDescriptor_ptr
+
+-------------------------------------------------------------------------------
+
+createSwapChain ::
+  WGPUHsInstance ->
+  WGPUDevice ->
+  WGPUSurface ->
+  WGPUTextureFormat ->
+  Int ->
+  Int ->
+  IO WGPUSwapChain
+createSwapChain inst device surface swapChainFormat w h = do
+  withCString "swapChain" $ \swapChainName_ptr ->
+    alloca $ \swapChainDescriptor_ptr -> do
+      let swapChainDescriptor =
+            WGPUSwapChainDescriptor
+              { nextInChain = nullPtr,
+                label = swapChainName_ptr,
+                usage = WGPUTextureUsage.RenderAttachment,
+                format = swapChainFormat,
+                width = fromIntegral w,
+                height = fromIntegral h,
+                presentMode = WGPUPresentMode.Fifo
+              }
+      poke swapChainDescriptor_ptr swapChainDescriptor
+      wgpuDeviceCreateSwapChain inst device surface swapChainDescriptor_ptr
+
+-------------------------------------------------------------------------------
+
+createCommandEncoder ::
+  WGPUHsInstance ->
+  WGPUDevice ->
+  IO WGPUCommandEncoder
+createCommandEncoder inst device = do
+  alloca $ \commandEncoderDescriptor_ptr -> do
+    let commandEncoderDescriptor =
+          WGPUCommandEncoderDescriptor
+            { nextInChain = nullPtr,
+              label = nullPtr
+            }
+    poke commandEncoderDescriptor_ptr commandEncoderDescriptor
+    wgpuDeviceCreateCommandEncoder inst device commandEncoderDescriptor_ptr
+
+-------------------------------------------------------------------------------
+
+beginRenderPass ::
+  WGPUHsInstance ->
+  WGPUCommandEncoder ->
+  WGPUTextureView ->
+  IO WGPURenderPassEncoder
+beginRenderPass inst cmdEncoder textureView = do
+  alloca $ \renderPassColorAttachment_ptr -> do
+    alloca $ \renderPassDescriptor_ptr -> do
+      let renderPassColorAttachment =
+            WGPURenderPassColorAttachment
+              { view = textureView,
+                resolveTarget = WGPUTextureView nullPtr,
+                loadOp = WGPULoadOp.Clear,
+                storeOp = WGPUStoreOp.Store,
+                clearColor = WGPUColor 0 0 0 1
+              }
+      poke renderPassColorAttachment_ptr renderPassColorAttachment
+
+      let renderPassDescriptor =
+            WGPURenderPassDescriptor
+              { nextInChain = nullPtr,
+                label = nullPtr,
+                colorAttachmentCount = 1,
+                colorAttachments = renderPassColorAttachment_ptr,
+                depthStencilAttachment = nullPtr,
+                occlusionQuerySet = WGPUQuerySet nullPtr
+              }
+      poke renderPassDescriptor_ptr renderPassDescriptor
+
+      wgpuCommandEncoderBeginRenderPass inst cmdEncoder renderPassDescriptor_ptr
+
+-------------------------------------------------------------------------------
+
+commandEncoderFinish ::
+  WGPUHsInstance ->
+  WGPUCommandEncoder ->
+  IO WGPUCommandBuffer
+commandEncoderFinish inst encoder = do
+  alloca $ \commandBufferDescriptor_ptr -> do
+    let commandBufferDescriptor =
+          WGPUCommandBufferDescriptor
+            { nextInChain = nullPtr,
+              label = nullPtr
+            }
+    poke commandBufferDescriptor_ptr commandBufferDescriptor
+
+    wgpuCommandEncoderFinish inst encoder commandBufferDescriptor_ptr
+
+-------------------------------------------------------------------------------
+
+queueSubmit ::
+  WGPUHsInstance ->
+  WGPUQueue ->
+  Word32 ->
+  WGPUCommandBuffer ->
+  IO ()
+queueSubmit inst queue n cmdBuffer = do
+  alloca $ \commandBuffer_ptr -> do
+    poke commandBuffer_ptr cmdBuffer
+
+    wgpuQueueSubmit inst queue n commandBuffer_ptr
diff --git a/src/WGPU/Raw/Dynamic.hs b/src/WGPU/Raw/Dynamic.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Dynamic.hs
@@ -0,0 +1,47 @@
+{-# LANGUAGE CPP #-}
+
+-- |
+module WGPU.Raw.Dynamic
+  ( -- * Functions
+    withWGPU,
+  )
+where
+
+import WGPU.Raw.Generated.Fun (WGPUHsInstance, loadDynamicInstance)
+
+#ifdef WGPUHS_UNIX
+import System.Posix.DynamicLinker (withDL, dlsym)
+
+-- | Load WGPU from a dynamic library and run a program using an instance.
+withWGPU ::
+  -- | Path to the wgpu-native dynamic library to load.
+  FilePath ->
+  -- | IO action using an instance of the WGPUHsInstance.
+  (WGPUHsInstance -> IO a) ->
+  -- | Completed IO action.
+  IO a
+withWGPU dynlibFile action = do
+  withDL dynlibFile [] $ \dl -> loadDynamicInstance (dlsym dl) >>= action
+#endif
+
+#ifdef WGPUHS_WINDOWS
+import Foreign (castPtrToFunPtr)
+import System.Win32.DLL (loadLibrary, freeLibrary, getProcAddress)
+
+-- | Load WGPU from a dynamic library and run a program using an instance.
+withWGPU ::
+  -- | Path to the wgpu-native dynamic library to load.
+  FilePath ->
+  -- | IO action using an instance of the WGPUHsInstance.
+  (WGPUHsInstance -> IO a) ->
+  -- | Completed IO action.
+  IO a
+withWGPU dynlibFile action = do
+  -- TODO: safer bracketing
+  hInstance <- loadLibrary dynlibFile
+  let load :: String -> IO (FunPtr a)
+      load = castPtrToFunPtr <$> getProcAddress
+  wgpuHsInstance <- loadDynamicInstance load
+  action wgpuHsInstance
+  freeLibrary hInstance
+#endif
diff --git a/src/WGPU/Raw/GLFWSurface.hs b/src/WGPU/Raw/GLFWSurface.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/GLFWSurface.hs
@@ -0,0 +1,65 @@
+{-# LANGUAGE CPP #-}
+{-# LANGUAGE ForeignFunctionInterface #-}
+
+-- |
+module WGPU.Raw.GLFWSurface where
+
+import Foreign (Ptr, alloca, castPtr, nullPtr, poke)
+import qualified Graphics.UI.GLFW as GLFW
+import qualified WGPU.Raw.Generated.Enum.WGPUSType as WGPUSType
+import WGPU.Raw.Generated.Fun (WGPUHsInstance, wgpuInstanceCreateSurface)
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptor
+import WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptorFromMetalLayer
+import WGPU.Raw.Types (WGPUInstance (WGPUInstance), WGPUSurface)
+
+#ifdef WGPUHS_TARGET_MACOS
+
+createSurface ::
+  WGPUHsInstance ->
+  GLFW.Window ->
+  IO WGPUSurface
+createSurface inst window = do
+  nsWindow <- GLFW.getCocoaWindow window
+  metalLayer <- wgpuhs_metal_layer nsWindow
+
+  alloca $ \ptr_surfaceDescriptor -> do
+    alloca $ \ptr_chainedStruct -> do
+      alloca $ \ptr_surfaceDescriptorFromMetalLayer -> do
+
+        let surfaceDescriptorFromMetalLayer =
+              WGPUSurfaceDescriptorFromMetalLayer
+              { chain =
+                  WGPUChainedStruct
+                  { next = nullPtr,
+                    sType = WGPUSType.SurfaceDescriptorFromMetalLayer
+                  },
+                layer = metalLayer
+              }
+        poke ptr_surfaceDescriptorFromMetalLayer surfaceDescriptorFromMetalLayer
+
+        let chainedStruct =
+              WGPUChainedStruct
+              { next = castPtr ptr_surfaceDescriptorFromMetalLayer,
+                sType = WGPUSType.SurfaceDescriptorFromMetalLayer
+              }
+        poke ptr_chainedStruct chainedStruct
+
+        let surfaceDescriptor =
+              WGPUSurfaceDescriptor
+              { nextInChain = ptr_chainedStruct,
+                label = nullPtr
+              }
+        poke ptr_surfaceDescriptor surfaceDescriptor
+
+        wgpuInstanceCreateSurface
+          inst
+          (WGPUInstance nullPtr)
+          ptr_surfaceDescriptor
+
+foreign import ccall "wgpuhs_metal_layer"
+  wgpuhs_metal_layer ::
+    Ptr () ->
+    IO (Ptr ())
+
+#endif
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUAdapterType.hs b/src/WGPU/Raw/Generated/Enum/WGPUAdapterType.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUAdapterType.hs
@@ -0,0 +1,30 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUAdapterType where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUAdapterType = WGPUAdapterType Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern DiscreteGPU :: forall a. (Eq a, Num a) => a
+pattern DiscreteGPU = 0x00000000
+
+pattern IntegratedGPU :: forall a. (Eq a, Num a) => a
+pattern IntegratedGPU = 0x00000001
+
+pattern CPU :: forall a. (Eq a, Num a) => a
+pattern CPU = 0x00000002
+
+pattern Unknown :: forall a. (Eq a, Num a) => a
+pattern Unknown = 0x00000003
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUAddressMode.hs b/src/WGPU/Raw/Generated/Enum/WGPUAddressMode.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUAddressMode.hs
@@ -0,0 +1,27 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUAddressMode where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUAddressMode = WGPUAddressMode Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Repeat :: forall a. (Eq a, Num a) => a
+pattern Repeat = 0x00000000
+
+pattern MirrorRepeat :: forall a. (Eq a, Num a) => a
+pattern MirrorRepeat = 0x00000001
+
+pattern ClampToEdge :: forall a. (Eq a, Num a) => a
+pattern ClampToEdge = 0x00000002
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUBackendType.hs b/src/WGPU/Raw/Generated/Enum/WGPUBackendType.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUBackendType.hs
@@ -0,0 +1,39 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUBackendType where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUBackendType = WGPUBackendType Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Null :: forall a. (Eq a, Num a) => a
+pattern Null = 0x00000000
+
+pattern D3D11 :: forall a. (Eq a, Num a) => a
+pattern D3D11 = 0x00000001
+
+pattern D3D12 :: forall a. (Eq a, Num a) => a
+pattern D3D12 = 0x00000002
+
+pattern Metal :: forall a. (Eq a, Num a) => a
+pattern Metal = 0x00000003
+
+pattern Vulkan :: forall a. (Eq a, Num a) => a
+pattern Vulkan = 0x00000004
+
+pattern OpenGL :: forall a. (Eq a, Num a) => a
+pattern OpenGL = 0x00000005
+
+pattern OpenGLES :: forall a. (Eq a, Num a) => a
+pattern OpenGLES = 0x00000006
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUBlendFactor.hs b/src/WGPU/Raw/Generated/Enum/WGPUBlendFactor.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUBlendFactor.hs
@@ -0,0 +1,57 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUBlendFactor where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUBlendFactor = WGPUBlendFactor Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Zero :: forall a. (Eq a, Num a) => a
+pattern Zero = 0x00000000
+
+pattern One :: forall a. (Eq a, Num a) => a
+pattern One = 0x00000001
+
+pattern Src :: forall a. (Eq a, Num a) => a
+pattern Src = 0x00000002
+
+pattern OneMinusSrc :: forall a. (Eq a, Num a) => a
+pattern OneMinusSrc = 0x00000003
+
+pattern SrcAlpha :: forall a. (Eq a, Num a) => a
+pattern SrcAlpha = 0x00000004
+
+pattern OneMinusSrcAlpha :: forall a. (Eq a, Num a) => a
+pattern OneMinusSrcAlpha = 0x00000005
+
+pattern Dst :: forall a. (Eq a, Num a) => a
+pattern Dst = 0x00000006
+
+pattern OneMinusDst :: forall a. (Eq a, Num a) => a
+pattern OneMinusDst = 0x00000007
+
+pattern DstAlpha :: forall a. (Eq a, Num a) => a
+pattern DstAlpha = 0x00000008
+
+pattern OneMinusDstAlpha :: forall a. (Eq a, Num a) => a
+pattern OneMinusDstAlpha = 0x00000009
+
+pattern SrcAlphaSaturated :: forall a. (Eq a, Num a) => a
+pattern SrcAlphaSaturated = 0x0000000A
+
+pattern Constant :: forall a. (Eq a, Num a) => a
+pattern Constant = 0x0000000B
+
+pattern OneMinusConstant :: forall a. (Eq a, Num a) => a
+pattern OneMinusConstant = 0x0000000C
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUBlendOperation.hs b/src/WGPU/Raw/Generated/Enum/WGPUBlendOperation.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUBlendOperation.hs
@@ -0,0 +1,33 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUBlendOperation where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUBlendOperation = WGPUBlendOperation Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Add :: forall a. (Eq a, Num a) => a
+pattern Add = 0x00000000
+
+pattern Subtract :: forall a. (Eq a, Num a) => a
+pattern Subtract = 0x00000001
+
+pattern ReverseSubtract :: forall a. (Eq a, Num a) => a
+pattern ReverseSubtract = 0x00000002
+
+pattern Min :: forall a. (Eq a, Num a) => a
+pattern Min = 0x00000003
+
+pattern Max :: forall a. (Eq a, Num a) => a
+pattern Max = 0x00000004
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUBufferBindingType.hs b/src/WGPU/Raw/Generated/Enum/WGPUBufferBindingType.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUBufferBindingType.hs
@@ -0,0 +1,30 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUBufferBindingType where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUBufferBindingType = WGPUBufferBindingType Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Undefined :: forall a. (Eq a, Num a) => a
+pattern Undefined = 0x00000000
+
+pattern Uniform :: forall a. (Eq a, Num a) => a
+pattern Uniform = 0x00000001
+
+pattern Storage :: forall a. (Eq a, Num a) => a
+pattern Storage = 0x00000002
+
+pattern ReadOnlyStorage :: forall a. (Eq a, Num a) => a
+pattern ReadOnlyStorage = 0x00000003
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUBufferMapAsyncStatus.hs b/src/WGPU/Raw/Generated/Enum/WGPUBufferMapAsyncStatus.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUBufferMapAsyncStatus.hs
@@ -0,0 +1,36 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUBufferMapAsyncStatus where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUBufferMapAsyncStatus = WGPUBufferMapAsyncStatus Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Success :: forall a. (Eq a, Num a) => a
+pattern Success = 0x00000000
+
+pattern Error :: forall a. (Eq a, Num a) => a
+pattern Error = 0x00000001
+
+pattern Unknown :: forall a. (Eq a, Num a) => a
+pattern Unknown = 0x00000002
+
+pattern DeviceLost :: forall a. (Eq a, Num a) => a
+pattern DeviceLost = 0x00000003
+
+pattern DestroyedBeforeCallback :: forall a. (Eq a, Num a) => a
+pattern DestroyedBeforeCallback = 0x00000004
+
+pattern UnmappedBeforeCallback :: forall a. (Eq a, Num a) => a
+pattern UnmappedBeforeCallback = 0x00000005
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUBufferUsage.hs b/src/WGPU/Raw/Generated/Enum/WGPUBufferUsage.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUBufferUsage.hs
@@ -0,0 +1,51 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUBufferUsage where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUBufferUsage = WGPUBufferUsage Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern None :: forall a. (Eq a, Num a) => a
+pattern None = 0x00000000
+
+pattern MapRead :: forall a. (Eq a, Num a) => a
+pattern MapRead = 0x00000001
+
+pattern MapWrite :: forall a. (Eq a, Num a) => a
+pattern MapWrite = 0x00000002
+
+pattern CopySrc :: forall a. (Eq a, Num a) => a
+pattern CopySrc = 0x00000004
+
+pattern CopyDst :: forall a. (Eq a, Num a) => a
+pattern CopyDst = 0x00000008
+
+pattern Index :: forall a. (Eq a, Num a) => a
+pattern Index = 0x00000010
+
+pattern Vertex :: forall a. (Eq a, Num a) => a
+pattern Vertex = 0x00000020
+
+pattern Uniform :: forall a. (Eq a, Num a) => a
+pattern Uniform = 0x00000040
+
+pattern Storage :: forall a. (Eq a, Num a) => a
+pattern Storage = 0x00000080
+
+pattern Indirect :: forall a. (Eq a, Num a) => a
+pattern Indirect = 0x00000100
+
+pattern QueryResolve :: forall a. (Eq a, Num a) => a
+pattern QueryResolve = 0x00000200
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUColorWriteMask.hs b/src/WGPU/Raw/Generated/Enum/WGPUColorWriteMask.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUColorWriteMask.hs
@@ -0,0 +1,36 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUColorWriteMask where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUColorWriteMask = WGPUColorWriteMask Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern None :: forall a. (Eq a, Num a) => a
+pattern None = 0x00000000
+
+pattern Red :: forall a. (Eq a, Num a) => a
+pattern Red = 0x00000001
+
+pattern Green :: forall a. (Eq a, Num a) => a
+pattern Green = 0x00000002
+
+pattern Blue :: forall a. (Eq a, Num a) => a
+pattern Blue = 0x00000004
+
+pattern Alpha :: forall a. (Eq a, Num a) => a
+pattern Alpha = 0x00000008
+
+pattern All :: forall a. (Eq a, Num a) => a
+pattern All = 0x0000000F
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUCompareFunction.hs b/src/WGPU/Raw/Generated/Enum/WGPUCompareFunction.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUCompareFunction.hs
@@ -0,0 +1,45 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUCompareFunction where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUCompareFunction = WGPUCompareFunction Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Undefined :: forall a. (Eq a, Num a) => a
+pattern Undefined = 0x00000000
+
+pattern Never :: forall a. (Eq a, Num a) => a
+pattern Never = 0x00000001
+
+pattern Less :: forall a. (Eq a, Num a) => a
+pattern Less = 0x00000002
+
+pattern LessEqual :: forall a. (Eq a, Num a) => a
+pattern LessEqual = 0x00000003
+
+pattern Greater :: forall a. (Eq a, Num a) => a
+pattern Greater = 0x00000004
+
+pattern GreaterEqual :: forall a. (Eq a, Num a) => a
+pattern GreaterEqual = 0x00000005
+
+pattern Equal :: forall a. (Eq a, Num a) => a
+pattern Equal = 0x00000006
+
+pattern NotEqual :: forall a. (Eq a, Num a) => a
+pattern NotEqual = 0x00000007
+
+pattern Always :: forall a. (Eq a, Num a) => a
+pattern Always = 0x00000008
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUCreatePipelineAsyncStatus.hs b/src/WGPU/Raw/Generated/Enum/WGPUCreatePipelineAsyncStatus.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUCreatePipelineAsyncStatus.hs
@@ -0,0 +1,33 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUCreatePipelineAsyncStatus where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUCreatePipelineAsyncStatus = WGPUCreatePipelineAsyncStatus Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Success :: forall a. (Eq a, Num a) => a
+pattern Success = 0x00000000
+
+pattern Error :: forall a. (Eq a, Num a) => a
+pattern Error = 0x00000001
+
+pattern DeviceLost :: forall a. (Eq a, Num a) => a
+pattern DeviceLost = 0x00000002
+
+pattern DeviceDestroyed :: forall a. (Eq a, Num a) => a
+pattern DeviceDestroyed = 0x00000003
+
+pattern Unknown :: forall a. (Eq a, Num a) => a
+pattern Unknown = 0x00000004
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUCullMode.hs b/src/WGPU/Raw/Generated/Enum/WGPUCullMode.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUCullMode.hs
@@ -0,0 +1,27 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUCullMode where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUCullMode = WGPUCullMode Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern None :: forall a. (Eq a, Num a) => a
+pattern None = 0x00000000
+
+pattern Front :: forall a. (Eq a, Num a) => a
+pattern Front = 0x00000001
+
+pattern Back :: forall a. (Eq a, Num a) => a
+pattern Back = 0x00000002
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUErrorFilter.hs b/src/WGPU/Raw/Generated/Enum/WGPUErrorFilter.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUErrorFilter.hs
@@ -0,0 +1,27 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUErrorFilter where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUErrorFilter = WGPUErrorFilter Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern None :: forall a. (Eq a, Num a) => a
+pattern None = 0x00000000
+
+pattern Validation :: forall a. (Eq a, Num a) => a
+pattern Validation = 0x00000001
+
+pattern OutOfMemory :: forall a. (Eq a, Num a) => a
+pattern OutOfMemory = 0x00000002
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUErrorType.hs b/src/WGPU/Raw/Generated/Enum/WGPUErrorType.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUErrorType.hs
@@ -0,0 +1,33 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUErrorType where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUErrorType = WGPUErrorType Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern NoError :: forall a. (Eq a, Num a) => a
+pattern NoError = 0x00000000
+
+pattern Validation :: forall a. (Eq a, Num a) => a
+pattern Validation = 0x00000001
+
+pattern OutOfMemory :: forall a. (Eq a, Num a) => a
+pattern OutOfMemory = 0x00000002
+
+pattern Unknown :: forall a. (Eq a, Num a) => a
+pattern Unknown = 0x00000003
+
+pattern DeviceLost :: forall a. (Eq a, Num a) => a
+pattern DeviceLost = 0x00000004
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUFilterMode.hs b/src/WGPU/Raw/Generated/Enum/WGPUFilterMode.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUFilterMode.hs
@@ -0,0 +1,24 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUFilterMode where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUFilterMode = WGPUFilterMode Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Nearest :: forall a. (Eq a, Num a) => a
+pattern Nearest = 0x00000000
+
+pattern Linear :: forall a. (Eq a, Num a) => a
+pattern Linear = 0x00000001
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUFrontFace.hs b/src/WGPU/Raw/Generated/Enum/WGPUFrontFace.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUFrontFace.hs
@@ -0,0 +1,24 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUFrontFace where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUFrontFace = WGPUFrontFace Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern CCW :: forall a. (Eq a, Num a) => a
+pattern CCW = 0x00000000
+
+pattern CW :: forall a. (Eq a, Num a) => a
+pattern CW = 0x00000001
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUIndexFormat.hs b/src/WGPU/Raw/Generated/Enum/WGPUIndexFormat.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUIndexFormat.hs
@@ -0,0 +1,27 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUIndexFormat where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUIndexFormat = WGPUIndexFormat Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Undefined :: forall a. (Eq a, Num a) => a
+pattern Undefined = 0x00000000
+
+pattern Uint16 :: forall a. (Eq a, Num a) => a
+pattern Uint16 = 0x00000001
+
+pattern Uint32 :: forall a. (Eq a, Num a) => a
+pattern Uint32 = 0x00000002
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUInputStepMode.hs b/src/WGPU/Raw/Generated/Enum/WGPUInputStepMode.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUInputStepMode.hs
@@ -0,0 +1,24 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUInputStepMode where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUInputStepMode = WGPUInputStepMode Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Vertex :: forall a. (Eq a, Num a) => a
+pattern Vertex = 0x00000000
+
+pattern Instance :: forall a. (Eq a, Num a) => a
+pattern Instance = 0x00000001
diff --git a/src/WGPU/Raw/Generated/Enum/WGPULoadOp.hs b/src/WGPU/Raw/Generated/Enum/WGPULoadOp.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPULoadOp.hs
@@ -0,0 +1,24 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPULoadOp where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPULoadOp = WGPULoadOp Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Clear :: forall a. (Eq a, Num a) => a
+pattern Clear = 0x00000000
+
+pattern Load :: forall a. (Eq a, Num a) => a
+pattern Load = 0x00000001
diff --git a/src/WGPU/Raw/Generated/Enum/WGPULogLevel.hs b/src/WGPU/Raw/Generated/Enum/WGPULogLevel.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPULogLevel.hs
@@ -0,0 +1,36 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPULogLevel where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPULogLevel = WGPULogLevel Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Off :: forall a. (Eq a, Num a) => a
+pattern Off = 0x00000000
+
+pattern Error :: forall a. (Eq a, Num a) => a
+pattern Error = 0x00000001
+
+pattern Warn :: forall a. (Eq a, Num a) => a
+pattern Warn = 0x00000002
+
+pattern Info :: forall a. (Eq a, Num a) => a
+pattern Info = 0x00000003
+
+pattern Debug :: forall a. (Eq a, Num a) => a
+pattern Debug = 0x00000004
+
+pattern Trace :: forall a. (Eq a, Num a) => a
+pattern Trace = 0x00000005
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUMapMode.hs b/src/WGPU/Raw/Generated/Enum/WGPUMapMode.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUMapMode.hs
@@ -0,0 +1,24 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUMapMode where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUMapMode = WGPUMapMode Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Read :: forall a. (Eq a, Num a) => a
+pattern Read = 0x00000001
+
+pattern Write :: forall a. (Eq a, Num a) => a
+pattern Write = 0x00000002
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUNativeFeature.hs b/src/WGPU/Raw/Generated/Enum/WGPUNativeFeature.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUNativeFeature.hs
@@ -0,0 +1,21 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUNativeFeature where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUNativeFeature = WGPUNativeFeature Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern TEXTURE_ADAPTER_SPECIFIC_FORMAT_FEATURES :: forall a. (Eq a, Num a) => a
+pattern TEXTURE_ADAPTER_SPECIFIC_FORMAT_FEATURES = 0x10000000
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUNativeSType.hs b/src/WGPU/Raw/Generated/Enum/WGPUNativeSType.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUNativeSType.hs
@@ -0,0 +1,24 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUNativeSType where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUNativeSType = WGPUNativeSType Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern DeviceExtras :: forall a. (Eq a, Num a) => a
+pattern DeviceExtras = 0x60000001
+
+pattern AdapterExtras :: forall a. (Eq a, Num a) => a
+pattern AdapterExtras = 0x60000002
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUPipelineStatisticName.hs b/src/WGPU/Raw/Generated/Enum/WGPUPipelineStatisticName.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUPipelineStatisticName.hs
@@ -0,0 +1,33 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUPipelineStatisticName where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUPipelineStatisticName = WGPUPipelineStatisticName Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern VertexShaderInvocations :: forall a. (Eq a, Num a) => a
+pattern VertexShaderInvocations = 0x00000000
+
+pattern ClipperInvocations :: forall a. (Eq a, Num a) => a
+pattern ClipperInvocations = 0x00000001
+
+pattern ClipperPrimitivesOut :: forall a. (Eq a, Num a) => a
+pattern ClipperPrimitivesOut = 0x00000002
+
+pattern FragmentShaderInvocations :: forall a. (Eq a, Num a) => a
+pattern FragmentShaderInvocations = 0x00000003
+
+pattern ComputeShaderInvocations :: forall a. (Eq a, Num a) => a
+pattern ComputeShaderInvocations = 0x00000004
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUPresentMode.hs b/src/WGPU/Raw/Generated/Enum/WGPUPresentMode.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUPresentMode.hs
@@ -0,0 +1,27 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUPresentMode where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUPresentMode = WGPUPresentMode Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Immediate :: forall a. (Eq a, Num a) => a
+pattern Immediate = 0x00000000
+
+pattern Mailbox :: forall a. (Eq a, Num a) => a
+pattern Mailbox = 0x00000001
+
+pattern Fifo :: forall a. (Eq a, Num a) => a
+pattern Fifo = 0x00000002
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUPrimitiveTopology.hs b/src/WGPU/Raw/Generated/Enum/WGPUPrimitiveTopology.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUPrimitiveTopology.hs
@@ -0,0 +1,33 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUPrimitiveTopology where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUPrimitiveTopology = WGPUPrimitiveTopology Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern PointList :: forall a. (Eq a, Num a) => a
+pattern PointList = 0x00000000
+
+pattern LineList :: forall a. (Eq a, Num a) => a
+pattern LineList = 0x00000001
+
+pattern LineStrip :: forall a. (Eq a, Num a) => a
+pattern LineStrip = 0x00000002
+
+pattern TriangleList :: forall a. (Eq a, Num a) => a
+pattern TriangleList = 0x00000003
+
+pattern TriangleStrip :: forall a. (Eq a, Num a) => a
+pattern TriangleStrip = 0x00000004
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUQueryType.hs b/src/WGPU/Raw/Generated/Enum/WGPUQueryType.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUQueryType.hs
@@ -0,0 +1,27 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUQueryType where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUQueryType = WGPUQueryType Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Occlusion :: forall a. (Eq a, Num a) => a
+pattern Occlusion = 0x00000000
+
+pattern PipelineStatistics :: forall a. (Eq a, Num a) => a
+pattern PipelineStatistics = 0x00000001
+
+pattern Timestamp :: forall a. (Eq a, Num a) => a
+pattern Timestamp = 0x00000002
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUQueueWorkDoneStatus.hs b/src/WGPU/Raw/Generated/Enum/WGPUQueueWorkDoneStatus.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUQueueWorkDoneStatus.hs
@@ -0,0 +1,30 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUQueueWorkDoneStatus where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUQueueWorkDoneStatus = WGPUQueueWorkDoneStatus Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Success :: forall a. (Eq a, Num a) => a
+pattern Success = 0x00000000
+
+pattern Error :: forall a. (Eq a, Num a) => a
+pattern Error = 0x00000001
+
+pattern Unknown :: forall a. (Eq a, Num a) => a
+pattern Unknown = 0x00000002
+
+pattern DeviceLost :: forall a. (Eq a, Num a) => a
+pattern DeviceLost = 0x00000003
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUSType.hs b/src/WGPU/Raw/Generated/Enum/WGPUSType.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUSType.hs
@@ -0,0 +1,42 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUSType where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUSType = WGPUSType Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Invalid :: forall a. (Eq a, Num a) => a
+pattern Invalid = 0x00000000
+
+pattern SurfaceDescriptorFromMetalLayer :: forall a. (Eq a, Num a) => a
+pattern SurfaceDescriptorFromMetalLayer = 0x00000001
+
+pattern SurfaceDescriptorFromWindowsHWND :: forall a. (Eq a, Num a) => a
+pattern SurfaceDescriptorFromWindowsHWND = 0x00000002
+
+pattern SurfaceDescriptorFromXlib :: forall a. (Eq a, Num a) => a
+pattern SurfaceDescriptorFromXlib = 0x00000003
+
+pattern SurfaceDescriptorFromCanvasHTMLSelector :: forall a. (Eq a, Num a) => a
+pattern SurfaceDescriptorFromCanvasHTMLSelector = 0x00000004
+
+pattern ShaderModuleSPIRVDescriptor :: forall a. (Eq a, Num a) => a
+pattern ShaderModuleSPIRVDescriptor = 0x00000005
+
+pattern ShaderModuleWGSLDescriptor :: forall a. (Eq a, Num a) => a
+pattern ShaderModuleWGSLDescriptor = 0x00000006
+
+pattern PrimitiveDepthClampingState :: forall a. (Eq a, Num a) => a
+pattern PrimitiveDepthClampingState = 0x00000007
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUSamplerBindingType.hs b/src/WGPU/Raw/Generated/Enum/WGPUSamplerBindingType.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUSamplerBindingType.hs
@@ -0,0 +1,30 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUSamplerBindingType where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUSamplerBindingType = WGPUSamplerBindingType Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Undefined :: forall a. (Eq a, Num a) => a
+pattern Undefined = 0x00000000
+
+pattern Filtering :: forall a. (Eq a, Num a) => a
+pattern Filtering = 0x00000001
+
+pattern NonFiltering :: forall a. (Eq a, Num a) => a
+pattern NonFiltering = 0x00000002
+
+pattern Comparison :: forall a. (Eq a, Num a) => a
+pattern Comparison = 0x00000003
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUShaderStage.hs b/src/WGPU/Raw/Generated/Enum/WGPUShaderStage.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUShaderStage.hs
@@ -0,0 +1,30 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUShaderStage where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUShaderStage = WGPUShaderStage Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern None :: forall a. (Eq a, Num a) => a
+pattern None = 0x00000000
+
+pattern Vertex :: forall a. (Eq a, Num a) => a
+pattern Vertex = 0x00000001
+
+pattern Fragment :: forall a. (Eq a, Num a) => a
+pattern Fragment = 0x00000002
+
+pattern Compute :: forall a. (Eq a, Num a) => a
+pattern Compute = 0x00000004
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUStencilOperation.hs b/src/WGPU/Raw/Generated/Enum/WGPUStencilOperation.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUStencilOperation.hs
@@ -0,0 +1,42 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUStencilOperation where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUStencilOperation = WGPUStencilOperation Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Keep :: forall a. (Eq a, Num a) => a
+pattern Keep = 0x00000000
+
+pattern Zero :: forall a. (Eq a, Num a) => a
+pattern Zero = 0x00000001
+
+pattern Replace :: forall a. (Eq a, Num a) => a
+pattern Replace = 0x00000002
+
+pattern Invert :: forall a. (Eq a, Num a) => a
+pattern Invert = 0x00000003
+
+pattern IncrementClamp :: forall a. (Eq a, Num a) => a
+pattern IncrementClamp = 0x00000004
+
+pattern DecrementClamp :: forall a. (Eq a, Num a) => a
+pattern DecrementClamp = 0x00000005
+
+pattern IncrementWrap :: forall a. (Eq a, Num a) => a
+pattern IncrementWrap = 0x00000006
+
+pattern DecrementWrap :: forall a. (Eq a, Num a) => a
+pattern DecrementWrap = 0x00000007
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUStorageTextureAccess.hs b/src/WGPU/Raw/Generated/Enum/WGPUStorageTextureAccess.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUStorageTextureAccess.hs
@@ -0,0 +1,27 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUStorageTextureAccess where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUStorageTextureAccess = WGPUStorageTextureAccess Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Undefined :: forall a. (Eq a, Num a) => a
+pattern Undefined = 0x00000000
+
+pattern ReadOnly :: forall a. (Eq a, Num a) => a
+pattern ReadOnly = 0x00000001
+
+pattern WriteOnly :: forall a. (Eq a, Num a) => a
+pattern WriteOnly = 0x00000002
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUStoreOp.hs b/src/WGPU/Raw/Generated/Enum/WGPUStoreOp.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUStoreOp.hs
@@ -0,0 +1,24 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUStoreOp where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUStoreOp = WGPUStoreOp Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Store :: forall a. (Eq a, Num a) => a
+pattern Store = 0x00000000
+
+pattern Clear :: forall a. (Eq a, Num a) => a
+pattern Clear = 0x00000001
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUTextureAspect.hs b/src/WGPU/Raw/Generated/Enum/WGPUTextureAspect.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUTextureAspect.hs
@@ -0,0 +1,27 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUTextureAspect where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUTextureAspect = WGPUTextureAspect Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern All :: forall a. (Eq a, Num a) => a
+pattern All = 0x00000000
+
+pattern StencilOnly :: forall a. (Eq a, Num a) => a
+pattern StencilOnly = 0x00000001
+
+pattern DepthOnly :: forall a. (Eq a, Num a) => a
+pattern DepthOnly = 0x00000002
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUTextureComponentType.hs b/src/WGPU/Raw/Generated/Enum/WGPUTextureComponentType.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUTextureComponentType.hs
@@ -0,0 +1,30 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUTextureComponentType where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUTextureComponentType = WGPUTextureComponentType Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Float :: forall a. (Eq a, Num a) => a
+pattern Float = 0x00000000
+
+pattern Sint :: forall a. (Eq a, Num a) => a
+pattern Sint = 0x00000001
+
+pattern Uint :: forall a. (Eq a, Num a) => a
+pattern Uint = 0x00000002
+
+pattern DepthComparison :: forall a. (Eq a, Num a) => a
+pattern DepthComparison = 0x00000003
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUTextureDimension.hs b/src/WGPU/Raw/Generated/Enum/WGPUTextureDimension.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUTextureDimension.hs
@@ -0,0 +1,27 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUTextureDimension where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUTextureDimension = WGPUTextureDimension Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern D1D :: forall a. (Eq a, Num a) => a
+pattern D1D = 0x00000000
+
+pattern D2D :: forall a. (Eq a, Num a) => a
+pattern D2D = 0x00000001
+
+pattern D3D :: forall a. (Eq a, Num a) => a
+pattern D3D = 0x00000002
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUTextureFormat.hs b/src/WGPU/Raw/Generated/Enum/WGPUTextureFormat.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUTextureFormat.hs
@@ -0,0 +1,183 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUTextureFormat where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUTextureFormat = WGPUTextureFormat Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Undefined :: forall a. (Eq a, Num a) => a
+pattern Undefined = 0x00000000
+
+pattern R8Unorm :: forall a. (Eq a, Num a) => a
+pattern R8Unorm = 0x00000001
+
+pattern R8Snorm :: forall a. (Eq a, Num a) => a
+pattern R8Snorm = 0x00000002
+
+pattern R8Uint :: forall a. (Eq a, Num a) => a
+pattern R8Uint = 0x00000003
+
+pattern R8Sint :: forall a. (Eq a, Num a) => a
+pattern R8Sint = 0x00000004
+
+pattern R16Uint :: forall a. (Eq a, Num a) => a
+pattern R16Uint = 0x00000005
+
+pattern R16Sint :: forall a. (Eq a, Num a) => a
+pattern R16Sint = 0x00000006
+
+pattern R16Float :: forall a. (Eq a, Num a) => a
+pattern R16Float = 0x00000007
+
+pattern RG8Unorm :: forall a. (Eq a, Num a) => a
+pattern RG8Unorm = 0x00000008
+
+pattern RG8Snorm :: forall a. (Eq a, Num a) => a
+pattern RG8Snorm = 0x00000009
+
+pattern RG8Uint :: forall a. (Eq a, Num a) => a
+pattern RG8Uint = 0x0000000A
+
+pattern RG8Sint :: forall a. (Eq a, Num a) => a
+pattern RG8Sint = 0x0000000B
+
+pattern R32Float :: forall a. (Eq a, Num a) => a
+pattern R32Float = 0x0000000C
+
+pattern R32Uint :: forall a. (Eq a, Num a) => a
+pattern R32Uint = 0x0000000D
+
+pattern R32Sint :: forall a. (Eq a, Num a) => a
+pattern R32Sint = 0x0000000E
+
+pattern RG16Uint :: forall a. (Eq a, Num a) => a
+pattern RG16Uint = 0x0000000F
+
+pattern RG16Sint :: forall a. (Eq a, Num a) => a
+pattern RG16Sint = 0x00000010
+
+pattern RG16Float :: forall a. (Eq a, Num a) => a
+pattern RG16Float = 0x00000011
+
+pattern RGBA8Unorm :: forall a. (Eq a, Num a) => a
+pattern RGBA8Unorm = 0x00000012
+
+pattern RGBA8UnormSrgb :: forall a. (Eq a, Num a) => a
+pattern RGBA8UnormSrgb = 0x00000013
+
+pattern RGBA8Snorm :: forall a. (Eq a, Num a) => a
+pattern RGBA8Snorm = 0x00000014
+
+pattern RGBA8Uint :: forall a. (Eq a, Num a) => a
+pattern RGBA8Uint = 0x00000015
+
+pattern RGBA8Sint :: forall a. (Eq a, Num a) => a
+pattern RGBA8Sint = 0x00000016
+
+pattern BGRA8Unorm :: forall a. (Eq a, Num a) => a
+pattern BGRA8Unorm = 0x00000017
+
+pattern BGRA8UnormSrgb :: forall a. (Eq a, Num a) => a
+pattern BGRA8UnormSrgb = 0x00000018
+
+pattern RGB10A2Unorm :: forall a. (Eq a, Num a) => a
+pattern RGB10A2Unorm = 0x00000019
+
+pattern RG11B10Ufloat :: forall a. (Eq a, Num a) => a
+pattern RG11B10Ufloat = 0x0000001A
+
+pattern RGB9E5Ufloat :: forall a. (Eq a, Num a) => a
+pattern RGB9E5Ufloat = 0x0000001B
+
+pattern RG32Float :: forall a. (Eq a, Num a) => a
+pattern RG32Float = 0x0000001C
+
+pattern RG32Uint :: forall a. (Eq a, Num a) => a
+pattern RG32Uint = 0x0000001D
+
+pattern RG32Sint :: forall a. (Eq a, Num a) => a
+pattern RG32Sint = 0x0000001E
+
+pattern RGBA16Uint :: forall a. (Eq a, Num a) => a
+pattern RGBA16Uint = 0x0000001F
+
+pattern RGBA16Sint :: forall a. (Eq a, Num a) => a
+pattern RGBA16Sint = 0x00000020
+
+pattern RGBA16Float :: forall a. (Eq a, Num a) => a
+pattern RGBA16Float = 0x00000021
+
+pattern RGBA32Float :: forall a. (Eq a, Num a) => a
+pattern RGBA32Float = 0x00000022
+
+pattern RGBA32Uint :: forall a. (Eq a, Num a) => a
+pattern RGBA32Uint = 0x00000023
+
+pattern RGBA32Sint :: forall a. (Eq a, Num a) => a
+pattern RGBA32Sint = 0x00000024
+
+pattern Depth32Float :: forall a. (Eq a, Num a) => a
+pattern Depth32Float = 0x00000025
+
+pattern Depth24Plus :: forall a. (Eq a, Num a) => a
+pattern Depth24Plus = 0x00000026
+
+pattern Depth24PlusStencil8 :: forall a. (Eq a, Num a) => a
+pattern Depth24PlusStencil8 = 0x00000027
+
+pattern Stencil8 :: forall a. (Eq a, Num a) => a
+pattern Stencil8 = 0x00000028
+
+pattern BC1RGBAUnorm :: forall a. (Eq a, Num a) => a
+pattern BC1RGBAUnorm = 0x00000029
+
+pattern BC1RGBAUnormSrgb :: forall a. (Eq a, Num a) => a
+pattern BC1RGBAUnormSrgb = 0x0000002A
+
+pattern BC2RGBAUnorm :: forall a. (Eq a, Num a) => a
+pattern BC2RGBAUnorm = 0x0000002B
+
+pattern BC2RGBAUnormSrgb :: forall a. (Eq a, Num a) => a
+pattern BC2RGBAUnormSrgb = 0x0000002C
+
+pattern BC3RGBAUnorm :: forall a. (Eq a, Num a) => a
+pattern BC3RGBAUnorm = 0x0000002D
+
+pattern BC3RGBAUnormSrgb :: forall a. (Eq a, Num a) => a
+pattern BC3RGBAUnormSrgb = 0x0000002E
+
+pattern BC4RUnorm :: forall a. (Eq a, Num a) => a
+pattern BC4RUnorm = 0x0000002F
+
+pattern BC4RSnorm :: forall a. (Eq a, Num a) => a
+pattern BC4RSnorm = 0x00000030
+
+pattern BC5RGUnorm :: forall a. (Eq a, Num a) => a
+pattern BC5RGUnorm = 0x00000031
+
+pattern BC5RGSnorm :: forall a. (Eq a, Num a) => a
+pattern BC5RGSnorm = 0x00000032
+
+pattern BC6HRGBUfloat :: forall a. (Eq a, Num a) => a
+pattern BC6HRGBUfloat = 0x00000033
+
+pattern BC6HRGBFloat :: forall a. (Eq a, Num a) => a
+pattern BC6HRGBFloat = 0x00000034
+
+pattern BC7RGBAUnorm :: forall a. (Eq a, Num a) => a
+pattern BC7RGBAUnorm = 0x00000035
+
+pattern BC7RGBAUnormSrgb :: forall a. (Eq a, Num a) => a
+pattern BC7RGBAUnormSrgb = 0x00000036
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUTextureSampleType.hs b/src/WGPU/Raw/Generated/Enum/WGPUTextureSampleType.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUTextureSampleType.hs
@@ -0,0 +1,36 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUTextureSampleType where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUTextureSampleType = WGPUTextureSampleType Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Undefined :: forall a. (Eq a, Num a) => a
+pattern Undefined = 0x00000000
+
+pattern Float :: forall a. (Eq a, Num a) => a
+pattern Float = 0x00000001
+
+pattern UnfilterableFloat :: forall a. (Eq a, Num a) => a
+pattern UnfilterableFloat = 0x00000002
+
+pattern Depth :: forall a. (Eq a, Num a) => a
+pattern Depth = 0x00000003
+
+pattern Sint :: forall a. (Eq a, Num a) => a
+pattern Sint = 0x00000004
+
+pattern Uint :: forall a. (Eq a, Num a) => a
+pattern Uint = 0x00000005
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUTextureUsage.hs b/src/WGPU/Raw/Generated/Enum/WGPUTextureUsage.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUTextureUsage.hs
@@ -0,0 +1,36 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUTextureUsage where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUTextureUsage = WGPUTextureUsage Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern None :: forall a. (Eq a, Num a) => a
+pattern None = 0x00000000
+
+pattern CopySrc :: forall a. (Eq a, Num a) => a
+pattern CopySrc = 0x00000001
+
+pattern CopyDst :: forall a. (Eq a, Num a) => a
+pattern CopyDst = 0x00000002
+
+pattern Sampled :: forall a. (Eq a, Num a) => a
+pattern Sampled = 0x00000004
+
+pattern Storage :: forall a. (Eq a, Num a) => a
+pattern Storage = 0x00000008
+
+pattern RenderAttachment :: forall a. (Eq a, Num a) => a
+pattern RenderAttachment = 0x00000010
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUTextureViewDimension.hs b/src/WGPU/Raw/Generated/Enum/WGPUTextureViewDimension.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUTextureViewDimension.hs
@@ -0,0 +1,39 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUTextureViewDimension where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUTextureViewDimension = WGPUTextureViewDimension Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Undefined :: forall a. (Eq a, Num a) => a
+pattern Undefined = 0x00000000
+
+pattern D1D :: forall a. (Eq a, Num a) => a
+pattern D1D = 0x00000001
+
+pattern D2D :: forall a. (Eq a, Num a) => a
+pattern D2D = 0x00000002
+
+pattern D2DArray :: forall a. (Eq a, Num a) => a
+pattern D2DArray = 0x00000003
+
+pattern Cube :: forall a. (Eq a, Num a) => a
+pattern Cube = 0x00000004
+
+pattern CubeArray :: forall a. (Eq a, Num a) => a
+pattern CubeArray = 0x00000005
+
+pattern D3D :: forall a. (Eq a, Num a) => a
+pattern D3D = 0x00000006
diff --git a/src/WGPU/Raw/Generated/Enum/WGPUVertexFormat.hs b/src/WGPU/Raw/Generated/Enum/WGPUVertexFormat.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Enum/WGPUVertexFormat.hs
@@ -0,0 +1,111 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+{-# LANGUAGE PatternSynonyms #-}
+{-# LANGUAGE ScopedTypeVariables #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Enum.WGPUVertexFormat where
+
+import Data.Word (Word32)
+import Foreign (Storable)
+import Prelude (Eq, Num, Show)
+
+newtype WGPUVertexFormat = WGPUVertexFormat Word32
+  deriving (Eq, Show, Num, Storable)
+
+pattern Undefined :: forall a. (Eq a, Num a) => a
+pattern Undefined = 0x00000000
+
+pattern Uint8x2 :: forall a. (Eq a, Num a) => a
+pattern Uint8x2 = 0x00000001
+
+pattern Uint8x4 :: forall a. (Eq a, Num a) => a
+pattern Uint8x4 = 0x00000002
+
+pattern Sint8x2 :: forall a. (Eq a, Num a) => a
+pattern Sint8x2 = 0x00000003
+
+pattern Sint8x4 :: forall a. (Eq a, Num a) => a
+pattern Sint8x4 = 0x00000004
+
+pattern Unorm8x2 :: forall a. (Eq a, Num a) => a
+pattern Unorm8x2 = 0x00000005
+
+pattern Unorm8x4 :: forall a. (Eq a, Num a) => a
+pattern Unorm8x4 = 0x00000006
+
+pattern Snorm8x2 :: forall a. (Eq a, Num a) => a
+pattern Snorm8x2 = 0x00000007
+
+pattern Snorm8x4 :: forall a. (Eq a, Num a) => a
+pattern Snorm8x4 = 0x00000008
+
+pattern Uint16x2 :: forall a. (Eq a, Num a) => a
+pattern Uint16x2 = 0x00000009
+
+pattern Uint16x4 :: forall a. (Eq a, Num a) => a
+pattern Uint16x4 = 0x0000000A
+
+pattern Sint16x2 :: forall a. (Eq a, Num a) => a
+pattern Sint16x2 = 0x0000000B
+
+pattern Sint16x4 :: forall a. (Eq a, Num a) => a
+pattern Sint16x4 = 0x0000000C
+
+pattern Unorm16x2 :: forall a. (Eq a, Num a) => a
+pattern Unorm16x2 = 0x0000000D
+
+pattern Unorm16x4 :: forall a. (Eq a, Num a) => a
+pattern Unorm16x4 = 0x0000000E
+
+pattern Snorm16x2 :: forall a. (Eq a, Num a) => a
+pattern Snorm16x2 = 0x0000000F
+
+pattern Snorm16x4 :: forall a. (Eq a, Num a) => a
+pattern Snorm16x4 = 0x00000010
+
+pattern Float16x2 :: forall a. (Eq a, Num a) => a
+pattern Float16x2 = 0x00000011
+
+pattern Float16x4 :: forall a. (Eq a, Num a) => a
+pattern Float16x4 = 0x00000012
+
+pattern Float32 :: forall a. (Eq a, Num a) => a
+pattern Float32 = 0x00000013
+
+pattern Float32x2 :: forall a. (Eq a, Num a) => a
+pattern Float32x2 = 0x00000014
+
+pattern Float32x3 :: forall a. (Eq a, Num a) => a
+pattern Float32x3 = 0x00000015
+
+pattern Float32x4 :: forall a. (Eq a, Num a) => a
+pattern Float32x4 = 0x00000016
+
+pattern Uint32 :: forall a. (Eq a, Num a) => a
+pattern Uint32 = 0x00000017
+
+pattern Uint32x2 :: forall a. (Eq a, Num a) => a
+pattern Uint32x2 = 0x00000018
+
+pattern Uint32x3 :: forall a. (Eq a, Num a) => a
+pattern Uint32x3 = 0x00000019
+
+pattern Uint32x4 :: forall a. (Eq a, Num a) => a
+pattern Uint32x4 = 0x0000001A
+
+pattern Sint32 :: forall a. (Eq a, Num a) => a
+pattern Sint32 = 0x0000001B
+
+pattern Sint32x2 :: forall a. (Eq a, Num a) => a
+pattern Sint32x2 = 0x0000001C
+
+pattern Sint32x3 :: forall a. (Eq a, Num a) => a
+pattern Sint32x3 = 0x0000001D
+
+pattern Sint32x4 :: forall a. (Eq a, Num a) => a
+pattern Sint32x4 = 0x0000001E
diff --git a/src/WGPU/Raw/Generated/Fun.hs b/src/WGPU/Raw/Generated/Fun.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Fun.hs
@@ -0,0 +1,417 @@
+{-# LANGUAGE ForeignFunctionInterface #-}
+{-# LANGUAGE RankNTypes #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Fun where
+
+import Foreign
+import Foreign.C
+import WGPU.Raw.Generated.Enum.WGPUAdapterType
+import WGPU.Raw.Generated.Enum.WGPUAddressMode
+import WGPU.Raw.Generated.Enum.WGPUBackendType
+import WGPU.Raw.Generated.Enum.WGPUBlendFactor
+import WGPU.Raw.Generated.Enum.WGPUBlendOperation
+import WGPU.Raw.Generated.Enum.WGPUBufferBindingType
+import WGPU.Raw.Generated.Enum.WGPUBufferMapAsyncStatus
+import WGPU.Raw.Generated.Enum.WGPUBufferUsage
+import WGPU.Raw.Generated.Enum.WGPUColorWriteMask
+import WGPU.Raw.Generated.Enum.WGPUCompareFunction
+import WGPU.Raw.Generated.Enum.WGPUCreatePipelineAsyncStatus
+import WGPU.Raw.Generated.Enum.WGPUCullMode
+import WGPU.Raw.Generated.Enum.WGPUErrorFilter
+import WGPU.Raw.Generated.Enum.WGPUErrorType
+import WGPU.Raw.Generated.Enum.WGPUFilterMode
+import WGPU.Raw.Generated.Enum.WGPUFrontFace
+import WGPU.Raw.Generated.Enum.WGPUIndexFormat
+import WGPU.Raw.Generated.Enum.WGPUInputStepMode
+import WGPU.Raw.Generated.Enum.WGPULoadOp
+import WGPU.Raw.Generated.Enum.WGPULogLevel
+import WGPU.Raw.Generated.Enum.WGPUMapMode
+import WGPU.Raw.Generated.Enum.WGPUNativeFeature
+import WGPU.Raw.Generated.Enum.WGPUNativeSType
+import WGPU.Raw.Generated.Enum.WGPUPipelineStatisticName
+import WGPU.Raw.Generated.Enum.WGPUPresentMode
+import WGPU.Raw.Generated.Enum.WGPUPrimitiveTopology
+import WGPU.Raw.Generated.Enum.WGPUQueryType
+import WGPU.Raw.Generated.Enum.WGPUQueueWorkDoneStatus
+import WGPU.Raw.Generated.Enum.WGPUSType
+import WGPU.Raw.Generated.Enum.WGPUSamplerBindingType
+import WGPU.Raw.Generated.Enum.WGPUShaderStage
+import WGPU.Raw.Generated.Enum.WGPUStencilOperation
+import WGPU.Raw.Generated.Enum.WGPUStorageTextureAccess
+import WGPU.Raw.Generated.Enum.WGPUStoreOp
+import WGPU.Raw.Generated.Enum.WGPUTextureAspect
+import WGPU.Raw.Generated.Enum.WGPUTextureComponentType
+import WGPU.Raw.Generated.Enum.WGPUTextureDimension
+import WGPU.Raw.Generated.Enum.WGPUTextureFormat
+import WGPU.Raw.Generated.Enum.WGPUTextureSampleType
+import WGPU.Raw.Generated.Enum.WGPUTextureUsage
+import WGPU.Raw.Generated.Enum.WGPUTextureViewDimension
+import WGPU.Raw.Generated.Enum.WGPUVertexFormat
+import WGPU.Raw.Generated.Struct.WGPUAdapterExtras
+import WGPU.Raw.Generated.Struct.WGPUAdapterProperties
+import WGPU.Raw.Generated.Struct.WGPUBindGroupDescriptor
+import WGPU.Raw.Generated.Struct.WGPUBindGroupEntry
+import WGPU.Raw.Generated.Struct.WGPUBindGroupLayoutDescriptor
+import WGPU.Raw.Generated.Struct.WGPUBindGroupLayoutEntry
+import WGPU.Raw.Generated.Struct.WGPUBlendComponent
+import WGPU.Raw.Generated.Struct.WGPUBlendState
+import WGPU.Raw.Generated.Struct.WGPUBufferBindingLayout
+import WGPU.Raw.Generated.Struct.WGPUBufferDescriptor
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUColor
+import WGPU.Raw.Generated.Struct.WGPUColorTargetState
+import WGPU.Raw.Generated.Struct.WGPUCommandBufferDescriptor
+import WGPU.Raw.Generated.Struct.WGPUCommandEncoderDescriptor
+import WGPU.Raw.Generated.Struct.WGPUComputePassDescriptor
+import WGPU.Raw.Generated.Struct.WGPUComputePipelineDescriptor
+import WGPU.Raw.Generated.Struct.WGPUDepthStencilState
+import WGPU.Raw.Generated.Struct.WGPUDeviceDescriptor
+import WGPU.Raw.Generated.Struct.WGPUDeviceExtras
+import WGPU.Raw.Generated.Struct.WGPUExtent3D
+import WGPU.Raw.Generated.Struct.WGPUFragmentState
+import WGPU.Raw.Generated.Struct.WGPUImageCopyBuffer
+import WGPU.Raw.Generated.Struct.WGPUImageCopyTexture
+import WGPU.Raw.Generated.Struct.WGPUInstanceDescriptor
+import WGPU.Raw.Generated.Struct.WGPUMultisampleState
+import WGPU.Raw.Generated.Struct.WGPUOrigin3D
+import WGPU.Raw.Generated.Struct.WGPUPipelineLayoutDescriptor
+import WGPU.Raw.Generated.Struct.WGPUPrimitiveDepthClampingState
+import WGPU.Raw.Generated.Struct.WGPUPrimitiveState
+import WGPU.Raw.Generated.Struct.WGPUProgrammableStageDescriptor
+import WGPU.Raw.Generated.Struct.WGPUQuerySetDescriptor
+import WGPU.Raw.Generated.Struct.WGPURenderBundleDescriptor
+import WGPU.Raw.Generated.Struct.WGPURenderBundleEncoderDescriptor
+import WGPU.Raw.Generated.Struct.WGPURenderPassColorAttachment
+import WGPU.Raw.Generated.Struct.WGPURenderPassDepthStencilAttachment
+import WGPU.Raw.Generated.Struct.WGPURenderPassDescriptor
+import WGPU.Raw.Generated.Struct.WGPURenderPipelineDescriptor
+import WGPU.Raw.Generated.Struct.WGPURequestAdapterOptions
+import WGPU.Raw.Generated.Struct.WGPUSamplerBindingLayout
+import WGPU.Raw.Generated.Struct.WGPUSamplerDescriptor
+import WGPU.Raw.Generated.Struct.WGPUShaderModuleDescriptor
+import WGPU.Raw.Generated.Struct.WGPUShaderModuleSPIRVDescriptor
+import WGPU.Raw.Generated.Struct.WGPUShaderModuleWGSLDescriptor
+import WGPU.Raw.Generated.Struct.WGPUStencilFaceState
+import WGPU.Raw.Generated.Struct.WGPUStorageTextureBindingLayout
+import WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptor
+import WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptorFromCanvasHTMLSelector
+import WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptorFromMetalLayer
+import WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptorFromWindowsHWND
+import WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptorFromXlib
+import WGPU.Raw.Generated.Struct.WGPUSwapChainDescriptor
+import WGPU.Raw.Generated.Struct.WGPUTextureBindingLayout
+import WGPU.Raw.Generated.Struct.WGPUTextureDataLayout
+import WGPU.Raw.Generated.Struct.WGPUTextureDescriptor
+import WGPU.Raw.Generated.Struct.WGPUTextureViewDescriptor
+import WGPU.Raw.Generated.Struct.WGPUVertexAttribute
+import WGPU.Raw.Generated.Struct.WGPUVertexBufferLayout
+import WGPU.Raw.Generated.Struct.WGPUVertexState
+import WGPU.Raw.Types
+import Prelude (IO, String, pure, (<$>))
+
+data WGPUHsInstance = WGPUHsInstance
+  { wgpuAdapterGetProperties :: WGPUAdapter -> Ptr (WGPUAdapterProperties) -> IO (()),
+    wgpuAdapterRequestDevice :: WGPUAdapter -> Ptr (WGPUDeviceDescriptor) -> WGPURequestDeviceCallback -> Ptr (()) -> IO (()),
+    wgpuBufferDestroy :: WGPUBuffer -> IO (()),
+    wgpuBufferGetMappedRange :: WGPUBuffer -> CSize -> CSize -> IO (Ptr (())),
+    wgpuBufferMapAsync :: WGPUBuffer -> WGPUMapModeFlags -> CSize -> CSize -> WGPUBufferMapCallback -> Ptr (()) -> IO (()),
+    wgpuBufferUnmap :: WGPUBuffer -> IO (()),
+    wgpuCommandEncoderBeginComputePass :: WGPUCommandEncoder -> Ptr (WGPUComputePassDescriptor) -> IO (WGPUComputePassEncoder),
+    wgpuCommandEncoderBeginRenderPass :: WGPUCommandEncoder -> Ptr (WGPURenderPassDescriptor) -> IO (WGPURenderPassEncoder),
+    wgpuCommandEncoderCopyBufferToBuffer :: WGPUCommandEncoder -> WGPUBuffer -> Word64 -> WGPUBuffer -> Word64 -> Word64 -> IO (()),
+    wgpuCommandEncoderCopyBufferToTexture :: WGPUCommandEncoder -> Ptr (WGPUImageCopyBuffer) -> Ptr (WGPUImageCopyTexture) -> Ptr (WGPUExtent3D) -> IO (()),
+    wgpuCommandEncoderCopyTextureToTexture :: WGPUCommandEncoder -> Ptr (WGPUImageCopyTexture) -> Ptr (WGPUImageCopyTexture) -> Ptr (WGPUExtent3D) -> IO (()),
+    wgpuCommandEncoderCopyTextureToBuffer :: WGPUCommandEncoder -> Ptr (WGPUImageCopyTexture) -> Ptr (WGPUImageCopyBuffer) -> Ptr (WGPUExtent3D) -> IO (()),
+    wgpuCommandEncoderFinish :: WGPUCommandEncoder -> Ptr (WGPUCommandBufferDescriptor) -> IO (WGPUCommandBuffer),
+    wgpuComputePassEncoderDispatch :: WGPUComputePassEncoder -> Word32 -> Word32 -> Word32 -> IO (()),
+    wgpuComputePassEncoderDispatchIndirect :: WGPUComputePassEncoder -> WGPUBuffer -> Word64 -> IO (()),
+    wgpuComputePassEncoderEndPass :: WGPUComputePassEncoder -> IO (()),
+    wgpuComputePassEncoderSetBindGroup :: WGPUComputePassEncoder -> Word32 -> WGPUBindGroup -> Word32 -> Ptr (Word32) -> IO (()),
+    wgpuComputePassEncoderSetPipeline :: WGPUComputePassEncoder -> WGPUComputePipeline -> IO (()),
+    wgpuDeviceCreateBindGroup :: WGPUDevice -> Ptr (WGPUBindGroupDescriptor) -> IO (WGPUBindGroup),
+    wgpuDeviceCreateBindGroupLayout :: WGPUDevice -> Ptr (WGPUBindGroupLayoutDescriptor) -> IO (WGPUBindGroupLayout),
+    wgpuDeviceCreateBuffer :: WGPUDevice -> Ptr (WGPUBufferDescriptor) -> IO (WGPUBuffer),
+    wgpuDeviceCreateCommandEncoder :: WGPUDevice -> Ptr (WGPUCommandEncoderDescriptor) -> IO (WGPUCommandEncoder),
+    wgpuDeviceCreateComputePipeline :: WGPUDevice -> Ptr (WGPUComputePipelineDescriptor) -> IO (WGPUComputePipeline),
+    wgpuDeviceCreatePipelineLayout :: WGPUDevice -> Ptr (WGPUPipelineLayoutDescriptor) -> IO (WGPUPipelineLayout),
+    wgpuDeviceCreateRenderPipeline :: WGPUDevice -> Ptr (WGPURenderPipelineDescriptor) -> IO (WGPURenderPipeline),
+    wgpuDeviceCreateSampler :: WGPUDevice -> Ptr (WGPUSamplerDescriptor) -> IO (WGPUSampler),
+    wgpuDeviceCreateShaderModule :: WGPUDevice -> Ptr (WGPUShaderModuleDescriptor) -> IO (WGPUShaderModule),
+    wgpuDeviceCreateSwapChain :: WGPUDevice -> WGPUSurface -> Ptr (WGPUSwapChainDescriptor) -> IO (WGPUSwapChain),
+    wgpuDeviceCreateTexture :: WGPUDevice -> Ptr (WGPUTextureDescriptor) -> IO (WGPUTexture),
+    wgpuDeviceGetQueue :: WGPUDevice -> IO (WGPUQueue),
+    wgpuInstanceCreateSurface :: WGPUInstance -> Ptr (WGPUSurfaceDescriptor) -> IO (WGPUSurface),
+    wgpuInstanceRequestAdapter :: WGPUInstance -> Ptr (WGPURequestAdapterOptions) -> WGPURequestAdapterCallback -> Ptr (()) -> IO (()),
+    wgpuQueueSubmit :: WGPUQueue -> Word32 -> Ptr (WGPUCommandBuffer) -> IO (()),
+    wgpuQueueWriteBuffer :: WGPUQueue -> WGPUBuffer -> Word64 -> Ptr (()) -> CSize -> IO (()),
+    wgpuQueueWriteTexture :: WGPUQueue -> Ptr (WGPUImageCopyTexture) -> Ptr (()) -> CSize -> Ptr (WGPUTextureDataLayout) -> Ptr (WGPUExtent3D) -> IO (()),
+    wgpuRenderPassEncoderDraw :: WGPURenderPassEncoder -> Word32 -> Word32 -> Word32 -> Word32 -> IO (()),
+    wgpuRenderPassEncoderDrawIndexed :: WGPURenderPassEncoder -> Word32 -> Word32 -> Word32 -> Int32 -> Word32 -> IO (()),
+    wgpuRenderPassEncoderDrawIndexedIndirect :: WGPURenderPassEncoder -> WGPUBuffer -> Word64 -> IO (()),
+    wgpuRenderPassEncoderDrawIndirect :: WGPURenderPassEncoder -> WGPUBuffer -> Word64 -> IO (()),
+    wgpuRenderPassEncoderEndPass :: WGPURenderPassEncoder -> IO (()),
+    wgpuRenderPassEncoderSetBindGroup :: WGPURenderPassEncoder -> Word32 -> WGPUBindGroup -> Word32 -> Ptr (Word32) -> IO (()),
+    wgpuRenderPassEncoderSetBlendConstant :: WGPURenderPassEncoder -> Ptr (WGPUColor) -> IO (()),
+    wgpuRenderPassEncoderSetIndexBuffer :: WGPURenderPassEncoder -> WGPUBuffer -> WGPUIndexFormat -> Word64 -> Word64 -> IO (()),
+    wgpuRenderPassEncoderSetPipeline :: WGPURenderPassEncoder -> WGPURenderPipeline -> IO (()),
+    wgpuRenderPassEncoderSetScissorRect :: WGPURenderPassEncoder -> Word32 -> Word32 -> Word32 -> Word32 -> IO (()),
+    wgpuRenderPassEncoderSetStencilReference :: WGPURenderPassEncoder -> Word32 -> IO (()),
+    wgpuRenderPassEncoderSetVertexBuffer :: WGPURenderPassEncoder -> Word32 -> WGPUBuffer -> Word64 -> Word64 -> IO (()),
+    wgpuRenderPassEncoderSetViewport :: WGPURenderPassEncoder -> CFloat -> CFloat -> CFloat -> CFloat -> CFloat -> CFloat -> IO (()),
+    wgpuSurfaceGetPreferredFormat :: WGPUSurface -> WGPUAdapter -> WGPUSurfaceGetPreferredFormatCallback -> Ptr (()) -> IO (()),
+    wgpuSwapChainGetCurrentTextureView :: WGPUSwapChain -> IO (WGPUTextureView),
+    wgpuSwapChainPresent :: WGPUSwapChain -> IO (()),
+    wgpuTextureCreateView :: WGPUTexture -> Ptr (WGPUTextureViewDescriptor) -> IO (WGPUTextureView),
+    wgpuTextureDestroy :: WGPUTexture -> IO (()),
+    wgpuDevicePoll :: WGPUDevice -> CBool -> IO (()),
+    wgpuSetLogCallback :: WGPULogCallback -> IO (()),
+    wgpuSetLogLevel :: WGPULogLevel -> IO (()),
+    wgpuGetVersion :: IO (Word32),
+    wgpuRenderPassEncoderSetPushConstants :: WGPURenderPassEncoder -> WGPUShaderStage -> Word32 -> Word32 -> Ptr (()) -> IO (())
+  }
+
+loadDynamicInstance ::
+  (forall a. String -> IO (FunPtr a)) ->
+  IO WGPUHsInstance
+loadDynamicInstance load = do
+  wgpuAdapterGetProperties <- mk_wgpuhsfn_wgpuAdapterGetProperties <$> load "wgpuAdapterGetProperties"
+  wgpuAdapterRequestDevice <- mk_wgpuhsfn_wgpuAdapterRequestDevice <$> load "wgpuAdapterRequestDevice"
+  wgpuBufferDestroy <- mk_wgpuhsfn_wgpuBufferDestroy <$> load "wgpuBufferDestroy"
+  wgpuBufferGetMappedRange <- mk_wgpuhsfn_wgpuBufferGetMappedRange <$> load "wgpuBufferGetMappedRange"
+  wgpuBufferMapAsync <- mk_wgpuhsfn_wgpuBufferMapAsync <$> load "wgpuBufferMapAsync"
+  wgpuBufferUnmap <- mk_wgpuhsfn_wgpuBufferUnmap <$> load "wgpuBufferUnmap"
+  wgpuCommandEncoderBeginComputePass <- mk_wgpuhsfn_wgpuCommandEncoderBeginComputePass <$> load "wgpuCommandEncoderBeginComputePass"
+  wgpuCommandEncoderBeginRenderPass <- mk_wgpuhsfn_wgpuCommandEncoderBeginRenderPass <$> load "wgpuCommandEncoderBeginRenderPass"
+  wgpuCommandEncoderCopyBufferToBuffer <- mk_wgpuhsfn_wgpuCommandEncoderCopyBufferToBuffer <$> load "wgpuCommandEncoderCopyBufferToBuffer"
+  wgpuCommandEncoderCopyBufferToTexture <- mk_wgpuhsfn_wgpuCommandEncoderCopyBufferToTexture <$> load "wgpuCommandEncoderCopyBufferToTexture"
+  wgpuCommandEncoderCopyTextureToTexture <- mk_wgpuhsfn_wgpuCommandEncoderCopyTextureToTexture <$> load "wgpuCommandEncoderCopyTextureToTexture"
+  wgpuCommandEncoderCopyTextureToBuffer <- mk_wgpuhsfn_wgpuCommandEncoderCopyTextureToBuffer <$> load "wgpuCommandEncoderCopyTextureToBuffer"
+  wgpuCommandEncoderFinish <- mk_wgpuhsfn_wgpuCommandEncoderFinish <$> load "wgpuCommandEncoderFinish"
+  wgpuComputePassEncoderDispatch <- mk_wgpuhsfn_wgpuComputePassEncoderDispatch <$> load "wgpuComputePassEncoderDispatch"
+  wgpuComputePassEncoderDispatchIndirect <- mk_wgpuhsfn_wgpuComputePassEncoderDispatchIndirect <$> load "wgpuComputePassEncoderDispatchIndirect"
+  wgpuComputePassEncoderEndPass <- mk_wgpuhsfn_wgpuComputePassEncoderEndPass <$> load "wgpuComputePassEncoderEndPass"
+  wgpuComputePassEncoderSetBindGroup <- mk_wgpuhsfn_wgpuComputePassEncoderSetBindGroup <$> load "wgpuComputePassEncoderSetBindGroup"
+  wgpuComputePassEncoderSetPipeline <- mk_wgpuhsfn_wgpuComputePassEncoderSetPipeline <$> load "wgpuComputePassEncoderSetPipeline"
+  wgpuDeviceCreateBindGroup <- mk_wgpuhsfn_wgpuDeviceCreateBindGroup <$> load "wgpuDeviceCreateBindGroup"
+  wgpuDeviceCreateBindGroupLayout <- mk_wgpuhsfn_wgpuDeviceCreateBindGroupLayout <$> load "wgpuDeviceCreateBindGroupLayout"
+  wgpuDeviceCreateBuffer <- mk_wgpuhsfn_wgpuDeviceCreateBuffer <$> load "wgpuDeviceCreateBuffer"
+  wgpuDeviceCreateCommandEncoder <- mk_wgpuhsfn_wgpuDeviceCreateCommandEncoder <$> load "wgpuDeviceCreateCommandEncoder"
+  wgpuDeviceCreateComputePipeline <- mk_wgpuhsfn_wgpuDeviceCreateComputePipeline <$> load "wgpuDeviceCreateComputePipeline"
+  wgpuDeviceCreatePipelineLayout <- mk_wgpuhsfn_wgpuDeviceCreatePipelineLayout <$> load "wgpuDeviceCreatePipelineLayout"
+  wgpuDeviceCreateRenderPipeline <- mk_wgpuhsfn_wgpuDeviceCreateRenderPipeline <$> load "wgpuDeviceCreateRenderPipeline"
+  wgpuDeviceCreateSampler <- mk_wgpuhsfn_wgpuDeviceCreateSampler <$> load "wgpuDeviceCreateSampler"
+  wgpuDeviceCreateShaderModule <- mk_wgpuhsfn_wgpuDeviceCreateShaderModule <$> load "wgpuDeviceCreateShaderModule"
+  wgpuDeviceCreateSwapChain <- mk_wgpuhsfn_wgpuDeviceCreateSwapChain <$> load "wgpuDeviceCreateSwapChain"
+  wgpuDeviceCreateTexture <- mk_wgpuhsfn_wgpuDeviceCreateTexture <$> load "wgpuDeviceCreateTexture"
+  wgpuDeviceGetQueue <- mk_wgpuhsfn_wgpuDeviceGetQueue <$> load "wgpuDeviceGetQueue"
+  wgpuInstanceCreateSurface <- mk_wgpuhsfn_wgpuInstanceCreateSurface <$> load "wgpuInstanceCreateSurface"
+  wgpuInstanceRequestAdapter <- mk_wgpuhsfn_wgpuInstanceRequestAdapter <$> load "wgpuInstanceRequestAdapter"
+  wgpuQueueSubmit <- mk_wgpuhsfn_wgpuQueueSubmit <$> load "wgpuQueueSubmit"
+  wgpuQueueWriteBuffer <- mk_wgpuhsfn_wgpuQueueWriteBuffer <$> load "wgpuQueueWriteBuffer"
+  wgpuQueueWriteTexture <- mk_wgpuhsfn_wgpuQueueWriteTexture <$> load "wgpuQueueWriteTexture"
+  wgpuRenderPassEncoderDraw <- mk_wgpuhsfn_wgpuRenderPassEncoderDraw <$> load "wgpuRenderPassEncoderDraw"
+  wgpuRenderPassEncoderDrawIndexed <- mk_wgpuhsfn_wgpuRenderPassEncoderDrawIndexed <$> load "wgpuRenderPassEncoderDrawIndexed"
+  wgpuRenderPassEncoderDrawIndexedIndirect <- mk_wgpuhsfn_wgpuRenderPassEncoderDrawIndexedIndirect <$> load "wgpuRenderPassEncoderDrawIndexedIndirect"
+  wgpuRenderPassEncoderDrawIndirect <- mk_wgpuhsfn_wgpuRenderPassEncoderDrawIndirect <$> load "wgpuRenderPassEncoderDrawIndirect"
+  wgpuRenderPassEncoderEndPass <- mk_wgpuhsfn_wgpuRenderPassEncoderEndPass <$> load "wgpuRenderPassEncoderEndPass"
+  wgpuRenderPassEncoderSetBindGroup <- mk_wgpuhsfn_wgpuRenderPassEncoderSetBindGroup <$> load "wgpuRenderPassEncoderSetBindGroup"
+  wgpuRenderPassEncoderSetBlendConstant <- mk_wgpuhsfn_wgpuRenderPassEncoderSetBlendConstant <$> load "wgpuRenderPassEncoderSetBlendConstant"
+  wgpuRenderPassEncoderSetIndexBuffer <- mk_wgpuhsfn_wgpuRenderPassEncoderSetIndexBuffer <$> load "wgpuRenderPassEncoderSetIndexBuffer"
+  wgpuRenderPassEncoderSetPipeline <- mk_wgpuhsfn_wgpuRenderPassEncoderSetPipeline <$> load "wgpuRenderPassEncoderSetPipeline"
+  wgpuRenderPassEncoderSetScissorRect <- mk_wgpuhsfn_wgpuRenderPassEncoderSetScissorRect <$> load "wgpuRenderPassEncoderSetScissorRect"
+  wgpuRenderPassEncoderSetStencilReference <- mk_wgpuhsfn_wgpuRenderPassEncoderSetStencilReference <$> load "wgpuRenderPassEncoderSetStencilReference"
+  wgpuRenderPassEncoderSetVertexBuffer <- mk_wgpuhsfn_wgpuRenderPassEncoderSetVertexBuffer <$> load "wgpuRenderPassEncoderSetVertexBuffer"
+  wgpuRenderPassEncoderSetViewport <- mk_wgpuhsfn_wgpuRenderPassEncoderSetViewport <$> load "wgpuRenderPassEncoderSetViewport"
+  wgpuSurfaceGetPreferredFormat <- mk_wgpuhsfn_wgpuSurfaceGetPreferredFormat <$> load "wgpuSurfaceGetPreferredFormat"
+  wgpuSwapChainGetCurrentTextureView <- mk_wgpuhsfn_wgpuSwapChainGetCurrentTextureView <$> load "wgpuSwapChainGetCurrentTextureView"
+  wgpuSwapChainPresent <- mk_wgpuhsfn_wgpuSwapChainPresent <$> load "wgpuSwapChainPresent"
+  wgpuTextureCreateView <- mk_wgpuhsfn_wgpuTextureCreateView <$> load "wgpuTextureCreateView"
+  wgpuTextureDestroy <- mk_wgpuhsfn_wgpuTextureDestroy <$> load "wgpuTextureDestroy"
+  wgpuDevicePoll <- mk_wgpuhsfn_wgpuDevicePoll <$> load "wgpuDevicePoll"
+  wgpuSetLogCallback <- mk_wgpuhsfn_wgpuSetLogCallback <$> load "wgpuSetLogCallback"
+  wgpuSetLogLevel <- mk_wgpuhsfn_wgpuSetLogLevel <$> load "wgpuSetLogLevel"
+  wgpuGetVersion <- mk_wgpuhsfn_wgpuGetVersion <$> load "wgpuGetVersion"
+  wgpuRenderPassEncoderSetPushConstants <- mk_wgpuhsfn_wgpuRenderPassEncoderSetPushConstants <$> load "wgpuRenderPassEncoderSetPushConstants"
+  pure WGPUHsInstance {..}
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuAdapterGetProperties :: FunPtr (WGPUAdapter -> Ptr (WGPUAdapterProperties) -> IO (())) -> WGPUAdapter -> Ptr (WGPUAdapterProperties) -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuAdapterRequestDevice :: FunPtr (WGPUAdapter -> Ptr (WGPUDeviceDescriptor) -> WGPURequestDeviceCallback -> Ptr (()) -> IO (())) -> WGPUAdapter -> Ptr (WGPUDeviceDescriptor) -> WGPURequestDeviceCallback -> Ptr (()) -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuBufferDestroy :: FunPtr (WGPUBuffer -> IO (())) -> WGPUBuffer -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuBufferGetMappedRange :: FunPtr (WGPUBuffer -> CSize -> CSize -> IO (Ptr (()))) -> WGPUBuffer -> CSize -> CSize -> IO (Ptr (()))
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuBufferMapAsync :: FunPtr (WGPUBuffer -> WGPUMapModeFlags -> CSize -> CSize -> WGPUBufferMapCallback -> Ptr (()) -> IO (())) -> WGPUBuffer -> WGPUMapModeFlags -> CSize -> CSize -> WGPUBufferMapCallback -> Ptr (()) -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuBufferUnmap :: FunPtr (WGPUBuffer -> IO (())) -> WGPUBuffer -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuCommandEncoderBeginComputePass :: FunPtr (WGPUCommandEncoder -> Ptr (WGPUComputePassDescriptor) -> IO (WGPUComputePassEncoder)) -> WGPUCommandEncoder -> Ptr (WGPUComputePassDescriptor) -> IO (WGPUComputePassEncoder)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuCommandEncoderBeginRenderPass :: FunPtr (WGPUCommandEncoder -> Ptr (WGPURenderPassDescriptor) -> IO (WGPURenderPassEncoder)) -> WGPUCommandEncoder -> Ptr (WGPURenderPassDescriptor) -> IO (WGPURenderPassEncoder)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuCommandEncoderCopyBufferToBuffer :: FunPtr (WGPUCommandEncoder -> WGPUBuffer -> Word64 -> WGPUBuffer -> Word64 -> Word64 -> IO (())) -> WGPUCommandEncoder -> WGPUBuffer -> Word64 -> WGPUBuffer -> Word64 -> Word64 -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuCommandEncoderCopyBufferToTexture :: FunPtr (WGPUCommandEncoder -> Ptr (WGPUImageCopyBuffer) -> Ptr (WGPUImageCopyTexture) -> Ptr (WGPUExtent3D) -> IO (())) -> WGPUCommandEncoder -> Ptr (WGPUImageCopyBuffer) -> Ptr (WGPUImageCopyTexture) -> Ptr (WGPUExtent3D) -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuCommandEncoderCopyTextureToTexture :: FunPtr (WGPUCommandEncoder -> Ptr (WGPUImageCopyTexture) -> Ptr (WGPUImageCopyTexture) -> Ptr (WGPUExtent3D) -> IO (())) -> WGPUCommandEncoder -> Ptr (WGPUImageCopyTexture) -> Ptr (WGPUImageCopyTexture) -> Ptr (WGPUExtent3D) -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuCommandEncoderCopyTextureToBuffer :: FunPtr (WGPUCommandEncoder -> Ptr (WGPUImageCopyTexture) -> Ptr (WGPUImageCopyBuffer) -> Ptr (WGPUExtent3D) -> IO (())) -> WGPUCommandEncoder -> Ptr (WGPUImageCopyTexture) -> Ptr (WGPUImageCopyBuffer) -> Ptr (WGPUExtent3D) -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuCommandEncoderFinish :: FunPtr (WGPUCommandEncoder -> Ptr (WGPUCommandBufferDescriptor) -> IO (WGPUCommandBuffer)) -> WGPUCommandEncoder -> Ptr (WGPUCommandBufferDescriptor) -> IO (WGPUCommandBuffer)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuComputePassEncoderDispatch :: FunPtr (WGPUComputePassEncoder -> Word32 -> Word32 -> Word32 -> IO (())) -> WGPUComputePassEncoder -> Word32 -> Word32 -> Word32 -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuComputePassEncoderDispatchIndirect :: FunPtr (WGPUComputePassEncoder -> WGPUBuffer -> Word64 -> IO (())) -> WGPUComputePassEncoder -> WGPUBuffer -> Word64 -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuComputePassEncoderEndPass :: FunPtr (WGPUComputePassEncoder -> IO (())) -> WGPUComputePassEncoder -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuComputePassEncoderSetBindGroup :: FunPtr (WGPUComputePassEncoder -> Word32 -> WGPUBindGroup -> Word32 -> Ptr (Word32) -> IO (())) -> WGPUComputePassEncoder -> Word32 -> WGPUBindGroup -> Word32 -> Ptr (Word32) -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuComputePassEncoderSetPipeline :: FunPtr (WGPUComputePassEncoder -> WGPUComputePipeline -> IO (())) -> WGPUComputePassEncoder -> WGPUComputePipeline -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuDeviceCreateBindGroup :: FunPtr (WGPUDevice -> Ptr (WGPUBindGroupDescriptor) -> IO (WGPUBindGroup)) -> WGPUDevice -> Ptr (WGPUBindGroupDescriptor) -> IO (WGPUBindGroup)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuDeviceCreateBindGroupLayout :: FunPtr (WGPUDevice -> Ptr (WGPUBindGroupLayoutDescriptor) -> IO (WGPUBindGroupLayout)) -> WGPUDevice -> Ptr (WGPUBindGroupLayoutDescriptor) -> IO (WGPUBindGroupLayout)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuDeviceCreateBuffer :: FunPtr (WGPUDevice -> Ptr (WGPUBufferDescriptor) -> IO (WGPUBuffer)) -> WGPUDevice -> Ptr (WGPUBufferDescriptor) -> IO (WGPUBuffer)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuDeviceCreateCommandEncoder :: FunPtr (WGPUDevice -> Ptr (WGPUCommandEncoderDescriptor) -> IO (WGPUCommandEncoder)) -> WGPUDevice -> Ptr (WGPUCommandEncoderDescriptor) -> IO (WGPUCommandEncoder)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuDeviceCreateComputePipeline :: FunPtr (WGPUDevice -> Ptr (WGPUComputePipelineDescriptor) -> IO (WGPUComputePipeline)) -> WGPUDevice -> Ptr (WGPUComputePipelineDescriptor) -> IO (WGPUComputePipeline)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuDeviceCreatePipelineLayout :: FunPtr (WGPUDevice -> Ptr (WGPUPipelineLayoutDescriptor) -> IO (WGPUPipelineLayout)) -> WGPUDevice -> Ptr (WGPUPipelineLayoutDescriptor) -> IO (WGPUPipelineLayout)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuDeviceCreateRenderPipeline :: FunPtr (WGPUDevice -> Ptr (WGPURenderPipelineDescriptor) -> IO (WGPURenderPipeline)) -> WGPUDevice -> Ptr (WGPURenderPipelineDescriptor) -> IO (WGPURenderPipeline)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuDeviceCreateSampler :: FunPtr (WGPUDevice -> Ptr (WGPUSamplerDescriptor) -> IO (WGPUSampler)) -> WGPUDevice -> Ptr (WGPUSamplerDescriptor) -> IO (WGPUSampler)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuDeviceCreateShaderModule :: FunPtr (WGPUDevice -> Ptr (WGPUShaderModuleDescriptor) -> IO (WGPUShaderModule)) -> WGPUDevice -> Ptr (WGPUShaderModuleDescriptor) -> IO (WGPUShaderModule)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuDeviceCreateSwapChain :: FunPtr (WGPUDevice -> WGPUSurface -> Ptr (WGPUSwapChainDescriptor) -> IO (WGPUSwapChain)) -> WGPUDevice -> WGPUSurface -> Ptr (WGPUSwapChainDescriptor) -> IO (WGPUSwapChain)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuDeviceCreateTexture :: FunPtr (WGPUDevice -> Ptr (WGPUTextureDescriptor) -> IO (WGPUTexture)) -> WGPUDevice -> Ptr (WGPUTextureDescriptor) -> IO (WGPUTexture)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuDeviceGetQueue :: FunPtr (WGPUDevice -> IO (WGPUQueue)) -> WGPUDevice -> IO (WGPUQueue)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuInstanceCreateSurface :: FunPtr (WGPUInstance -> Ptr (WGPUSurfaceDescriptor) -> IO (WGPUSurface)) -> WGPUInstance -> Ptr (WGPUSurfaceDescriptor) -> IO (WGPUSurface)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuInstanceRequestAdapter :: FunPtr (WGPUInstance -> Ptr (WGPURequestAdapterOptions) -> WGPURequestAdapterCallback -> Ptr (()) -> IO (())) -> WGPUInstance -> Ptr (WGPURequestAdapterOptions) -> WGPURequestAdapterCallback -> Ptr (()) -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuQueueSubmit :: FunPtr (WGPUQueue -> Word32 -> Ptr (WGPUCommandBuffer) -> IO (())) -> WGPUQueue -> Word32 -> Ptr (WGPUCommandBuffer) -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuQueueWriteBuffer :: FunPtr (WGPUQueue -> WGPUBuffer -> Word64 -> Ptr (()) -> CSize -> IO (())) -> WGPUQueue -> WGPUBuffer -> Word64 -> Ptr (()) -> CSize -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuQueueWriteTexture :: FunPtr (WGPUQueue -> Ptr (WGPUImageCopyTexture) -> Ptr (()) -> CSize -> Ptr (WGPUTextureDataLayout) -> Ptr (WGPUExtent3D) -> IO (())) -> WGPUQueue -> Ptr (WGPUImageCopyTexture) -> Ptr (()) -> CSize -> Ptr (WGPUTextureDataLayout) -> Ptr (WGPUExtent3D) -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderDraw :: FunPtr (WGPURenderPassEncoder -> Word32 -> Word32 -> Word32 -> Word32 -> IO (())) -> WGPURenderPassEncoder -> Word32 -> Word32 -> Word32 -> Word32 -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderDrawIndexed :: FunPtr (WGPURenderPassEncoder -> Word32 -> Word32 -> Word32 -> Int32 -> Word32 -> IO (())) -> WGPURenderPassEncoder -> Word32 -> Word32 -> Word32 -> Int32 -> Word32 -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderDrawIndexedIndirect :: FunPtr (WGPURenderPassEncoder -> WGPUBuffer -> Word64 -> IO (())) -> WGPURenderPassEncoder -> WGPUBuffer -> Word64 -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderDrawIndirect :: FunPtr (WGPURenderPassEncoder -> WGPUBuffer -> Word64 -> IO (())) -> WGPURenderPassEncoder -> WGPUBuffer -> Word64 -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderEndPass :: FunPtr (WGPURenderPassEncoder -> IO (())) -> WGPURenderPassEncoder -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderSetBindGroup :: FunPtr (WGPURenderPassEncoder -> Word32 -> WGPUBindGroup -> Word32 -> Ptr (Word32) -> IO (())) -> WGPURenderPassEncoder -> Word32 -> WGPUBindGroup -> Word32 -> Ptr (Word32) -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderSetBlendConstant :: FunPtr (WGPURenderPassEncoder -> Ptr (WGPUColor) -> IO (())) -> WGPURenderPassEncoder -> Ptr (WGPUColor) -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderSetIndexBuffer :: FunPtr (WGPURenderPassEncoder -> WGPUBuffer -> WGPUIndexFormat -> Word64 -> Word64 -> IO (())) -> WGPURenderPassEncoder -> WGPUBuffer -> WGPUIndexFormat -> Word64 -> Word64 -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderSetPipeline :: FunPtr (WGPURenderPassEncoder -> WGPURenderPipeline -> IO (())) -> WGPURenderPassEncoder -> WGPURenderPipeline -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderSetScissorRect :: FunPtr (WGPURenderPassEncoder -> Word32 -> Word32 -> Word32 -> Word32 -> IO (())) -> WGPURenderPassEncoder -> Word32 -> Word32 -> Word32 -> Word32 -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderSetStencilReference :: FunPtr (WGPURenderPassEncoder -> Word32 -> IO (())) -> WGPURenderPassEncoder -> Word32 -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderSetVertexBuffer :: FunPtr (WGPURenderPassEncoder -> Word32 -> WGPUBuffer -> Word64 -> Word64 -> IO (())) -> WGPURenderPassEncoder -> Word32 -> WGPUBuffer -> Word64 -> Word64 -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderSetViewport :: FunPtr (WGPURenderPassEncoder -> CFloat -> CFloat -> CFloat -> CFloat -> CFloat -> CFloat -> IO (())) -> WGPURenderPassEncoder -> CFloat -> CFloat -> CFloat -> CFloat -> CFloat -> CFloat -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuSurfaceGetPreferredFormat :: FunPtr (WGPUSurface -> WGPUAdapter -> WGPUSurfaceGetPreferredFormatCallback -> Ptr (()) -> IO (())) -> WGPUSurface -> WGPUAdapter -> WGPUSurfaceGetPreferredFormatCallback -> Ptr (()) -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuSwapChainGetCurrentTextureView :: FunPtr (WGPUSwapChain -> IO (WGPUTextureView)) -> WGPUSwapChain -> IO (WGPUTextureView)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuSwapChainPresent :: FunPtr (WGPUSwapChain -> IO (())) -> WGPUSwapChain -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuTextureCreateView :: FunPtr (WGPUTexture -> Ptr (WGPUTextureViewDescriptor) -> IO (WGPUTextureView)) -> WGPUTexture -> Ptr (WGPUTextureViewDescriptor) -> IO (WGPUTextureView)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuTextureDestroy :: FunPtr (WGPUTexture -> IO (())) -> WGPUTexture -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuDevicePoll :: FunPtr (WGPUDevice -> CBool -> IO (())) -> WGPUDevice -> CBool -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuSetLogCallback :: FunPtr (WGPULogCallback -> IO (())) -> WGPULogCallback -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuSetLogLevel :: FunPtr (WGPULogLevel -> IO (())) -> WGPULogLevel -> IO (())
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuGetVersion :: FunPtr (IO (Word32)) -> IO (Word32)
+
+foreign import ccall "dynamic"
+  mk_wgpuhsfn_wgpuRenderPassEncoderSetPushConstants :: FunPtr (WGPURenderPassEncoder -> WGPUShaderStage -> Word32 -> Word32 -> Ptr (()) -> IO (())) -> WGPURenderPassEncoder -> WGPUShaderStage -> Word32 -> Word32 -> Ptr (()) -> IO (())
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUAdapterExtras.hsc b/src/WGPU/Raw/Generated/Struct/WGPUAdapterExtras.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUAdapterExtras.hsc
@@ -0,0 +1,37 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUAdapterExtras where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUBackendType
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUAdapterExtras = WGPUAdapterExtras {
+  chain :: WGPUChainedStruct,
+  backend :: WGPUBackendType
+}
+
+instance Storable WGPUAdapterExtras where
+  sizeOf _ = (#size WGPUAdapterExtras)
+  alignment = sizeOf
+  peek ptr = do
+    chain <- (#peek WGPUAdapterExtras, chain) ptr
+    backend <- (#peek WGPUAdapterExtras, backend) ptr
+    pure $! WGPUAdapterExtras{..}
+  poke ptr WGPUAdapterExtras{..} = do
+    (#poke WGPUAdapterExtras, chain) ptr chain
+    (#poke WGPUAdapterExtras, backend) ptr backend
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUAdapterProperties.hsc b/src/WGPU/Raw/Generated/Struct/WGPUAdapterProperties.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUAdapterProperties.hsc
@@ -0,0 +1,53 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUAdapterProperties where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUAdapterType
+import WGPU.Raw.Generated.Enum.WGPUBackendType
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUAdapterProperties = WGPUAdapterProperties {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  deviceID :: Word32,
+  vendorID :: Word32,
+  name :: Ptr (CChar),
+  driverDescription :: Ptr (CChar),
+  adapterType :: WGPUAdapterType,
+  backendType :: WGPUBackendType
+}
+
+instance Storable WGPUAdapterProperties where
+  sizeOf _ = (#size WGPUAdapterProperties)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUAdapterProperties, nextInChain) ptr
+    deviceID <- (#peek WGPUAdapterProperties, deviceID) ptr
+    vendorID <- (#peek WGPUAdapterProperties, vendorID) ptr
+    name <- (#peek WGPUAdapterProperties, name) ptr
+    driverDescription <- (#peek WGPUAdapterProperties, driverDescription) ptr
+    adapterType <- (#peek WGPUAdapterProperties, adapterType) ptr
+    backendType <- (#peek WGPUAdapterProperties, backendType) ptr
+    pure $! WGPUAdapterProperties{..}
+  poke ptr WGPUAdapterProperties{..} = do
+    (#poke WGPUAdapterProperties, nextInChain) ptr nextInChain
+    (#poke WGPUAdapterProperties, deviceID) ptr deviceID
+    (#poke WGPUAdapterProperties, vendorID) ptr vendorID
+    (#poke WGPUAdapterProperties, name) ptr name
+    (#poke WGPUAdapterProperties, driverDescription) ptr driverDescription
+    (#poke WGPUAdapterProperties, adapterType) ptr adapterType
+    (#poke WGPUAdapterProperties, backendType) ptr backendType
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUBindGroupDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUBindGroupDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUBindGroupDescriptor.hsc
@@ -0,0 +1,46 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUBindGroupDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUBindGroupEntry
+
+data WGPUBindGroupDescriptor = WGPUBindGroupDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar),
+  layout :: WGPUBindGroupLayout,
+  entryCount :: Word32,
+  entries :: Ptr (WGPUBindGroupEntry)
+}
+
+instance Storable WGPUBindGroupDescriptor where
+  sizeOf _ = (#size WGPUBindGroupDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUBindGroupDescriptor, nextInChain) ptr
+    label <- (#peek WGPUBindGroupDescriptor, label) ptr
+    layout <- (#peek WGPUBindGroupDescriptor, layout) ptr
+    entryCount <- (#peek WGPUBindGroupDescriptor, entryCount) ptr
+    entries <- (#peek WGPUBindGroupDescriptor, entries) ptr
+    pure $! WGPUBindGroupDescriptor{..}
+  poke ptr WGPUBindGroupDescriptor{..} = do
+    (#poke WGPUBindGroupDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUBindGroupDescriptor, label) ptr label
+    (#poke WGPUBindGroupDescriptor, layout) ptr layout
+    (#poke WGPUBindGroupDescriptor, entryCount) ptr entryCount
+    (#poke WGPUBindGroupDescriptor, entries) ptr entries
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUBindGroupEntry.hsc b/src/WGPU/Raw/Generated/Struct/WGPUBindGroupEntry.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUBindGroupEntry.hsc
@@ -0,0 +1,48 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUBindGroupEntry where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+
+
+data WGPUBindGroupEntry = WGPUBindGroupEntry {
+  binding :: Word32,
+  buffer :: WGPUBuffer,
+  offset :: Word64,
+  size :: Word64,
+  sampler :: WGPUSampler,
+  textureView :: WGPUTextureView
+}
+
+instance Storable WGPUBindGroupEntry where
+  sizeOf _ = (#size WGPUBindGroupEntry)
+  alignment = sizeOf
+  peek ptr = do
+    binding <- (#peek WGPUBindGroupEntry, binding) ptr
+    buffer <- (#peek WGPUBindGroupEntry, buffer) ptr
+    offset <- (#peek WGPUBindGroupEntry, offset) ptr
+    size <- (#peek WGPUBindGroupEntry, size) ptr
+    sampler <- (#peek WGPUBindGroupEntry, sampler) ptr
+    textureView <- (#peek WGPUBindGroupEntry, textureView) ptr
+    pure $! WGPUBindGroupEntry{..}
+  poke ptr WGPUBindGroupEntry{..} = do
+    (#poke WGPUBindGroupEntry, binding) ptr binding
+    (#poke WGPUBindGroupEntry, buffer) ptr buffer
+    (#poke WGPUBindGroupEntry, offset) ptr offset
+    (#poke WGPUBindGroupEntry, size) ptr size
+    (#poke WGPUBindGroupEntry, sampler) ptr sampler
+    (#poke WGPUBindGroupEntry, textureView) ptr textureView
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUBindGroupLayoutDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUBindGroupLayoutDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUBindGroupLayoutDescriptor.hsc
@@ -0,0 +1,43 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUBindGroupLayoutDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUBindGroupLayoutEntry
+
+data WGPUBindGroupLayoutDescriptor = WGPUBindGroupLayoutDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar),
+  entryCount :: Word32,
+  entries :: Ptr (WGPUBindGroupLayoutEntry)
+}
+
+instance Storable WGPUBindGroupLayoutDescriptor where
+  sizeOf _ = (#size WGPUBindGroupLayoutDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUBindGroupLayoutDescriptor, nextInChain) ptr
+    label <- (#peek WGPUBindGroupLayoutDescriptor, label) ptr
+    entryCount <- (#peek WGPUBindGroupLayoutDescriptor, entryCount) ptr
+    entries <- (#peek WGPUBindGroupLayoutDescriptor, entries) ptr
+    pure $! WGPUBindGroupLayoutDescriptor{..}
+  poke ptr WGPUBindGroupLayoutDescriptor{..} = do
+    (#poke WGPUBindGroupLayoutDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUBindGroupLayoutDescriptor, label) ptr label
+    (#poke WGPUBindGroupLayoutDescriptor, entryCount) ptr entryCount
+    (#poke WGPUBindGroupLayoutDescriptor, entries) ptr entries
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUBindGroupLayoutEntry.hsc b/src/WGPU/Raw/Generated/Struct/WGPUBindGroupLayoutEntry.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUBindGroupLayoutEntry.hsc
@@ -0,0 +1,55 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUBindGroupLayoutEntry where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUBufferBindingLayout
+import WGPU.Raw.Generated.Struct.WGPUSamplerBindingLayout
+import WGPU.Raw.Generated.Struct.WGPUTextureBindingLayout
+import WGPU.Raw.Generated.Struct.WGPUStorageTextureBindingLayout
+
+data WGPUBindGroupLayoutEntry = WGPUBindGroupLayoutEntry {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  binding :: Word32,
+  visibility :: WGPUShaderStageFlags,
+  buffer :: WGPUBufferBindingLayout,
+  sampler :: WGPUSamplerBindingLayout,
+  texture :: WGPUTextureBindingLayout,
+  storageTexture :: WGPUStorageTextureBindingLayout
+}
+
+instance Storable WGPUBindGroupLayoutEntry where
+  sizeOf _ = (#size WGPUBindGroupLayoutEntry)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUBindGroupLayoutEntry, nextInChain) ptr
+    binding <- (#peek WGPUBindGroupLayoutEntry, binding) ptr
+    visibility <- (#peek WGPUBindGroupLayoutEntry, visibility) ptr
+    buffer <- (#peek WGPUBindGroupLayoutEntry, buffer) ptr
+    sampler <- (#peek WGPUBindGroupLayoutEntry, sampler) ptr
+    texture <- (#peek WGPUBindGroupLayoutEntry, texture) ptr
+    storageTexture <- (#peek WGPUBindGroupLayoutEntry, storageTexture) ptr
+    pure $! WGPUBindGroupLayoutEntry{..}
+  poke ptr WGPUBindGroupLayoutEntry{..} = do
+    (#poke WGPUBindGroupLayoutEntry, nextInChain) ptr nextInChain
+    (#poke WGPUBindGroupLayoutEntry, binding) ptr binding
+    (#poke WGPUBindGroupLayoutEntry, visibility) ptr visibility
+    (#poke WGPUBindGroupLayoutEntry, buffer) ptr buffer
+    (#poke WGPUBindGroupLayoutEntry, sampler) ptr sampler
+    (#poke WGPUBindGroupLayoutEntry, texture) ptr texture
+    (#poke WGPUBindGroupLayoutEntry, storageTexture) ptr storageTexture
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUBlendComponent.hsc b/src/WGPU/Raw/Generated/Struct/WGPUBlendComponent.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUBlendComponent.hsc
@@ -0,0 +1,41 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUBlendComponent where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUBlendFactor
+import WGPU.Raw.Generated.Enum.WGPUBlendFactor
+import WGPU.Raw.Generated.Enum.WGPUBlendOperation
+
+data WGPUBlendComponent = WGPUBlendComponent {
+  srcFactor :: WGPUBlendFactor,
+  dstFactor :: WGPUBlendFactor,
+  operation :: WGPUBlendOperation
+}
+
+instance Storable WGPUBlendComponent where
+  sizeOf _ = (#size WGPUBlendComponent)
+  alignment = sizeOf
+  peek ptr = do
+    srcFactor <- (#peek WGPUBlendComponent, srcFactor) ptr
+    dstFactor <- (#peek WGPUBlendComponent, dstFactor) ptr
+    operation <- (#peek WGPUBlendComponent, operation) ptr
+    pure $! WGPUBlendComponent{..}
+  poke ptr WGPUBlendComponent{..} = do
+    (#poke WGPUBlendComponent, srcFactor) ptr srcFactor
+    (#poke WGPUBlendComponent, dstFactor) ptr dstFactor
+    (#poke WGPUBlendComponent, operation) ptr operation
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUBlendState.hsc b/src/WGPU/Raw/Generated/Struct/WGPUBlendState.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUBlendState.hsc
@@ -0,0 +1,37 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUBlendState where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUBlendComponent
+import WGPU.Raw.Generated.Struct.WGPUBlendComponent
+
+data WGPUBlendState = WGPUBlendState {
+  color :: WGPUBlendComponent,
+  alpha :: WGPUBlendComponent
+}
+
+instance Storable WGPUBlendState where
+  sizeOf _ = (#size WGPUBlendState)
+  alignment = sizeOf
+  peek ptr = do
+    color <- (#peek WGPUBlendState, color) ptr
+    alpha <- (#peek WGPUBlendState, alpha) ptr
+    pure $! WGPUBlendState{..}
+  poke ptr WGPUBlendState{..} = do
+    (#poke WGPUBlendState, color) ptr color
+    (#poke WGPUBlendState, alpha) ptr alpha
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUBufferBindingLayout.hsc b/src/WGPU/Raw/Generated/Struct/WGPUBufferBindingLayout.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUBufferBindingLayout.hsc
@@ -0,0 +1,43 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUBufferBindingLayout where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUBufferBindingType
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUBufferBindingLayout = WGPUBufferBindingLayout {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  typ :: WGPUBufferBindingType,
+  hasDynamicOffset :: CBool,
+  minBindingSize :: Word64
+}
+
+instance Storable WGPUBufferBindingLayout where
+  sizeOf _ = (#size WGPUBufferBindingLayout)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUBufferBindingLayout, nextInChain) ptr
+    typ <- (#peek WGPUBufferBindingLayout, type) ptr
+    hasDynamicOffset <- (#peek WGPUBufferBindingLayout, hasDynamicOffset) ptr
+    minBindingSize <- (#peek WGPUBufferBindingLayout, minBindingSize) ptr
+    pure $! WGPUBufferBindingLayout{..}
+  poke ptr WGPUBufferBindingLayout{..} = do
+    (#poke WGPUBufferBindingLayout, nextInChain) ptr nextInChain
+    (#poke WGPUBufferBindingLayout, type) ptr typ
+    (#poke WGPUBufferBindingLayout, hasDynamicOffset) ptr hasDynamicOffset
+    (#poke WGPUBufferBindingLayout, minBindingSize) ptr minBindingSize
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUBufferDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUBufferDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUBufferDescriptor.hsc
@@ -0,0 +1,45 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUBufferDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUBufferDescriptor = WGPUBufferDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar),
+  usage :: WGPUBufferUsageFlags,
+  size :: Word64,
+  mappedAtCreation :: CBool
+}
+
+instance Storable WGPUBufferDescriptor where
+  sizeOf _ = (#size WGPUBufferDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUBufferDescriptor, nextInChain) ptr
+    label <- (#peek WGPUBufferDescriptor, label) ptr
+    usage <- (#peek WGPUBufferDescriptor, usage) ptr
+    size <- (#peek WGPUBufferDescriptor, size) ptr
+    mappedAtCreation <- (#peek WGPUBufferDescriptor, mappedAtCreation) ptr
+    pure $! WGPUBufferDescriptor{..}
+  poke ptr WGPUBufferDescriptor{..} = do
+    (#poke WGPUBufferDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUBufferDescriptor, label) ptr label
+    (#poke WGPUBufferDescriptor, usage) ptr usage
+    (#poke WGPUBufferDescriptor, size) ptr size
+    (#poke WGPUBufferDescriptor, mappedAtCreation) ptr mappedAtCreation
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUChainedStruct.hsc b/src/WGPU/Raw/Generated/Struct/WGPUChainedStruct.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUChainedStruct.hsc
@@ -0,0 +1,36 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUChainedStruct where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUSType
+
+data WGPUChainedStruct = WGPUChainedStruct {
+  next :: Ptr (WGPUChainedStruct),
+  sType :: WGPUSType
+}
+
+instance Storable WGPUChainedStruct where
+  sizeOf _ = (#size WGPUChainedStruct)
+  alignment = sizeOf
+  peek ptr = do
+    next <- (#peek WGPUChainedStruct, next) ptr
+    sType <- (#peek WGPUChainedStruct, sType) ptr
+    pure $! WGPUChainedStruct{..}
+  poke ptr WGPUChainedStruct{..} = do
+    (#poke WGPUChainedStruct, next) ptr next
+    (#poke WGPUChainedStruct, sType) ptr sType
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUColor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUColor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUColor.hsc
@@ -0,0 +1,42 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUColor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+
+
+data WGPUColor = WGPUColor {
+  r :: CDouble,
+  g :: CDouble,
+  b :: CDouble,
+  a :: CDouble
+}
+
+instance Storable WGPUColor where
+  sizeOf _ = (#size WGPUColor)
+  alignment = sizeOf
+  peek ptr = do
+    r <- (#peek WGPUColor, r) ptr
+    g <- (#peek WGPUColor, g) ptr
+    b <- (#peek WGPUColor, b) ptr
+    a <- (#peek WGPUColor, a) ptr
+    pure $! WGPUColor{..}
+  poke ptr WGPUColor{..} = do
+    (#poke WGPUColor, r) ptr r
+    (#poke WGPUColor, g) ptr g
+    (#poke WGPUColor, b) ptr b
+    (#poke WGPUColor, a) ptr a
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUColorTargetState.hsc b/src/WGPU/Raw/Generated/Struct/WGPUColorTargetState.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUColorTargetState.hsc
@@ -0,0 +1,44 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUColorTargetState where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUTextureFormat
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUBlendState
+
+data WGPUColorTargetState = WGPUColorTargetState {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  format :: WGPUTextureFormat,
+  blend :: Ptr (WGPUBlendState),
+  writeMask :: WGPUColorWriteMaskFlags
+}
+
+instance Storable WGPUColorTargetState where
+  sizeOf _ = (#size WGPUColorTargetState)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUColorTargetState, nextInChain) ptr
+    format <- (#peek WGPUColorTargetState, format) ptr
+    blend <- (#peek WGPUColorTargetState, blend) ptr
+    writeMask <- (#peek WGPUColorTargetState, writeMask) ptr
+    pure $! WGPUColorTargetState{..}
+  poke ptr WGPUColorTargetState{..} = do
+    (#poke WGPUColorTargetState, nextInChain) ptr nextInChain
+    (#poke WGPUColorTargetState, format) ptr format
+    (#poke WGPUColorTargetState, blend) ptr blend
+    (#poke WGPUColorTargetState, writeMask) ptr writeMask
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUCommandBufferDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUCommandBufferDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUCommandBufferDescriptor.hsc
@@ -0,0 +1,36 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUCommandBufferDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUCommandBufferDescriptor = WGPUCommandBufferDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar)
+}
+
+instance Storable WGPUCommandBufferDescriptor where
+  sizeOf _ = (#size WGPUCommandBufferDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUCommandBufferDescriptor, nextInChain) ptr
+    label <- (#peek WGPUCommandBufferDescriptor, label) ptr
+    pure $! WGPUCommandBufferDescriptor{..}
+  poke ptr WGPUCommandBufferDescriptor{..} = do
+    (#poke WGPUCommandBufferDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUCommandBufferDescriptor, label) ptr label
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUCommandEncoderDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUCommandEncoderDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUCommandEncoderDescriptor.hsc
@@ -0,0 +1,36 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUCommandEncoderDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUCommandEncoderDescriptor = WGPUCommandEncoderDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar)
+}
+
+instance Storable WGPUCommandEncoderDescriptor where
+  sizeOf _ = (#size WGPUCommandEncoderDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUCommandEncoderDescriptor, nextInChain) ptr
+    label <- (#peek WGPUCommandEncoderDescriptor, label) ptr
+    pure $! WGPUCommandEncoderDescriptor{..}
+  poke ptr WGPUCommandEncoderDescriptor{..} = do
+    (#poke WGPUCommandEncoderDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUCommandEncoderDescriptor, label) ptr label
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUComputePassDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUComputePassDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUComputePassDescriptor.hsc
@@ -0,0 +1,36 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUComputePassDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUComputePassDescriptor = WGPUComputePassDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar)
+}
+
+instance Storable WGPUComputePassDescriptor where
+  sizeOf _ = (#size WGPUComputePassDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUComputePassDescriptor, nextInChain) ptr
+    label <- (#peek WGPUComputePassDescriptor, label) ptr
+    pure $! WGPUComputePassDescriptor{..}
+  poke ptr WGPUComputePassDescriptor{..} = do
+    (#poke WGPUComputePassDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUComputePassDescriptor, label) ptr label
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUComputePipelineDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUComputePipelineDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUComputePipelineDescriptor.hsc
@@ -0,0 +1,43 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUComputePipelineDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUProgrammableStageDescriptor
+
+data WGPUComputePipelineDescriptor = WGPUComputePipelineDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar),
+  layout :: WGPUPipelineLayout,
+  computeStage :: WGPUProgrammableStageDescriptor
+}
+
+instance Storable WGPUComputePipelineDescriptor where
+  sizeOf _ = (#size WGPUComputePipelineDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUComputePipelineDescriptor, nextInChain) ptr
+    label <- (#peek WGPUComputePipelineDescriptor, label) ptr
+    layout <- (#peek WGPUComputePipelineDescriptor, layout) ptr
+    computeStage <- (#peek WGPUComputePipelineDescriptor, computeStage) ptr
+    pure $! WGPUComputePipelineDescriptor{..}
+  poke ptr WGPUComputePipelineDescriptor{..} = do
+    (#poke WGPUComputePipelineDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUComputePipelineDescriptor, label) ptr label
+    (#poke WGPUComputePipelineDescriptor, layout) ptr layout
+    (#poke WGPUComputePipelineDescriptor, computeStage) ptr computeStage
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUDepthStencilState.hsc b/src/WGPU/Raw/Generated/Struct/WGPUDepthStencilState.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUDepthStencilState.hsc
@@ -0,0 +1,67 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUDepthStencilState where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUTextureFormat
+import WGPU.Raw.Generated.Enum.WGPUCompareFunction
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUStencilFaceState
+import WGPU.Raw.Generated.Struct.WGPUStencilFaceState
+
+data WGPUDepthStencilState = WGPUDepthStencilState {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  format :: WGPUTextureFormat,
+  depthWriteEnabled :: CBool,
+  depthCompare :: WGPUCompareFunction,
+  stencilFront :: WGPUStencilFaceState,
+  stencilBack :: WGPUStencilFaceState,
+  stencilReadMask :: Word32,
+  stencilWriteMask :: Word32,
+  depthBias :: Int32,
+  depthBiasSlopeScale :: CFloat,
+  depthBiasClamp :: CFloat
+}
+
+instance Storable WGPUDepthStencilState where
+  sizeOf _ = (#size WGPUDepthStencilState)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUDepthStencilState, nextInChain) ptr
+    format <- (#peek WGPUDepthStencilState, format) ptr
+    depthWriteEnabled <- (#peek WGPUDepthStencilState, depthWriteEnabled) ptr
+    depthCompare <- (#peek WGPUDepthStencilState, depthCompare) ptr
+    stencilFront <- (#peek WGPUDepthStencilState, stencilFront) ptr
+    stencilBack <- (#peek WGPUDepthStencilState, stencilBack) ptr
+    stencilReadMask <- (#peek WGPUDepthStencilState, stencilReadMask) ptr
+    stencilWriteMask <- (#peek WGPUDepthStencilState, stencilWriteMask) ptr
+    depthBias <- (#peek WGPUDepthStencilState, depthBias) ptr
+    depthBiasSlopeScale <- (#peek WGPUDepthStencilState, depthBiasSlopeScale) ptr
+    depthBiasClamp <- (#peek WGPUDepthStencilState, depthBiasClamp) ptr
+    pure $! WGPUDepthStencilState{..}
+  poke ptr WGPUDepthStencilState{..} = do
+    (#poke WGPUDepthStencilState, nextInChain) ptr nextInChain
+    (#poke WGPUDepthStencilState, format) ptr format
+    (#poke WGPUDepthStencilState, depthWriteEnabled) ptr depthWriteEnabled
+    (#poke WGPUDepthStencilState, depthCompare) ptr depthCompare
+    (#poke WGPUDepthStencilState, stencilFront) ptr stencilFront
+    (#poke WGPUDepthStencilState, stencilBack) ptr stencilBack
+    (#poke WGPUDepthStencilState, stencilReadMask) ptr stencilReadMask
+    (#poke WGPUDepthStencilState, stencilWriteMask) ptr stencilWriteMask
+    (#poke WGPUDepthStencilState, depthBias) ptr depthBias
+    (#poke WGPUDepthStencilState, depthBiasSlopeScale) ptr depthBiasSlopeScale
+    (#poke WGPUDepthStencilState, depthBiasClamp) ptr depthBiasClamp
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUDeviceDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUDeviceDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUDeviceDescriptor.hsc
@@ -0,0 +1,33 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUDeviceDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUDeviceDescriptor = WGPUDeviceDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct)
+}
+
+instance Storable WGPUDeviceDescriptor where
+  sizeOf _ = (#size WGPUDeviceDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUDeviceDescriptor, nextInChain) ptr
+    pure $! WGPUDeviceDescriptor{..}
+  poke ptr WGPUDeviceDescriptor{..} = do
+    (#poke WGPUDeviceDescriptor, nextInChain) ptr nextInChain
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUDeviceExtras.hsc b/src/WGPU/Raw/Generated/Struct/WGPUDeviceExtras.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUDeviceExtras.hsc
@@ -0,0 +1,67 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUDeviceExtras where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUNativeFeature
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUDeviceExtras = WGPUDeviceExtras {
+  chain :: WGPUChainedStruct,
+  maxTextureDimension1D :: Word32,
+  maxTextureDimension2D :: Word32,
+  maxTextureDimension3D :: Word32,
+  maxTextureArrayLayers :: Word32,
+  maxBindGroups :: Word32,
+  maxDynamicStorageBuffersPerPipelineLayout :: Word32,
+  maxStorageBuffersPerShaderStage :: Word32,
+  maxStorageBufferBindingSize :: Word32,
+  nativeFeatures :: WGPUNativeFeature,
+  label :: Ptr (CChar),
+  tracePath :: Ptr (CChar)
+}
+
+instance Storable WGPUDeviceExtras where
+  sizeOf _ = (#size WGPUDeviceExtras)
+  alignment = sizeOf
+  peek ptr = do
+    chain <- (#peek WGPUDeviceExtras, chain) ptr
+    maxTextureDimension1D <- (#peek WGPUDeviceExtras, maxTextureDimension1D) ptr
+    maxTextureDimension2D <- (#peek WGPUDeviceExtras, maxTextureDimension2D) ptr
+    maxTextureDimension3D <- (#peek WGPUDeviceExtras, maxTextureDimension3D) ptr
+    maxTextureArrayLayers <- (#peek WGPUDeviceExtras, maxTextureArrayLayers) ptr
+    maxBindGroups <- (#peek WGPUDeviceExtras, maxBindGroups) ptr
+    maxDynamicStorageBuffersPerPipelineLayout <- (#peek WGPUDeviceExtras, maxDynamicStorageBuffersPerPipelineLayout) ptr
+    maxStorageBuffersPerShaderStage <- (#peek WGPUDeviceExtras, maxStorageBuffersPerShaderStage) ptr
+    maxStorageBufferBindingSize <- (#peek WGPUDeviceExtras, maxStorageBufferBindingSize) ptr
+    nativeFeatures <- (#peek WGPUDeviceExtras, nativeFeatures) ptr
+    label <- (#peek WGPUDeviceExtras, label) ptr
+    tracePath <- (#peek WGPUDeviceExtras, tracePath) ptr
+    pure $! WGPUDeviceExtras{..}
+  poke ptr WGPUDeviceExtras{..} = do
+    (#poke WGPUDeviceExtras, chain) ptr chain
+    (#poke WGPUDeviceExtras, maxTextureDimension1D) ptr maxTextureDimension1D
+    (#poke WGPUDeviceExtras, maxTextureDimension2D) ptr maxTextureDimension2D
+    (#poke WGPUDeviceExtras, maxTextureDimension3D) ptr maxTextureDimension3D
+    (#poke WGPUDeviceExtras, maxTextureArrayLayers) ptr maxTextureArrayLayers
+    (#poke WGPUDeviceExtras, maxBindGroups) ptr maxBindGroups
+    (#poke WGPUDeviceExtras, maxDynamicStorageBuffersPerPipelineLayout) ptr maxDynamicStorageBuffersPerPipelineLayout
+    (#poke WGPUDeviceExtras, maxStorageBuffersPerShaderStage) ptr maxStorageBuffersPerShaderStage
+    (#poke WGPUDeviceExtras, maxStorageBufferBindingSize) ptr maxStorageBufferBindingSize
+    (#poke WGPUDeviceExtras, nativeFeatures) ptr nativeFeatures
+    (#poke WGPUDeviceExtras, label) ptr label
+    (#poke WGPUDeviceExtras, tracePath) ptr tracePath
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUExtent3D.hsc b/src/WGPU/Raw/Generated/Struct/WGPUExtent3D.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUExtent3D.hsc
@@ -0,0 +1,39 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUExtent3D where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+
+
+data WGPUExtent3D = WGPUExtent3D {
+  width :: Word32,
+  height :: Word32,
+  depthOrArrayLayers :: Word32
+}
+
+instance Storable WGPUExtent3D where
+  sizeOf _ = (#size WGPUExtent3D)
+  alignment = sizeOf
+  peek ptr = do
+    width <- (#peek WGPUExtent3D, width) ptr
+    height <- (#peek WGPUExtent3D, height) ptr
+    depthOrArrayLayers <- (#peek WGPUExtent3D, depthOrArrayLayers) ptr
+    pure $! WGPUExtent3D{..}
+  poke ptr WGPUExtent3D{..} = do
+    (#poke WGPUExtent3D, width) ptr width
+    (#poke WGPUExtent3D, height) ptr height
+    (#poke WGPUExtent3D, depthOrArrayLayers) ptr depthOrArrayLayers
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUFragmentState.hsc b/src/WGPU/Raw/Generated/Struct/WGPUFragmentState.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUFragmentState.hsc
@@ -0,0 +1,46 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUFragmentState where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUColorTargetState
+
+data WGPUFragmentState = WGPUFragmentState {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  shaderModule :: WGPUShaderModule,
+  entryPoint :: Ptr (CChar),
+  targetCount :: Word32,
+  targets :: Ptr (WGPUColorTargetState)
+}
+
+instance Storable WGPUFragmentState where
+  sizeOf _ = (#size WGPUFragmentState)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUFragmentState, nextInChain) ptr
+    shaderModule <- (#peek WGPUFragmentState, module) ptr
+    entryPoint <- (#peek WGPUFragmentState, entryPoint) ptr
+    targetCount <- (#peek WGPUFragmentState, targetCount) ptr
+    targets <- (#peek WGPUFragmentState, targets) ptr
+    pure $! WGPUFragmentState{..}
+  poke ptr WGPUFragmentState{..} = do
+    (#poke WGPUFragmentState, nextInChain) ptr nextInChain
+    (#poke WGPUFragmentState, module) ptr shaderModule
+    (#poke WGPUFragmentState, entryPoint) ptr entryPoint
+    (#poke WGPUFragmentState, targetCount) ptr targetCount
+    (#poke WGPUFragmentState, targets) ptr targets
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUImageCopyBuffer.hsc b/src/WGPU/Raw/Generated/Struct/WGPUImageCopyBuffer.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUImageCopyBuffer.hsc
@@ -0,0 +1,40 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUImageCopyBuffer where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUTextureDataLayout
+
+data WGPUImageCopyBuffer = WGPUImageCopyBuffer {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  layout :: WGPUTextureDataLayout,
+  buffer :: WGPUBuffer
+}
+
+instance Storable WGPUImageCopyBuffer where
+  sizeOf _ = (#size WGPUImageCopyBuffer)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUImageCopyBuffer, nextInChain) ptr
+    layout <- (#peek WGPUImageCopyBuffer, layout) ptr
+    buffer <- (#peek WGPUImageCopyBuffer, buffer) ptr
+    pure $! WGPUImageCopyBuffer{..}
+  poke ptr WGPUImageCopyBuffer{..} = do
+    (#poke WGPUImageCopyBuffer, nextInChain) ptr nextInChain
+    (#poke WGPUImageCopyBuffer, layout) ptr layout
+    (#poke WGPUImageCopyBuffer, buffer) ptr buffer
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUImageCopyTexture.hsc b/src/WGPU/Raw/Generated/Struct/WGPUImageCopyTexture.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUImageCopyTexture.hsc
@@ -0,0 +1,47 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUImageCopyTexture where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUTextureAspect
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUOrigin3D
+
+data WGPUImageCopyTexture = WGPUImageCopyTexture {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  texture :: WGPUTexture,
+  mipLevel :: Word32,
+  origin :: WGPUOrigin3D,
+  aspect :: WGPUTextureAspect
+}
+
+instance Storable WGPUImageCopyTexture where
+  sizeOf _ = (#size WGPUImageCopyTexture)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUImageCopyTexture, nextInChain) ptr
+    texture <- (#peek WGPUImageCopyTexture, texture) ptr
+    mipLevel <- (#peek WGPUImageCopyTexture, mipLevel) ptr
+    origin <- (#peek WGPUImageCopyTexture, origin) ptr
+    aspect <- (#peek WGPUImageCopyTexture, aspect) ptr
+    pure $! WGPUImageCopyTexture{..}
+  poke ptr WGPUImageCopyTexture{..} = do
+    (#poke WGPUImageCopyTexture, nextInChain) ptr nextInChain
+    (#poke WGPUImageCopyTexture, texture) ptr texture
+    (#poke WGPUImageCopyTexture, mipLevel) ptr mipLevel
+    (#poke WGPUImageCopyTexture, origin) ptr origin
+    (#poke WGPUImageCopyTexture, aspect) ptr aspect
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUInstanceDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUInstanceDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUInstanceDescriptor.hsc
@@ -0,0 +1,33 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUInstanceDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUInstanceDescriptor = WGPUInstanceDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct)
+}
+
+instance Storable WGPUInstanceDescriptor where
+  sizeOf _ = (#size WGPUInstanceDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUInstanceDescriptor, nextInChain) ptr
+    pure $! WGPUInstanceDescriptor{..}
+  poke ptr WGPUInstanceDescriptor{..} = do
+    (#poke WGPUInstanceDescriptor, nextInChain) ptr nextInChain
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUMultisampleState.hsc b/src/WGPU/Raw/Generated/Struct/WGPUMultisampleState.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUMultisampleState.hsc
@@ -0,0 +1,42 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUMultisampleState where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUMultisampleState = WGPUMultisampleState {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  count :: Word32,
+  mask :: Word32,
+  alphaToCoverageEnabled :: CBool
+}
+
+instance Storable WGPUMultisampleState where
+  sizeOf _ = (#size WGPUMultisampleState)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUMultisampleState, nextInChain) ptr
+    count <- (#peek WGPUMultisampleState, count) ptr
+    mask <- (#peek WGPUMultisampleState, mask) ptr
+    alphaToCoverageEnabled <- (#peek WGPUMultisampleState, alphaToCoverageEnabled) ptr
+    pure $! WGPUMultisampleState{..}
+  poke ptr WGPUMultisampleState{..} = do
+    (#poke WGPUMultisampleState, nextInChain) ptr nextInChain
+    (#poke WGPUMultisampleState, count) ptr count
+    (#poke WGPUMultisampleState, mask) ptr mask
+    (#poke WGPUMultisampleState, alphaToCoverageEnabled) ptr alphaToCoverageEnabled
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUOrigin3D.hsc b/src/WGPU/Raw/Generated/Struct/WGPUOrigin3D.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUOrigin3D.hsc
@@ -0,0 +1,39 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUOrigin3D where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+
+
+data WGPUOrigin3D = WGPUOrigin3D {
+  x :: Word32,
+  y :: Word32,
+  z :: Word32
+}
+
+instance Storable WGPUOrigin3D where
+  sizeOf _ = (#size WGPUOrigin3D)
+  alignment = sizeOf
+  peek ptr = do
+    x <- (#peek WGPUOrigin3D, x) ptr
+    y <- (#peek WGPUOrigin3D, y) ptr
+    z <- (#peek WGPUOrigin3D, z) ptr
+    pure $! WGPUOrigin3D{..}
+  poke ptr WGPUOrigin3D{..} = do
+    (#poke WGPUOrigin3D, x) ptr x
+    (#poke WGPUOrigin3D, y) ptr y
+    (#poke WGPUOrigin3D, z) ptr z
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUPipelineLayoutDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUPipelineLayoutDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUPipelineLayoutDescriptor.hsc
@@ -0,0 +1,42 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUPipelineLayoutDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUPipelineLayoutDescriptor = WGPUPipelineLayoutDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar),
+  bindGroupLayoutCount :: Word32,
+  bindGroupLayouts :: Ptr (WGPUBindGroupLayout)
+}
+
+instance Storable WGPUPipelineLayoutDescriptor where
+  sizeOf _ = (#size WGPUPipelineLayoutDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUPipelineLayoutDescriptor, nextInChain) ptr
+    label <- (#peek WGPUPipelineLayoutDescriptor, label) ptr
+    bindGroupLayoutCount <- (#peek WGPUPipelineLayoutDescriptor, bindGroupLayoutCount) ptr
+    bindGroupLayouts <- (#peek WGPUPipelineLayoutDescriptor, bindGroupLayouts) ptr
+    pure $! WGPUPipelineLayoutDescriptor{..}
+  poke ptr WGPUPipelineLayoutDescriptor{..} = do
+    (#poke WGPUPipelineLayoutDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUPipelineLayoutDescriptor, label) ptr label
+    (#poke WGPUPipelineLayoutDescriptor, bindGroupLayoutCount) ptr bindGroupLayoutCount
+    (#poke WGPUPipelineLayoutDescriptor, bindGroupLayouts) ptr bindGroupLayouts
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUPrimitiveDepthClampingState.hsc b/src/WGPU/Raw/Generated/Struct/WGPUPrimitiveDepthClampingState.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUPrimitiveDepthClampingState.hsc
@@ -0,0 +1,36 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUPrimitiveDepthClampingState where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUPrimitiveDepthClampingState = WGPUPrimitiveDepthClampingState {
+  chain :: WGPUChainedStruct,
+  clampDepth :: CBool
+}
+
+instance Storable WGPUPrimitiveDepthClampingState where
+  sizeOf _ = (#size WGPUPrimitiveDepthClampingState)
+  alignment = sizeOf
+  peek ptr = do
+    chain <- (#peek WGPUPrimitiveDepthClampingState, chain) ptr
+    clampDepth <- (#peek WGPUPrimitiveDepthClampingState, clampDepth) ptr
+    pure $! WGPUPrimitiveDepthClampingState{..}
+  poke ptr WGPUPrimitiveDepthClampingState{..} = do
+    (#poke WGPUPrimitiveDepthClampingState, chain) ptr chain
+    (#poke WGPUPrimitiveDepthClampingState, clampDepth) ptr clampDepth
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUPrimitiveState.hsc b/src/WGPU/Raw/Generated/Struct/WGPUPrimitiveState.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUPrimitiveState.hsc
@@ -0,0 +1,49 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUPrimitiveState where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUPrimitiveTopology
+import WGPU.Raw.Generated.Enum.WGPUIndexFormat
+import WGPU.Raw.Generated.Enum.WGPUFrontFace
+import WGPU.Raw.Generated.Enum.WGPUCullMode
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUPrimitiveState = WGPUPrimitiveState {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  topology :: WGPUPrimitiveTopology,
+  stripIndexFormat :: WGPUIndexFormat,
+  frontFace :: WGPUFrontFace,
+  cullMode :: WGPUCullMode
+}
+
+instance Storable WGPUPrimitiveState where
+  sizeOf _ = (#size WGPUPrimitiveState)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUPrimitiveState, nextInChain) ptr
+    topology <- (#peek WGPUPrimitiveState, topology) ptr
+    stripIndexFormat <- (#peek WGPUPrimitiveState, stripIndexFormat) ptr
+    frontFace <- (#peek WGPUPrimitiveState, frontFace) ptr
+    cullMode <- (#peek WGPUPrimitiveState, cullMode) ptr
+    pure $! WGPUPrimitiveState{..}
+  poke ptr WGPUPrimitiveState{..} = do
+    (#poke WGPUPrimitiveState, nextInChain) ptr nextInChain
+    (#poke WGPUPrimitiveState, topology) ptr topology
+    (#poke WGPUPrimitiveState, stripIndexFormat) ptr stripIndexFormat
+    (#poke WGPUPrimitiveState, frontFace) ptr frontFace
+    (#poke WGPUPrimitiveState, cullMode) ptr cullMode
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUProgrammableStageDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUProgrammableStageDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUProgrammableStageDescriptor.hsc
@@ -0,0 +1,39 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUProgrammableStageDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUProgrammableStageDescriptor = WGPUProgrammableStageDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  shaderModule :: WGPUShaderModule,
+  entryPoint :: Ptr (CChar)
+}
+
+instance Storable WGPUProgrammableStageDescriptor where
+  sizeOf _ = (#size WGPUProgrammableStageDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUProgrammableStageDescriptor, nextInChain) ptr
+    shaderModule <- (#peek WGPUProgrammableStageDescriptor, module) ptr
+    entryPoint <- (#peek WGPUProgrammableStageDescriptor, entryPoint) ptr
+    pure $! WGPUProgrammableStageDescriptor{..}
+  poke ptr WGPUProgrammableStageDescriptor{..} = do
+    (#poke WGPUProgrammableStageDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUProgrammableStageDescriptor, module) ptr shaderModule
+    (#poke WGPUProgrammableStageDescriptor, entryPoint) ptr entryPoint
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUQuerySetDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUQuerySetDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUQuerySetDescriptor.hsc
@@ -0,0 +1,50 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUQuerySetDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUQueryType
+import WGPU.Raw.Generated.Enum.WGPUPipelineStatisticName
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUQuerySetDescriptor = WGPUQuerySetDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar),
+  typ :: WGPUQueryType,
+  count :: Word32,
+  pipelineStatistics :: Ptr (WGPUPipelineStatisticName),
+  pipelineStatisticsCount :: Word32
+}
+
+instance Storable WGPUQuerySetDescriptor where
+  sizeOf _ = (#size WGPUQuerySetDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUQuerySetDescriptor, nextInChain) ptr
+    label <- (#peek WGPUQuerySetDescriptor, label) ptr
+    typ <- (#peek WGPUQuerySetDescriptor, type) ptr
+    count <- (#peek WGPUQuerySetDescriptor, count) ptr
+    pipelineStatistics <- (#peek WGPUQuerySetDescriptor, pipelineStatistics) ptr
+    pipelineStatisticsCount <- (#peek WGPUQuerySetDescriptor, pipelineStatisticsCount) ptr
+    pure $! WGPUQuerySetDescriptor{..}
+  poke ptr WGPUQuerySetDescriptor{..} = do
+    (#poke WGPUQuerySetDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUQuerySetDescriptor, label) ptr label
+    (#poke WGPUQuerySetDescriptor, type) ptr typ
+    (#poke WGPUQuerySetDescriptor, count) ptr count
+    (#poke WGPUQuerySetDescriptor, pipelineStatistics) ptr pipelineStatistics
+    (#poke WGPUQuerySetDescriptor, pipelineStatisticsCount) ptr pipelineStatisticsCount
diff --git a/src/WGPU/Raw/Generated/Struct/WGPURenderBundleDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPURenderBundleDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPURenderBundleDescriptor.hsc
@@ -0,0 +1,36 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPURenderBundleDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPURenderBundleDescriptor = WGPURenderBundleDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar)
+}
+
+instance Storable WGPURenderBundleDescriptor where
+  sizeOf _ = (#size WGPURenderBundleDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPURenderBundleDescriptor, nextInChain) ptr
+    label <- (#peek WGPURenderBundleDescriptor, label) ptr
+    pure $! WGPURenderBundleDescriptor{..}
+  poke ptr WGPURenderBundleDescriptor{..} = do
+    (#poke WGPURenderBundleDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPURenderBundleDescriptor, label) ptr label
diff --git a/src/WGPU/Raw/Generated/Struct/WGPURenderBundleEncoderDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPURenderBundleEncoderDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPURenderBundleEncoderDescriptor.hsc
@@ -0,0 +1,50 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPURenderBundleEncoderDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUTextureFormat
+import WGPU.Raw.Generated.Enum.WGPUTextureFormat
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPURenderBundleEncoderDescriptor = WGPURenderBundleEncoderDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar),
+  colorFormatsCount :: Word32,
+  colorFormats :: Ptr (WGPUTextureFormat),
+  depthStencilFormat :: WGPUTextureFormat,
+  sampleCount :: Word32
+}
+
+instance Storable WGPURenderBundleEncoderDescriptor where
+  sizeOf _ = (#size WGPURenderBundleEncoderDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPURenderBundleEncoderDescriptor, nextInChain) ptr
+    label <- (#peek WGPURenderBundleEncoderDescriptor, label) ptr
+    colorFormatsCount <- (#peek WGPURenderBundleEncoderDescriptor, colorFormatsCount) ptr
+    colorFormats <- (#peek WGPURenderBundleEncoderDescriptor, colorFormats) ptr
+    depthStencilFormat <- (#peek WGPURenderBundleEncoderDescriptor, depthStencilFormat) ptr
+    sampleCount <- (#peek WGPURenderBundleEncoderDescriptor, sampleCount) ptr
+    pure $! WGPURenderBundleEncoderDescriptor{..}
+  poke ptr WGPURenderBundleEncoderDescriptor{..} = do
+    (#poke WGPURenderBundleEncoderDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPURenderBundleEncoderDescriptor, label) ptr label
+    (#poke WGPURenderBundleEncoderDescriptor, colorFormatsCount) ptr colorFormatsCount
+    (#poke WGPURenderBundleEncoderDescriptor, colorFormats) ptr colorFormats
+    (#poke WGPURenderBundleEncoderDescriptor, depthStencilFormat) ptr depthStencilFormat
+    (#poke WGPURenderBundleEncoderDescriptor, sampleCount) ptr sampleCount
diff --git a/src/WGPU/Raw/Generated/Struct/WGPURenderPassColorAttachment.hsc b/src/WGPU/Raw/Generated/Struct/WGPURenderPassColorAttachment.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPURenderPassColorAttachment.hsc
@@ -0,0 +1,47 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPURenderPassColorAttachment where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPULoadOp
+import WGPU.Raw.Generated.Enum.WGPUStoreOp
+import WGPU.Raw.Generated.Struct.WGPUColor
+
+data WGPURenderPassColorAttachment = WGPURenderPassColorAttachment {
+  view :: WGPUTextureView,
+  resolveTarget :: WGPUTextureView,
+  loadOp :: WGPULoadOp,
+  storeOp :: WGPUStoreOp,
+  clearColor :: WGPUColor
+}
+
+instance Storable WGPURenderPassColorAttachment where
+  sizeOf _ = (#size WGPURenderPassColorAttachment)
+  alignment = sizeOf
+  peek ptr = do
+    view <- (#peek WGPURenderPassColorAttachment, view) ptr
+    resolveTarget <- (#peek WGPURenderPassColorAttachment, resolveTarget) ptr
+    loadOp <- (#peek WGPURenderPassColorAttachment, loadOp) ptr
+    storeOp <- (#peek WGPURenderPassColorAttachment, storeOp) ptr
+    clearColor <- (#peek WGPURenderPassColorAttachment, clearColor) ptr
+    pure $! WGPURenderPassColorAttachment{..}
+  poke ptr WGPURenderPassColorAttachment{..} = do
+    (#poke WGPURenderPassColorAttachment, view) ptr view
+    (#poke WGPURenderPassColorAttachment, resolveTarget) ptr resolveTarget
+    (#poke WGPURenderPassColorAttachment, loadOp) ptr loadOp
+    (#poke WGPURenderPassColorAttachment, storeOp) ptr storeOp
+    (#poke WGPURenderPassColorAttachment, clearColor) ptr clearColor
diff --git a/src/WGPU/Raw/Generated/Struct/WGPURenderPassDepthStencilAttachment.hsc b/src/WGPU/Raw/Generated/Struct/WGPURenderPassDepthStencilAttachment.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPURenderPassDepthStencilAttachment.hsc
@@ -0,0 +1,60 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPURenderPassDepthStencilAttachment where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPULoadOp
+import WGPU.Raw.Generated.Enum.WGPUStoreOp
+import WGPU.Raw.Generated.Enum.WGPULoadOp
+import WGPU.Raw.Generated.Enum.WGPUStoreOp
+
+data WGPURenderPassDepthStencilAttachment = WGPURenderPassDepthStencilAttachment {
+  view :: WGPUTextureView,
+  depthLoadOp :: WGPULoadOp,
+  depthStoreOp :: WGPUStoreOp,
+  clearDepth :: CFloat,
+  depthReadOnly :: CBool,
+  stencilLoadOp :: WGPULoadOp,
+  stencilStoreOp :: WGPUStoreOp,
+  clearStencil :: Word32,
+  stencilReadOnly :: CBool
+}
+
+instance Storable WGPURenderPassDepthStencilAttachment where
+  sizeOf _ = (#size WGPURenderPassDepthStencilAttachment)
+  alignment = sizeOf
+  peek ptr = do
+    view <- (#peek WGPURenderPassDepthStencilAttachment, view) ptr
+    depthLoadOp <- (#peek WGPURenderPassDepthStencilAttachment, depthLoadOp) ptr
+    depthStoreOp <- (#peek WGPURenderPassDepthStencilAttachment, depthStoreOp) ptr
+    clearDepth <- (#peek WGPURenderPassDepthStencilAttachment, clearDepth) ptr
+    depthReadOnly <- (#peek WGPURenderPassDepthStencilAttachment, depthReadOnly) ptr
+    stencilLoadOp <- (#peek WGPURenderPassDepthStencilAttachment, stencilLoadOp) ptr
+    stencilStoreOp <- (#peek WGPURenderPassDepthStencilAttachment, stencilStoreOp) ptr
+    clearStencil <- (#peek WGPURenderPassDepthStencilAttachment, clearStencil) ptr
+    stencilReadOnly <- (#peek WGPURenderPassDepthStencilAttachment, stencilReadOnly) ptr
+    pure $! WGPURenderPassDepthStencilAttachment{..}
+  poke ptr WGPURenderPassDepthStencilAttachment{..} = do
+    (#poke WGPURenderPassDepthStencilAttachment, view) ptr view
+    (#poke WGPURenderPassDepthStencilAttachment, depthLoadOp) ptr depthLoadOp
+    (#poke WGPURenderPassDepthStencilAttachment, depthStoreOp) ptr depthStoreOp
+    (#poke WGPURenderPassDepthStencilAttachment, clearDepth) ptr clearDepth
+    (#poke WGPURenderPassDepthStencilAttachment, depthReadOnly) ptr depthReadOnly
+    (#poke WGPURenderPassDepthStencilAttachment, stencilLoadOp) ptr stencilLoadOp
+    (#poke WGPURenderPassDepthStencilAttachment, stencilStoreOp) ptr stencilStoreOp
+    (#poke WGPURenderPassDepthStencilAttachment, clearStencil) ptr clearStencil
+    (#poke WGPURenderPassDepthStencilAttachment, stencilReadOnly) ptr stencilReadOnly
diff --git a/src/WGPU/Raw/Generated/Struct/WGPURenderPassDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPURenderPassDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPURenderPassDescriptor.hsc
@@ -0,0 +1,50 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPURenderPassDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPURenderPassColorAttachment
+import WGPU.Raw.Generated.Struct.WGPURenderPassDepthStencilAttachment
+
+data WGPURenderPassDescriptor = WGPURenderPassDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar),
+  colorAttachmentCount :: Word32,
+  colorAttachments :: Ptr (WGPURenderPassColorAttachment),
+  depthStencilAttachment :: Ptr (WGPURenderPassDepthStencilAttachment),
+  occlusionQuerySet :: WGPUQuerySet
+}
+
+instance Storable WGPURenderPassDescriptor where
+  sizeOf _ = (#size WGPURenderPassDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPURenderPassDescriptor, nextInChain) ptr
+    label <- (#peek WGPURenderPassDescriptor, label) ptr
+    colorAttachmentCount <- (#peek WGPURenderPassDescriptor, colorAttachmentCount) ptr
+    colorAttachments <- (#peek WGPURenderPassDescriptor, colorAttachments) ptr
+    depthStencilAttachment <- (#peek WGPURenderPassDescriptor, depthStencilAttachment) ptr
+    occlusionQuerySet <- (#peek WGPURenderPassDescriptor, occlusionQuerySet) ptr
+    pure $! WGPURenderPassDescriptor{..}
+  poke ptr WGPURenderPassDescriptor{..} = do
+    (#poke WGPURenderPassDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPURenderPassDescriptor, label) ptr label
+    (#poke WGPURenderPassDescriptor, colorAttachmentCount) ptr colorAttachmentCount
+    (#poke WGPURenderPassDescriptor, colorAttachments) ptr colorAttachments
+    (#poke WGPURenderPassDescriptor, depthStencilAttachment) ptr depthStencilAttachment
+    (#poke WGPURenderPassDescriptor, occlusionQuerySet) ptr occlusionQuerySet
diff --git a/src/WGPU/Raw/Generated/Struct/WGPURenderPipelineDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPURenderPipelineDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPURenderPipelineDescriptor.hsc
@@ -0,0 +1,59 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPURenderPipelineDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUVertexState
+import WGPU.Raw.Generated.Struct.WGPUPrimitiveState
+import WGPU.Raw.Generated.Struct.WGPUDepthStencilState
+import WGPU.Raw.Generated.Struct.WGPUMultisampleState
+import WGPU.Raw.Generated.Struct.WGPUFragmentState
+
+data WGPURenderPipelineDescriptor = WGPURenderPipelineDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar),
+  layout :: WGPUPipelineLayout,
+  vertex :: WGPUVertexState,
+  primitive :: WGPUPrimitiveState,
+  depthStencil :: Ptr (WGPUDepthStencilState),
+  multisample :: WGPUMultisampleState,
+  fragment :: Ptr (WGPUFragmentState)
+}
+
+instance Storable WGPURenderPipelineDescriptor where
+  sizeOf _ = (#size WGPURenderPipelineDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPURenderPipelineDescriptor, nextInChain) ptr
+    label <- (#peek WGPURenderPipelineDescriptor, label) ptr
+    layout <- (#peek WGPURenderPipelineDescriptor, layout) ptr
+    vertex <- (#peek WGPURenderPipelineDescriptor, vertex) ptr
+    primitive <- (#peek WGPURenderPipelineDescriptor, primitive) ptr
+    depthStencil <- (#peek WGPURenderPipelineDescriptor, depthStencil) ptr
+    multisample <- (#peek WGPURenderPipelineDescriptor, multisample) ptr
+    fragment <- (#peek WGPURenderPipelineDescriptor, fragment) ptr
+    pure $! WGPURenderPipelineDescriptor{..}
+  poke ptr WGPURenderPipelineDescriptor{..} = do
+    (#poke WGPURenderPipelineDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPURenderPipelineDescriptor, label) ptr label
+    (#poke WGPURenderPipelineDescriptor, layout) ptr layout
+    (#poke WGPURenderPipelineDescriptor, vertex) ptr vertex
+    (#poke WGPURenderPipelineDescriptor, primitive) ptr primitive
+    (#poke WGPURenderPipelineDescriptor, depthStencil) ptr depthStencil
+    (#poke WGPURenderPipelineDescriptor, multisample) ptr multisample
+    (#poke WGPURenderPipelineDescriptor, fragment) ptr fragment
diff --git a/src/WGPU/Raw/Generated/Struct/WGPURequestAdapterOptions.hsc b/src/WGPU/Raw/Generated/Struct/WGPURequestAdapterOptions.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPURequestAdapterOptions.hsc
@@ -0,0 +1,36 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPURequestAdapterOptions where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPURequestAdapterOptions = WGPURequestAdapterOptions {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  compatibleSurface :: WGPUSurface
+}
+
+instance Storable WGPURequestAdapterOptions where
+  sizeOf _ = (#size WGPURequestAdapterOptions)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPURequestAdapterOptions, nextInChain) ptr
+    compatibleSurface <- (#peek WGPURequestAdapterOptions, compatibleSurface) ptr
+    pure $! WGPURequestAdapterOptions{..}
+  poke ptr WGPURequestAdapterOptions{..} = do
+    (#poke WGPURequestAdapterOptions, nextInChain) ptr nextInChain
+    (#poke WGPURequestAdapterOptions, compatibleSurface) ptr compatibleSurface
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUSamplerBindingLayout.hsc b/src/WGPU/Raw/Generated/Struct/WGPUSamplerBindingLayout.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUSamplerBindingLayout.hsc
@@ -0,0 +1,37 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUSamplerBindingLayout where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUSamplerBindingType
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUSamplerBindingLayout = WGPUSamplerBindingLayout {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  typ :: WGPUSamplerBindingType
+}
+
+instance Storable WGPUSamplerBindingLayout where
+  sizeOf _ = (#size WGPUSamplerBindingLayout)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUSamplerBindingLayout, nextInChain) ptr
+    typ <- (#peek WGPUSamplerBindingLayout, type) ptr
+    pure $! WGPUSamplerBindingLayout{..}
+  poke ptr WGPUSamplerBindingLayout{..} = do
+    (#poke WGPUSamplerBindingLayout, nextInChain) ptr nextInChain
+    (#poke WGPUSamplerBindingLayout, type) ptr typ
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUSamplerDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUSamplerDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUSamplerDescriptor.hsc
@@ -0,0 +1,73 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUSamplerDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUAddressMode
+import WGPU.Raw.Generated.Enum.WGPUAddressMode
+import WGPU.Raw.Generated.Enum.WGPUAddressMode
+import WGPU.Raw.Generated.Enum.WGPUFilterMode
+import WGPU.Raw.Generated.Enum.WGPUFilterMode
+import WGPU.Raw.Generated.Enum.WGPUFilterMode
+import WGPU.Raw.Generated.Enum.WGPUCompareFunction
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUSamplerDescriptor = WGPUSamplerDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar),
+  addressModeU :: WGPUAddressMode,
+  addressModeV :: WGPUAddressMode,
+  addressModeW :: WGPUAddressMode,
+  magFilter :: WGPUFilterMode,
+  minFilter :: WGPUFilterMode,
+  mipmapFilter :: WGPUFilterMode,
+  lodMinClamp :: CFloat,
+  lodMaxClamp :: CFloat,
+  compare :: WGPUCompareFunction,
+  maxAnisotropy :: Word16
+}
+
+instance Storable WGPUSamplerDescriptor where
+  sizeOf _ = (#size WGPUSamplerDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUSamplerDescriptor, nextInChain) ptr
+    label <- (#peek WGPUSamplerDescriptor, label) ptr
+    addressModeU <- (#peek WGPUSamplerDescriptor, addressModeU) ptr
+    addressModeV <- (#peek WGPUSamplerDescriptor, addressModeV) ptr
+    addressModeW <- (#peek WGPUSamplerDescriptor, addressModeW) ptr
+    magFilter <- (#peek WGPUSamplerDescriptor, magFilter) ptr
+    minFilter <- (#peek WGPUSamplerDescriptor, minFilter) ptr
+    mipmapFilter <- (#peek WGPUSamplerDescriptor, mipmapFilter) ptr
+    lodMinClamp <- (#peek WGPUSamplerDescriptor, lodMinClamp) ptr
+    lodMaxClamp <- (#peek WGPUSamplerDescriptor, lodMaxClamp) ptr
+    compare <- (#peek WGPUSamplerDescriptor, compare) ptr
+    maxAnisotropy <- (#peek WGPUSamplerDescriptor, maxAnisotropy) ptr
+    pure $! WGPUSamplerDescriptor{..}
+  poke ptr WGPUSamplerDescriptor{..} = do
+    (#poke WGPUSamplerDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUSamplerDescriptor, label) ptr label
+    (#poke WGPUSamplerDescriptor, addressModeU) ptr addressModeU
+    (#poke WGPUSamplerDescriptor, addressModeV) ptr addressModeV
+    (#poke WGPUSamplerDescriptor, addressModeW) ptr addressModeW
+    (#poke WGPUSamplerDescriptor, magFilter) ptr magFilter
+    (#poke WGPUSamplerDescriptor, minFilter) ptr minFilter
+    (#poke WGPUSamplerDescriptor, mipmapFilter) ptr mipmapFilter
+    (#poke WGPUSamplerDescriptor, lodMinClamp) ptr lodMinClamp
+    (#poke WGPUSamplerDescriptor, lodMaxClamp) ptr lodMaxClamp
+    (#poke WGPUSamplerDescriptor, compare) ptr compare
+    (#poke WGPUSamplerDescriptor, maxAnisotropy) ptr maxAnisotropy
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUShaderModuleDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUShaderModuleDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUShaderModuleDescriptor.hsc
@@ -0,0 +1,36 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUShaderModuleDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUShaderModuleDescriptor = WGPUShaderModuleDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar)
+}
+
+instance Storable WGPUShaderModuleDescriptor where
+  sizeOf _ = (#size WGPUShaderModuleDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUShaderModuleDescriptor, nextInChain) ptr
+    label <- (#peek WGPUShaderModuleDescriptor, label) ptr
+    pure $! WGPUShaderModuleDescriptor{..}
+  poke ptr WGPUShaderModuleDescriptor{..} = do
+    (#poke WGPUShaderModuleDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUShaderModuleDescriptor, label) ptr label
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUShaderModuleSPIRVDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUShaderModuleSPIRVDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUShaderModuleSPIRVDescriptor.hsc
@@ -0,0 +1,39 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUShaderModuleSPIRVDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUShaderModuleSPIRVDescriptor = WGPUShaderModuleSPIRVDescriptor {
+  chain :: WGPUChainedStruct,
+  codeSize :: Word32,
+  code :: Ptr (Word32)
+}
+
+instance Storable WGPUShaderModuleSPIRVDescriptor where
+  sizeOf _ = (#size WGPUShaderModuleSPIRVDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    chain <- (#peek WGPUShaderModuleSPIRVDescriptor, chain) ptr
+    codeSize <- (#peek WGPUShaderModuleSPIRVDescriptor, codeSize) ptr
+    code <- (#peek WGPUShaderModuleSPIRVDescriptor, code) ptr
+    pure $! WGPUShaderModuleSPIRVDescriptor{..}
+  poke ptr WGPUShaderModuleSPIRVDescriptor{..} = do
+    (#poke WGPUShaderModuleSPIRVDescriptor, chain) ptr chain
+    (#poke WGPUShaderModuleSPIRVDescriptor, codeSize) ptr codeSize
+    (#poke WGPUShaderModuleSPIRVDescriptor, code) ptr code
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUShaderModuleWGSLDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUShaderModuleWGSLDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUShaderModuleWGSLDescriptor.hsc
@@ -0,0 +1,36 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUShaderModuleWGSLDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUShaderModuleWGSLDescriptor = WGPUShaderModuleWGSLDescriptor {
+  chain :: WGPUChainedStruct,
+  source :: Ptr (CChar)
+}
+
+instance Storable WGPUShaderModuleWGSLDescriptor where
+  sizeOf _ = (#size WGPUShaderModuleWGSLDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    chain <- (#peek WGPUShaderModuleWGSLDescriptor, chain) ptr
+    source <- (#peek WGPUShaderModuleWGSLDescriptor, source) ptr
+    pure $! WGPUShaderModuleWGSLDescriptor{..}
+  poke ptr WGPUShaderModuleWGSLDescriptor{..} = do
+    (#poke WGPUShaderModuleWGSLDescriptor, chain) ptr chain
+    (#poke WGPUShaderModuleWGSLDescriptor, source) ptr source
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUStencilFaceState.hsc b/src/WGPU/Raw/Generated/Struct/WGPUStencilFaceState.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUStencilFaceState.hsc
@@ -0,0 +1,45 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUStencilFaceState where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUCompareFunction
+import WGPU.Raw.Generated.Enum.WGPUStencilOperation
+import WGPU.Raw.Generated.Enum.WGPUStencilOperation
+import WGPU.Raw.Generated.Enum.WGPUStencilOperation
+
+data WGPUStencilFaceState = WGPUStencilFaceState {
+  compare :: WGPUCompareFunction,
+  failOp :: WGPUStencilOperation,
+  depthFailOp :: WGPUStencilOperation,
+  passOp :: WGPUStencilOperation
+}
+
+instance Storable WGPUStencilFaceState where
+  sizeOf _ = (#size WGPUStencilFaceState)
+  alignment = sizeOf
+  peek ptr = do
+    compare <- (#peek WGPUStencilFaceState, compare) ptr
+    failOp <- (#peek WGPUStencilFaceState, failOp) ptr
+    depthFailOp <- (#peek WGPUStencilFaceState, depthFailOp) ptr
+    passOp <- (#peek WGPUStencilFaceState, passOp) ptr
+    pure $! WGPUStencilFaceState{..}
+  poke ptr WGPUStencilFaceState{..} = do
+    (#poke WGPUStencilFaceState, compare) ptr compare
+    (#poke WGPUStencilFaceState, failOp) ptr failOp
+    (#poke WGPUStencilFaceState, depthFailOp) ptr depthFailOp
+    (#poke WGPUStencilFaceState, passOp) ptr passOp
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUStorageTextureBindingLayout.hsc b/src/WGPU/Raw/Generated/Struct/WGPUStorageTextureBindingLayout.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUStorageTextureBindingLayout.hsc
@@ -0,0 +1,45 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUStorageTextureBindingLayout where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUStorageTextureAccess
+import WGPU.Raw.Generated.Enum.WGPUTextureFormat
+import WGPU.Raw.Generated.Enum.WGPUTextureViewDimension
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUStorageTextureBindingLayout = WGPUStorageTextureBindingLayout {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  access :: WGPUStorageTextureAccess,
+  format :: WGPUTextureFormat,
+  viewDimension :: WGPUTextureViewDimension
+}
+
+instance Storable WGPUStorageTextureBindingLayout where
+  sizeOf _ = (#size WGPUStorageTextureBindingLayout)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUStorageTextureBindingLayout, nextInChain) ptr
+    access <- (#peek WGPUStorageTextureBindingLayout, access) ptr
+    format <- (#peek WGPUStorageTextureBindingLayout, format) ptr
+    viewDimension <- (#peek WGPUStorageTextureBindingLayout, viewDimension) ptr
+    pure $! WGPUStorageTextureBindingLayout{..}
+  poke ptr WGPUStorageTextureBindingLayout{..} = do
+    (#poke WGPUStorageTextureBindingLayout, nextInChain) ptr nextInChain
+    (#poke WGPUStorageTextureBindingLayout, access) ptr access
+    (#poke WGPUStorageTextureBindingLayout, format) ptr format
+    (#poke WGPUStorageTextureBindingLayout, viewDimension) ptr viewDimension
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptor.hsc
@@ -0,0 +1,36 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUSurfaceDescriptor = WGPUSurfaceDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar)
+}
+
+instance Storable WGPUSurfaceDescriptor where
+  sizeOf _ = (#size WGPUSurfaceDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUSurfaceDescriptor, nextInChain) ptr
+    label <- (#peek WGPUSurfaceDescriptor, label) ptr
+    pure $! WGPUSurfaceDescriptor{..}
+  poke ptr WGPUSurfaceDescriptor{..} = do
+    (#poke WGPUSurfaceDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUSurfaceDescriptor, label) ptr label
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptorFromCanvasHTMLSelector.hsc b/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptorFromCanvasHTMLSelector.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptorFromCanvasHTMLSelector.hsc
@@ -0,0 +1,36 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptorFromCanvasHTMLSelector where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUSurfaceDescriptorFromCanvasHTMLSelector = WGPUSurfaceDescriptorFromCanvasHTMLSelector {
+  chain :: WGPUChainedStruct,
+  selector :: Ptr (CChar)
+}
+
+instance Storable WGPUSurfaceDescriptorFromCanvasHTMLSelector where
+  sizeOf _ = (#size WGPUSurfaceDescriptorFromCanvasHTMLSelector)
+  alignment = sizeOf
+  peek ptr = do
+    chain <- (#peek WGPUSurfaceDescriptorFromCanvasHTMLSelector, chain) ptr
+    selector <- (#peek WGPUSurfaceDescriptorFromCanvasHTMLSelector, selector) ptr
+    pure $! WGPUSurfaceDescriptorFromCanvasHTMLSelector{..}
+  poke ptr WGPUSurfaceDescriptorFromCanvasHTMLSelector{..} = do
+    (#poke WGPUSurfaceDescriptorFromCanvasHTMLSelector, chain) ptr chain
+    (#poke WGPUSurfaceDescriptorFromCanvasHTMLSelector, selector) ptr selector
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptorFromMetalLayer.hsc b/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptorFromMetalLayer.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptorFromMetalLayer.hsc
@@ -0,0 +1,36 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptorFromMetalLayer where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUSurfaceDescriptorFromMetalLayer = WGPUSurfaceDescriptorFromMetalLayer {
+  chain :: WGPUChainedStruct,
+  layer :: Ptr (())
+}
+
+instance Storable WGPUSurfaceDescriptorFromMetalLayer where
+  sizeOf _ = (#size WGPUSurfaceDescriptorFromMetalLayer)
+  alignment = sizeOf
+  peek ptr = do
+    chain <- (#peek WGPUSurfaceDescriptorFromMetalLayer, chain) ptr
+    layer <- (#peek WGPUSurfaceDescriptorFromMetalLayer, layer) ptr
+    pure $! WGPUSurfaceDescriptorFromMetalLayer{..}
+  poke ptr WGPUSurfaceDescriptorFromMetalLayer{..} = do
+    (#poke WGPUSurfaceDescriptorFromMetalLayer, chain) ptr chain
+    (#poke WGPUSurfaceDescriptorFromMetalLayer, layer) ptr layer
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptorFromWindowsHWND.hsc b/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptorFromWindowsHWND.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptorFromWindowsHWND.hsc
@@ -0,0 +1,39 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptorFromWindowsHWND where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUSurfaceDescriptorFromWindowsHWND = WGPUSurfaceDescriptorFromWindowsHWND {
+  chain :: WGPUChainedStruct,
+  hinstance :: Ptr (()),
+  hwnd :: Ptr (())
+}
+
+instance Storable WGPUSurfaceDescriptorFromWindowsHWND where
+  sizeOf _ = (#size WGPUSurfaceDescriptorFromWindowsHWND)
+  alignment = sizeOf
+  peek ptr = do
+    chain <- (#peek WGPUSurfaceDescriptorFromWindowsHWND, chain) ptr
+    hinstance <- (#peek WGPUSurfaceDescriptorFromWindowsHWND, hinstance) ptr
+    hwnd <- (#peek WGPUSurfaceDescriptorFromWindowsHWND, hwnd) ptr
+    pure $! WGPUSurfaceDescriptorFromWindowsHWND{..}
+  poke ptr WGPUSurfaceDescriptorFromWindowsHWND{..} = do
+    (#poke WGPUSurfaceDescriptorFromWindowsHWND, chain) ptr chain
+    (#poke WGPUSurfaceDescriptorFromWindowsHWND, hinstance) ptr hinstance
+    (#poke WGPUSurfaceDescriptorFromWindowsHWND, hwnd) ptr hwnd
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptorFromXlib.hsc b/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptorFromXlib.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUSurfaceDescriptorFromXlib.hsc
@@ -0,0 +1,39 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptorFromXlib where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUSurfaceDescriptorFromXlib = WGPUSurfaceDescriptorFromXlib {
+  chain :: WGPUChainedStruct,
+  display :: Ptr (()),
+  window :: Word32
+}
+
+instance Storable WGPUSurfaceDescriptorFromXlib where
+  sizeOf _ = (#size WGPUSurfaceDescriptorFromXlib)
+  alignment = sizeOf
+  peek ptr = do
+    chain <- (#peek WGPUSurfaceDescriptorFromXlib, chain) ptr
+    display <- (#peek WGPUSurfaceDescriptorFromXlib, display) ptr
+    window <- (#peek WGPUSurfaceDescriptorFromXlib, window) ptr
+    pure $! WGPUSurfaceDescriptorFromXlib{..}
+  poke ptr WGPUSurfaceDescriptorFromXlib{..} = do
+    (#poke WGPUSurfaceDescriptorFromXlib, chain) ptr chain
+    (#poke WGPUSurfaceDescriptorFromXlib, display) ptr display
+    (#poke WGPUSurfaceDescriptorFromXlib, window) ptr window
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUSwapChainDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUSwapChainDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUSwapChainDescriptor.hsc
@@ -0,0 +1,53 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUSwapChainDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUTextureFormat
+import WGPU.Raw.Generated.Enum.WGPUPresentMode
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUSwapChainDescriptor = WGPUSwapChainDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar),
+  usage :: WGPUTextureUsageFlags,
+  format :: WGPUTextureFormat,
+  width :: Word32,
+  height :: Word32,
+  presentMode :: WGPUPresentMode
+}
+
+instance Storable WGPUSwapChainDescriptor where
+  sizeOf _ = (#size WGPUSwapChainDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUSwapChainDescriptor, nextInChain) ptr
+    label <- (#peek WGPUSwapChainDescriptor, label) ptr
+    usage <- (#peek WGPUSwapChainDescriptor, usage) ptr
+    format <- (#peek WGPUSwapChainDescriptor, format) ptr
+    width <- (#peek WGPUSwapChainDescriptor, width) ptr
+    height <- (#peek WGPUSwapChainDescriptor, height) ptr
+    presentMode <- (#peek WGPUSwapChainDescriptor, presentMode) ptr
+    pure $! WGPUSwapChainDescriptor{..}
+  poke ptr WGPUSwapChainDescriptor{..} = do
+    (#poke WGPUSwapChainDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUSwapChainDescriptor, label) ptr label
+    (#poke WGPUSwapChainDescriptor, usage) ptr usage
+    (#poke WGPUSwapChainDescriptor, format) ptr format
+    (#poke WGPUSwapChainDescriptor, width) ptr width
+    (#poke WGPUSwapChainDescriptor, height) ptr height
+    (#poke WGPUSwapChainDescriptor, presentMode) ptr presentMode
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUTextureBindingLayout.hsc b/src/WGPU/Raw/Generated/Struct/WGPUTextureBindingLayout.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUTextureBindingLayout.hsc
@@ -0,0 +1,44 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUTextureBindingLayout where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUTextureSampleType
+import WGPU.Raw.Generated.Enum.WGPUTextureViewDimension
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUTextureBindingLayout = WGPUTextureBindingLayout {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  sampleType :: WGPUTextureSampleType,
+  viewDimension :: WGPUTextureViewDimension,
+  multisampled :: CBool
+}
+
+instance Storable WGPUTextureBindingLayout where
+  sizeOf _ = (#size WGPUTextureBindingLayout)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUTextureBindingLayout, nextInChain) ptr
+    sampleType <- (#peek WGPUTextureBindingLayout, sampleType) ptr
+    viewDimension <- (#peek WGPUTextureBindingLayout, viewDimension) ptr
+    multisampled <- (#peek WGPUTextureBindingLayout, multisampled) ptr
+    pure $! WGPUTextureBindingLayout{..}
+  poke ptr WGPUTextureBindingLayout{..} = do
+    (#poke WGPUTextureBindingLayout, nextInChain) ptr nextInChain
+    (#poke WGPUTextureBindingLayout, sampleType) ptr sampleType
+    (#poke WGPUTextureBindingLayout, viewDimension) ptr viewDimension
+    (#poke WGPUTextureBindingLayout, multisampled) ptr multisampled
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUTextureDataLayout.hsc b/src/WGPU/Raw/Generated/Struct/WGPUTextureDataLayout.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUTextureDataLayout.hsc
@@ -0,0 +1,42 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUTextureDataLayout where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUTextureDataLayout = WGPUTextureDataLayout {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  offset :: Word64,
+  bytesPerRow :: Word32,
+  rowsPerImage :: Word32
+}
+
+instance Storable WGPUTextureDataLayout where
+  sizeOf _ = (#size WGPUTextureDataLayout)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUTextureDataLayout, nextInChain) ptr
+    offset <- (#peek WGPUTextureDataLayout, offset) ptr
+    bytesPerRow <- (#peek WGPUTextureDataLayout, bytesPerRow) ptr
+    rowsPerImage <- (#peek WGPUTextureDataLayout, rowsPerImage) ptr
+    pure $! WGPUTextureDataLayout{..}
+  poke ptr WGPUTextureDataLayout{..} = do
+    (#poke WGPUTextureDataLayout, nextInChain) ptr nextInChain
+    (#poke WGPUTextureDataLayout, offset) ptr offset
+    (#poke WGPUTextureDataLayout, bytesPerRow) ptr bytesPerRow
+    (#poke WGPUTextureDataLayout, rowsPerImage) ptr rowsPerImage
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUTextureDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUTextureDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUTextureDescriptor.hsc
@@ -0,0 +1,57 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUTextureDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUTextureDimension
+import WGPU.Raw.Generated.Enum.WGPUTextureFormat
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUExtent3D
+
+data WGPUTextureDescriptor = WGPUTextureDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar),
+  usage :: WGPUTextureUsageFlags,
+  dimension :: WGPUTextureDimension,
+  size :: WGPUExtent3D,
+  format :: WGPUTextureFormat,
+  mipLevelCount :: Word32,
+  sampleCount :: Word32
+}
+
+instance Storable WGPUTextureDescriptor where
+  sizeOf _ = (#size WGPUTextureDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUTextureDescriptor, nextInChain) ptr
+    label <- (#peek WGPUTextureDescriptor, label) ptr
+    usage <- (#peek WGPUTextureDescriptor, usage) ptr
+    dimension <- (#peek WGPUTextureDescriptor, dimension) ptr
+    size <- (#peek WGPUTextureDescriptor, size) ptr
+    format <- (#peek WGPUTextureDescriptor, format) ptr
+    mipLevelCount <- (#peek WGPUTextureDescriptor, mipLevelCount) ptr
+    sampleCount <- (#peek WGPUTextureDescriptor, sampleCount) ptr
+    pure $! WGPUTextureDescriptor{..}
+  poke ptr WGPUTextureDescriptor{..} = do
+    (#poke WGPUTextureDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUTextureDescriptor, label) ptr label
+    (#poke WGPUTextureDescriptor, usage) ptr usage
+    (#poke WGPUTextureDescriptor, dimension) ptr dimension
+    (#poke WGPUTextureDescriptor, size) ptr size
+    (#poke WGPUTextureDescriptor, format) ptr format
+    (#poke WGPUTextureDescriptor, mipLevelCount) ptr mipLevelCount
+    (#poke WGPUTextureDescriptor, sampleCount) ptr sampleCount
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUTextureViewDescriptor.hsc b/src/WGPU/Raw/Generated/Struct/WGPUTextureViewDescriptor.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUTextureViewDescriptor.hsc
@@ -0,0 +1,60 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUTextureViewDescriptor where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUTextureFormat
+import WGPU.Raw.Generated.Enum.WGPUTextureViewDimension
+import WGPU.Raw.Generated.Enum.WGPUTextureAspect
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+
+data WGPUTextureViewDescriptor = WGPUTextureViewDescriptor {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  label :: Ptr (CChar),
+  format :: WGPUTextureFormat,
+  dimension :: WGPUTextureViewDimension,
+  baseMipLevel :: Word32,
+  mipLevelCount :: Word32,
+  baseArrayLayer :: Word32,
+  arrayLayerCount :: Word32,
+  aspect :: WGPUTextureAspect
+}
+
+instance Storable WGPUTextureViewDescriptor where
+  sizeOf _ = (#size WGPUTextureViewDescriptor)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUTextureViewDescriptor, nextInChain) ptr
+    label <- (#peek WGPUTextureViewDescriptor, label) ptr
+    format <- (#peek WGPUTextureViewDescriptor, format) ptr
+    dimension <- (#peek WGPUTextureViewDescriptor, dimension) ptr
+    baseMipLevel <- (#peek WGPUTextureViewDescriptor, baseMipLevel) ptr
+    mipLevelCount <- (#peek WGPUTextureViewDescriptor, mipLevelCount) ptr
+    baseArrayLayer <- (#peek WGPUTextureViewDescriptor, baseArrayLayer) ptr
+    arrayLayerCount <- (#peek WGPUTextureViewDescriptor, arrayLayerCount) ptr
+    aspect <- (#peek WGPUTextureViewDescriptor, aspect) ptr
+    pure $! WGPUTextureViewDescriptor{..}
+  poke ptr WGPUTextureViewDescriptor{..} = do
+    (#poke WGPUTextureViewDescriptor, nextInChain) ptr nextInChain
+    (#poke WGPUTextureViewDescriptor, label) ptr label
+    (#poke WGPUTextureViewDescriptor, format) ptr format
+    (#poke WGPUTextureViewDescriptor, dimension) ptr dimension
+    (#poke WGPUTextureViewDescriptor, baseMipLevel) ptr baseMipLevel
+    (#poke WGPUTextureViewDescriptor, mipLevelCount) ptr mipLevelCount
+    (#poke WGPUTextureViewDescriptor, baseArrayLayer) ptr baseArrayLayer
+    (#poke WGPUTextureViewDescriptor, arrayLayerCount) ptr arrayLayerCount
+    (#poke WGPUTextureViewDescriptor, aspect) ptr aspect
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUVertexAttribute.hsc b/src/WGPU/Raw/Generated/Struct/WGPUVertexAttribute.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUVertexAttribute.hsc
@@ -0,0 +1,39 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUVertexAttribute where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUVertexFormat
+
+data WGPUVertexAttribute = WGPUVertexAttribute {
+  format :: WGPUVertexFormat,
+  offset :: Word64,
+  shaderLocation :: Word32
+}
+
+instance Storable WGPUVertexAttribute where
+  sizeOf _ = (#size WGPUVertexAttribute)
+  alignment = sizeOf
+  peek ptr = do
+    format <- (#peek WGPUVertexAttribute, format) ptr
+    offset <- (#peek WGPUVertexAttribute, offset) ptr
+    shaderLocation <- (#peek WGPUVertexAttribute, shaderLocation) ptr
+    pure $! WGPUVertexAttribute{..}
+  poke ptr WGPUVertexAttribute{..} = do
+    (#poke WGPUVertexAttribute, format) ptr format
+    (#poke WGPUVertexAttribute, offset) ptr offset
+    (#poke WGPUVertexAttribute, shaderLocation) ptr shaderLocation
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUVertexBufferLayout.hsc b/src/WGPU/Raw/Generated/Struct/WGPUVertexBufferLayout.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUVertexBufferLayout.hsc
@@ -0,0 +1,43 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUVertexBufferLayout where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Enum.WGPUInputStepMode
+import WGPU.Raw.Generated.Struct.WGPUVertexAttribute
+
+data WGPUVertexBufferLayout = WGPUVertexBufferLayout {
+  arrayStride :: Word64,
+  stepMode :: WGPUInputStepMode,
+  attributeCount :: Word32,
+  attributes :: Ptr (WGPUVertexAttribute)
+}
+
+instance Storable WGPUVertexBufferLayout where
+  sizeOf _ = (#size WGPUVertexBufferLayout)
+  alignment = sizeOf
+  peek ptr = do
+    arrayStride <- (#peek WGPUVertexBufferLayout, arrayStride) ptr
+    stepMode <- (#peek WGPUVertexBufferLayout, stepMode) ptr
+    attributeCount <- (#peek WGPUVertexBufferLayout, attributeCount) ptr
+    attributes <- (#peek WGPUVertexBufferLayout, attributes) ptr
+    pure $! WGPUVertexBufferLayout{..}
+  poke ptr WGPUVertexBufferLayout{..} = do
+    (#poke WGPUVertexBufferLayout, arrayStride) ptr arrayStride
+    (#poke WGPUVertexBufferLayout, stepMode) ptr stepMode
+    (#poke WGPUVertexBufferLayout, attributeCount) ptr attributeCount
+    (#poke WGPUVertexBufferLayout, attributes) ptr attributes
diff --git a/src/WGPU/Raw/Generated/Struct/WGPUVertexState.hsc b/src/WGPU/Raw/Generated/Struct/WGPUVertexState.hsc
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Generated/Struct/WGPUVertexState.hsc
@@ -0,0 +1,46 @@
+{-# OPTIONS_GHC -Wno-unused-imports #-}
+{-# LANGUAGE RecordWildCards #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+
+-- This file was generated by wgpu-raw-hs-codegen on:
+--   2021-08-15T08:56:06.968390
+-- Using wgpu-native git hash:
+--   b10496e7eed9349f0fd541e6dfe5029cb436de74 wgpu-native (v0.9.2.2)
+
+module WGPU.Raw.Generated.Struct.WGPUVertexState where
+
+#include "wgpu.h"
+
+import Data.Word (Word16, Word32, Word64)
+import Data.Int (Int32)
+import Foreign
+import Foreign.C.Types
+import WGPU.Raw.Types
+import Prelude (pure, ($!))
+import WGPU.Raw.Generated.Struct.WGPUChainedStruct
+import WGPU.Raw.Generated.Struct.WGPUVertexBufferLayout
+
+data WGPUVertexState = WGPUVertexState {
+  nextInChain :: Ptr (WGPUChainedStruct),
+  shaderModule :: WGPUShaderModule,
+  entryPoint :: Ptr (CChar),
+  bufferCount :: Word32,
+  buffers :: Ptr (WGPUVertexBufferLayout)
+}
+
+instance Storable WGPUVertexState where
+  sizeOf _ = (#size WGPUVertexState)
+  alignment = sizeOf
+  peek ptr = do
+    nextInChain <- (#peek WGPUVertexState, nextInChain) ptr
+    shaderModule <- (#peek WGPUVertexState, module) ptr
+    entryPoint <- (#peek WGPUVertexState, entryPoint) ptr
+    bufferCount <- (#peek WGPUVertexState, bufferCount) ptr
+    buffers <- (#peek WGPUVertexState, buffers) ptr
+    pure $! WGPUVertexState{..}
+  poke ptr WGPUVertexState{..} = do
+    (#poke WGPUVertexState, nextInChain) ptr nextInChain
+    (#poke WGPUVertexState, module) ptr shaderModule
+    (#poke WGPUVertexState, entryPoint) ptr entryPoint
+    (#poke WGPUVertexState, bufferCount) ptr bufferCount
+    (#poke WGPUVertexState, buffers) ptr buffers
diff --git a/src/WGPU/Raw/Types.hs b/src/WGPU/Raw/Types.hs
new file mode 100644
--- /dev/null
+++ b/src/WGPU/Raw/Types.hs
@@ -0,0 +1,184 @@
+{-# LANGUAGE GeneralizedNewtypeDeriving #-}
+
+-- |
+module WGPU.Raw.Types where
+
+import Data.Word (Word32)
+import Foreign (FunPtr, Ptr, Storable)
+import Foreign.C.Types (CChar)
+import WGPU.Raw.Generated.Enum.WGPUBufferMapAsyncStatus
+import WGPU.Raw.Generated.Enum.WGPUCreatePipelineAsyncStatus
+import WGPU.Raw.Generated.Enum.WGPUErrorType
+import WGPU.Raw.Generated.Enum.WGPULogLevel
+import WGPU.Raw.Generated.Enum.WGPUQueueWorkDoneStatus
+import WGPU.Raw.Generated.Enum.WGPUTextureFormat
+
+-------------------------------------------------------------------------------
+-- Opaque pointers
+
+newtype WGPUAdapter = WGPUAdapter (Ptr ())
+  deriving (Storable)
+
+newtype WGPUBindGroup = WGPUBindGroup (Ptr ())
+  deriving (Storable)
+
+newtype WGPUBindGroupLayout = WGPUBindGroupLayout (Ptr ())
+  deriving (Storable)
+
+newtype WGPUBuffer = WGPUBuffer (Ptr ())
+  deriving (Storable)
+
+newtype WGPUCommandBuffer = WGPUCommandBuffer (Ptr ())
+  deriving (Storable)
+
+newtype WGPUCommandEncoder = WGPUCommandEncoder (Ptr ())
+  deriving (Storable)
+
+newtype WGPUComputePassEncoder = WGPUComputePassEncoder (Ptr ())
+  deriving (Storable)
+
+newtype WGPUComputePipeline = WGPUComputePipeline (Ptr ())
+  deriving (Storable)
+
+newtype WGPUDevice = WGPUDevice (Ptr ())
+  deriving (Storable)
+
+newtype WGPUInstance = WGPUInstance (Ptr ())
+  deriving (Storable)
+
+newtype WGPUPipelineLayout = WGPUPipelineLayout (Ptr ())
+  deriving (Storable)
+
+newtype WGPUQuerySet = WGPUQuerySet (Ptr ())
+  deriving (Storable)
+
+newtype WGPUQueue = WGPUQueue (Ptr ())
+  deriving (Storable)
+
+newtype WGPURenderBundle = WGPURenderBundle (Ptr ())
+  deriving (Storable)
+
+newtype WGPURenderBundleEncoder = WGPURenderBundleEncoder (Ptr ())
+  deriving (Storable)
+
+newtype WGPURenderPassEncoder = WGPURenderPassEncoder (Ptr ())
+  deriving (Storable)
+
+newtype WGPURenderPipeline = WGPURenderPipeline (Ptr ())
+  deriving (Storable)
+
+newtype WGPUSampler = WGPUSampler (Ptr ())
+  deriving (Storable)
+
+newtype WGPUShaderModule = WGPUShaderModule (Ptr ())
+  deriving (Storable)
+
+newtype WGPUSurface = WGPUSurface (Ptr ())
+  deriving (Storable)
+
+newtype WGPUSwapChain = WGPUSwapChain (Ptr ())
+  deriving (Storable)
+
+newtype WGPUTexture = WGPUTexture (Ptr ())
+  deriving (Storable)
+
+newtype WGPUTextureView = WGPUTextureView (Ptr ())
+  deriving (Storable)
+
+-------------------------------------------------------------------------------
+-- Extra type aliases
+
+type WGPUFlags = Word32
+
+type WGPUBufferUsageFlags = WGPUFlags
+
+type WGPUColorWriteMaskFlags = WGPUFlags
+
+type WGPUMapModeFlags = WGPUFlags
+
+type WGPUShaderStageFlags = WGPUFlags
+
+type WGPUTextureUsageFlags = WGPUFlags
+
+-------------------------------------------------------------------------------
+-- Function pointers from webgpu.h
+
+type WGPUProc = FunPtr (IO ())
+
+type WGPURequestDeviceCallback =
+  FunPtr
+    ( WGPUDevice ->
+      Ptr () ->
+      IO ()
+    )
+
+type WGPUBufferMapCallback =
+  FunPtr
+    ( WGPUBufferMapAsyncStatus ->
+      Ptr () ->
+      IO ()
+    )
+
+type WGPUCreateComputePipelineAsyncCallback =
+  FunPtr
+    ( WGPUCreatePipelineAsyncStatus ->
+      WGPUComputePipeline ->
+      Ptr CChar ->
+      Ptr () ->
+      IO ()
+    )
+
+type WGPUCreateRenderPipelineAsyncCallback =
+  FunPtr
+    ( WGPUCreatePipelineAsyncStatus ->
+      WGPURenderPipeline ->
+      Ptr CChar ->
+      Ptr () ->
+      IO ()
+    )
+
+type WGPUDeviceLostCallback =
+  FunPtr
+    ( Ptr CChar ->
+      Ptr () ->
+      IO ()
+    )
+
+type WGPUErrorCallback =
+  FunPtr
+    ( WGPUErrorType ->
+      Ptr CChar ->
+      Ptr () ->
+      IO ()
+    )
+
+type WGPURequestAdapterCallback =
+  FunPtr
+    ( WGPUAdapter ->
+      Ptr () ->
+      IO ()
+    )
+
+type WGPUQueueWorkDoneCallback =
+  FunPtr
+    ( WGPUQueueWorkDoneStatus ->
+      Ptr () ->
+      IO ()
+    )
+
+type WGPUSurfaceGetPreferredFormatCallback =
+  FunPtr
+    ( WGPUTextureFormat ->
+      Ptr () ->
+      IO ()
+    )
+
+-------------------------------------------------------------------------------
+-- Function pointers from wgpu.h
+
+type WGPULogCallback =
+  FunPtr
+    ( WGPULogLevel ->
+      Ptr CChar ->
+      IO ()
+    )
diff --git a/wgpu-raw-hs.cabal b/wgpu-raw-hs.cabal
new file mode 100644
--- /dev/null
+++ b/wgpu-raw-hs.cabal
@@ -0,0 +1,183 @@
+cabal-version:      3.0
+name:               wgpu-raw-hs
+version:            0.1.0.0
+synopsis:           WGPU Raw
+description:        A very low-level WGPU binding.
+bug-reports:        https://github.com/lancelet/wgpu-hs/issues
+license:            BSD-3-Clause
+author:             Jonathan Merritt
+maintainer:         j.s.merritt@gmail.com
+copyright:          Copyright (C) Jonathan Merritt, 2021
+category:           Graphics
+extra-source-files:
+  cbits/webgpu-headers/webgpu.h
+  cbits/wgpu.h
+  CHANGELOG.md
+
+flag glfw
+  description: Enable GLFW integration
+  default:     True
+  manual:      True
+
+flag examples
+  description: Build the example(s)
+  default:     True
+  manual:      True
+
+common base
+  default-language: Haskell2010
+  build-depends:    base ^>=4.14.0.0
+
+common ghc-options
+  ghc-options:
+    -Wall -Wcompat -Wincomplete-record-updates
+    -Wincomplete-uni-patterns -Wredundant-constraints
+
+library
+  import:          base, ghc-options
+  include-dirs:    cbits
+  hs-source-dirs:  src
+  exposed-modules:
+    WGPU.Raw.Dynamic
+    WGPU.Raw.Generated.Enum.WGPUAdapterType
+    WGPU.Raw.Generated.Enum.WGPUAddressMode
+    WGPU.Raw.Generated.Enum.WGPUBackendType
+    WGPU.Raw.Generated.Enum.WGPUBlendFactor
+    WGPU.Raw.Generated.Enum.WGPUBlendOperation
+    WGPU.Raw.Generated.Enum.WGPUBufferBindingType
+    WGPU.Raw.Generated.Enum.WGPUBufferMapAsyncStatus
+    WGPU.Raw.Generated.Enum.WGPUBufferUsage
+    WGPU.Raw.Generated.Enum.WGPUColorWriteMask
+    WGPU.Raw.Generated.Enum.WGPUCompareFunction
+    WGPU.Raw.Generated.Enum.WGPUCreatePipelineAsyncStatus
+    WGPU.Raw.Generated.Enum.WGPUCullMode
+    WGPU.Raw.Generated.Enum.WGPUErrorFilter
+    WGPU.Raw.Generated.Enum.WGPUErrorType
+    WGPU.Raw.Generated.Enum.WGPUFilterMode
+    WGPU.Raw.Generated.Enum.WGPUFrontFace
+    WGPU.Raw.Generated.Enum.WGPUIndexFormat
+    WGPU.Raw.Generated.Enum.WGPUInputStepMode
+    WGPU.Raw.Generated.Enum.WGPULoadOp
+    WGPU.Raw.Generated.Enum.WGPULogLevel
+    WGPU.Raw.Generated.Enum.WGPUMapMode
+    WGPU.Raw.Generated.Enum.WGPUNativeFeature
+    WGPU.Raw.Generated.Enum.WGPUNativeSType
+    WGPU.Raw.Generated.Enum.WGPUPipelineStatisticName
+    WGPU.Raw.Generated.Enum.WGPUPresentMode
+    WGPU.Raw.Generated.Enum.WGPUPrimitiveTopology
+    WGPU.Raw.Generated.Enum.WGPUQueryType
+    WGPU.Raw.Generated.Enum.WGPUQueueWorkDoneStatus
+    WGPU.Raw.Generated.Enum.WGPUSamplerBindingType
+    WGPU.Raw.Generated.Enum.WGPUShaderStage
+    WGPU.Raw.Generated.Enum.WGPUStencilOperation
+    WGPU.Raw.Generated.Enum.WGPUStorageTextureAccess
+    WGPU.Raw.Generated.Enum.WGPUStoreOp
+    WGPU.Raw.Generated.Enum.WGPUSType
+    WGPU.Raw.Generated.Enum.WGPUTextureAspect
+    WGPU.Raw.Generated.Enum.WGPUTextureComponentType
+    WGPU.Raw.Generated.Enum.WGPUTextureDimension
+    WGPU.Raw.Generated.Enum.WGPUTextureFormat
+    WGPU.Raw.Generated.Enum.WGPUTextureSampleType
+    WGPU.Raw.Generated.Enum.WGPUTextureUsage
+    WGPU.Raw.Generated.Enum.WGPUTextureViewDimension
+    WGPU.Raw.Generated.Enum.WGPUVertexFormat
+    WGPU.Raw.Generated.Fun
+    WGPU.Raw.Generated.Struct.WGPUAdapterExtras
+    WGPU.Raw.Generated.Struct.WGPUAdapterProperties
+    WGPU.Raw.Generated.Struct.WGPUBindGroupDescriptor
+    WGPU.Raw.Generated.Struct.WGPUBindGroupEntry
+    WGPU.Raw.Generated.Struct.WGPUBindGroupLayoutDescriptor
+    WGPU.Raw.Generated.Struct.WGPUBindGroupLayoutEntry
+    WGPU.Raw.Generated.Struct.WGPUBlendComponent
+    WGPU.Raw.Generated.Struct.WGPUBlendState
+    WGPU.Raw.Generated.Struct.WGPUBufferBindingLayout
+    WGPU.Raw.Generated.Struct.WGPUBufferDescriptor
+    WGPU.Raw.Generated.Struct.WGPUChainedStruct
+    WGPU.Raw.Generated.Struct.WGPUColor
+    WGPU.Raw.Generated.Struct.WGPUColorTargetState
+    WGPU.Raw.Generated.Struct.WGPUCommandBufferDescriptor
+    WGPU.Raw.Generated.Struct.WGPUCommandEncoderDescriptor
+    WGPU.Raw.Generated.Struct.WGPUComputePassDescriptor
+    WGPU.Raw.Generated.Struct.WGPUComputePipelineDescriptor
+    WGPU.Raw.Generated.Struct.WGPUDepthStencilState
+    WGPU.Raw.Generated.Struct.WGPUDeviceDescriptor
+    WGPU.Raw.Generated.Struct.WGPUDeviceExtras
+    WGPU.Raw.Generated.Struct.WGPUExtent3D
+    WGPU.Raw.Generated.Struct.WGPUFragmentState
+    WGPU.Raw.Generated.Struct.WGPUImageCopyBuffer
+    WGPU.Raw.Generated.Struct.WGPUImageCopyTexture
+    WGPU.Raw.Generated.Struct.WGPUInstanceDescriptor
+    WGPU.Raw.Generated.Struct.WGPUMultisampleState
+    WGPU.Raw.Generated.Struct.WGPUOrigin3D
+    WGPU.Raw.Generated.Struct.WGPUPipelineLayoutDescriptor
+    WGPU.Raw.Generated.Struct.WGPUPrimitiveDepthClampingState
+    WGPU.Raw.Generated.Struct.WGPUPrimitiveState
+    WGPU.Raw.Generated.Struct.WGPUProgrammableStageDescriptor
+    WGPU.Raw.Generated.Struct.WGPUQuerySetDescriptor
+    WGPU.Raw.Generated.Struct.WGPURenderBundleDescriptor
+    WGPU.Raw.Generated.Struct.WGPURenderBundleEncoderDescriptor
+    WGPU.Raw.Generated.Struct.WGPURenderPassColorAttachment
+    WGPU.Raw.Generated.Struct.WGPURenderPassDepthStencilAttachment
+    WGPU.Raw.Generated.Struct.WGPURenderPassDescriptor
+    WGPU.Raw.Generated.Struct.WGPURenderPipelineDescriptor
+    WGPU.Raw.Generated.Struct.WGPURequestAdapterOptions
+    WGPU.Raw.Generated.Struct.WGPUSamplerBindingLayout
+    WGPU.Raw.Generated.Struct.WGPUSamplerDescriptor
+    WGPU.Raw.Generated.Struct.WGPUShaderModuleDescriptor
+    WGPU.Raw.Generated.Struct.WGPUShaderModuleSPIRVDescriptor
+    WGPU.Raw.Generated.Struct.WGPUShaderModuleWGSLDescriptor
+    WGPU.Raw.Generated.Struct.WGPUStencilFaceState
+    WGPU.Raw.Generated.Struct.WGPUStorageTextureBindingLayout
+    WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptor
+    WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptorFromCanvasHTMLSelector
+    WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptorFromMetalLayer
+    WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptorFromWindowsHWND
+    WGPU.Raw.Generated.Struct.WGPUSurfaceDescriptorFromXlib
+    WGPU.Raw.Generated.Struct.WGPUSwapChainDescriptor
+    WGPU.Raw.Generated.Struct.WGPUTextureBindingLayout
+    WGPU.Raw.Generated.Struct.WGPUTextureDataLayout
+    WGPU.Raw.Generated.Struct.WGPUTextureDescriptor
+    WGPU.Raw.Generated.Struct.WGPUTextureViewDescriptor
+    WGPU.Raw.Generated.Struct.WGPUVertexAttribute
+    WGPU.Raw.Generated.Struct.WGPUVertexBufferLayout
+    WGPU.Raw.Generated.Struct.WGPUVertexState
+    WGPU.Raw.Types
+
+  if flag(glfw)
+    build-depends:   GLFW-b
+    exposed-modules: WGPU.Raw.GLFWSurface
+
+    if os(osx)
+      c-sources:  cbits/surface-macos.m
+      frameworks: AppKit QuartzCore
+
+  if os(osx)
+    cpp-options:   -DWGPUHS_UNIX -DWGPUHS_TARGET_MACOS
+    cc-options:    -DWGPUHS_TARGET=WGPUHS_TARGET_MACOS
+    build-depends: unix ^>=2.7.2
+
+  if os(linux)
+    cpp-options:   -DWGPUHS_UNIX -DWGPUHS_TARGET_LINUX
+    cc-options:    -DWGPUHS_TARGET=WGPUHS_TARGET_LINUX
+    build-depends: unix ^>=2.7.2
+
+  if os(windows)
+    cpp-options:   -DWGPUHS_WINDOWS -DWGPUHS_TARGET_WINDOWS
+    cc-options:    -DWGPUHS_TARGET=WGPUHS_TARGET_WINDOWS
+    build-depends: Win32
+
+executable triangle
+  import:         base, ghc-options
+
+  if flag(examples)
+    build-depends:
+      , base
+      , GLFW-b       ^>=3.3.0
+      , wgpu-raw-hs
+
+  else
+    buildable: False
+
+  hs-source-dirs: examples/triangle
+  main-is:        Triangle.hs
+  ghc-options:    -main-is Triangle
