Retrieve the list of supported lock modes on the camera.
camera_error_t camera_get_3a_lock_modes(camera_handle_t handle, int numasked, int *numsupported, uint32_t *modes)
The handle returned by a call to the camera_open() function.
The requested number of modes to retrieve from the camera and should be equal to the number of elements in the array you pass as the modes argument.
A pointer that is updated with the number of lock modes that are supported by the camera.
A pointer to an uint32 array. The array is updated with the lock modes supported by the camera. Ensure that you create an array with the same number of elements as indicated by the numasked argument.
The lock modes that are supported are returned as separate elements in an array. The following examples list the array elements that are returned:
For a camera where all three lock modes can be operated independently, the array returned is as follows:
- element 0: CAMERA_3A_AUTOFOCUS - element 1: CAMERA_3A_AUTOEXPOSURE - element 2: CAMERA_3A_AUTOWHITEBALANCE - element 3: CAMERA_3A_NONEFor a camera where autofocus and auto exposure need to be locked simultaneously, the array returned is as follows:
- element 0: CAMERA_3A_AUTOFOCUS|CAMERA_3A_AUTOEXPOSURE - element 1: CAMERA_3A_AUTOWHITEBALANCE - element 1: CAMERA_3A_NONEFor a camera where autofocus, auto exposure, and auto white balance needs to be locked together, the array returned is as follows:
- element 0: CAMERA_3A_AUTOFOCUS|CAMERA_3A_AUTOEXPOSURE| CAMERA_3A_AUTOWHITEBALANCE - element 1: CAMERA_3A_NONEFor a camera that supports only autofocus, the array returned is as follows:
- element 0: CAMERA_3A_AUTOFOCUS - element 1: CAMERA_3A_NONEWhen calling this function, ensure that the modes argument points to an array which has at least the number of elements allocated as specified in the numasked argument. To determine an appropriate size for this array, you can invoke this function in presizing-mode by setting the numasked argument to 0 or modes argument set to NULL. When the function is invoked in this presizing-mode, the maximum array size required is returned in numsupported argument. You can then allocate an array of the appropriate size and invoke the function again with numasked argument set to the value returned previously in the numsupported argument.