init(device:action:)
Creates a slider to control the exposure bias of the specified capture device with an action to respond to exposure bias changes.
Declaration
init(device: AVCaptureDevice, action: @escaping @MainActor @Sendable (Float) -> Void)Parameters
- device:
The capture device to control.
- action:
An action the system calls on the main actor to handle changes to the device’s Exposuretargetbias property.
Discussion
The system only calls the specified action when the exposure bias slider changes the device’s videoZoomFactor property value. If you need to react to other sources of changes to the exposure target bias, use key-value observation instead.