<!--
{
  "availability" : [
    "iOS: 12.0.0 -",
    "iPadOS: 12.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.14.0 -",
    "tvOS: 12.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Metal",
  "identifier" : "/documentation/Metal/MTLTextureDescriptor/textureBufferDescriptor(with:width:resourceOptions:usage:)",
  "metadataVersion" : "0.1.0",
  "role" : "Type Method",
  "symbol" : {
    "kind" : "Type Method",
    "modules" : [
      "Metal"
    ],
    "preciseIdentifier" : "c:objc(cs)MTLTextureDescriptor(cm)textureBufferDescriptorWithPixelFormat:width:resourceOptions:usage:"
  },
  "title" : "textureBufferDescriptor(with:width:resourceOptions:usage:)"
}
-->

# textureBufferDescriptor(with:width:resourceOptions:usage:)

Creates a texture descriptor object for a texture buffer.

```
class func textureBufferDescriptor(with pixelFormat: MTLPixelFormat, width: Int, resourceOptions: MTLResourceOptions = [], usage: MTLTextureUsage) -> MTLTextureDescriptor
```

## Parameters

`pixelFormat`

The format describing how every pixel on the texture buffer is stored. The default value is [`MTLPixelFormat.rgba8Unorm`](/documentation/Metal/MTLPixelFormat/rgba8Unorm).

`width`

The width of the texture buffer. The value needs to be greater than or equal to `1`.

`resourceOptions`

The access options to use for the new texture buffer.

`usage`

The allowed usage of the new texture buffer.

## Return Value

A pointer to a texture descriptor object for a texture buffer.

## Discussion

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)