CameraX is an addition to Android Jetpack that makes it easier to add camera capabilities to your app. The library provides a number of compatibility fixes and workarounds to help make the developer experience consistent across many devices.

For information on how to use the CameraX library in your app or library, see CameraX Overview.

Declaring dependencies

To add a dependency on CameraX, you must add the Google Maven repository to your project. Read Google's Maven repository for more information.

Add the following to each module’s build.gradle file:

dependencies {
  // CameraX core library
  def camerax_version = "1.0.0-alpha01"
  implementation "$camerax_version"
  // If you want to use Camera2 extensions
  implementation "$camerax_version"

Version 1.0.0-alpha01

May 7, 2019 and are released. The commits included in this version are available here.