gecko0307 / bindbc-wgpu

WebGPU for D

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

wgpu_render_pass_set_bind_group invalid offsets type

helikopterodaktyl opened this issue · comments

I think dynamic offsets are improperly passed to wgpu-native. bindbc-wgpu uses:

alias da_wgpu_render_pass_set_bind_group = void function(WGPURenderPass* pass,
                                                         uint index,
                                                         WGPUBindGroupId bind_group_id,
                                                         const WGPUBufferAddress* offsets,
                                                         uintptr_t offsets_length);

WGPUBufferAddress is a int64 value.

WGPU-native uses https://github.com/gfx-rs/wgpu-native/blob/b5daa1f7c7dfa2a6af0feb9c28486ef70c2ae483/ffi/wgpu.h#L2246 "WGPUDynamicOffset* offsets", which are int32 values. I believe bindbc-wgpu should use WGPUDynamicOffset* too in these functions. The compute render pass equivalent seems to be having the same issue.