---
title: AVCaptureConnection
framework: avfoundation
role: symbol
role_heading: Class
path: avfoundation/avcaptureconnection
---

# AVCaptureConnection

An object that represents a connection from a capture input to a capture output.

## Declaration

```swift
class AVCaptureConnection
```

## Overview

Overview Capture inputs have one or more input ports (instances of AVCaptureInput.Port). Capture outputs can accept data from one or more sources (for example, an AVCaptureMovieFileOutput object accepts both video and audio data). You can add an AVCaptureConnection instance to a session using the addConnection(_:) method only if the canAddConnection(_:) method returns true. When using the addInput(_:) or addOutput(_:) method, the session forms connections automatically between all compatible inputs and outputs. You only need to add connections manually when adding an input or output with no connections. You can also use connections to enable or disable the flow of data from a given input or to a given output.

## Topics

### Creating a connection

- [init(inputPorts:output:)](avfoundation/avcaptureconnection/init(inputports:output:).md)
- [init(inputPort:videoPreviewLayer:)](avfoundation/avcaptureconnection/init(inputport:videopreviewlayer:).md)

### Enabling a connection

- [isEnabled](avfoundation/avcaptureconnection/isenabled.md)
- [isActive](avfoundation/avcaptureconnection/isactive.md)

### Inspecting a connection

- [inputPorts](avfoundation/avcaptureconnection/inputports.md)
- [output](avfoundation/avcaptureconnection/output.md)
- [videoPreviewLayer](avfoundation/avcaptureconnection/videopreviewlayer.md)
- [audioChannels](avfoundation/avcaptureconnection/audiochannels.md)

### Rotating a video

- [isVideoRotationAngleSupported(_:)](avfoundation/avcaptureconnection/isvideorotationanglesupported(_:).md)
- [videoRotationAngle](avfoundation/avcaptureconnection/videorotationangle.md)

### Mirroring a video

- [isVideoMirroringSupported](avfoundation/avcaptureconnection/isvideomirroringsupported.md)
- [isVideoMirrored](avfoundation/avcaptureconnection/isvideomirrored.md)
- [automaticallyAdjustsVideoMirroring](avfoundation/avcaptureconnection/automaticallyadjustsvideomirroring.md)

### Stabilizing video

- [isVideoStabilizationSupported](avfoundation/avcaptureconnection/isvideostabilizationsupported.md)
- [activeVideoStabilizationMode](avfoundation/avcaptureconnection/activevideostabilizationmode.md)
- [preferredVideoStabilizationMode](avfoundation/avcaptureconnection/preferredvideostabilizationmode.md)

### Delivering camera calibration settings

- [isCameraIntrinsicMatrixDeliverySupported](avfoundation/avcaptureconnection/iscameraintrinsicmatrixdeliverysupported.md)
- [isCameraIntrinsicMatrixDeliveryEnabled](avfoundation/avcaptureconnection/iscameraintrinsicmatrixdeliveryenabled.md)

### Configuring a video’s frame rate

- [isVideoMinFrameDurationSupported](avfoundation/avcaptureconnection/isvideominframedurationsupported.md)
- [videoMinFrameDuration](avfoundation/avcaptureconnection/videominframeduration.md)
- [isVideoMaxFrameDurationSupported](avfoundation/avcaptureconnection/isvideomaxframedurationsupported.md)
- [videoMaxFrameDuration](avfoundation/avcaptureconnection/videomaxframeduration.md)

### Scaling a video

- [videoMaxScaleAndCropFactor](avfoundation/avcaptureconnection/videomaxscaleandcropfactor.md)
- [videoScaleAndCropFactor](avfoundation/avcaptureconnection/videoscaleandcropfactor.md)

### Interlacing video

- [isVideoFieldModeSupported](avfoundation/avcaptureconnection/isvideofieldmodesupported.md)
- [videoFieldMode](avfoundation/avcaptureconnection/videofieldmode.md)
- [AVVideoFieldMode](avfoundation/avvideofieldmode.md)

### Deprecated

- [isVideoStabilizationEnabled](avfoundation/avcaptureconnection/isvideostabilizationenabled.md)
- [enablesVideoStabilizationWhenAvailable](avfoundation/avcaptureconnection/enablesvideostabilizationwhenavailable.md)
- [isVideoOrientationSupported](avfoundation/avcaptureconnection/isvideoorientationsupported.md)
- [videoOrientation](avfoundation/avcaptureconnection/videoorientation.md)
- [AVCaptureVideoOrientation](avfoundation/avcapturevideoorientation.md)

## Relationships

### Inherits From

- [NSObject](objectivec/nsobject-swift.class.md)

### Conforms To

- [CVarArg](swift/cvararg.md)
- [CustomDebugStringConvertible](swift/customdebugstringconvertible.md)
- [CustomStringConvertible](swift/customstringconvertible.md)
- [Equatable](swift/equatable.md)
- [Hashable](swift/hashable.md)
- [NSObjectProtocol](objectivec/nsobjectprotocol.md)

## See Also

### Capture sessions

- [Setting up a capture session](avfoundation/setting-up-a-capture-session.md)
- [Accessing the camera while multitasking on iPad](avkit/accessing-the-camera-while-multitasking-on-ipad.md)
- [AVCam: Building a camera app](avfoundation/avcam-building-a-camera-app.md)
- [Build a responsive camera app that launches quickly](avfoundation/build-a-responsive-camera-app-that-launches-quickly.md)
- [Capturing Cinematic video](avfoundation/capturing-cinematic-video.md)
- [Supporting Center Stage front camera in your iOS app](avfoundation/supporting-center-stage-front-camera-in-your-ios-app.md)
- [AVMultiCamPiP: Capturing from Multiple Cameras](avfoundation/avmulticampip-capturing-from-multiple-cameras.md)
- [AVCamBarcode: detecting barcodes and faces](avfoundation/avcambarcode-detecting-barcodes-and-faces.md)
- [AVCaptureSession](avfoundation/avcapturesession.md)
- [AVCaptureMultiCamSession](avfoundation/avcapturemulticamsession.md)
- [AVCaptureInput](avfoundation/avcaptureinput.md)
- [AVCaptureOutput](avfoundation/avcaptureoutput.md)
