Enumeration Case


The resource’s contents can be accessed only by the GPU and only exist temporarily during a render pass.


MTLStorageModeMemoryless = 3


In macOS, the memoryless storage mode is not available.

Memoryless resources can be used only as temporary render targets in a render pass (in effect, MTLTexture objects configured and used with a MTLRenderPassAttachmentDescriptor object). You can’t load the texture’s contents at the start of the render pass (MTLLoadActionLoad), nor may you store its contents (MTLStoreActionStore) at the end of the render pass.

Use memoryless resources whenever a render target’s contents are only needed during the rendering process. For example, most render passes do not store depth attachments and multisample attachments to memory. You can significantly reduce your memory usage by creating these attachments as memoryless resources.

On Metal devices that support tile rendering, you can use imageblocks to manage transient rendering data more flexibly. See Metal Shading Language specification.

For more guidance on how to choose storage modes, see Setting Resource Storage Modes.

See Also

Storage Mode Options


The resource is stored in system memory and is accessible to both the CPU and the GPU.


The CPU and GPU may maintain separate copies of the resource, and any changes must be explicitly synchronized.


The resource can be accessed only by the GPU.