Device.createBuffer - multiple declarations

Function Device.createBuffer

Creates a new buffer.

Buffer createBuffer (
  BufferUsage usage,
  uint size,
  const(string) label
) const;

Parameters

NameDescription
usage How the buffer shall be used.
size Size of the buffer, in bytes.
label Optional, human-readable debug label for the buffer.

Function Device.createBuffer

Creates a new buffer.

Buffer createBuffer (
  BufferUsage usage,
  uint size,
  std.typecons.Flag!("mappedAtCreation") mappedAtCreation = Flag.no,
  const(string) label = null
) const;

Parameters

NameDescription
usage How the buffer shall be used.
size Size of the buffer, in bytes.
mappedAtCreation Whether the buffer is mapped to local memory upon creation.
label Optional, human-readable debug label for the buffer.

Function Device.createBuffer

Creates a new buffer.

Buffer createBuffer (
  const(__C.WGPUBufferDescriptor) descriptor
) const;