---
title: MTL4BufferRange
framework: metal
role: symbol
role_heading: Structure
path: metal/mtl4bufferrange
---

# MTL4BufferRange

## Declaration

```swift
struct MTL4BufferRange
```

## Overview

Overview A struct representing a range of a Metal buffer. The offset into the buffer is included in the address. The length is generally optional, which a value of (uint64_t)-1 representing the range from the given address to the end of the buffer. However, providing the length can enable more accurate API validation, especially when sub-allocating ranges of a buffer.

## Topics

### Initializers

- [init()](metal/mtl4bufferrange/init().md)
- [init(bufferAddress:length:)](metal/mtl4bufferrange/init(bufferaddress:length:).md)

### Instance Properties

- [bufferAddress](metal/mtl4bufferrange/bufferaddress.md)
- [length](metal/mtl4bufferrange/length.md)

## Relationships

### Conforms To

- [BitwiseCopyable](swift/bitwisecopyable.md)
- [Sendable](swift/sendable.md)

## See Also

### Supporting types

- [MTLAxisAlignedBoundingBox](metal/mtlaxisalignedboundingbox-swift.typealias.md)
- [MTLPackedFloat3](metal/mtlpackedfloat3-swift.typealias.md)
- [MTLPackedFloat4x3](metal/mtlpackedfloat4x3-swift.typealias.md)
- [MTLPackedFloat3Make(_:_:_:)](metal/mtlpackedfloat3make(_:_:_:).md)
- [MTL4BufferRangeMake(_:_:)](metal/mtl4bufferrangemake(_:_:).md)
