<!--
{
  "availability" : [
    "iOS: 8.0.0 -",
    "iPadOS: 8.0.0 -",
    "macCatalyst: 13.1.0 -",
    "macOS: 10.11.0 -",
    "tvOS: -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "Metal",
  "identifier" : "/documentation/Metal/MTLComputeCommandEncoder/setTextures:withRange:",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Metal"
    ],
    "preciseIdentifier" : "c:objc(pl)MTLComputeCommandEncoder(im)setTextures:withRange:"
  },
  "title" : "setTextures:withRange:"
}
-->

# setTextures:withRange:

Binds multiple textures to the texture argument table, allowing compute kernels to access their data on the GPU.

```
- (void) setTextures:(id<MTLTexture> const[]) textures withRange:(NSRange) range;
```

## Parameters

`textures`

An array of [`MTLTexture`](/documentation/Metal/MTLTexture) instances to bind to the texture argument table.

`range`

The texture table indices to bind each of the `textures` to, in the order they appear.

## Discussion> Important:
> This method requires that the number of instances in `textures` be the same as the length of `range`.

---

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)