Contents

canSetSessionPreset(_:)

Determines whether you can configure a capture session with the specified preset.

Declaration

func canSetSessionPreset(_ preset: AVCaptureSession.Preset) -> Bool

Parameters

  • preset:

    A preset value to test.

Return Value

true if the capture session supports the preset; otherwise, false.

Discussion

Use this method to determine whether the capture session, in its current I/O configuration, supports a particular preset. You can only set a preset that returns true as the capture session’s sessionPreset property value.

See Also

Setting a session preset