mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-04 22:58:46 +00:00
wgpu: fix wrapper and add more wrappers
This commit is contained in:
Vendored
+16
-4
@@ -1530,8 +1530,10 @@ foreign libwgpu {
|
|||||||
DeviceCreateShaderModule :: proc(device: Device, descriptor: /* const */ ^ShaderModuleDescriptor) -> ShaderModule ---
|
DeviceCreateShaderModule :: proc(device: Device, descriptor: /* const */ ^ShaderModuleDescriptor) -> ShaderModule ---
|
||||||
DeviceCreateTexture :: proc(device: Device, descriptor: /* const */ ^TextureDescriptor) -> Texture ---
|
DeviceCreateTexture :: proc(device: Device, descriptor: /* const */ ^TextureDescriptor) -> Texture ---
|
||||||
DeviceDestroy :: proc(device: Device) ---
|
DeviceDestroy :: proc(device: Device) ---
|
||||||
DeviceGetAdapterInfo :: proc(device: Device, info: ^AdapterInfo) -> Status ---
|
@(link_name="wgpuDeviceGetAdapterInfo")
|
||||||
DeviceGetFeatures :: proc(device: Device, features: ^SupportedFeatures) ---
|
RawDeviceGetAdapterInfo :: proc(device: Device, info: ^AdapterInfo) -> Status ---
|
||||||
|
@(link_name="wgpuDeviceGetFeatures")
|
||||||
|
RawDeviceGetFeatures :: proc(device: Device, features: ^SupportedFeatures) ---
|
||||||
@(link_name="wgpuDeviceGetLimits")
|
@(link_name="wgpuDeviceGetLimits")
|
||||||
RawDeviceGetLimits :: proc(device: Device, limits: ^Limits) -> Status ---
|
RawDeviceGetLimits :: proc(device: Device, limits: ^Limits) -> Status ---
|
||||||
DeviceGetLostFuture :: proc(device: Device) -> Future ---
|
DeviceGetLostFuture :: proc(device: Device) -> Future ---
|
||||||
@@ -1721,8 +1723,8 @@ AdapterGetLimits :: proc "c" (adapter: Adapter) -> (limits: Limits, status: Stat
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
AdapterGetInfo :: proc "c" (adapter: Adapter) -> (info: AdapterInfo) {
|
AdapterGetInfo :: proc "c" (adapter: Adapter) -> (info: AdapterInfo, status: Status) {
|
||||||
RawAdapterGetInfo(adapter, &info)
|
status = RawAdapterGetInfo(adapter, &info)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1774,6 +1776,16 @@ DeviceGetLimits :: proc "c" (device: Device) -> (limits: Limits, status: Status)
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
DeviceGetAdapterInfo :: proc "c" (device: Device) -> (info: AdapterInfo, status: Status) {
|
||||||
|
status = RawDeviceGetAdapterInfo(device, &info)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
DeviceGetFeatures :: proc "c" (device: Device) -> (features: SupportedFeatures) {
|
||||||
|
RawDeviceGetFeatures(device, &features)
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
BufferWithDataDescriptor :: struct {
|
BufferWithDataDescriptor :: struct {
|
||||||
/* NULLABLE */ label: StringView,
|
/* NULLABLE */ label: StringView,
|
||||||
usage: BufferUsageFlags,
|
usage: BufferUsageFlags,
|
||||||
|
|||||||
Reference in New Issue
Block a user