Instance Property

isConnected

Indicates whether the device is currently connected.

Declaration

var isConnected: Bool { get }

Discussion

The value of this property indicates whether the device represented by the receiver is connected and available for use as a capture device. When the value of this property becomes false for a given instance, however, it will not become true again. If the same physical device again becomes available to the system, it will be represented using a new instance of AVCaptureDevice.

You can observe changes to the value of this property using Key-value observing.

See Also

Inspecting Device Characteristics

var position: AVCaptureDevice.Position

Indicates the physical position of the device hardware on the system.

func hasMediaType(AVMediaType) -> Bool

Returns a Boolean value that indicates whether the device provides media with a given type.

var modelID: String

The model ID of the device.

var localizedName: String

A localized, human-readable name for the receiver.

var uniqueID: String

An ID unique to the model of device corresponding to the receiver.

func supportsSessionPreset(AVCaptureSession.Preset) -> Bool

Returns a Boolean value that indicates whether the receiver can be used in a capture session configured with the given preset.

var lensAperture: Float

The size of the lens diaphragm.

var deviceType: AVCaptureDevice.DeviceType

The general type of the device, such as a built-in microphone or wide-angle camera.

var manufacturer: String

A human-readable string describing the manufacturer of the device.