Structure

AVCaptureDevice.DeviceType

Values identifying the capture device’s type.

Declaration

struct DeviceType

Overview

Use the device type with the default(_:for:position:) method and the AVCaptureDevice.DiscoverySession class.

Topics

Initializers

init(rawValue: String)

Creates an AVCaptureDevice.DeviceType value from its string representation.

Capture Device Types

static let builtInDualCamera: AVCaptureDevice.DeviceType

A combination of wide-angle and telephoto cameras that creates a capture device.

static let builtInDualWideCamera: AVCaptureDevice.DeviceType

A device that consists of two cameras of fixed focal length, one ultrawide angle and one wide angle.

static let builtInTripleCamera: AVCaptureDevice.DeviceType

A device that consists of three cameras of fixed focal length, one ultrawide angle, one wide angle, and one telephoto.

static let builtInUltraWideCamera: AVCaptureDevice.DeviceType

A built-in camera with a shorter focal length than that of a wide-angle camera.

static let builtInTelephotoCamera: AVCaptureDevice.DeviceType

A built-in camera device with a longer focal length than a wide-angle camera.

static let builtInTrueDepthCamera: AVCaptureDevice.DeviceType

A combination of cameras and other sensors that creates a capture device capable of photo, video, and depth capture.

Relationships

See Also

Discovering Devices

init?(uniqueID: String)

Returns the device with a given ID.

class func `default`(for: AVMediaType) -> AVCaptureDevice?

Returns the default device used to capture data of a given media type.

class func `default`(AVCaptureDevice.DeviceType, for: AVMediaType?, position: AVCaptureDevice.Position) -> AVCaptureDevice?

Returns the default device for the specified device type, media type, and position.

enum AVCaptureDevice.Position

Constants to specify the position of a capture device.

class AVCaptureDevice.DiscoverySession

A query for finding and monitoring available capture devices.

static let AVCaptureDeviceWasConnected: NSNotification.Name

Posted when a new device becomes available.

static let AVCaptureDeviceWasDisconnected: NSNotification.Name

Posted when an existing device becomes unavailable.

class func devices() -> [AVCaptureDevice]

Returns an array of the available capture devices on the system.

Deprecated
class func devices(for: AVMediaType) -> [AVCaptureDevice]

Returns an array of the devices able to capture data of a given media type.

Deprecated