camera2: Rename CameraProperties to CameraCharacteristics
Bug: 10360518
Change-Id: I725d0e5c2d1d40828bf40b809107fff693ca6d30
diff --git a/tests/tests/hardware/src/android/hardware/camera2/cts/CameraPropertiesTest.java b/tests/tests/hardware/src/android/hardware/camera2/cts/CameraCharacteristicsTest.java
similarity index 74%
rename from tests/tests/hardware/src/android/hardware/camera2/cts/CameraPropertiesTest.java
rename to tests/tests/hardware/src/android/hardware/camera2/cts/CameraCharacteristicsTest.java
index 6a402de..2241568 100644
--- a/tests/tests/hardware/src/android/hardware/camera2/cts/CameraPropertiesTest.java
+++ b/tests/tests/hardware/src/android/hardware/camera2/cts/CameraCharacteristicsTest.java
@@ -17,24 +17,24 @@
/**
* ! Do not edit this file directly !
*
- * Generated automatically from system/media/camera/docs/CameraPropertiesTest.mako.
- * This file contains only the auto-generated CameraProperties CTS tests; it does
+ * Generated automatically from system/media/camera/docs/CameraCharacteristicsTest.mako.
+ * This file contains only the auto-generated CameraCharacteristics CTS tests; it does
* not contain any additional manual tests, which would be in a separate file.
*/
package android.hardware.camera2.cts;
import android.content.Context;
+import android.hardware.camera2.CameraCharacteristics;
import android.hardware.camera2.CameraDevice;
import android.hardware.camera2.CameraManager;
-import android.hardware.camera2.CameraProperties;
import android.os.Handler;
import android.test.AndroidTestCase;
/**
- * Auto-generated CTS test for CameraProperties fields.
+ * Auto-generated CTS test for CameraCharacteristics fields.
*/
-public class CameraPropertiesTest extends AndroidTestCase {
+public class CameraCharacteristicsTest extends AndroidTestCase {
private CameraManager mCameraManager;
private CameraTestThread mLooperThread;
@@ -63,12 +63,12 @@
super.tearDown();
}
- public void testCameraPropertiesAndroidControlAeAvailableAntibandingModes() throws Exception {
+ public void testCameraCharacteristicsAndroidControlAeAvailableAntibandingModes() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -78,16 +78,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.control.aeAvailableAntibandingModes",
- props.get(CameraProperties.CONTROL_AE_AVAILABLE_ANTIBANDING_MODES));
+ props.get(CameraCharacteristics.CONTROL_AE_AVAILABLE_ANTIBANDING_MODES));
}
}
- public void testCameraPropertiesAndroidControlAeAvailableTargetFpsRanges() throws Exception {
+ public void testCameraCharacteristicsAndroidControlAeAvailableTargetFpsRanges() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -97,16 +97,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.control.aeAvailableTargetFpsRanges",
- props.get(CameraProperties.CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES));
+ props.get(CameraCharacteristics.CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES));
}
}
- public void testCameraPropertiesAndroidControlAeCompensationRange() throws Exception {
+ public void testCameraCharacteristicsAndroidControlAeCompensationRange() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -116,16 +116,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.control.aeCompensationRange",
- props.get(CameraProperties.CONTROL_AE_COMPENSATION_RANGE));
+ props.get(CameraCharacteristics.CONTROL_AE_COMPENSATION_RANGE));
}
}
- public void testCameraPropertiesAndroidControlAeCompensationStep() throws Exception {
+ public void testCameraCharacteristicsAndroidControlAeCompensationStep() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -135,16 +135,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.control.aeCompensationStep",
- props.get(CameraProperties.CONTROL_AE_COMPENSATION_STEP));
+ props.get(CameraCharacteristics.CONTROL_AE_COMPENSATION_STEP));
}
}
- public void testCameraPropertiesAndroidControlAfAvailableModes() throws Exception {
+ public void testCameraCharacteristicsAndroidControlAfAvailableModes() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -154,16 +154,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.control.afAvailableModes",
- props.get(CameraProperties.CONTROL_AF_AVAILABLE_MODES));
+ props.get(CameraCharacteristics.CONTROL_AF_AVAILABLE_MODES));
}
}
- public void testCameraPropertiesAndroidControlAvailableEffects() throws Exception {
+ public void testCameraCharacteristicsAndroidControlAvailableEffects() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -173,16 +173,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.control.availableEffects",
- props.get(CameraProperties.CONTROL_AVAILABLE_EFFECTS));
+ props.get(CameraCharacteristics.CONTROL_AVAILABLE_EFFECTS));
}
}
- public void testCameraPropertiesAndroidControlAvailableSceneModes() throws Exception {
+ public void testCameraCharacteristicsAndroidControlAvailableSceneModes() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -192,16 +192,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.control.availableSceneModes",
- props.get(CameraProperties.CONTROL_AVAILABLE_SCENE_MODES));
+ props.get(CameraCharacteristics.CONTROL_AVAILABLE_SCENE_MODES));
}
}
- public void testCameraPropertiesAndroidControlAvailableVideoStabilizationModes() throws Exception {
+ public void testCameraCharacteristicsAndroidControlAvailableVideoStabilizationModes() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -211,16 +211,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.control.availableVideoStabilizationModes",
- props.get(CameraProperties.CONTROL_AVAILABLE_VIDEO_STABILIZATION_MODES));
+ props.get(CameraCharacteristics.CONTROL_AVAILABLE_VIDEO_STABILIZATION_MODES));
}
}
- public void testCameraPropertiesAndroidControlAwbAvailableModes() throws Exception {
+ public void testCameraCharacteristicsAndroidControlAwbAvailableModes() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -230,16 +230,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.control.awbAvailableModes",
- props.get(CameraProperties.CONTROL_AWB_AVAILABLE_MODES));
+ props.get(CameraCharacteristics.CONTROL_AWB_AVAILABLE_MODES));
}
}
- public void testCameraPropertiesAndroidControlMaxRegions() throws Exception {
+ public void testCameraCharacteristicsAndroidControlMaxRegions() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -249,16 +249,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.control.maxRegions",
- props.get(CameraProperties.CONTROL_MAX_REGIONS));
+ props.get(CameraCharacteristics.CONTROL_MAX_REGIONS));
}
}
- public void testCameraPropertiesAndroidFlashInfoAvailable() throws Exception {
+ public void testCameraCharacteristicsAndroidFlashInfoAvailable() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -268,16 +268,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.flash.info.available",
- props.get(CameraProperties.FLASH_INFO_AVAILABLE));
+ props.get(CameraCharacteristics.FLASH_INFO_AVAILABLE));
}
}
- public void testCameraPropertiesAndroidJpegAvailableThumbnailSizes() throws Exception {
+ public void testCameraCharacteristicsAndroidJpegAvailableThumbnailSizes() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -287,16 +287,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.jpeg.availableThumbnailSizes",
- props.get(CameraProperties.JPEG_AVAILABLE_THUMBNAIL_SIZES));
+ props.get(CameraCharacteristics.JPEG_AVAILABLE_THUMBNAIL_SIZES));
}
}
- public void testCameraPropertiesAndroidLensFacing() throws Exception {
+ public void testCameraCharacteristicsAndroidLensFacing() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -306,16 +306,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.lens.facing",
- props.get(CameraProperties.LENS_FACING));
+ props.get(CameraCharacteristics.LENS_FACING));
}
}
- public void testCameraPropertiesAndroidLensInfoAvailableApertures() throws Exception {
+ public void testCameraCharacteristicsAndroidLensInfoAvailableApertures() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -325,16 +325,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.lens.info.availableApertures",
- props.get(CameraProperties.LENS_INFO_AVAILABLE_APERTURES));
+ props.get(CameraCharacteristics.LENS_INFO_AVAILABLE_APERTURES));
}
}
- public void testCameraPropertiesAndroidLensInfoAvailableFilterDensities() throws Exception {
+ public void testCameraCharacteristicsAndroidLensInfoAvailableFilterDensities() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -344,16 +344,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.lens.info.availableFilterDensities",
- props.get(CameraProperties.LENS_INFO_AVAILABLE_FILTER_DENSITIES));
+ props.get(CameraCharacteristics.LENS_INFO_AVAILABLE_FILTER_DENSITIES));
}
}
- public void testCameraPropertiesAndroidLensInfoAvailableFocalLengths() throws Exception {
+ public void testCameraCharacteristicsAndroidLensInfoAvailableFocalLengths() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -363,16 +363,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.lens.info.availableFocalLengths",
- props.get(CameraProperties.LENS_INFO_AVAILABLE_FOCAL_LENGTHS));
+ props.get(CameraCharacteristics.LENS_INFO_AVAILABLE_FOCAL_LENGTHS));
}
}
- public void testCameraPropertiesAndroidLensInfoAvailableOpticalStabilization() throws Exception {
+ public void testCameraCharacteristicsAndroidLensInfoAvailableOpticalStabilization() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -382,16 +382,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.lens.info.availableOpticalStabilization",
- props.get(CameraProperties.LENS_INFO_AVAILABLE_OPTICAL_STABILIZATION));
+ props.get(CameraCharacteristics.LENS_INFO_AVAILABLE_OPTICAL_STABILIZATION));
}
}
- public void testCameraPropertiesAndroidLensInfoHyperfocalDistance() throws Exception {
+ public void testCameraCharacteristicsAndroidLensInfoHyperfocalDistance() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -401,16 +401,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.lens.info.hyperfocalDistance",
- props.get(CameraProperties.LENS_INFO_HYPERFOCAL_DISTANCE));
+ props.get(CameraCharacteristics.LENS_INFO_HYPERFOCAL_DISTANCE));
}
}
- public void testCameraPropertiesAndroidLensInfoMinimumFocusDistance() throws Exception {
+ public void testCameraCharacteristicsAndroidLensInfoMinimumFocusDistance() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -420,16 +420,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.lens.info.minimumFocusDistance",
- props.get(CameraProperties.LENS_INFO_MINIMUM_FOCUS_DISTANCE));
+ props.get(CameraCharacteristics.LENS_INFO_MINIMUM_FOCUS_DISTANCE));
}
}
- public void testCameraPropertiesAndroidLensInfoShadingMapSize() throws Exception {
+ public void testCameraCharacteristicsAndroidLensInfoShadingMapSize() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -439,16 +439,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.lens.info.shadingMapSize",
- props.get(CameraProperties.LENS_INFO_SHADING_MAP_SIZE));
+ props.get(CameraCharacteristics.LENS_INFO_SHADING_MAP_SIZE));
}
}
- public void testCameraPropertiesAndroidRequestMaxNumOutputStreams() throws Exception {
+ public void testCameraCharacteristicsAndroidRequestMaxNumOutputStreams() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -458,16 +458,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.request.maxNumOutputStreams",
- props.get(CameraProperties.REQUEST_MAX_NUM_OUTPUT_STREAMS));
+ props.get(CameraCharacteristics.REQUEST_MAX_NUM_OUTPUT_STREAMS));
}
}
- public void testCameraPropertiesAndroidScalerAvailableFormats() throws Exception {
+ public void testCameraCharacteristicsAndroidScalerAvailableFormats() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -477,16 +477,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.scaler.availableFormats",
- props.get(CameraProperties.SCALER_AVAILABLE_FORMATS));
+ props.get(CameraCharacteristics.SCALER_AVAILABLE_FORMATS));
}
}
- public void testCameraPropertiesAndroidScalerAvailableJpegMinDurations() throws Exception {
+ public void testCameraCharacteristicsAndroidScalerAvailableJpegMinDurations() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -496,16 +496,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.scaler.availableJpegMinDurations",
- props.get(CameraProperties.SCALER_AVAILABLE_JPEG_MIN_DURATIONS));
+ props.get(CameraCharacteristics.SCALER_AVAILABLE_JPEG_MIN_DURATIONS));
}
}
- public void testCameraPropertiesAndroidScalerAvailableJpegSizes() throws Exception {
+ public void testCameraCharacteristicsAndroidScalerAvailableJpegSizes() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -515,16 +515,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.scaler.availableJpegSizes",
- props.get(CameraProperties.SCALER_AVAILABLE_JPEG_SIZES));
+ props.get(CameraCharacteristics.SCALER_AVAILABLE_JPEG_SIZES));
}
}
- public void testCameraPropertiesAndroidScalerAvailableMaxDigitalZoom() throws Exception {
+ public void testCameraCharacteristicsAndroidScalerAvailableMaxDigitalZoom() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -534,16 +534,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.scaler.availableMaxDigitalZoom",
- props.get(CameraProperties.SCALER_AVAILABLE_MAX_DIGITAL_ZOOM));
+ props.get(CameraCharacteristics.SCALER_AVAILABLE_MAX_DIGITAL_ZOOM));
}
}
- public void testCameraPropertiesAndroidScalerAvailableProcessedMinDurations() throws Exception {
+ public void testCameraCharacteristicsAndroidScalerAvailableProcessedMinDurations() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -553,16 +553,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.scaler.availableProcessedMinDurations",
- props.get(CameraProperties.SCALER_AVAILABLE_PROCESSED_MIN_DURATIONS));
+ props.get(CameraCharacteristics.SCALER_AVAILABLE_PROCESSED_MIN_DURATIONS));
}
}
- public void testCameraPropertiesAndroidScalerAvailableProcessedSizes() throws Exception {
+ public void testCameraCharacteristicsAndroidScalerAvailableProcessedSizes() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -572,16 +572,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.scaler.availableProcessedSizes",
- props.get(CameraProperties.SCALER_AVAILABLE_PROCESSED_SIZES));
+ props.get(CameraCharacteristics.SCALER_AVAILABLE_PROCESSED_SIZES));
}
}
- public void testCameraPropertiesAndroidSensorBaseGainFactor() throws Exception {
+ public void testCameraCharacteristicsAndroidSensorBaseGainFactor() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -591,16 +591,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.sensor.baseGainFactor",
- props.get(CameraProperties.SENSOR_BASE_GAIN_FACTOR));
+ props.get(CameraCharacteristics.SENSOR_BASE_GAIN_FACTOR));
}
}
- public void testCameraPropertiesAndroidSensorMaxAnalogSensitivity() throws Exception {
+ public void testCameraCharacteristicsAndroidSensorMaxAnalogSensitivity() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -610,16 +610,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.sensor.maxAnalogSensitivity",
- props.get(CameraProperties.SENSOR_MAX_ANALOG_SENSITIVITY));
+ props.get(CameraCharacteristics.SENSOR_MAX_ANALOG_SENSITIVITY));
}
}
- public void testCameraPropertiesAndroidSensorOrientation() throws Exception {
+ public void testCameraCharacteristicsAndroidSensorOrientation() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -629,16 +629,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.sensor.orientation",
- props.get(CameraProperties.SENSOR_ORIENTATION));
+ props.get(CameraCharacteristics.SENSOR_ORIENTATION));
}
}
- public void testCameraPropertiesAndroidSensorInfoActiveArraySize() throws Exception {
+ public void testCameraCharacteristicsAndroidSensorInfoActiveArraySize() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -648,16 +648,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.sensor.info.activeArraySize",
- props.get(CameraProperties.SENSOR_INFO_ACTIVE_ARRAY_SIZE));
+ props.get(CameraCharacteristics.SENSOR_INFO_ACTIVE_ARRAY_SIZE));
}
}
- public void testCameraPropertiesAndroidSensorInfoSensitivityRange() throws Exception {
+ public void testCameraCharacteristicsAndroidSensorInfoSensitivityRange() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -667,16 +667,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.sensor.info.sensitivityRange",
- props.get(CameraProperties.SENSOR_INFO_SENSITIVITY_RANGE));
+ props.get(CameraCharacteristics.SENSOR_INFO_SENSITIVITY_RANGE));
}
}
- public void testCameraPropertiesAndroidSensorInfoExposureTimeRange() throws Exception {
+ public void testCameraCharacteristicsAndroidSensorInfoExposureTimeRange() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -686,16 +686,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.sensor.info.exposureTimeRange",
- props.get(CameraProperties.SENSOR_INFO_EXPOSURE_TIME_RANGE));
+ props.get(CameraCharacteristics.SENSOR_INFO_EXPOSURE_TIME_RANGE));
}
}
- public void testCameraPropertiesAndroidSensorInfoMaxFrameDuration() throws Exception {
+ public void testCameraCharacteristicsAndroidSensorInfoMaxFrameDuration() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -705,16 +705,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.sensor.info.maxFrameDuration",
- props.get(CameraProperties.SENSOR_INFO_MAX_FRAME_DURATION));
+ props.get(CameraCharacteristics.SENSOR_INFO_MAX_FRAME_DURATION));
}
}
- public void testCameraPropertiesAndroidSensorInfoPhysicalSize() throws Exception {
+ public void testCameraCharacteristicsAndroidSensorInfoPhysicalSize() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -724,16 +724,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.sensor.info.physicalSize",
- props.get(CameraProperties.SENSOR_INFO_PHYSICAL_SIZE));
+ props.get(CameraCharacteristics.SENSOR_INFO_PHYSICAL_SIZE));
}
}
- public void testCameraPropertiesAndroidStatisticsInfoAvailableFaceDetectModes() throws Exception {
+ public void testCameraCharacteristicsAndroidStatisticsInfoAvailableFaceDetectModes() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -743,16 +743,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.statistics.info.availableFaceDetectModes",
- props.get(CameraProperties.STATISTICS_INFO_AVAILABLE_FACE_DETECT_MODES));
+ props.get(CameraCharacteristics.STATISTICS_INFO_AVAILABLE_FACE_DETECT_MODES));
}
}
- public void testCameraPropertiesAndroidStatisticsInfoMaxFaceCount() throws Exception {
+ public void testCameraCharacteristicsAndroidStatisticsInfoMaxFaceCount() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -762,16 +762,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.statistics.info.maxFaceCount",
- props.get(CameraProperties.STATISTICS_INFO_MAX_FACE_COUNT));
+ props.get(CameraCharacteristics.STATISTICS_INFO_MAX_FACE_COUNT));
}
}
- public void testCameraPropertiesAndroidTonemapMaxCurvePoints() throws Exception {
+ public void testCameraCharacteristicsAndroidTonemapMaxCurvePoints() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -781,16 +781,16 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.tonemap.maxCurvePoints",
- props.get(CameraProperties.TONEMAP_MAX_CURVE_POINTS));
+ props.get(CameraCharacteristics.TONEMAP_MAX_CURVE_POINTS));
}
}
- public void testCameraPropertiesAndroidInfoSupportedHardwareLevel() throws Exception {
+ public void testCameraCharacteristicsAndroidInfoSupportedHardwareLevel() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull("Failed to open camera", camera);
- CameraProperties props;
+ CameraCharacteristics props;
try {
props = camera.getProperties();
}
@@ -800,7 +800,7 @@
assertNotNull(String.format("Can't get camera properties from: ID %s", ids[i]),
props);
assertNotNull("Invalid property: android.info.supportedHardwareLevel",
- props.get(CameraProperties.INFO_SUPPORTED_HARDWARE_LEVEL));
+ props.get(CameraCharacteristics.INFO_SUPPORTED_HARDWARE_LEVEL));
}
}
}
diff --git a/tests/tests/hardware/src/android/hardware/camera2/cts/CameraDeviceTest.java b/tests/tests/hardware/src/android/hardware/camera2/cts/CameraDeviceTest.java
index 98f0778..e65f90e 100644
--- a/tests/tests/hardware/src/android/hardware/camera2/cts/CameraDeviceTest.java
+++ b/tests/tests/hardware/src/android/hardware/camera2/cts/CameraDeviceTest.java
@@ -18,10 +18,10 @@
import android.content.Context;
import android.graphics.ImageFormat;
+import android.hardware.camera2.CameraCharacteristics;
import android.hardware.camera2.CameraDevice;
import android.hardware.camera2.CameraManager;
import android.hardware.camera2.CameraMetadata;
-import android.hardware.camera2.CameraProperties;
import android.hardware.camera2.CaptureFailure;
import android.hardware.camera2.CaptureRequest;
import android.hardware.camera2.CaptureResult;
@@ -232,7 +232,7 @@
/**
* Test: that the properties can be queried for this device.
*/
- CameraProperties props = camera.getProperties();
+ CameraCharacteristics props = camera.getProperties();
assertNotNull("Failed to get camera properties", props);
// TODO: Add more tests to check more fields.
diff --git a/tests/tests/hardware/src/android/hardware/camera2/cts/CameraManagerTest.java b/tests/tests/hardware/src/android/hardware/camera2/cts/CameraManagerTest.java
index 086a4f3..014b144 100644
--- a/tests/tests/hardware/src/android/hardware/camera2/cts/CameraManagerTest.java
+++ b/tests/tests/hardware/src/android/hardware/camera2/cts/CameraManagerTest.java
@@ -19,9 +19,9 @@
import android.content.Context;
import android.content.pm.PackageManager;
import android.hardware.camera2.CameraAccessException;
+import android.hardware.camera2.CameraCharacteristics;
import android.hardware.camera2.CameraDevice;
import android.hardware.camera2.CameraManager;
-import android.hardware.camera2.CameraProperties;
import android.os.Handler;
import android.test.AndroidTestCase;
import android.util.Log;
@@ -103,14 +103,14 @@
}
// Test: that properties can be queried from each device, without exceptions.
- public void testCameraManagerGetCameraProperties() throws Exception {
+ public void testCameraManagerGetCameraCharacteristics() throws Exception {
String[] ids = mCameraManager.getCameraIdList();
for (int i = 0; i < ids.length; i++) {
CameraDevice camera = CameraTestUtils.openCamera(mCameraManager, ids[i], mHandler);
assertNotNull(
String.format("Failed to open camera device ID: %s", ids[i]), camera);
try {
- CameraProperties props = camera.getProperties();
+ CameraCharacteristics props = camera.getProperties();
assertNotNull(
String.format("Can't get camera properties from: ID %s", ids[i]), props);
}
@@ -130,7 +130,7 @@
invalidId.append(ids[i]);
}
try {
- CameraProperties props = mCameraManager.getCameraProperties(
+ CameraCharacteristics props = mCameraManager.getCameraCharacteristics(
invalidId.toString());
fail(String.format("Accepted invalid camera ID: %s", invalidId.toString()));
}
diff --git a/tests/tests/hardware/src/android/hardware/camera2/cts/CameraTestUtils.java b/tests/tests/hardware/src/android/hardware/camera2/cts/CameraTestUtils.java
index 5c1ec91..a110ae9 100644
--- a/tests/tests/hardware/src/android/hardware/camera2/cts/CameraTestUtils.java
+++ b/tests/tests/hardware/src/android/hardware/camera2/cts/CameraTestUtils.java
@@ -21,7 +21,7 @@
import android.hardware.camera2.CameraDevice;
import android.hardware.camera2.CameraManager;
import android.hardware.camera2.CameraMetadata;
-import android.hardware.camera2.CameraProperties;
+import android.hardware.camera2.CameraCharacteristics;
import android.hardware.camera2.Size;
import android.media.Image;
import android.media.Image.Plane;
@@ -268,18 +268,18 @@
public static Size[] getSupportedSizeForFormat(int format, CameraDevice camera)
throws Exception {
CameraMetadata.Key<Size[]> key = null;
- CameraProperties properties = camera.getProperties();
+ CameraCharacteristics properties = camera.getProperties();
assertNotNull("Can't get camera properties!", properties);
switch (format) {
case ImageFormat.JPEG:
- key = CameraProperties.SCALER_AVAILABLE_JPEG_SIZES;
+ key = CameraCharacteristics.SCALER_AVAILABLE_JPEG_SIZES;
break;
case ImageFormat.YUV_420_888:
case ImageFormat.YV12:
case ImageFormat.NV21:
case ImageFormat.Y8:
case ImageFormat.Y16:
- key = CameraProperties.SCALER_AVAILABLE_PROCESSED_SIZES;
+ key = CameraCharacteristics.SCALER_AVAILABLE_PROCESSED_SIZES;
break;
default:
throw new UnsupportedOperationException(
diff --git a/tests/tests/hardware/src/android/hardware/camera2/cts/ImageReaderTest.java b/tests/tests/hardware/src/android/hardware/camera2/cts/ImageReaderTest.java
index a03f51b..112ca77 100644
--- a/tests/tests/hardware/src/android/hardware/camera2/cts/ImageReaderTest.java
+++ b/tests/tests/hardware/src/android/hardware/camera2/cts/ImageReaderTest.java
@@ -24,7 +24,7 @@
import android.hardware.camera2.CameraAccessException;
import android.hardware.camera2.CameraDevice;
import android.hardware.camera2.CameraManager;
-import android.hardware.camera2.CameraProperties;
+import android.hardware.camera2.CameraCharacteristics;
import android.hardware.camera2.CaptureRequest;
import android.hardware.camera2.Size;
import android.media.Image;
@@ -129,7 +129,7 @@
}
private void bufferFormatTestByCamera(int format, String cameraId) throws Exception {
- CameraProperties properties = mCamera.getProperties();
+ CameraCharacteristics properties = mCamera.getProperties();
assertNotNull("Can't get camera properties!", properties);
/**
@@ -141,7 +141,7 @@
*/
// Comment out below check to work around b/10406212.
/*
- int[] availableFormats = properties.get(CameraProperties.SCALER_AVAILABLE_FORMATS);
+ int[] availableFormats = properties.get(CameraCharacteristics.SCALER_AVAILABLE_FORMATS);
assertArrayNotEmpty(availableFormats,
"availableFormats should not be empty");
Arrays.sort(availableFormats);