mirror of
https://github.com/gfx-rs/wgpu.git
synced 2024-11-22 06:44:14 +00:00
Regenerate bindings
This commit is contained in:
parent
c7f2425b98
commit
f647fd8030
1
examples/vendor/glfw
vendored
Submodule
1
examples/vendor/glfw
vendored
Submodule
@ -0,0 +1 @@
|
|||||||
|
Subproject commit 29d8ca4ce4aef8e0afca62b8ace9ee18a24a9ffd
|
@ -4,9 +4,10 @@
|
|||||||
typedef void *WGPUId;
|
typedef void *WGPUId;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#include <stdarg.h>
|
||||||
|
#include <stdbool.h>
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <stdbool.h>
|
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
WGPUBindingType_UniformBuffer = 0,
|
WGPUBindingType_UniformBuffer = 0,
|
||||||
@ -50,6 +51,11 @@ typedef enum {
|
|||||||
WGPUCompareFunction_Always = 7,
|
WGPUCompareFunction_Always = 7,
|
||||||
} WGPUCompareFunction;
|
} WGPUCompareFunction;
|
||||||
|
|
||||||
|
typedef enum {
|
||||||
|
WGPULoadOp_Clear = 0,
|
||||||
|
WGPULoadOp_Load = 1,
|
||||||
|
} WGPULoadOp;
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
WGPUPowerPreference_Default = 0,
|
WGPUPowerPreference_Default = 0,
|
||||||
WGPUPowerPreference_LowPower = 1,
|
WGPUPowerPreference_LowPower = 1,
|
||||||
@ -81,6 +87,10 @@ typedef enum {
|
|||||||
WGPUStencilOperation_DecrementWrap = 7,
|
WGPUStencilOperation_DecrementWrap = 7,
|
||||||
} WGPUStencilOperation;
|
} WGPUStencilOperation;
|
||||||
|
|
||||||
|
typedef enum {
|
||||||
|
WGPUStoreOp_Store = 0,
|
||||||
|
} WGPUStoreOp;
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
WGPUTextureDimension_D1,
|
WGPUTextureDimension_D1,
|
||||||
WGPUTextureDimension_D2,
|
WGPUTextureDimension_D2,
|
||||||
@ -103,8 +113,6 @@ typedef enum {
|
|||||||
WGPUTextureViewDimension_D3,
|
WGPUTextureViewDimension_D3,
|
||||||
} WGPUTextureViewDimension;
|
} WGPUTextureViewDimension;
|
||||||
|
|
||||||
typedef struct WGPURenderPassDescriptor_TextureViewId WGPURenderPassDescriptor_TextureViewId;
|
|
||||||
|
|
||||||
typedef WGPUId WGPUDeviceId;
|
typedef WGPUId WGPUDeviceId;
|
||||||
|
|
||||||
typedef WGPUId WGPUAdapterId;
|
typedef WGPUId WGPUAdapterId;
|
||||||
@ -123,6 +131,38 @@ typedef WGPUId WGPUCommandBufferId;
|
|||||||
|
|
||||||
typedef WGPUId WGPURenderPassId;
|
typedef WGPUId WGPURenderPassId;
|
||||||
|
|
||||||
|
typedef WGPUId WGPUTextureViewId;
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
float r;
|
||||||
|
float g;
|
||||||
|
float b;
|
||||||
|
float a;
|
||||||
|
} WGPUColor;
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
WGPUTextureViewId attachment;
|
||||||
|
WGPULoadOp load_op;
|
||||||
|
WGPUStoreOp store_op;
|
||||||
|
WGPUColor clear_color;
|
||||||
|
} WGPURenderPassColorAttachmentDescriptor_TextureViewId;
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
WGPUTextureViewId attachment;
|
||||||
|
WGPULoadOp depth_load_op;
|
||||||
|
WGPUStoreOp depth_store_op;
|
||||||
|
float clear_depth;
|
||||||
|
WGPULoadOp stencil_load_op;
|
||||||
|
WGPUStoreOp stencil_store_op;
|
||||||
|
uint32_t clear_stencil;
|
||||||
|
} WGPURenderPassDepthStencilAttachmentDescriptor_TextureViewId;
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
const WGPURenderPassColorAttachmentDescriptor_TextureViewId *color_attachments;
|
||||||
|
uintptr_t color_attachments_length;
|
||||||
|
const WGPURenderPassDepthStencilAttachmentDescriptor_TextureViewId *depth_stencil_attachment;
|
||||||
|
} WGPURenderPassDescriptor;
|
||||||
|
|
||||||
typedef WGPUId WGPUBindGroupId;
|
typedef WGPUId WGPUBindGroupId;
|
||||||
|
|
||||||
typedef WGPUId WGPUComputePipelineId;
|
typedef WGPUId WGPUComputePipelineId;
|
||||||
@ -231,6 +271,19 @@ typedef struct {
|
|||||||
WGPUByteArray code;
|
WGPUByteArray code;
|
||||||
} WGPUShaderModuleDescriptor;
|
} WGPUShaderModuleDescriptor;
|
||||||
|
|
||||||
|
typedef WGPUId WGPUSwapChainId;
|
||||||
|
|
||||||
|
typedef WGPUId WGPUSurfaceId;
|
||||||
|
|
||||||
|
typedef uint32_t WGPUTextureUsageFlags;
|
||||||
|
|
||||||
|
typedef struct {
|
||||||
|
WGPUTextureUsageFlags usage;
|
||||||
|
WGPUTextureFormat format;
|
||||||
|
uint32_t width;
|
||||||
|
uint32_t height;
|
||||||
|
} WGPUSwapChainDescriptor;
|
||||||
|
|
||||||
typedef WGPUId WGPUTextureId;
|
typedef WGPUId WGPUTextureId;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
@ -239,8 +292,6 @@ typedef struct {
|
|||||||
uint32_t depth;
|
uint32_t depth;
|
||||||
} WGPUExtent3d;
|
} WGPUExtent3d;
|
||||||
|
|
||||||
typedef uint32_t WGPUTextureUsageFlags;
|
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
WGPUExtent3d size;
|
WGPUExtent3d size;
|
||||||
uint32_t array_size;
|
uint32_t array_size;
|
||||||
@ -255,7 +306,10 @@ typedef struct {
|
|||||||
WGPUPowerPreference power_preference;
|
WGPUPowerPreference power_preference;
|
||||||
} WGPUAdapterDescriptor;
|
} WGPUAdapterDescriptor;
|
||||||
|
|
||||||
typedef WGPUId WGPUTextureViewId;
|
typedef struct {
|
||||||
|
WGPUTextureId texture_id;
|
||||||
|
WGPUTextureViewId view_id;
|
||||||
|
} WGPUSwapChainOutput;
|
||||||
|
|
||||||
typedef uint32_t WGPUTextureAspectFlags;
|
typedef uint32_t WGPUTextureAspectFlags;
|
||||||
|
|
||||||
@ -337,13 +391,17 @@ typedef struct {
|
|||||||
|
|
||||||
#define WGPUTextureUsageFlags_TRANSFER_SRC 1
|
#define WGPUTextureUsageFlags_TRANSFER_SRC 1
|
||||||
|
|
||||||
|
#define WGPUTrackPermit_EXTEND (WGPUTrackPermit){ .bits = 1 }
|
||||||
|
|
||||||
|
#define WGPUTrackPermit_REPLACE (WGPUTrackPermit){ .bits = 2 }
|
||||||
|
|
||||||
WGPUDeviceId wgpu_adapter_create_device(WGPUAdapterId adapter_id,
|
WGPUDeviceId wgpu_adapter_create_device(WGPUAdapterId adapter_id,
|
||||||
const WGPUDeviceDescriptor *_desc);
|
const WGPUDeviceDescriptor *_desc);
|
||||||
|
|
||||||
WGPUComputePassId wgpu_command_buffer_begin_compute_pass(WGPUCommandBufferId command_buffer_id);
|
WGPUComputePassId wgpu_command_buffer_begin_compute_pass(WGPUCommandBufferId command_buffer_id);
|
||||||
|
|
||||||
WGPURenderPassId wgpu_command_buffer_begin_render_pass(WGPUCommandBufferId command_buffer_id,
|
WGPURenderPassId wgpu_command_buffer_begin_render_pass(WGPUCommandBufferId command_buffer_id,
|
||||||
WGPURenderPassDescriptor_TextureViewId desc);
|
WGPURenderPassDescriptor desc);
|
||||||
|
|
||||||
void wgpu_compute_pass_dispatch(WGPUComputePassId pass_id, uint32_t x, uint32_t y, uint32_t z);
|
void wgpu_compute_pass_dispatch(WGPUComputePassId pass_id, uint32_t x, uint32_t y, uint32_t z);
|
||||||
|
|
||||||
@ -378,6 +436,10 @@ WGPURenderPipelineId wgpu_device_create_render_pipeline(WGPUDeviceId device_id,
|
|||||||
WGPUShaderModuleId wgpu_device_create_shader_module(WGPUDeviceId device_id,
|
WGPUShaderModuleId wgpu_device_create_shader_module(WGPUDeviceId device_id,
|
||||||
const WGPUShaderModuleDescriptor *desc);
|
const WGPUShaderModuleDescriptor *desc);
|
||||||
|
|
||||||
|
WGPUSwapChainId wgpu_device_create_swap_chain(WGPUDeviceId device_id,
|
||||||
|
WGPUSurfaceId surface_id,
|
||||||
|
const WGPUSwapChainDescriptor *desc);
|
||||||
|
|
||||||
WGPUTextureId wgpu_device_create_texture(WGPUDeviceId device_id, const WGPUTextureDescriptor *desc);
|
WGPUTextureId wgpu_device_create_texture(WGPUDeviceId device_id, const WGPUTextureDescriptor *desc);
|
||||||
|
|
||||||
WGPUQueueId wgpu_device_get_queue(WGPUDeviceId device_id);
|
WGPUQueueId wgpu_device_get_queue(WGPUDeviceId device_id);
|
||||||
@ -391,6 +453,10 @@ void wgpu_queue_submit(WGPUQueueId queue_id,
|
|||||||
|
|
||||||
WGPUCommandBufferId wgpu_render_pass_end_pass(WGPURenderPassId pass_id);
|
WGPUCommandBufferId wgpu_render_pass_end_pass(WGPURenderPassId pass_id);
|
||||||
|
|
||||||
|
WGPUSwapChainOutput wgpu_swap_chain_get_next_texture(WGPUSwapChainId swap_chain_id);
|
||||||
|
|
||||||
|
void wgpu_swap_chain_present(WGPUSwapChainId swap_chain_id);
|
||||||
|
|
||||||
WGPUTextureViewId wgpu_texture_create_default_texture_view(WGPUTextureId texture_id);
|
WGPUTextureViewId wgpu_texture_create_default_texture_view(WGPUTextureId texture_id);
|
||||||
|
|
||||||
WGPUTextureViewId wgpu_texture_create_texture_view(WGPUTextureId texture_id,
|
WGPUTextureViewId wgpu_texture_create_texture_view(WGPUTextureId texture_id,
|
||||||
|
Loading…
Reference in New Issue
Block a user