Aller au contenu

GPUBufferBinding

A buffer resource and the byte range exposed to a shader through a bind group.

Properties

buffer

abstract val buffer: GPUBuffer
The GPUBuffer to bind. See [GPUBufferBinding.buffer in the WebGPU specification](https://www.w3.org/TR/webgpu/#dom-gpubufferbinding-buffer).

offset

abstract val offset: GPUSize64
The offset, in bytes, from the beginning of buffer to the beginning of the range exposed to the shader by the buffer binding.

size

abstract val size: GPUSize64?
The size, in bytes, of the buffer binding. If not provided, specifies the range starting at offset and ending at the end of buffer.