resolveCounterRange(_:)
Transforms samples of a GPU’s counter set from the driver’s internal format to a standard Metal data structure.
Declaration
func resolveCounterRange(_ range: Range<Int>) throws -> Data?Parameters
- range:
A range that indicates which sample instances the method resolves in the counter sample buffer.
Mentioned in
Return Value
A Data instance in Swift, or an NSData instance in Objective-C, if the method successfully resolves the range of samples in the buffer; otherwise, nil.
Discussion
You can only call this method on a counter sample buffer that you create with MTLStorageMode.shared (see storageMode). For an example of how and when to use this method, see Converting a GPU’s counter data into a readable format.