MijickCamera/Sources/Internal/Manager/Helpers/Capture Session/CaptureSession.swift

28 lines
841 B
Swift
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

//
// CaptureSession.swift of MijickCamera
//
// Created by Tomasz Kurylik. Sending from Kraków!
// - Mail: tomasz.kurylik@mijick.com
// - GitHub: https://github.com/FulcrumOne
// - Medium: https://medium.com/@mijick
//
// Copyright ©2024 Mijick. All rights reserved.
import AVKit
protocol CaptureSession: Sendable {
// MARK: Attributes
var isRunning: Bool { get }
var deviceInputs: [any CaptureDeviceInput] { get }
var outputs: [AVCaptureOutput] { get }
var sessionPreset: AVCaptureSession.Preset { get set }
// MARK: Methods
func startRunning()
func stopRunningAndReturnNewInstance() -> CaptureSession
func add(input: (any CaptureDeviceInput)?) throws(MCameraError)
func remove(input: (any CaptureDeviceInput)?)
func add(output: AVCaptureOutput?) throws(MCameraError)
}