MTLDevice_Extensions.CreateBuffer<T> Method

Definition

Creates and returns a new buffer with a copy of the specified data.

public static Metal.IMTLBuffer CreateBuffer<T> (this Metal.IMTLDevice This, T[] data, Metal.MTLResourceOptions options) where T : struct;
static member CreateBuffer : Metal.IMTLDevice * 'T[] * Metal.MTLResourceOptions -> Metal.IMTLBuffer (requires 'T : struct)

Type Parameters

T

The type for which to create a buffer.

Parameters

This
IMTLDevice

The instance on which this method operates.

data
T[]

The data to copy into the buffer.

options
MTLResourceOptions

Options for creating the buffer.

Returns

Applies to