---
title: kAudioQueueHardwareCodecPolicy_UseHardwareOnly
framework: audiotoolbox
role: symbol
role_heading: Global Variable
path: audiotoolbox/kaudioqueuehardwarecodecpolicy_usehardwareonly
---

# kAudioQueueHardwareCodecPolicy_UseHardwareOnly

The audio queue will use a hardware codec if one is available and if its use is permitted by the audio session category that you have set.

## Declaration

```swift
var kAudioQueueHardwareCodecPolicy_UseHardwareOnly: UInt32 { get }
```

## See Also

### Constants

- [kAudioQueueProperty_HardwareCodecPolicy](audiotoolbox/kaudioqueueproperty_hardwarecodecpolicy.md)
- [kAudioQueueHardwareCodecPolicy_Default](audiotoolbox/kaudioqueuehardwarecodecpolicy_default.md)
- [kAudioQueueHardwareCodecPolicy_UseSoftwareOnly](audiotoolbox/kaudioqueuehardwarecodecpolicy_usesoftwareonly.md)
- [kAudioQueueHardwareCodecPolicy_PreferSoftware](audiotoolbox/kaudioqueuehardwarecodecpolicy_prefersoftware.md)
- [kAudioQueueHardwareCodecPolicy_PreferHardware](audiotoolbox/kaudioqueuehardwarecodecpolicy_preferhardware.md)
