Skip to content

Commit

Permalink
Migrate to camera-viewfinder-compose in CameraX (#106)
Browse files Browse the repository at this point in the history
* Migrate to camera-viewfinder-compose in CameraX

 * Removes mirror of camera-viewfinder-compose and replaces
   it with a dependency on the CameraX artifact

 * Adds @composable adapter, CameraXViewfinder, that connects
   CameraX's Preview use case to Viewfinder

 * Removes tao-to-focus code as we no longer can retrieve
   the View from the composable. This code will need to be
   replaced by touch event callbacks that will be added to
   the Viewfinder composable in a future update.

* Apply spotless for copyright headers
  • Loading branch information
temcguir authored Feb 9, 2024
1 parent 2912d9f commit de4019c
Show file tree
Hide file tree
Showing 11 changed files with 138 additions and 289 deletions.
1 change: 0 additions & 1 deletion camera-viewfinder-compose/.gitignore

This file was deleted.

Empty file.
21 changes: 0 additions & 21 deletions camera-viewfinder-compose/proguard-rules.pro

This file was deleted.

19 changes: 0 additions & 19 deletions camera-viewfinder-compose/src/main/AndroidManifest.xml

This file was deleted.

This file was deleted.

3 changes: 1 addition & 2 deletions domain/camera/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2023 The Android Open Source Project
* Copyright (C) 2023-2024 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -68,7 +68,6 @@ dependencies {
implementation(libs.camera.lifecycle)
implementation(libs.camera.video)

implementation(libs.camera.view)
implementation(libs.camera.extensions)

// Hilt
Expand Down
5 changes: 2 additions & 3 deletions feature/preview/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2023 The Android Open Source Project
* Copyright (C) 2023-2024 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -101,7 +101,7 @@ dependencies {

// CameraX
implementation(libs.camera.core)
implementation(libs.camera.view)
implementation(libs.camera.viewfinder.compose)

// Hilt
implementation(libs.dagger.hilt.android)
Expand All @@ -113,7 +113,6 @@ dependencies {
// Project dependencies
implementation(project(":data:settings"))
implementation(project(":domain:camera"))
implementation(project(":camera-viewfinder-compose"))
implementation(project(":feature:quicksettings"))
}

Expand Down
Loading

0 comments on commit de4019c

Please sign in to comment.