diff --git a/app/build.gradle.kts b/app/build.gradle.kts
index 9f889b10e..be7fcd1ed 100644
--- a/app/build.gradle.kts
+++ b/app/build.gradle.kts
@@ -134,6 +134,7 @@ dependencies {
androidTestImplementation(libs.truth)
androidTestImplementation(libs.testParameterInjector)
androidTestImplementation(project(":ui:components:capture"))
+ androidTestImplementation(project(":ui:debug"))
androidTestUtil(libs.androidx.orchestrator)
implementation(libs.androidx.core.ktx)
@@ -169,6 +170,7 @@ dependencies {
// capture components
implementation(project(":ui:components:capture"))
+ implementation(project(":ui:debug"))
// Low Light implementations
implementation(project(":core:camera:low-light-playservices"))
diff --git a/app/src/androidTest/java/com/google/jetpackcamera/DebugHideComponentsTest.kt b/app/src/androidTest/java/com/google/jetpackcamera/DebugHideComponentsTest.kt
index d908b2f56..ef29f97d0 100644
--- a/app/src/androidTest/java/com/google/jetpackcamera/DebugHideComponentsTest.kt
+++ b/app/src/androidTest/java/com/google/jetpackcamera/DebugHideComponentsTest.kt
@@ -25,14 +25,14 @@ import androidx.test.uiautomator.UiDevice
import com.google.common.truth.Truth.assertThat
import com.google.jetpackcamera.ui.components.capture.AMPLITUDE_HOT_TAG
import com.google.jetpackcamera.ui.components.capture.AMPLITUDE_NONE_TAG
-import com.google.jetpackcamera.ui.components.capture.BTN_DEBUG_HIDE_COMPONENTS_TAG
import com.google.jetpackcamera.ui.components.capture.CAPTURE_BUTTON
-import com.google.jetpackcamera.ui.components.capture.DEBUG_OVERLAY_BUTTON
import com.google.jetpackcamera.ui.components.capture.FLIP_CAMERA_BUTTON
-import com.google.jetpackcamera.ui.components.capture.LOGICAL_CAMERA_ID_TAG
-import com.google.jetpackcamera.ui.components.capture.PHYSICAL_CAMERA_ID_TAG
import com.google.jetpackcamera.ui.components.capture.ZOOM_BUTTON_ROW_TAG
-import com.google.jetpackcamera.ui.components.capture.ZOOM_RATIO_TAG
+import com.google.jetpackcamera.ui.debug.BTN_DEBUG_HIDE_COMPONENTS_TAG
+import com.google.jetpackcamera.ui.debug.DEBUG_OVERLAY_BUTTON
+import com.google.jetpackcamera.ui.debug.LOGICAL_CAMERA_ID_TAG
+import com.google.jetpackcamera.ui.debug.PHYSICAL_CAMERA_ID_TAG
+import com.google.jetpackcamera.ui.debug.ZOOM_RATIO_TAG
import com.google.jetpackcamera.utils.TEST_REQUIRED_PERMISSIONS
import com.google.jetpackcamera.utils.debugExtra
import com.google.jetpackcamera.utils.runMainActivityScenarioTest
diff --git a/app/src/androidTest/java/com/google/jetpackcamera/FocusMeteringTest.kt b/app/src/androidTest/java/com/google/jetpackcamera/FocusMeteringTest.kt
index f72ebbd16..311fb3ecf 100644
--- a/app/src/androidTest/java/com/google/jetpackcamera/FocusMeteringTest.kt
+++ b/app/src/androidTest/java/com/google/jetpackcamera/FocusMeteringTest.kt
@@ -25,10 +25,10 @@ import androidx.compose.ui.test.performClick
import androidx.compose.ui.test.performTouchInput
import androidx.test.ext.junit.runners.AndroidJUnit4
import androidx.test.rule.GrantPermissionRule
-import com.google.jetpackcamera.ui.components.capture.BTN_DEBUG_HIDE_COMPONENTS_TAG
import com.google.jetpackcamera.ui.components.capture.CAPTURE_BUTTON
import com.google.jetpackcamera.ui.components.capture.FOCUS_METERING_INDICATOR_TAG
import com.google.jetpackcamera.ui.components.capture.PREVIEW_DISPLAY
+import com.google.jetpackcamera.ui.debug.BTN_DEBUG_HIDE_COMPONENTS_TAG
import com.google.jetpackcamera.utils.FOCUS_METERING_INDICATOR_TIMEOUT_MILLIS
import com.google.jetpackcamera.utils.TEST_REQUIRED_PERMISSIONS
import com.google.jetpackcamera.utils.debugExtra
diff --git a/app/src/androidTest/java/com/google/jetpackcamera/utils/ComposeTestRuleExt.kt b/app/src/androidTest/java/com/google/jetpackcamera/utils/ComposeTestRuleExt.kt
index 2575e2566..42fe89a1c 100644
--- a/app/src/androidTest/java/com/google/jetpackcamera/utils/ComposeTestRuleExt.kt
+++ b/app/src/androidTest/java/com/google/jetpackcamera/utils/ComposeTestRuleExt.kt
@@ -31,6 +31,7 @@ import androidx.compose.ui.test.isDisplayed
import androidx.compose.ui.test.isEnabled
import androidx.compose.ui.test.isNotDisplayed
import androidx.compose.ui.test.junit4.ComposeTestRule
+import androidx.compose.ui.test.onAllNodesWithTag
import androidx.compose.ui.test.onNodeWithContentDescription
import androidx.compose.ui.test.onNodeWithTag
import androidx.compose.ui.test.onNodeWithText
diff --git a/feature/preview/build.gradle.kts b/feature/preview/build.gradle.kts
index badeea6bb..8f1ac7d69 100644
--- a/feature/preview/build.gradle.kts
+++ b/feature/preview/build.gradle.kts
@@ -151,7 +151,7 @@ dependencies {
implementation(project(":ui:uistate:capture"))
implementation(project(":ui:uistateadapter"))
implementation(project(":ui:uistateadapter:capture"))
-
+ implementation(project(":ui:debug"))
}
// Allow references to generated code
diff --git a/feature/preview/src/main/java/com/google/jetpackcamera/feature/preview/PreviewScreen.kt b/feature/preview/src/main/java/com/google/jetpackcamera/feature/preview/PreviewScreen.kt
index 90cfbe02a..dfb2beac1 100644
--- a/feature/preview/src/main/java/com/google/jetpackcamera/feature/preview/PreviewScreen.kt
+++ b/feature/preview/src/main/java/com/google/jetpackcamera/feature/preview/PreviewScreen.kt
@@ -91,7 +91,6 @@ import com.google.jetpackcamera.ui.components.capture.VideoQualityIcon
import com.google.jetpackcamera.ui.components.capture.ZoomButtonRow
import com.google.jetpackcamera.ui.components.capture.ZoomStateManager
import com.google.jetpackcamera.ui.components.capture.debouncedOrientationFlow
-import com.google.jetpackcamera.ui.components.capture.debug.DebugOverlay
import com.google.jetpackcamera.ui.components.capture.quicksettings.QuickSettingsBottomSheet
import com.google.jetpackcamera.ui.components.capture.quicksettings.ui.FlashModeIndicator
import com.google.jetpackcamera.ui.components.capture.quicksettings.ui.HdrIndicator
@@ -101,13 +100,14 @@ import com.google.jetpackcamera.ui.controller.CaptureController
import com.google.jetpackcamera.ui.controller.ImageWellController
import com.google.jetpackcamera.ui.controller.ScreenFlashController
import com.google.jetpackcamera.ui.controller.SnackBarController
-import com.google.jetpackcamera.ui.controller.debug.DebugController
import com.google.jetpackcamera.ui.controller.quicksettings.QuickSettingsController
+import com.google.jetpackcamera.ui.debug.DebugController
+import com.google.jetpackcamera.ui.debug.DebugOverlay
+import com.google.jetpackcamera.ui.debug.DebugUiState
import com.google.jetpackcamera.ui.uistate.SnackBarUiState
import com.google.jetpackcamera.ui.uistate.capture.AudioUiState
import com.google.jetpackcamera.ui.uistate.capture.CaptureButtonUiState
import com.google.jetpackcamera.ui.uistate.capture.CaptureModeToggleUiState
-import com.google.jetpackcamera.ui.uistate.capture.DebugUiState
import com.google.jetpackcamera.ui.uistate.capture.FlipLensUiState
import com.google.jetpackcamera.ui.uistate.capture.ImageWellUiState
import com.google.jetpackcamera.ui.uistate.capture.ScreenFlashUiState
diff --git a/feature/preview/src/main/java/com/google/jetpackcamera/feature/preview/PreviewViewModel.kt b/feature/preview/src/main/java/com/google/jetpackcamera/feature/preview/PreviewViewModel.kt
index 6e5940277..7e1909e81 100644
--- a/feature/preview/src/main/java/com/google/jetpackcamera/feature/preview/PreviewViewModel.kt
+++ b/feature/preview/src/main/java/com/google/jetpackcamera/feature/preview/PreviewViewModel.kt
@@ -48,23 +48,23 @@ import com.google.jetpackcamera.ui.controller.ImageWellController
import com.google.jetpackcamera.ui.controller.ScreenFlashController
import com.google.jetpackcamera.ui.controller.SnackBarController
import com.google.jetpackcamera.ui.controller.ZoomController
-import com.google.jetpackcamera.ui.controller.debug.DebugController
import com.google.jetpackcamera.ui.controller.impl.CameraControllerImpl
import com.google.jetpackcamera.ui.controller.impl.CaptureControllerImpl
-import com.google.jetpackcamera.ui.controller.impl.DebugControllerImpl
import com.google.jetpackcamera.ui.controller.impl.ImageWellControllerImpl
import com.google.jetpackcamera.ui.controller.impl.QuickSettingsControllerImpl
import com.google.jetpackcamera.ui.controller.impl.ScreenFlashControllerImpl
import com.google.jetpackcamera.ui.controller.impl.SnackBarControllerImpl
import com.google.jetpackcamera.ui.controller.impl.ZoomControllerImpl
import com.google.jetpackcamera.ui.controller.quicksettings.QuickSettingsController
+import com.google.jetpackcamera.ui.debug.DebugController
+import com.google.jetpackcamera.ui.debug.DebugControllerImpl
+import com.google.jetpackcamera.ui.debug.DebugUiState
+import com.google.jetpackcamera.ui.debug.debugUiState
import com.google.jetpackcamera.ui.uistate.SnackBarUiState
import com.google.jetpackcamera.ui.uistate.SnackbarData
-import com.google.jetpackcamera.ui.uistate.capture.DebugUiState
import com.google.jetpackcamera.ui.uistate.capture.TrackedCaptureUiState
import com.google.jetpackcamera.ui.uistate.capture.compound.CaptureUiState
import com.google.jetpackcamera.ui.uistateadapter.capture.compound.captureUiState
-import com.google.jetpackcamera.ui.uistateadapter.capture.debugUiState
import dagger.hilt.android.lifecycle.HiltViewModel
import javax.inject.Inject
import kotlinx.coroutines.Deferred
diff --git a/settings.gradle.kts b/settings.gradle.kts
index f04820411..0e35b85ca 100644
--- a/settings.gradle.kts
+++ b/settings.gradle.kts
@@ -64,3 +64,6 @@ include(":core:camera:postprocess")
include(":ui:controller")
include(":ui:controller:impl")
include(":ui:controller:testing")
+include(":ui:debug")
+include(":ui:debug:testing")
+
diff --git a/ui/components/capture/src/main/java/com/google/jetpackcamera/ui/components/capture/TestTags.kt b/ui/components/capture/src/main/java/com/google/jetpackcamera/ui/components/capture/TestTags.kt
index d9cdfc25a..0222856f0 100644
--- a/ui/components/capture/src/main/java/com/google/jetpackcamera/ui/components/capture/TestTags.kt
+++ b/ui/components/capture/src/main/java/com/google/jetpackcamera/ui/components/capture/TestTags.kt
@@ -52,20 +52,8 @@ const val ZOOM_BUTTON_5_TAG = "ZoomButton5Tag"
// debug component tags
-const val ZOOM_RATIO_TAG = "ZoomRatioTag"
-const val LOGICAL_CAMERA_ID_TAG = "LogicalCameraIdTag"
-const val PHYSICAL_CAMERA_ID_TAG = "PhysicalCameraIdTag"
const val ELAPSED_TIME_TAG = "ElapsedTimeTag"
const val VIDEO_QUALITY_TAG = "VideoQualityTag"
-const val DEBUG_OVERLAY_BUTTON = "DebugOverlayButton"
-
-const val BTN_DEBUG_HIDE_COMPONENTS_TAG = "btn_debug_hide_components"
-const val DEBUG_OVERLAY_SHOW_CAMERA_PROPERTIES_BUTTON = "DebugOverlayShowCameraPropertiesButton"
-const val DEBUG_OVERLAY_SET_ZOOM_RATIO_BUTTON = "DebugOverlaySetZoomRatioButton"
-const val DEBUG_OVERLAY_CAMERA_PROPERTIES_TAG = "DebugOverlayCameraPropertiesTag"
-const val DEBUG_OVERLAY_SET_ZOOM_RATIO_TEXT_FIELD = "DebugOverlaySetZoomRatioTextField"
-const val DEBUG_OVERLAY_SET_ZOOM_RATIO_SET_BUTTON = "DebugOverlaySetZoomRatioSetButton"
-const val DEBUG_OVERLAY_VIDEO_RESOLUTION_TAG = "DebugOverlayVideoResolutionTag"
// quick settings tags
// todo(kc): rename quick_settings_drop_down to something more appropriate?
diff --git a/ui/components/capture/src/main/res/values/strings.xml b/ui/components/capture/src/main/res/values/strings.xml
index f85c8d88b..2aa412658 100644
--- a/ui/components/capture/src/main/res/values/strings.xml
+++ b/ui/components/capture/src/main/res/values/strings.xml
@@ -32,13 +32,7 @@
%1$.2fx
-
- Physical ID:
- Logical ID:
- Debug
- Hiding components
- Displaying components
diff --git a/ui/debug/build.gradle.kts b/ui/debug/build.gradle.kts
new file mode 100644
index 000000000..01b81f8d5
--- /dev/null
+++ b/ui/debug/build.gradle.kts
@@ -0,0 +1,91 @@
+/*
+ * Copyright (C) 2026 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.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+plugins {
+ alias(libs.plugins.android.library)
+ alias(libs.plugins.kotlin.android)
+ alias(libs.plugins.kotlin.kapt)
+ alias(libs.plugins.compose.compiler)
+}
+
+android {
+ namespace = "com.google.jetpackcamera.ui.debug"
+ compileSdk = libs.versions.compileSdk.get().toInt()
+
+ defaultConfig {
+ minSdk = libs.versions.minSdk.get().toInt()
+ testOptions.targetSdk = libs.versions.targetSdk.get().toInt()
+ lint.targetSdk = libs.versions.targetSdk.get().toInt()
+
+ testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
+ }
+
+ flavorDimensions += "flavor"
+ productFlavors {
+ create("stable") {
+ dimension = "flavor"
+ isDefault = true
+ }
+ }
+
+ compileOptions {
+ sourceCompatibility = JavaVersion.VERSION_17
+ targetCompatibility = JavaVersion.VERSION_17
+ }
+ kotlin {
+ jvmToolchain(17)
+ }
+ buildFeatures {
+ buildConfig = true
+ compose = true
+ }
+}
+
+dependencies {
+ // Compose
+ val composeBom = platform(libs.compose.bom)
+ implementation(composeBom)
+
+ // Compose - Material Design 3
+ implementation(libs.compose.material3)
+
+ // Compose - Android Studio Preview support
+ implementation(libs.compose.ui.tooling.preview)
+ debugImplementation(libs.compose.ui.tooling)
+
+ // CameraX
+ implementation(libs.camera.core)
+
+ // Testing
+ testImplementation(libs.junit)
+ testImplementation(libs.truth)
+ androidTestImplementation(libs.truth)
+ androidTestImplementation(libs.androidx.junit)
+
+ implementation(libs.androidx.activity.compose)
+
+ implementation(project(":core:camera"))
+ implementation(project(":core:model"))
+ implementation(project(":core:common"))
+ implementation(project(":data:settings"))
+ implementation(project(":ui:uistate:capture"))
+ implementation(project(":ui:controller"))
+}
+
+// Allow references to generated code
+kapt {
+ correctErrorTypes = true
+}
diff --git a/ui/controller/src/main/java/com/google/jetpackcamera/ui/controller/debug/DebugController.kt b/ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugController.kt
similarity index 90%
rename from ui/controller/src/main/java/com/google/jetpackcamera/ui/controller/debug/DebugController.kt
rename to ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugController.kt
index 7099f6d69..38dddcf52 100644
--- a/ui/controller/src/main/java/com/google/jetpackcamera/ui/controller/debug/DebugController.kt
+++ b/ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugController.kt
@@ -13,12 +13,12 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package com.google.jetpackcamera.ui.controller.debug
+package com.google.jetpackcamera.ui.debug
import com.google.jetpackcamera.model.TestPattern
/**
- * Interface for controlling debug features.
+ * Interface contract for managing interactions with debug settings.
*/
interface DebugController {
/**
diff --git a/ui/controller/impl/src/main/java/com/google/jetpackcamera/ui/controller/impl/DebugControllerImpl.kt b/ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugControllerImpl.kt
similarity index 93%
rename from ui/controller/impl/src/main/java/com/google/jetpackcamera/ui/controller/impl/DebugControllerImpl.kt
rename to ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugControllerImpl.kt
index 8f45db17e..b2311f872 100644
--- a/ui/controller/impl/src/main/java/com/google/jetpackcamera/ui/controller/impl/DebugControllerImpl.kt
+++ b/ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugControllerImpl.kt
@@ -13,11 +13,10 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package com.google.jetpackcamera.ui.controller.impl
+package com.google.jetpackcamera.ui.debug
import com.google.jetpackcamera.core.camera.CameraSystem
import com.google.jetpackcamera.model.TestPattern
-import com.google.jetpackcamera.ui.controller.debug.DebugController
import com.google.jetpackcamera.ui.uistate.capture.TrackedCaptureUiState
import kotlinx.coroutines.flow.MutableStateFlow
import kotlinx.coroutines.flow.update
diff --git a/ui/components/capture/src/main/java/com/google/jetpackcamera/ui/components/capture/debug/DebugOverlayComponents.kt b/ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugOverlayComponents.kt
similarity index 92%
rename from ui/components/capture/src/main/java/com/google/jetpackcamera/ui/components/capture/debug/DebugOverlayComponents.kt
rename to ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugOverlayComponents.kt
index 8567c46aa..5b8fbfd04 100644
--- a/ui/components/capture/src/main/java/com/google/jetpackcamera/ui/components/capture/debug/DebugOverlayComponents.kt
+++ b/ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugOverlayComponents.kt
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package com.google.jetpackcamera.ui.components.capture.debug
+package com.google.jetpackcamera.ui.debug
import android.util.Log
import androidx.activity.compose.BackHandler
@@ -63,20 +63,6 @@ import androidx.compose.ui.text.input.KeyboardType
import androidx.compose.ui.unit.dp
import androidx.compose.ui.unit.sp
import com.google.jetpackcamera.model.TestPattern
-import com.google.jetpackcamera.ui.components.capture.BTN_DEBUG_HIDE_COMPONENTS_TAG
-import com.google.jetpackcamera.ui.components.capture.DEBUG_OVERLAY_BUTTON
-import com.google.jetpackcamera.ui.components.capture.DEBUG_OVERLAY_CAMERA_PROPERTIES_TAG
-import com.google.jetpackcamera.ui.components.capture.DEBUG_OVERLAY_SET_ZOOM_RATIO_BUTTON
-import com.google.jetpackcamera.ui.components.capture.DEBUG_OVERLAY_SET_ZOOM_RATIO_SET_BUTTON
-import com.google.jetpackcamera.ui.components.capture.DEBUG_OVERLAY_SET_ZOOM_RATIO_TEXT_FIELD
-import com.google.jetpackcamera.ui.components.capture.DEBUG_OVERLAY_SHOW_CAMERA_PROPERTIES_BUTTON
-import com.google.jetpackcamera.ui.components.capture.DEBUG_OVERLAY_VIDEO_RESOLUTION_TAG
-import com.google.jetpackcamera.ui.components.capture.LOGICAL_CAMERA_ID_TAG
-import com.google.jetpackcamera.ui.components.capture.PHYSICAL_CAMERA_ID_TAG
-import com.google.jetpackcamera.ui.components.capture.R
-import com.google.jetpackcamera.ui.components.capture.ZOOM_RATIO_TAG
-import com.google.jetpackcamera.ui.controller.debug.DebugController
-import com.google.jetpackcamera.ui.uistate.capture.DebugUiState
import kotlin.math.abs
private const val TAG = "DebugOverlayComponents"
@@ -113,7 +99,7 @@ private fun ZoomRatioText(modifier: Modifier = Modifier, primaryZoomRatio: Float
DebugTextBar(
modifier = modifier,
title = "Zoom Ratio: ",
- value = stringResource(id = R.string.zoom_ratio_text, primaryZoomRatio ?: 1f),
+ value = stringResource(id = R.string.debug_zoom_ratio_text, primaryZoomRatio ?: 1f),
tag = ZOOM_RATIO_TAG
)
}
diff --git a/ui/uistate/capture/src/main/java/com/google/jetpackcamera/ui/uistate/capture/DebugUiState.kt b/ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugUiState.kt
similarity index 98%
rename from ui/uistate/capture/src/main/java/com/google/jetpackcamera/ui/uistate/capture/DebugUiState.kt
rename to ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugUiState.kt
index 83b444434..ba06c55aa 100644
--- a/ui/uistate/capture/src/main/java/com/google/jetpackcamera/ui/uistate/capture/DebugUiState.kt
+++ b/ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugUiState.kt
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package com.google.jetpackcamera.ui.uistate.capture
+package com.google.jetpackcamera.ui.debug
import android.util.Size
import com.google.jetpackcamera.model.TestPattern
diff --git a/ui/uistateadapter/capture/src/main/java/com/google/jetpackcamera/ui/uistateadapter/capture/DebugUiStateAdapter.kt b/ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugUiStateAdapter.kt
similarity index 98%
rename from ui/uistateadapter/capture/src/main/java/com/google/jetpackcamera/ui/uistateadapter/capture/DebugUiStateAdapter.kt
rename to ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugUiStateAdapter.kt
index 57ff410dc..58b43d761 100644
--- a/ui/uistateadapter/capture/src/main/java/com/google/jetpackcamera/ui/uistateadapter/capture/DebugUiStateAdapter.kt
+++ b/ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/DebugUiStateAdapter.kt
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package com.google.jetpackcamera.ui.uistateadapter.capture
+package com.google.jetpackcamera.ui.debug
import android.util.Size
import com.google.jetpackcamera.core.camera.CameraState
@@ -25,7 +25,6 @@ import com.google.jetpackcamera.settings.ConstraintsRepository
import com.google.jetpackcamera.settings.model.CameraAppSettings
import com.google.jetpackcamera.settings.model.CameraSystemConstraints
import com.google.jetpackcamera.settings.model.forCurrentLens
-import com.google.jetpackcamera.ui.uistate.capture.DebugUiState
import com.google.jetpackcamera.ui.uistate.capture.TrackedCaptureUiState
import kotlinx.coroutines.flow.Flow
import kotlinx.coroutines.flow.MutableStateFlow
diff --git a/ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/TestTags.kt b/ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/TestTags.kt
new file mode 100644
index 000000000..a4edfcc2d
--- /dev/null
+++ b/ui/debug/src/main/java/com/google/jetpackcamera/ui/debug/TestTags.kt
@@ -0,0 +1,29 @@
+/*
+ * Copyright (C) 2026 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.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package com.google.jetpackcamera.ui.debug
+
+const val ZOOM_RATIO_TAG = "ZoomRatioTag"
+const val LOGICAL_CAMERA_ID_TAG = "LogicalCameraIdTag"
+const val PHYSICAL_CAMERA_ID_TAG = "PhysicalCameraIdTag"
+const val DEBUG_OVERLAY_BUTTON = "DebugOverlayButton"
+
+const val BTN_DEBUG_HIDE_COMPONENTS_TAG = "btn_debug_hide_components"
+const val DEBUG_OVERLAY_SHOW_CAMERA_PROPERTIES_BUTTON = "DebugOverlayShowCameraPropertiesButton"
+const val DEBUG_OVERLAY_SET_ZOOM_RATIO_BUTTON = "DebugOverlaySetZoomRatioButton"
+const val DEBUG_OVERLAY_CAMERA_PROPERTIES_TAG = "DebugOverlayCameraPropertiesTag"
+const val DEBUG_OVERLAY_SET_ZOOM_RATIO_TEXT_FIELD = "DebugOverlaySetZoomRatioTextField"
+const val DEBUG_OVERLAY_SET_ZOOM_RATIO_SET_BUTTON = "DebugOverlaySetZoomRatioSetButton"
+const val DEBUG_OVERLAY_VIDEO_RESOLUTION_TAG = "DebugOverlayVideoResolutionTag"
diff --git a/ui/components/capture/src/main/res/drawable/ic_visibility.xml b/ui/debug/src/main/res/drawable/ic_visibility.xml
similarity index 100%
rename from ui/components/capture/src/main/res/drawable/ic_visibility.xml
rename to ui/debug/src/main/res/drawable/ic_visibility.xml
diff --git a/ui/components/capture/src/main/res/drawable/ic_visibility_off.xml b/ui/debug/src/main/res/drawable/ic_visibility_off.xml
similarity index 100%
rename from ui/components/capture/src/main/res/drawable/ic_visibility_off.xml
rename to ui/debug/src/main/res/drawable/ic_visibility_off.xml
diff --git a/ui/debug/src/main/res/values/strings.xml b/ui/debug/src/main/res/values/strings.xml
new file mode 100644
index 000000000..775fb7aaf
--- /dev/null
+++ b/ui/debug/src/main/res/values/strings.xml
@@ -0,0 +1,25 @@
+
+
+
+
+ Physical ID:
+ Logical ID:
+ Debug
+ Hiding components
+ Displaying components
+ %1$.2fx
+
diff --git a/ui/debug/testing/build.gradle.kts b/ui/debug/testing/build.gradle.kts
new file mode 100644
index 000000000..4abe6a083
--- /dev/null
+++ b/ui/debug/testing/build.gradle.kts
@@ -0,0 +1,58 @@
+/*
+ * Copyright (C) 2026 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.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+plugins {
+ alias(libs.plugins.android.library)
+ alias(libs.plugins.kotlin.android)
+}
+
+android {
+ namespace = "com.google.jetpackcamera.ui.debug.testing"
+ compileSdk = libs.versions.compileSdk.get().toInt()
+
+ defaultConfig {
+ minSdk = libs.versions.minSdk.get().toInt()
+ testOptions.targetSdk = libs.versions.targetSdk.get().toInt()
+ lint.targetSdk = libs.versions.targetSdk.get().toInt()
+
+ testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner"
+ }
+
+ flavorDimensions += "flavor"
+ productFlavors {
+ create("stable") {
+ dimension = "flavor"
+ isDefault = true
+ }
+ }
+
+ compileOptions {
+ sourceCompatibility = JavaVersion.VERSION_17
+ targetCompatibility = JavaVersion.VERSION_17
+ }
+ kotlin {
+ jvmToolchain(17)
+ }
+}
+
+dependencies {
+ implementation(project(":ui:debug"))
+ implementation(project(":core:model"))
+
+ // Testing
+ testImplementation(libs.junit)
+ testImplementation(libs.truth)
+}
diff --git a/ui/debug/testing/src/main/AndroidManifest.xml b/ui/debug/testing/src/main/AndroidManifest.xml
new file mode 100644
index 000000000..57317bf89
--- /dev/null
+++ b/ui/debug/testing/src/main/AndroidManifest.xml
@@ -0,0 +1,18 @@
+
+
+
+
diff --git a/ui/controller/testing/src/main/java/com/google/jetpackcamera/ui/controller/testing/FakeDebugController.kt b/ui/debug/testing/src/main/java/com/google/jetpackcamera/ui/debug/FakeDebugController.kt
similarity index 92%
rename from ui/controller/testing/src/main/java/com/google/jetpackcamera/ui/controller/testing/FakeDebugController.kt
rename to ui/debug/testing/src/main/java/com/google/jetpackcamera/ui/debug/FakeDebugController.kt
index 4d8b427a5..76c5f7d25 100644
--- a/ui/controller/testing/src/main/java/com/google/jetpackcamera/ui/controller/testing/FakeDebugController.kt
+++ b/ui/debug/testing/src/main/java/com/google/jetpackcamera/ui/debug/FakeDebugController.kt
@@ -13,10 +13,9 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package com.google.jetpackcamera.ui.controller.testing
+package com.google.jetpackcamera.ui.debug
import com.google.jetpackcamera.model.TestPattern
-import com.google.jetpackcamera.ui.controller.debug.DebugController
/**
* A fake implementation of [DebugController] that allows for configuring actions for its methods.
diff --git a/ui/controller/testing/src/test/java/com/google/jetpackcamera/ui/controller/testing/FakeDebugControllerTest.kt b/ui/debug/testing/src/test/java/com/google/jetpackcamera/ui/debug/FakeDebugControllerTest.kt
similarity index 96%
rename from ui/controller/testing/src/test/java/com/google/jetpackcamera/ui/controller/testing/FakeDebugControllerTest.kt
rename to ui/debug/testing/src/test/java/com/google/jetpackcamera/ui/debug/FakeDebugControllerTest.kt
index 6f7aeded3..6ab4b053f 100644
--- a/ui/controller/testing/src/test/java/com/google/jetpackcamera/ui/controller/testing/FakeDebugControllerTest.kt
+++ b/ui/debug/testing/src/test/java/com/google/jetpackcamera/ui/debug/FakeDebugControllerTest.kt
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
-package com.google.jetpackcamera.ui.controller.testing
+package com.google.jetpackcamera.ui.debug
import com.google.common.truth.Truth.assertThat
import com.google.jetpackcamera.model.TestPattern