AutoFocusCallback typedef

  1. @Reference('android_hardware/camera/AutoFocusCallback')
AutoFocusCallback = void Function(bool success)

Callback used to notify on completion of camera auto focus.

Devices that do not support auto-focus will receive a "fake" callback to this callback. If your application needs auto-focus and should not be installed on devices without auto-focus, you must declare that your app uses the android.hardware.camera.autofocus feature, in the <uses-feature> manifest element.

If the camera does not support auto-focus and Camera.autoFocus is called, AutoFocusCallback will be called immediately with a fake value of success set to true. The auto-focus routine does not lock auto-exposure and auto-white balance after it completes.

success: whether the auto-focus was successful.

See: Camera.autoFocus.

Implementation

@Reference('android_hardware/camera/AutoFocusCallback')
typedef AutoFocusCallback = void Function(bool success);