Contents

Buffers

Create and manage untyped data your app uses to exchange information with its shader functions.

Overview

Each MTLBuffer instance represents a general purpose, typeless memory allocation that your app uses to send and retrieve data from a shader. Your app decides how to use and interpret the buffer’s underlying bytes.

You create buffers from either an MTLDevice or MTLHeap instance.

Buffers inherently support the MTLResource protocol’s properties and methods, including storageMode, which controls how the GPU handles its memory (see Resource fundamentals).

Topics

General purpose buffers

Argument buffers

Model I/O interoperability

See Also

Resources