Module versioning information for the Camera hardware module, based on camera_module_t.common.module_api_version. The two most significant hex digits represent the major version, and the two least significant represent the minor version.

Versions: 0.X - 1.X [CAMERA_MODULE_API_VERSION_1_0]

Camera modules that report these version numbers implement the initial camera module HAL interface. All camera devices openable through this module support only version 1 of the camera device HAL. The device_version and static_camera_characteristics fields of camera_info are not valid. Only the android.hardware.Camera API can be supported by this module and its devices.

Version: 2.0 [CAMERA_MODULE_API_VERSION_2_0]

Camera modules that report this version number implement the second version of the camera module HAL interface. Camera devices openable through this module may support either version 1.0 or version 2.0 of the camera device HAL interface. The device_version field of camera_info is always valid; the static_camera_characteristics field of camera_info is valid if the device_version field is 2.0 or higher.

Version: 2.1 [CAMERA_MODULE_API_VERSION_2_1]

This camera module version adds support for asynchronous callbacks to the framework from the camera HAL module, which is used to notify the framework about changes to the camera module state. Modules that provide a valid set_callbacks() method must report at least this version number.

Version: 2.2 [CAMERA_MODULE_API_VERSION_2_2]

This camera module version adds vendor tag support from the module, and deprecates the old vendor_tag_query_ops that were previously only accessible with a device open.

Version: 2.3 [CAMERA_MODULE_API_VERSION_2_3]

This camera module version adds open legacy camera HAL device support. Framework can use it to open the camera device as lower device HAL version HAL device if the same device can support multiple device API versions. The standard hardware module open call (common.methods->open) continues to open the camera device with the latest supported version, which is also the version listed in camera_info_t.device_version. Predefined macros for currently-defined version numbers All module versions <= HARDWARE_MODULE_API_VERSION(1, 0xFF) must be treated as CAMERA_MODULE_API_VERSION_1_0

Callback functions for the camera HAL module to use to inform the framework of changes to the camera subsystem. These are called only by HAL modules implementing version CAMERA_MODULE_API_VERSION_2_1 or higher of the HAL module API interface.

The camera device is not currently connected, and opening it will return failure. Calls to get_camera_info must still succeed, and provide the same information it would if the camera were connected

CAMERA_DEVICE_STATUS_PRESENT

The camera device is connected, and opening it will succeed. The information returned by get_camera_info cannot change due to this status change. By default, the framework will assume all devices are in this state.

CAMERA_DEVICE_STATUS_ENUMERATING

The camera device is connected, but it is undergoing an enumeration and so opening the device will return -EBUSY. Calls to get_camera_info must still succeed, as if the camera was in the PRESENT status.