---
title: MTLCounterDontSample
framework: metal
role: symbol
role_heading: Global Variable
path: metal/mtlcounterdontsample
---

# MTLCounterDontSample

A sentinel value that instructs an encoder to skip sampling a counter as the GPU runs the encoder’s pass.

## Declaration

```swift
var MTLCounterDontSample: Int { get }
```

## Mentioned in

Sampling GPU data into counter sample buffers

## Discussion

Discussion You can skip sampling at specific stages by assigning this sentinel value to the following properties instead of an offset to a counter sample buffer:  |   |   |   |   |   |

## See Also

### Counter sample buffers

- [Creating a counter sample buffer to store a GPU’s counter data during a pass](metal/creating-a-counter-sample-buffer-to-store-a-gpus-counter-data-during-a-pass.md)
- [MTLCounterSampleBufferDescriptor](metal/mtlcountersamplebufferdescriptor.md)
- [MTLCounterSampleBuffer](metal/mtlcountersamplebuffer.md)
- [Sampling GPU data into counter sample buffers](metal/sampling-gpu-data-into-counter-sample-buffers.md)
