Camera2PhotoCaptureState
public enum Camera2PhotoCaptureState : Equatable, CustomStringConvertible
Camera photo capture state.
-
Photo capture is stopped and ready to be operated.
- latestSavedMediaId: identifier of latest saved media, or
nil
if no media was saved since connection
Declaration
Swift
case stopped(latestSavedMediaId: String?)
- latestSavedMediaId: identifier of latest saved media, or
-
Photo capture is starting. This state is entered from
stopped
after a call toCamera2PhotoCapture.start()
.Declaration
Swift
case starting
-
Photo capture is started.
- startTimeOnSystemClock: time when the capture did start, in seconds in the local device’s default clock reference; may be negative if the capture started before local device boot
- duration: closure allowing to retrieve capture duration so far
- photoCount: number of photo taken in the session
- mediaStorage: destination storage for produced media,
nil
if unknown
Declaration
Swift
case started(startTimeOnSystemClock: Double, duration: () -> TimeInterval, photoCount: Int, mediaStorage: StorageType?)
-
Photo capture is stopping.
- reason: reason why the photo capture is stopping
- savedMediaId: identifier of saved media if any, otherwise
nil
Declaration
Swift
case stopping(reason: StopReason, savedMediaId: String?)
-
Photo capture stop reason.
See moreDeclaration
Swift
public enum StopReason : String, CustomStringConvertible
-
Equatable.
Declaration
Swift
public static func == (lhs: Camera2PhotoCaptureState, rhs: Camera2PhotoCaptureState) -> Bool
-
Debug description.
Declaration
Swift
public var description: String { get }
-
Whether photo capture can be started.
Declaration
Swift
public var canStart: Bool { get }
-
Whether photo capture can be stopped.
Declaration
Swift
public var canStop: Bool { get }