---
title: isPrimaryConstituentDeviceSwitchingBehaviorForRecordingEnabled
framework: avfoundation
role: symbol
role_heading: Instance Property
path: avfoundation/avcapturemoviefileoutput/isprimaryconstituentdeviceswitchingbehaviorforrecordingenabled
---

# isPrimaryConstituentDeviceSwitchingBehaviorForRecordingEnabled

A Boolean value that indicates whether to restrict constituent device switching behavior during recording.

## Declaration

```swift
var isPrimaryConstituentDeviceSwitchingBehaviorForRecordingEnabled: Bool { get set }
```

## Discussion

Discussion Use this property to enable camera switching restrictions when recording movies. You set restrictions by calling the output’s setPrimaryConstituentDeviceSwitchingBehaviorForRecording(_:restrictedSwitchingBehaviorConditions:) method. The restrictions take effect when you start recording, and revert to the behavior set by the capture device’s primaryConstituentDeviceSwitchingBehavior when you stop recording. By default, this property is true when connected to a capture device that supports constituent device switching.

## See Also

### Restricting camera switching

- [setPrimaryConstituentDeviceSwitchingBehaviorForRecording(_:restrictedSwitchingBehaviorConditions:)](avfoundation/avcapturemoviefileoutput/setprimaryconstituentdeviceswitchingbehaviorforrecording(_:restrictedswitchingbehaviorconditions:).md)
- [primaryConstituentDeviceSwitchingBehaviorForRecording](avfoundation/avcapturemoviefileoutput/primaryconstituentdeviceswitchingbehaviorforrecording.md)
- [primaryConstituentDeviceRestrictedSwitchingBehaviorConditionsForRecording](avfoundation/avcapturemoviefileoutput/primaryconstituentdevicerestrictedswitchingbehaviorconditionsforrecording.md)
