1 /* 2 * Copyright (C) 2013 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17 package android.hardware.camera2; 18 19 import android.annotation.NonNull; 20 import android.annotation.TestApi; 21 import android.compat.annotation.UnsupportedAppUsage; 22 import android.hardware.camera2.impl.CameraMetadataNative; 23 import android.hardware.camera2.impl.PublicKey; 24 import android.hardware.camera2.impl.SyntheticKey; 25 import android.util.Log; 26 27 import java.lang.reflect.Field; 28 import java.lang.reflect.Modifier; 29 import java.util.ArrayList; 30 import java.util.Arrays; 31 import java.util.Collections; 32 import java.util.List; 33 34 /** 35 * The base class for camera controls and information. 36 * 37 * <p> 38 * This class defines the basic key/value map used for querying for camera 39 * characteristics or capture results, and for setting camera request 40 * parameters. 41 * </p> 42 * 43 * <p> 44 * All instances of CameraMetadata are immutable. The list of keys with {@link #getKeys()} 45 * never changes, nor do the values returned by any key with {@code #get} throughout 46 * the lifetime of the object. 47 * </p> 48 * 49 * @see CameraDevice 50 * @see CameraManager 51 * @see CameraCharacteristics 52 **/ 53 public abstract class CameraMetadata<TKey> { 54 55 private static final String TAG = "CameraMetadataAb"; 56 private static final boolean DEBUG = false; 57 private CameraMetadataNative mNativeInstance = null; 58 59 /** 60 * Set a camera metadata field to a value. The field definitions can be 61 * found in {@link CameraCharacteristics}, {@link CaptureResult}, and 62 * {@link CaptureRequest}. 63 * 64 * @param key The metadata field to write. 65 * @param value The value to set the field to, which must be of a matching 66 * type to the key. 67 * 68 * @hide 69 */ CameraMetadata()70 protected CameraMetadata() { 71 } 72 73 /** 74 * Get a camera metadata field value. 75 * 76 * <p>The field definitions can be 77 * found in {@link CameraCharacteristics}, {@link CaptureResult}, and 78 * {@link CaptureRequest}.</p> 79 * 80 * <p>Querying the value for the same key more than once will return a value 81 * which is equal to the previous queried value.</p> 82 * 83 * @throws IllegalArgumentException if the key was not valid 84 * 85 * @param key The metadata field to read. 86 * @return The value of that key, or {@code null} if the field is not set. 87 * 88 * @hide 89 */ getProtected(TKey key)90 protected abstract <T> T getProtected(TKey key); 91 92 /** 93 * @hide 94 */ setNativeInstance(CameraMetadataNative nativeInstance)95 protected void setNativeInstance(CameraMetadataNative nativeInstance) { 96 mNativeInstance = nativeInstance; 97 } 98 99 /** 100 * Retrieves the native std::shared_ptr<CameraMetadata*>* as a Java long. 101 * Returns 0 if mNativeInstance is null. 102 * 103 * @hide 104 */ 105 @UnsupportedAppUsage(publicAlternatives = "This method is exposed for native " 106 + "{@code ACameraMetadata_fromCameraMetadata} in {@code libcamera2ndk}.") getNativeMetadataPtr()107 public long getNativeMetadataPtr() { 108 if (mNativeInstance == null) { 109 return 0; 110 } else { 111 return mNativeInstance.getMetadataPtr(); 112 } 113 } 114 115 /** 116 * Retrieves the CameraMetadataNative instance. 117 * 118 * @hide 119 */ getNativeMetadata()120 public CameraMetadataNative getNativeMetadata() { 121 return mNativeInstance; 122 } 123 124 /** 125 * @hide 126 */ getKeyClass()127 protected abstract Class<TKey> getKeyClass(); 128 129 /** 130 * Returns a list of the keys contained in this map. 131 * 132 * <p>The list returned is not modifiable, so any attempts to modify it will throw 133 * a {@code UnsupportedOperationException}.</p> 134 * 135 * <p>All values retrieved by a key from this list with {@code #get} are guaranteed to be 136 * non-{@code null}. Each key is only listed once in the list. The order of the keys 137 * is undefined.</p> 138 * 139 * @return List of the keys contained in this map. 140 */ 141 @SuppressWarnings("unchecked") 142 @NonNull getKeys()143 public List<TKey> getKeys() { 144 Class<CameraMetadata<TKey>> thisClass = (Class<CameraMetadata<TKey>>) getClass(); 145 return Collections.unmodifiableList( 146 getKeys(thisClass, getKeyClass(), this, /*filterTags*/null, 147 /*includeSynthetic*/ true)); 148 } 149 150 /** 151 * Return a list of all the Key<?> that are declared as a field inside of the class 152 * {@code type}. 153 * 154 * <p> 155 * Optionally, if {@code instance} is not null, then filter out any keys with null values. 156 * </p> 157 * 158 * <p> 159 * Optionally, if {@code filterTags} is not {@code null}, then filter out any keys 160 * whose native {@code tag} is not in {@code filterTags}. The {@code filterTags} array will be 161 * sorted as a side effect. 162 * {@code includeSynthetic} Includes public syntenthic fields by default. 163 * </p> 164 */ 165 /*package*/ @SuppressWarnings("unchecked") getKeys( Class<?> type, Class<TKey> keyClass, CameraMetadata<TKey> instance, int[] filterTags, boolean includeSynthetic)166 <TKey> ArrayList<TKey> getKeys( 167 Class<?> type, Class<TKey> keyClass, 168 CameraMetadata<TKey> instance, 169 int[] filterTags, boolean includeSynthetic) { 170 171 if (DEBUG) Log.v(TAG, "getKeysStatic for " + type); 172 173 // TotalCaptureResult does not have any of the keys on it, use CaptureResult instead 174 if (type.equals(TotalCaptureResult.class)) { 175 type = CaptureResult.class; 176 } 177 178 if (filterTags != null) { 179 Arrays.sort(filterTags); 180 } 181 182 ArrayList<TKey> keyList = new ArrayList<TKey>(); 183 184 Field[] fields = type.getDeclaredFields(); 185 for (Field field : fields) { 186 // Filter for Keys that are public 187 if (field.getType().isAssignableFrom(keyClass) && 188 (field.getModifiers() & Modifier.PUBLIC) != 0) { 189 190 TKey key; 191 try { 192 key = (TKey) field.get(instance); 193 } catch (IllegalAccessException e) { 194 throw new AssertionError("Can't get IllegalAccessException", e); 195 } catch (IllegalArgumentException e) { 196 throw new AssertionError("Can't get IllegalArgumentException", e); 197 } 198 199 if (instance == null || instance.getProtected(key) != null) { 200 if (shouldKeyBeAdded(key, field, filterTags, includeSynthetic)) { 201 keyList.add(key); 202 203 if (DEBUG) { 204 Log.v(TAG, "getKeysStatic - key was added - " + key); 205 } 206 } else if (DEBUG) { 207 Log.v(TAG, "getKeysStatic - key was filtered - " + key); 208 } 209 } 210 } 211 } 212 213 if (null == mNativeInstance) { 214 return keyList; 215 } 216 217 ArrayList<TKey> vendorKeys = mNativeInstance.getAllVendorKeys(keyClass); 218 219 if (vendorKeys != null) { 220 for (TKey k : vendorKeys) { 221 String keyName; 222 long vendorId; 223 if (k instanceof CaptureRequest.Key<?>) { 224 keyName = ((CaptureRequest.Key<?>) k).getName(); 225 vendorId = ((CaptureRequest.Key<?>) k).getVendorId(); 226 } else if (k instanceof CaptureResult.Key<?>) { 227 keyName = ((CaptureResult.Key<?>) k).getName(); 228 vendorId = ((CaptureResult.Key<?>) k).getVendorId(); 229 } else if (k instanceof CameraCharacteristics.Key<?>) { 230 keyName = ((CameraCharacteristics.Key<?>) k).getName(); 231 vendorId = ((CameraCharacteristics.Key<?>) k).getVendorId(); 232 } else { 233 continue; 234 } 235 236 237 if (filterTags != null && Arrays.binarySearch(filterTags, 238 CameraMetadataNative.getTag(keyName, vendorId)) < 0) { 239 // ignore vendor keys not in filterTags 240 continue; 241 } 242 if (instance == null || instance.getProtected(k) != null) { 243 keyList.add(k); 244 } 245 246 } 247 } 248 249 return keyList; 250 } 251 252 @SuppressWarnings("rawtypes") shouldKeyBeAdded(TKey key, Field field, int[] filterTags, boolean includeSynthetic)253 private static <TKey> boolean shouldKeyBeAdded(TKey key, Field field, int[] filterTags, 254 boolean includeSynthetic) { 255 if (key == null) { 256 throw new NullPointerException("key must not be null"); 257 } 258 259 CameraMetadataNative.Key nativeKey; 260 261 /* 262 * Get the native key from the public api key 263 */ 264 if (key instanceof CameraCharacteristics.Key) { 265 nativeKey = ((CameraCharacteristics.Key)key).getNativeKey(); 266 } else if (key instanceof CaptureResult.Key) { 267 nativeKey = ((CaptureResult.Key)key).getNativeKey(); 268 } else if (key instanceof CaptureRequest.Key) { 269 nativeKey = ((CaptureRequest.Key)key).getNativeKey(); 270 } else { 271 // Reject fields that aren't a key 272 throw new IllegalArgumentException("key type must be that of a metadata key"); 273 } 274 275 if (field.getAnnotation(PublicKey.class) == null) { 276 // Never expose @hide keys up to the API user 277 return false; 278 } 279 280 // No filtering necessary 281 if (filterTags == null) { 282 return true; 283 } 284 285 if (field.getAnnotation(SyntheticKey.class) != null) { 286 // This key is synthetic, so calling #getTag will throw IAE 287 288 return includeSynthetic; 289 } 290 291 /* 292 * Regular key: look up it's native tag and see if it's in filterTags 293 */ 294 295 int keyTag = nativeKey.getTag(); 296 297 // non-negative result is returned iff the value is in the array 298 return Arrays.binarySearch(filterTags, keyTag) >= 0; 299 } 300 301 /*@O~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~ 302 * The enum values below this point are generated from metadata 303 * definitions in /system/media/camera/docs. Do not modify by hand or 304 * modify the comment blocks at the start or end. 305 *~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~*/ 306 307 // 308 // Enumeration values for CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION 309 // 310 311 /** 312 * <p>The lens focus distance is not accurate, and the units used for 313 * {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance} do not correspond to any physical units.</p> 314 * <p>Setting the lens to the same focus distance on separate occasions may 315 * result in a different real focus distance, depending on factors such 316 * as the orientation of the device, the age of the focusing mechanism, 317 * and the device temperature. The focus distance value will still be 318 * in the range of <code>[0, {@link CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE android.lens.info.minimumFocusDistance}]</code>, where 0 319 * represents the farthest focus.</p> 320 * 321 * @see CaptureRequest#LENS_FOCUS_DISTANCE 322 * @see CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE 323 * @see CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION 324 */ 325 public static final int LENS_INFO_FOCUS_DISTANCE_CALIBRATION_UNCALIBRATED = 0; 326 327 /** 328 * <p>The lens focus distance is measured in diopters.</p> 329 * <p>However, setting the lens to the same focus distance 330 * on separate occasions may result in a different real 331 * focus distance, depending on factors such as the 332 * orientation of the device, the age of the focusing 333 * mechanism, and the device temperature.</p> 334 * @see CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION 335 */ 336 public static final int LENS_INFO_FOCUS_DISTANCE_CALIBRATION_APPROXIMATE = 1; 337 338 /** 339 * <p>The lens focus distance is measured in diopters, and 340 * is calibrated.</p> 341 * <p>The lens mechanism is calibrated so that setting the 342 * same focus distance is repeatable on multiple 343 * occasions with good accuracy, and the focus distance 344 * corresponds to the real physical distance to the plane 345 * of best focus.</p> 346 * @see CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION 347 */ 348 public static final int LENS_INFO_FOCUS_DISTANCE_CALIBRATION_CALIBRATED = 2; 349 350 // 351 // Enumeration values for CameraCharacteristics#LENS_FACING 352 // 353 354 /** 355 * <p>The camera device faces the same direction as the device's screen.</p> 356 * @see CameraCharacteristics#LENS_FACING 357 */ 358 public static final int LENS_FACING_FRONT = 0; 359 360 /** 361 * <p>The camera device faces the opposite direction as the device's screen.</p> 362 * @see CameraCharacteristics#LENS_FACING 363 */ 364 public static final int LENS_FACING_BACK = 1; 365 366 /** 367 * <p>The camera device is an external camera, and has no fixed facing relative to the 368 * device's screen.</p> 369 * @see CameraCharacteristics#LENS_FACING 370 */ 371 public static final int LENS_FACING_EXTERNAL = 2; 372 373 // 374 // Enumeration values for CameraCharacteristics#LENS_POSE_REFERENCE 375 // 376 377 /** 378 * <p>The value of {@link CameraCharacteristics#LENS_POSE_TRANSLATION android.lens.poseTranslation} is relative to the optical center of 379 * the largest camera device facing the same direction as this camera.</p> 380 * <p>This is the default value for API levels before Android P.</p> 381 * 382 * @see CameraCharacteristics#LENS_POSE_TRANSLATION 383 * @see CameraCharacteristics#LENS_POSE_REFERENCE 384 */ 385 public static final int LENS_POSE_REFERENCE_PRIMARY_CAMERA = 0; 386 387 /** 388 * <p>The value of {@link CameraCharacteristics#LENS_POSE_TRANSLATION android.lens.poseTranslation} is relative to the position of the 389 * primary gyroscope of this Android device.</p> 390 * 391 * @see CameraCharacteristics#LENS_POSE_TRANSLATION 392 * @see CameraCharacteristics#LENS_POSE_REFERENCE 393 */ 394 public static final int LENS_POSE_REFERENCE_GYROSCOPE = 1; 395 396 /** 397 * <p>The camera device cannot represent the values of {@link CameraCharacteristics#LENS_POSE_TRANSLATION android.lens.poseTranslation} 398 * and {@link CameraCharacteristics#LENS_POSE_ROTATION android.lens.poseRotation} accurately enough. One such example is a camera device 399 * on the cover of a foldable phone: in order to measure the pose translation and rotation, 400 * some kind of hinge position sensor would be needed.</p> 401 * <p>The value of {@link CameraCharacteristics#LENS_POSE_TRANSLATION android.lens.poseTranslation} must be all zeros, and 402 * {@link CameraCharacteristics#LENS_POSE_ROTATION android.lens.poseRotation} must be values matching its default facing.</p> 403 * 404 * @see CameraCharacteristics#LENS_POSE_ROTATION 405 * @see CameraCharacteristics#LENS_POSE_TRANSLATION 406 * @see CameraCharacteristics#LENS_POSE_REFERENCE 407 */ 408 public static final int LENS_POSE_REFERENCE_UNDEFINED = 2; 409 410 // 411 // Enumeration values for CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 412 // 413 414 /** 415 * <p>The minimal set of capabilities that every camera 416 * device (regardless of {@link CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL android.info.supportedHardwareLevel}) 417 * supports.</p> 418 * <p>This capability is listed by all normal devices, and 419 * indicates that the camera device has a feature set 420 * that's comparable to the baseline requirements for the 421 * older android.hardware.Camera API.</p> 422 * <p>Devices with the DEPTH_OUTPUT capability might not list this 423 * capability, indicating that they support only depth measurement, 424 * not standard color output.</p> 425 * 426 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL 427 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 428 */ 429 public static final int REQUEST_AVAILABLE_CAPABILITIES_BACKWARD_COMPATIBLE = 0; 430 431 /** 432 * <p>The camera device can be manually controlled (3A algorithms such 433 * as auto-exposure, and auto-focus can be bypassed). 434 * The camera device supports basic manual control of the sensor image 435 * acquisition related stages. This means the following controls are 436 * guaranteed to be supported:</p> 437 * <ul> 438 * <li>Manual frame duration control<ul> 439 * <li>{@link CaptureRequest#SENSOR_FRAME_DURATION android.sensor.frameDuration}</li> 440 * <li>{@link CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION android.sensor.info.maxFrameDuration}</li> 441 * </ul> 442 * </li> 443 * <li>Manual exposure control<ul> 444 * <li>{@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}</li> 445 * <li>{@link CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE android.sensor.info.exposureTimeRange}</li> 446 * </ul> 447 * </li> 448 * <li>Manual sensitivity control<ul> 449 * <li>{@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}</li> 450 * <li>{@link CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE android.sensor.info.sensitivityRange}</li> 451 * </ul> 452 * </li> 453 * <li>Manual lens control (if the lens is adjustable)<ul> 454 * <li>android.lens.*</li> 455 * </ul> 456 * </li> 457 * <li>Manual flash control (if a flash unit is present)<ul> 458 * <li>android.flash.*</li> 459 * </ul> 460 * </li> 461 * <li>Manual black level locking<ul> 462 * <li>{@link CaptureRequest#BLACK_LEVEL_LOCK android.blackLevel.lock}</li> 463 * </ul> 464 * </li> 465 * <li>Auto exposure lock<ul> 466 * <li>{@link CaptureRequest#CONTROL_AE_LOCK android.control.aeLock}</li> 467 * </ul> 468 * </li> 469 * </ul> 470 * <p>If any of the above 3A algorithms are enabled, then the camera 471 * device will accurately report the values applied by 3A in the 472 * result.</p> 473 * <p>A given camera device may also support additional manual sensor controls, 474 * but this capability only covers the above list of controls.</p> 475 * <p>If this is supported, {@link CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP android.scaler.streamConfigurationMap} will 476 * additionally return a min frame duration that is greater than 477 * zero for each supported size-format combination.</p> 478 * <p>For camera devices with LOGICAL_MULTI_CAMERA capability, when the underlying active 479 * physical camera switches, exposureTime, sensitivity, and lens properties may change 480 * even if AE/AF is locked. However, the overall auto exposure and auto focus experience 481 * for users will be consistent. Refer to LOGICAL_MULTI_CAMERA capability for details.</p> 482 * 483 * @see CaptureRequest#BLACK_LEVEL_LOCK 484 * @see CaptureRequest#CONTROL_AE_LOCK 485 * @see CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP 486 * @see CaptureRequest#SENSOR_EXPOSURE_TIME 487 * @see CaptureRequest#SENSOR_FRAME_DURATION 488 * @see CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE 489 * @see CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION 490 * @see CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE 491 * @see CaptureRequest#SENSOR_SENSITIVITY 492 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 493 */ 494 public static final int REQUEST_AVAILABLE_CAPABILITIES_MANUAL_SENSOR = 1; 495 496 /** 497 * <p>The camera device post-processing stages can be manually controlled. 498 * The camera device supports basic manual control of the image post-processing 499 * stages. This means the following controls are guaranteed to be supported:</p> 500 * <ul> 501 * <li> 502 * <p>Manual tonemap control</p> 503 * <ul> 504 * <li>{@link CaptureRequest#TONEMAP_CURVE android.tonemap.curve}</li> 505 * <li>{@link CaptureRequest#TONEMAP_MODE android.tonemap.mode}</li> 506 * <li>{@link CameraCharacteristics#TONEMAP_MAX_CURVE_POINTS android.tonemap.maxCurvePoints}</li> 507 * <li>{@link CaptureRequest#TONEMAP_GAMMA android.tonemap.gamma}</li> 508 * <li>{@link CaptureRequest#TONEMAP_PRESET_CURVE android.tonemap.presetCurve}</li> 509 * </ul> 510 * </li> 511 * <li> 512 * <p>Manual white balance control</p> 513 * <ul> 514 * <li>{@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}</li> 515 * <li>{@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains}</li> 516 * </ul> 517 * </li> 518 * <li>Manual lens shading map control<ul> 519 * <li>{@link CaptureRequest#SHADING_MODE android.shading.mode}</li> 520 * <li>{@link CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE android.statistics.lensShadingMapMode}</li> 521 * <li>android.statistics.lensShadingMap</li> 522 * <li>android.lens.info.shadingMapSize</li> 523 * </ul> 524 * </li> 525 * <li>Manual aberration correction control (if aberration correction is supported)<ul> 526 * <li>{@link CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE android.colorCorrection.aberrationMode}</li> 527 * <li>{@link CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES android.colorCorrection.availableAberrationModes}</li> 528 * </ul> 529 * </li> 530 * <li>Auto white balance lock<ul> 531 * <li>{@link CaptureRequest#CONTROL_AWB_LOCK android.control.awbLock}</li> 532 * </ul> 533 * </li> 534 * </ul> 535 * <p>If auto white balance is enabled, then the camera device 536 * will accurately report the values applied by AWB in the result.</p> 537 * <p>A given camera device may also support additional post-processing 538 * controls, but this capability only covers the above list of controls.</p> 539 * <p>For camera devices with LOGICAL_MULTI_CAMERA capability, when underlying active 540 * physical camera switches, tonemap, white balance, and shading map may change even if 541 * awb is locked. However, the overall post-processing experience for users will be 542 * consistent. Refer to LOGICAL_MULTI_CAMERA capability for details.</p> 543 * 544 * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE 545 * @see CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES 546 * @see CaptureRequest#COLOR_CORRECTION_GAINS 547 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM 548 * @see CaptureRequest#CONTROL_AWB_LOCK 549 * @see CaptureRequest#SHADING_MODE 550 * @see CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE 551 * @see CaptureRequest#TONEMAP_CURVE 552 * @see CaptureRequest#TONEMAP_GAMMA 553 * @see CameraCharacteristics#TONEMAP_MAX_CURVE_POINTS 554 * @see CaptureRequest#TONEMAP_MODE 555 * @see CaptureRequest#TONEMAP_PRESET_CURVE 556 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 557 */ 558 public static final int REQUEST_AVAILABLE_CAPABILITIES_MANUAL_POST_PROCESSING = 2; 559 560 /** 561 * <p>The camera device supports outputting RAW buffers and 562 * metadata for interpreting them.</p> 563 * <p>Devices supporting the RAW capability allow both for 564 * saving DNG files, and for direct application processing of 565 * raw sensor images.</p> 566 * <ul> 567 * <li>RAW_SENSOR is supported as an output format.</li> 568 * <li>The maximum available resolution for RAW_SENSOR streams 569 * will match either the value in 570 * {@link CameraCharacteristics#SENSOR_INFO_PIXEL_ARRAY_SIZE android.sensor.info.pixelArraySize} or 571 * {@link CameraCharacteristics#SENSOR_INFO_PRE_CORRECTION_ACTIVE_ARRAY_SIZE android.sensor.info.preCorrectionActiveArraySize}.</li> 572 * <li>All DNG-related optional metadata entries are provided 573 * by the camera device.</li> 574 * </ul> 575 * 576 * @see CameraCharacteristics#SENSOR_INFO_PIXEL_ARRAY_SIZE 577 * @see CameraCharacteristics#SENSOR_INFO_PRE_CORRECTION_ACTIVE_ARRAY_SIZE 578 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 579 */ 580 public static final int REQUEST_AVAILABLE_CAPABILITIES_RAW = 3; 581 582 /** 583 * <p>The camera device supports the Zero Shutter Lag reprocessing use case.</p> 584 * <ul> 585 * <li>One input stream is supported, that is, <code>{@link CameraCharacteristics#REQUEST_MAX_NUM_INPUT_STREAMS android.request.maxNumInputStreams} == 1</code>.</li> 586 * <li>{@link android.graphics.ImageFormat#PRIVATE } is supported as an output/input format, 587 * that is, {@link android.graphics.ImageFormat#PRIVATE } is included in the lists of 588 * formats returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputFormats } and {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputFormats }.</li> 589 * <li>{@link android.hardware.camera2.params.StreamConfigurationMap#getValidOutputFormatsForInput } 590 * returns non-empty int[] for each supported input format returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputFormats }.</li> 591 * <li>Each size returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputSizes getInputSizes(ImageFormat.PRIVATE)} is also included in {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputSizes getOutputSizes(ImageFormat.PRIVATE)}</li> 592 * <li>Using {@link android.graphics.ImageFormat#PRIVATE } does not cause a frame rate drop 593 * relative to the sensor's maximum capture rate (at that resolution).</li> 594 * <li>{@link android.graphics.ImageFormat#PRIVATE } will be reprocessable into both 595 * {@link android.graphics.ImageFormat#YUV_420_888 } and 596 * {@link android.graphics.ImageFormat#JPEG } formats.</li> 597 * <li>For a MONOCHROME camera supporting Y8 format, {@link android.graphics.ImageFormat#PRIVATE } will be reprocessable into 598 * {@link android.graphics.ImageFormat#Y8 }.</li> 599 * <li>The maximum available resolution for PRIVATE streams 600 * (both input/output) will match the maximum available 601 * resolution of JPEG streams.</li> 602 * <li>Static metadata {@link CameraCharacteristics#REPROCESS_MAX_CAPTURE_STALL android.reprocess.maxCaptureStall}.</li> 603 * <li>Only below controls are effective for reprocessing requests and 604 * will be present in capture results, other controls in reprocess 605 * requests will be ignored by the camera device.<ul> 606 * <li>android.jpeg.*</li> 607 * <li>{@link CaptureRequest#NOISE_REDUCTION_MODE android.noiseReduction.mode}</li> 608 * <li>{@link CaptureRequest#EDGE_MODE android.edge.mode}</li> 609 * </ul> 610 * </li> 611 * <li>{@link CameraCharacteristics#NOISE_REDUCTION_AVAILABLE_NOISE_REDUCTION_MODES android.noiseReduction.availableNoiseReductionModes} and 612 * {@link CameraCharacteristics#EDGE_AVAILABLE_EDGE_MODES android.edge.availableEdgeModes} will both list ZERO_SHUTTER_LAG as a supported mode.</li> 613 * </ul> 614 * 615 * @see CameraCharacteristics#EDGE_AVAILABLE_EDGE_MODES 616 * @see CaptureRequest#EDGE_MODE 617 * @see CameraCharacteristics#NOISE_REDUCTION_AVAILABLE_NOISE_REDUCTION_MODES 618 * @see CaptureRequest#NOISE_REDUCTION_MODE 619 * @see CameraCharacteristics#REPROCESS_MAX_CAPTURE_STALL 620 * @see CameraCharacteristics#REQUEST_MAX_NUM_INPUT_STREAMS 621 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 622 */ 623 public static final int REQUEST_AVAILABLE_CAPABILITIES_PRIVATE_REPROCESSING = 4; 624 625 /** 626 * <p>The camera device supports accurately reporting the sensor settings for many of 627 * the sensor controls while the built-in 3A algorithm is running. This allows 628 * reporting of sensor settings even when these settings cannot be manually changed.</p> 629 * <p>The values reported for the following controls are guaranteed to be available 630 * in the CaptureResult, including when 3A is enabled:</p> 631 * <ul> 632 * <li>Exposure control<ul> 633 * <li>{@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}</li> 634 * </ul> 635 * </li> 636 * <li>Sensitivity control<ul> 637 * <li>{@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}</li> 638 * </ul> 639 * </li> 640 * <li>Lens controls (if the lens is adjustable)<ul> 641 * <li>{@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance}</li> 642 * <li>{@link CaptureRequest#LENS_APERTURE android.lens.aperture}</li> 643 * </ul> 644 * </li> 645 * </ul> 646 * <p>This capability is a subset of the MANUAL_SENSOR control capability, and will 647 * always be included if the MANUAL_SENSOR capability is available.</p> 648 * 649 * @see CaptureRequest#LENS_APERTURE 650 * @see CaptureRequest#LENS_FOCUS_DISTANCE 651 * @see CaptureRequest#SENSOR_EXPOSURE_TIME 652 * @see CaptureRequest#SENSOR_SENSITIVITY 653 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 654 */ 655 public static final int REQUEST_AVAILABLE_CAPABILITIES_READ_SENSOR_SETTINGS = 5; 656 657 /** 658 * <p>The camera device supports capturing high-resolution images at >= 20 frames per 659 * second, in at least the uncompressed YUV format, when post-processing settings are 660 * set to FAST. Additionally, all image resolutions less than 24 megapixels can be 661 * captured at >= 10 frames per second. Here, 'high resolution' means at least 8 662 * megapixels, or the maximum resolution of the device, whichever is smaller.</p> 663 * <p>More specifically, this means that a size matching the camera device's active array 664 * size is listed as a supported size for the {@link android.graphics.ImageFormat#YUV_420_888 } format in either {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputSizes } or {@link android.hardware.camera2.params.StreamConfigurationMap#getHighResolutionOutputSizes }, 665 * with a minimum frame duration for that format and size of either <= 1/20 s, or 666 * <= 1/10 s if the image size is less than 24 megapixels, respectively; and 667 * the {@link CameraCharacteristics#CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES android.control.aeAvailableTargetFpsRanges} entry lists at least one FPS range 668 * where the minimum FPS is >= 1 / minimumFrameDuration for the maximum-size 669 * YUV_420_888 format. If that maximum size is listed in {@link android.hardware.camera2.params.StreamConfigurationMap#getHighResolutionOutputSizes }, 670 * then the list of resolutions for YUV_420_888 from {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputSizes } contains at 671 * least one resolution >= 8 megapixels, with a minimum frame duration of <= 1/20 672 * s.</p> 673 * <p>If the device supports the {@link android.graphics.ImageFormat#RAW10 }, {@link android.graphics.ImageFormat#RAW12 }, {@link android.graphics.ImageFormat#Y8 }, then those can also be 674 * captured at the same rate as the maximum-size YUV_420_888 resolution is.</p> 675 * <p>If the device supports the PRIVATE_REPROCESSING capability, then the same guarantees 676 * as for the YUV_420_888 format also apply to the {@link android.graphics.ImageFormat#PRIVATE } format.</p> 677 * <p>In addition, the {@link CameraCharacteristics#SYNC_MAX_LATENCY android.sync.maxLatency} field is guaranted to have a value between 0 678 * and 4, inclusive. {@link CameraCharacteristics#CONTROL_AE_LOCK_AVAILABLE android.control.aeLockAvailable} and {@link CameraCharacteristics#CONTROL_AWB_LOCK_AVAILABLE android.control.awbLockAvailable} 679 * are also guaranteed to be <code>true</code> so burst capture with these two locks ON yields 680 * consistent image output.</p> 681 * 682 * @see CameraCharacteristics#CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES 683 * @see CameraCharacteristics#CONTROL_AE_LOCK_AVAILABLE 684 * @see CameraCharacteristics#CONTROL_AWB_LOCK_AVAILABLE 685 * @see CameraCharacteristics#SYNC_MAX_LATENCY 686 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 687 */ 688 public static final int REQUEST_AVAILABLE_CAPABILITIES_BURST_CAPTURE = 6; 689 690 /** 691 * <p>The camera device supports the YUV_420_888 reprocessing use case, similar as 692 * PRIVATE_REPROCESSING, This capability requires the camera device to support the 693 * following:</p> 694 * <ul> 695 * <li>One input stream is supported, that is, <code>{@link CameraCharacteristics#REQUEST_MAX_NUM_INPUT_STREAMS android.request.maxNumInputStreams} == 1</code>.</li> 696 * <li>{@link android.graphics.ImageFormat#YUV_420_888 } is supported as an output/input 697 * format, that is, YUV_420_888 is included in the lists of formats returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputFormats } and {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputFormats }.</li> 698 * <li>{@link android.hardware.camera2.params.StreamConfigurationMap#getValidOutputFormatsForInput } 699 * returns non-empty int[] for each supported input format returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputFormats }.</li> 700 * <li>Each size returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputSizes getInputSizes(YUV_420_888)} is also included in {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputSizes getOutputSizes(YUV_420_888)}</li> 701 * <li>Using {@link android.graphics.ImageFormat#YUV_420_888 } does not cause a frame rate 702 * drop relative to the sensor's maximum capture rate (at that resolution).</li> 703 * <li>{@link android.graphics.ImageFormat#YUV_420_888 } will be reprocessable into both 704 * {@link android.graphics.ImageFormat#YUV_420_888 } and {@link android.graphics.ImageFormat#JPEG } formats.</li> 705 * <li>The maximum available resolution for {@link android.graphics.ImageFormat#YUV_420_888 } streams (both input/output) will match the 706 * maximum available resolution of {@link android.graphics.ImageFormat#JPEG } streams.</li> 707 * <li>For a MONOCHROME camera with Y8 format support, all the requirements mentioned 708 * above for YUV_420_888 apply for Y8 format as well.</li> 709 * <li>Static metadata {@link CameraCharacteristics#REPROCESS_MAX_CAPTURE_STALL android.reprocess.maxCaptureStall}.</li> 710 * <li>Only the below controls are effective for reprocessing requests and will be present 711 * in capture results. The reprocess requests are from the original capture results 712 * that are associated with the intermediate {@link android.graphics.ImageFormat#YUV_420_888 } output buffers. All other controls in the 713 * reprocess requests will be ignored by the camera device.<ul> 714 * <li>android.jpeg.*</li> 715 * <li>{@link CaptureRequest#NOISE_REDUCTION_MODE android.noiseReduction.mode}</li> 716 * <li>{@link CaptureRequest#EDGE_MODE android.edge.mode}</li> 717 * <li>{@link CaptureRequest#REPROCESS_EFFECTIVE_EXPOSURE_FACTOR android.reprocess.effectiveExposureFactor}</li> 718 * </ul> 719 * </li> 720 * <li>{@link CameraCharacteristics#NOISE_REDUCTION_AVAILABLE_NOISE_REDUCTION_MODES android.noiseReduction.availableNoiseReductionModes} and 721 * {@link CameraCharacteristics#EDGE_AVAILABLE_EDGE_MODES android.edge.availableEdgeModes} will both list ZERO_SHUTTER_LAG as a supported mode.</li> 722 * </ul> 723 * 724 * @see CameraCharacteristics#EDGE_AVAILABLE_EDGE_MODES 725 * @see CaptureRequest#EDGE_MODE 726 * @see CameraCharacteristics#NOISE_REDUCTION_AVAILABLE_NOISE_REDUCTION_MODES 727 * @see CaptureRequest#NOISE_REDUCTION_MODE 728 * @see CaptureRequest#REPROCESS_EFFECTIVE_EXPOSURE_FACTOR 729 * @see CameraCharacteristics#REPROCESS_MAX_CAPTURE_STALL 730 * @see CameraCharacteristics#REQUEST_MAX_NUM_INPUT_STREAMS 731 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 732 */ 733 public static final int REQUEST_AVAILABLE_CAPABILITIES_YUV_REPROCESSING = 7; 734 735 /** 736 * <p>The camera device can produce depth measurements from its field of view.</p> 737 * <p>This capability requires the camera device to support the following:</p> 738 * <ul> 739 * <li>{@link android.graphics.ImageFormat#DEPTH16 } is supported as 740 * an output format.</li> 741 * <li>{@link android.graphics.ImageFormat#DEPTH_POINT_CLOUD } is 742 * optionally supported as an output format.</li> 743 * <li>This camera device, and all camera devices with the same {@link CameraCharacteristics#LENS_FACING android.lens.facing}, will 744 * list the following calibration metadata entries in both {@link android.hardware.camera2.CameraCharacteristics } 745 * and {@link android.hardware.camera2.CaptureResult }:<ul> 746 * <li>{@link CameraCharacteristics#LENS_POSE_TRANSLATION android.lens.poseTranslation}</li> 747 * <li>{@link CameraCharacteristics#LENS_POSE_ROTATION android.lens.poseRotation}</li> 748 * <li>{@link CameraCharacteristics#LENS_INTRINSIC_CALIBRATION android.lens.intrinsicCalibration}</li> 749 * <li>{@link CameraCharacteristics#LENS_DISTORTION android.lens.distortion}</li> 750 * </ul> 751 * </li> 752 * <li>The {@link CameraCharacteristics#DEPTH_DEPTH_IS_EXCLUSIVE android.depth.depthIsExclusive} entry is listed by this device.</li> 753 * <li>As of Android P, the {@link CameraCharacteristics#LENS_POSE_REFERENCE android.lens.poseReference} entry is listed by this device.</li> 754 * <li>A LIMITED camera with only the DEPTH_OUTPUT capability does not have to support 755 * normal YUV_420_888, Y8, JPEG, and PRIV-format outputs. It only has to support the 756 * DEPTH16 format.</li> 757 * </ul> 758 * <p>Generally, depth output operates at a slower frame rate than standard color capture, 759 * so the DEPTH16 and DEPTH_POINT_CLOUD formats will commonly have a stall duration that 760 * should be accounted for (see {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputStallDuration }). 761 * On a device that supports both depth and color-based output, to enable smooth preview, 762 * using a repeating burst is recommended, where a depth-output target is only included 763 * once every N frames, where N is the ratio between preview output rate and depth output 764 * rate, including depth stall time.</p> 765 * 766 * @see CameraCharacteristics#DEPTH_DEPTH_IS_EXCLUSIVE 767 * @see CameraCharacteristics#LENS_DISTORTION 768 * @see CameraCharacteristics#LENS_FACING 769 * @see CameraCharacteristics#LENS_INTRINSIC_CALIBRATION 770 * @see CameraCharacteristics#LENS_POSE_REFERENCE 771 * @see CameraCharacteristics#LENS_POSE_ROTATION 772 * @see CameraCharacteristics#LENS_POSE_TRANSLATION 773 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 774 */ 775 public static final int REQUEST_AVAILABLE_CAPABILITIES_DEPTH_OUTPUT = 8; 776 777 /** 778 * <p>The device supports constrained high speed video recording (frame rate >=120fps) use 779 * case. The camera device will support high speed capture session created by {@link android.hardware.camera2.CameraDevice#createConstrainedHighSpeedCaptureSession }, which 780 * only accepts high speed request lists created by {@link android.hardware.camera2.CameraConstrainedHighSpeedCaptureSession#createHighSpeedRequestList }.</p> 781 * <p>A camera device can still support high speed video streaming by advertising the high 782 * speed FPS ranges in {@link CameraCharacteristics#CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES android.control.aeAvailableTargetFpsRanges}. For this case, all 783 * normal capture request per frame control and synchronization requirements will apply 784 * to the high speed fps ranges, the same as all other fps ranges. This capability 785 * describes the capability of a specialized operating mode with many limitations (see 786 * below), which is only targeted at high speed video recording.</p> 787 * <p>The supported high speed video sizes and fps ranges are specified in {@link android.hardware.camera2.params.StreamConfigurationMap#getHighSpeedVideoFpsRanges }. 788 * To get desired output frame rates, the application is only allowed to select video 789 * size and FPS range combinations provided by {@link android.hardware.camera2.params.StreamConfigurationMap#getHighSpeedVideoSizes }. The 790 * fps range can be controlled via {@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange}.</p> 791 * <p>In this capability, the camera device will override aeMode, awbMode, and afMode to 792 * ON, AUTO, and CONTINUOUS_VIDEO, respectively. All post-processing block mode 793 * controls will be overridden to be FAST. Therefore, no manual control of capture 794 * and post-processing parameters is possible. All other controls operate the 795 * same as when {@link CaptureRequest#CONTROL_MODE android.control.mode} == AUTO. This means that all other 796 * android.control.* fields continue to work, such as</p> 797 * <ul> 798 * <li>{@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange}</li> 799 * <li>{@link CaptureRequest#CONTROL_AE_EXPOSURE_COMPENSATION android.control.aeExposureCompensation}</li> 800 * <li>{@link CaptureRequest#CONTROL_AE_LOCK android.control.aeLock}</li> 801 * <li>{@link CaptureRequest#CONTROL_AWB_LOCK android.control.awbLock}</li> 802 * <li>{@link CaptureRequest#CONTROL_EFFECT_MODE android.control.effectMode}</li> 803 * <li>{@link CaptureRequest#CONTROL_AE_REGIONS android.control.aeRegions}</li> 804 * <li>{@link CaptureRequest#CONTROL_AF_REGIONS android.control.afRegions}</li> 805 * <li>{@link CaptureRequest#CONTROL_AWB_REGIONS android.control.awbRegions}</li> 806 * <li>{@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}</li> 807 * <li>{@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}</li> 808 * <li>{@link CaptureRequest#CONTROL_ZOOM_RATIO android.control.zoomRatio}</li> 809 * </ul> 810 * <p>Outside of android.control.*, the following controls will work:</p> 811 * <ul> 812 * <li>{@link CaptureRequest#FLASH_MODE android.flash.mode} (TORCH mode only, automatic flash for still capture will not 813 * work since aeMode is ON)</li> 814 * <li>{@link CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE android.lens.opticalStabilizationMode} (if it is supported)</li> 815 * <li>{@link CaptureRequest#SCALER_CROP_REGION android.scaler.cropRegion}</li> 816 * <li>{@link CaptureRequest#STATISTICS_FACE_DETECT_MODE android.statistics.faceDetectMode} (if it is supported)</li> 817 * </ul> 818 * <p>For high speed recording use case, the actual maximum supported frame rate may 819 * be lower than what camera can output, depending on the destination Surfaces for 820 * the image data. For example, if the destination surface is from video encoder, 821 * the application need check if the video encoder is capable of supporting the 822 * high frame rate for a given video size, or it will end up with lower recording 823 * frame rate. If the destination surface is from preview window, the actual preview frame 824 * rate will be bounded by the screen refresh rate.</p> 825 * <p>The camera device will only support up to 2 high speed simultaneous output surfaces 826 * (preview and recording surfaces) in this mode. Above controls will be effective only 827 * if all of below conditions are true:</p> 828 * <ul> 829 * <li>The application creates a camera capture session with no more than 2 surfaces via 830 * {@link android.hardware.camera2.CameraDevice#createConstrainedHighSpeedCaptureSession }. The 831 * targeted surfaces must be preview surface (either from {@link android.view.SurfaceView } or {@link android.graphics.SurfaceTexture }) or recording 832 * surface(either from {@link android.media.MediaRecorder#getSurface } or {@link android.media.MediaCodec#createInputSurface }).</li> 833 * <li>The stream sizes are selected from the sizes reported by 834 * {@link android.hardware.camera2.params.StreamConfigurationMap#getHighSpeedVideoSizes }.</li> 835 * <li>The FPS ranges are selected from {@link android.hardware.camera2.params.StreamConfigurationMap#getHighSpeedVideoFpsRanges }.</li> 836 * </ul> 837 * <p>When above conditions are NOT satistied, 838 * {@link android.hardware.camera2.CameraDevice#createConstrainedHighSpeedCaptureSession } 839 * will fail.</p> 840 * <p>Switching to a FPS range that has different maximum FPS may trigger some camera device 841 * reconfigurations, which may introduce extra latency. It is recommended that 842 * the application avoids unnecessary maximum target FPS changes as much as possible 843 * during high speed streaming.</p> 844 * 845 * @see CameraCharacteristics#CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES 846 * @see CaptureRequest#CONTROL_AE_EXPOSURE_COMPENSATION 847 * @see CaptureRequest#CONTROL_AE_LOCK 848 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER 849 * @see CaptureRequest#CONTROL_AE_REGIONS 850 * @see CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE 851 * @see CaptureRequest#CONTROL_AF_REGIONS 852 * @see CaptureRequest#CONTROL_AF_TRIGGER 853 * @see CaptureRequest#CONTROL_AWB_LOCK 854 * @see CaptureRequest#CONTROL_AWB_REGIONS 855 * @see CaptureRequest#CONTROL_EFFECT_MODE 856 * @see CaptureRequest#CONTROL_MODE 857 * @see CaptureRequest#CONTROL_ZOOM_RATIO 858 * @see CaptureRequest#FLASH_MODE 859 * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE 860 * @see CaptureRequest#SCALER_CROP_REGION 861 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE 862 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 863 */ 864 public static final int REQUEST_AVAILABLE_CAPABILITIES_CONSTRAINED_HIGH_SPEED_VIDEO = 9; 865 866 /** 867 * <p>The camera device supports the MOTION_TRACKING value for 868 * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent}, which limits maximum exposure time to 20 ms.</p> 869 * <p>This limits the motion blur of capture images, resulting in better image tracking 870 * results for use cases such as image stabilization or augmented reality.</p> 871 * 872 * @see CaptureRequest#CONTROL_CAPTURE_INTENT 873 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 874 */ 875 public static final int REQUEST_AVAILABLE_CAPABILITIES_MOTION_TRACKING = 10; 876 877 /** 878 * <p>The camera device is a logical camera backed by two or more physical cameras.</p> 879 * <p>In API level 28, the physical cameras must also be exposed to the application via 880 * {@link android.hardware.camera2.CameraManager#getCameraIdList }.</p> 881 * <p>Starting from API level 29:</p> 882 * <ul> 883 * <li>Some or all physical cameras may not be independently exposed to the application, 884 * in which case the physical camera IDs will not be available in 885 * {@link android.hardware.camera2.CameraManager#getCameraIdList }. But the 886 * application can still query the physical cameras' characteristics by calling 887 * {@link android.hardware.camera2.CameraManager#getCameraCharacteristics }.</li> 888 * <li>If a physical camera is hidden from camera ID list, the mandatory stream 889 * combinations for that physical camera must be supported through the logical camera 890 * using physical streams. One exception is that in API level 30, a physical camera 891 * may become unavailable via 892 * {@link CameraManager.AvailabilityCallback#onPhysicalCameraUnavailable } 893 * callback.</li> 894 * </ul> 895 * <p>Combinations of logical and physical streams, or physical streams from different 896 * physical cameras are not guaranteed. However, if the camera device supports 897 * {@link CameraDevice#isSessionConfigurationSupported }, 898 * application must be able to query whether a stream combination involving physical 899 * streams is supported by calling 900 * {@link CameraDevice#isSessionConfigurationSupported }.</p> 901 * <p>Camera application shouldn't assume that there are at most 1 rear camera and 1 front 902 * camera in the system. For an application that switches between front and back cameras, 903 * the recommendation is to switch between the first rear camera and the first front 904 * camera in the list of supported camera devices.</p> 905 * <p>This capability requires the camera device to support the following:</p> 906 * <ul> 907 * <li>The IDs of underlying physical cameras are returned via 908 * {@link android.hardware.camera2.CameraCharacteristics#getPhysicalCameraIds }.</li> 909 * <li>This camera device must list static metadata 910 * {@link CameraCharacteristics#LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE android.logicalMultiCamera.sensorSyncType} in 911 * {@link android.hardware.camera2.CameraCharacteristics }.</li> 912 * <li>The underlying physical cameras' static metadata must list the following entries, 913 * so that the application can correlate pixels from the physical streams:<ul> 914 * <li>{@link CameraCharacteristics#LENS_POSE_REFERENCE android.lens.poseReference}</li> 915 * <li>{@link CameraCharacteristics#LENS_POSE_ROTATION android.lens.poseRotation}</li> 916 * <li>{@link CameraCharacteristics#LENS_POSE_TRANSLATION android.lens.poseTranslation}</li> 917 * <li>{@link CameraCharacteristics#LENS_INTRINSIC_CALIBRATION android.lens.intrinsicCalibration}</li> 918 * <li>{@link CameraCharacteristics#LENS_DISTORTION android.lens.distortion}</li> 919 * </ul> 920 * </li> 921 * <li>The SENSOR_INFO_TIMESTAMP_SOURCE of the logical device and physical devices must be 922 * the same.</li> 923 * <li>The logical camera must be LIMITED or higher device.</li> 924 * </ul> 925 * <p>A logical camera device's dynamic metadata may contain 926 * {@link CaptureResult#LOGICAL_MULTI_CAMERA_ACTIVE_PHYSICAL_ID android.logicalMultiCamera.activePhysicalId} to notify the application of the current 927 * active physical camera Id. An active physical camera is the physical camera from which 928 * the logical camera's main image data outputs (YUV or RAW) and metadata come from. 929 * In addition, this serves as an indication which physical camera is used to output to 930 * a RAW stream, or in case only physical cameras support RAW, which physical RAW stream 931 * the application should request.</p> 932 * <p>Logical camera's static metadata tags below describe the default active physical 933 * camera. An active physical camera is default if it's used when application directly 934 * uses requests built from a template. All templates will default to the same active 935 * physical camera.</p> 936 * <ul> 937 * <li>{@link CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE android.sensor.info.sensitivityRange}</li> 938 * <li>{@link CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT android.sensor.info.colorFilterArrangement}</li> 939 * <li>{@link CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE android.sensor.info.exposureTimeRange}</li> 940 * <li>{@link CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION android.sensor.info.maxFrameDuration}</li> 941 * <li>{@link CameraCharacteristics#SENSOR_INFO_PHYSICAL_SIZE android.sensor.info.physicalSize}</li> 942 * <li>{@link CameraCharacteristics#SENSOR_INFO_WHITE_LEVEL android.sensor.info.whiteLevel}</li> 943 * <li>{@link CameraCharacteristics#SENSOR_INFO_LENS_SHADING_APPLIED android.sensor.info.lensShadingApplied}</li> 944 * <li>{@link CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 android.sensor.referenceIlluminant1}</li> 945 * <li>{@link CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT2 android.sensor.referenceIlluminant2}</li> 946 * <li>{@link CameraCharacteristics#SENSOR_CALIBRATION_TRANSFORM1 android.sensor.calibrationTransform1}</li> 947 * <li>{@link CameraCharacteristics#SENSOR_CALIBRATION_TRANSFORM2 android.sensor.calibrationTransform2}</li> 948 * <li>{@link CameraCharacteristics#SENSOR_COLOR_TRANSFORM1 android.sensor.colorTransform1}</li> 949 * <li>{@link CameraCharacteristics#SENSOR_COLOR_TRANSFORM2 android.sensor.colorTransform2}</li> 950 * <li>{@link CameraCharacteristics#SENSOR_FORWARD_MATRIX1 android.sensor.forwardMatrix1}</li> 951 * <li>{@link CameraCharacteristics#SENSOR_FORWARD_MATRIX2 android.sensor.forwardMatrix2}</li> 952 * <li>{@link CameraCharacteristics#SENSOR_BLACK_LEVEL_PATTERN android.sensor.blackLevelPattern}</li> 953 * <li>{@link CameraCharacteristics#SENSOR_MAX_ANALOG_SENSITIVITY android.sensor.maxAnalogSensitivity}</li> 954 * <li>{@link CameraCharacteristics#SENSOR_OPTICAL_BLACK_REGIONS android.sensor.opticalBlackRegions}</li> 955 * <li>{@link CameraCharacteristics#SENSOR_AVAILABLE_TEST_PATTERN_MODES android.sensor.availableTestPatternModes}</li> 956 * <li>{@link CameraCharacteristics#LENS_INFO_HYPERFOCAL_DISTANCE android.lens.info.hyperfocalDistance}</li> 957 * <li>{@link CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE android.lens.info.minimumFocusDistance}</li> 958 * <li>{@link CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION android.lens.info.focusDistanceCalibration}</li> 959 * <li>{@link CameraCharacteristics#LENS_POSE_ROTATION android.lens.poseRotation}</li> 960 * <li>{@link CameraCharacteristics#LENS_POSE_TRANSLATION android.lens.poseTranslation}</li> 961 * <li>{@link CameraCharacteristics#LENS_INTRINSIC_CALIBRATION android.lens.intrinsicCalibration}</li> 962 * <li>{@link CameraCharacteristics#LENS_POSE_REFERENCE android.lens.poseReference}</li> 963 * <li>{@link CameraCharacteristics#LENS_DISTORTION android.lens.distortion}</li> 964 * </ul> 965 * <p>The field of view of non-RAW physical streams must not be smaller than that of the 966 * non-RAW logical streams, or the maximum field-of-view of the physical camera, 967 * whichever is smaller. The application should check the physical capture result 968 * metadata for how the physical streams are cropped or zoomed. More specifically, given 969 * the physical camera result metadata, the effective horizontal field-of-view of the 970 * physical camera is:</p> 971 * <pre><code>fov = 2 * atan2(cropW * sensorW / (2 * zoomRatio * activeArrayW), focalLength) 972 * </code></pre> 973 * <p>where the equation parameters are the physical camera's crop region width, physical 974 * sensor width, zoom ratio, active array width, and focal length respectively. Typically 975 * the physical stream of active physical camera has the same field-of-view as the 976 * logical streams. However, the same may not be true for physical streams from 977 * non-active physical cameras. For example, if the logical camera has a wide-ultrawide 978 * configuration where the wide lens is the default, when the crop region is set to the 979 * logical camera's active array size, (and the zoom ratio set to 1.0 starting from 980 * Android 11), a physical stream for the ultrawide camera may prefer outputing images 981 * with larger field-of-view than that of the wide camera for better stereo matching 982 * margin or more robust motion tracking. At the same time, the physical non-RAW streams' 983 * field of view must not be smaller than the requested crop region and zoom ratio, as 984 * long as it's within the physical lens' capability. For example, for a logical camera 985 * with wide-tele lens configuration where the wide lens is the default, if the logical 986 * camera's crop region is set to maximum size, and zoom ratio set to 1.0, the physical 987 * stream for the tele lens will be configured to its maximum size crop region (no zoom).</p> 988 * <p><em>Deprecated:</em> Prior to Android 11, the field of view of all non-RAW physical streams 989 * cannot be larger than that of non-RAW logical streams. If the logical camera has a 990 * wide-ultrawide lens configuration where the wide lens is the default, when the logical 991 * camera's crop region is set to maximum size, the FOV of the physical streams for the 992 * ultrawide lens will be the same as the logical stream, by making the crop region 993 * smaller than its active array size to compensate for the smaller focal length.</p> 994 * <p>There are two ways for the application to capture RAW images from a logical camera 995 * with RAW capability:</p> 996 * <ul> 997 * <li>Because the underlying physical cameras may have different RAW capabilities (such 998 * as resolution or CFA pattern), to maintain backward compatibility, when a RAW stream 999 * is configured, the camera device makes sure the default active physical camera remains 1000 * active and does not switch to other physical cameras. (One exception is that, if the 1001 * logical camera consists of identical image sensors and advertises multiple focalLength 1002 * due to different lenses, the camera device may generate RAW images from different 1003 * physical cameras based on the focalLength being set by the application.) This 1004 * backward-compatible approach usually results in loss of optical zoom, to telephoto 1005 * lens or to ultrawide lens.</li> 1006 * <li>Alternatively, to take advantage of the full zoomRatio range of the logical camera, 1007 * the application should use {@link android.hardware.camera2.MultiResolutionImageReader } 1008 * to capture RAW images from the currently active physical camera. Because different 1009 * physical camera may have different RAW characteristics, the application needs to use 1010 * the characteristics and result metadata of the active physical camera for the 1011 * relevant RAW metadata.</li> 1012 * </ul> 1013 * <p>The capture request and result metadata tags required for backward compatible camera 1014 * functionalities will be solely based on the logical camera capability. On the other 1015 * hand, the use of manual capture controls (sensor or post-processing) with a 1016 * logical camera may result in unexpected behavior when the HAL decides to switch 1017 * between physical cameras with different characteristics under the hood. For example, 1018 * when the application manually sets exposure time and sensitivity while zooming in, 1019 * the brightness of the camera images may suddenly change because HAL switches from one 1020 * physical camera to the other.</p> 1021 * 1022 * @see CameraCharacteristics#LENS_DISTORTION 1023 * @see CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION 1024 * @see CameraCharacteristics#LENS_INFO_HYPERFOCAL_DISTANCE 1025 * @see CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE 1026 * @see CameraCharacteristics#LENS_INTRINSIC_CALIBRATION 1027 * @see CameraCharacteristics#LENS_POSE_REFERENCE 1028 * @see CameraCharacteristics#LENS_POSE_ROTATION 1029 * @see CameraCharacteristics#LENS_POSE_TRANSLATION 1030 * @see CaptureResult#LOGICAL_MULTI_CAMERA_ACTIVE_PHYSICAL_ID 1031 * @see CameraCharacteristics#LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE 1032 * @see CameraCharacteristics#SENSOR_AVAILABLE_TEST_PATTERN_MODES 1033 * @see CameraCharacteristics#SENSOR_BLACK_LEVEL_PATTERN 1034 * @see CameraCharacteristics#SENSOR_CALIBRATION_TRANSFORM1 1035 * @see CameraCharacteristics#SENSOR_CALIBRATION_TRANSFORM2 1036 * @see CameraCharacteristics#SENSOR_COLOR_TRANSFORM1 1037 * @see CameraCharacteristics#SENSOR_COLOR_TRANSFORM2 1038 * @see CameraCharacteristics#SENSOR_FORWARD_MATRIX1 1039 * @see CameraCharacteristics#SENSOR_FORWARD_MATRIX2 1040 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT 1041 * @see CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE 1042 * @see CameraCharacteristics#SENSOR_INFO_LENS_SHADING_APPLIED 1043 * @see CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION 1044 * @see CameraCharacteristics#SENSOR_INFO_PHYSICAL_SIZE 1045 * @see CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE 1046 * @see CameraCharacteristics#SENSOR_INFO_WHITE_LEVEL 1047 * @see CameraCharacteristics#SENSOR_MAX_ANALOG_SENSITIVITY 1048 * @see CameraCharacteristics#SENSOR_OPTICAL_BLACK_REGIONS 1049 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1050 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT2 1051 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 1052 */ 1053 public static final int REQUEST_AVAILABLE_CAPABILITIES_LOGICAL_MULTI_CAMERA = 11; 1054 1055 /** 1056 * <p>The camera device is a monochrome camera that doesn't contain a color filter array, 1057 * and for YUV_420_888 stream, the pixel values on U and V planes are all 128.</p> 1058 * <p>A MONOCHROME camera must support the guaranteed stream combinations required for 1059 * its device level and capabilities. Additionally, if the monochrome camera device 1060 * supports Y8 format, all mandatory stream combination requirements related to {@link android.graphics.ImageFormat#YUV_420_888 YUV_420_888} apply 1061 * to {@link android.graphics.ImageFormat#Y8 Y8} as well. There are no 1062 * mandatory stream combination requirements with regard to 1063 * {@link android.graphics.ImageFormat#Y8 Y8} for Bayer camera devices.</p> 1064 * <p>Starting from Android Q, the SENSOR_INFO_COLOR_FILTER_ARRANGEMENT of a MONOCHROME 1065 * camera will be either MONO or NIR.</p> 1066 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 1067 */ 1068 public static final int REQUEST_AVAILABLE_CAPABILITIES_MONOCHROME = 12; 1069 1070 /** 1071 * <p>The camera device is capable of writing image data into a region of memory 1072 * inaccessible to Android userspace or the Android kernel, and only accessible to 1073 * trusted execution environments (TEE).</p> 1074 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 1075 */ 1076 public static final int REQUEST_AVAILABLE_CAPABILITIES_SECURE_IMAGE_DATA = 13; 1077 1078 /** 1079 * <p>The camera device is only accessible by Android's system components and privileged 1080 * applications. Processes need to have the android.permission.SYSTEM_CAMERA in 1081 * addition to android.permission.CAMERA in order to connect to this camera device.</p> 1082 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 1083 */ 1084 public static final int REQUEST_AVAILABLE_CAPABILITIES_SYSTEM_CAMERA = 14; 1085 1086 /** 1087 * <p>The camera device supports the OFFLINE_PROCESSING use case.</p> 1088 * <p>With OFFLINE_PROCESSING capability, the application can switch an ongoing 1089 * capture session to offline mode by calling the 1090 * CameraCaptureSession#switchToOffline method and specify streams to be kept in offline 1091 * mode. The camera will then stop currently active repeating requests, prepare for 1092 * some requests to go into offline mode, and return an offline session object. After 1093 * the switchToOffline call returns, the original capture session is in closed state as 1094 * if the CameraCaptureSession#close method has been called. 1095 * In the offline mode, all inflight requests will continue to be processed in the 1096 * background, and the application can immediately close the camera or create a new 1097 * capture session without losing those requests' output images and capture results.</p> 1098 * <p>While the camera device is processing offline requests, it 1099 * might not be able to support all stream configurations it can support 1100 * without offline requests. When that happens, the createCaptureSession 1101 * method call will fail. The following stream configurations are guaranteed to work 1102 * without hitting the resource busy exception:</p> 1103 * <ul> 1104 * <li>One ongoing offline session: target one output surface of YUV or 1105 * JPEG format, any resolution.</li> 1106 * <li>The active camera capture session:<ol> 1107 * <li>One preview surface (SurfaceView or SurfaceTexture) up to 1920 width</li> 1108 * <li>One YUV ImageReader surface up to 1920 width</li> 1109 * <li>One Jpeg ImageReader, any resolution: the camera device is 1110 * allowed to slow down JPEG output speed by 50% if there is any ongoing offline 1111 * session.</li> 1112 * <li>If the device supports PRIVATE_REPROCESSING, one pair of ImageWriter/ImageReader 1113 * surfaces of private format, with the same resolution that is larger or equal to 1114 * the JPEG ImageReader resolution above.</li> 1115 * </ol> 1116 * </li> 1117 * <li>Alternatively, the active camera session above can be replaced by an legacy 1118 * {@link android.hardware.Camera Camera} with the following parameter settings:<ol> 1119 * <li>Preview size up to 1920 width</li> 1120 * <li>Preview callback size up to 1920 width</li> 1121 * <li>Video size up to 1920 width</li> 1122 * <li>Picture size, any resolution: the camera device is 1123 * allowed to slow down JPEG output speed by 50% if there is any ongoing offline 1124 * session.</li> 1125 * </ol> 1126 * </li> 1127 * </ul> 1128 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 1129 */ 1130 public static final int REQUEST_AVAILABLE_CAPABILITIES_OFFLINE_PROCESSING = 15; 1131 1132 /** 1133 * <p>This camera device is capable of producing ultra high resolution images in 1134 * addition to the image sizes described in the 1135 * {@link CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP android.scaler.streamConfigurationMap}. 1136 * It can operate in 'default' mode and 'max resolution' mode. It generally does this 1137 * by binning pixels in 'default' mode and not binning them in 'max resolution' mode. 1138 * <code>{@link CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP android.scaler.streamConfigurationMap}</code> describes the streams supported in 'default' 1139 * mode. 1140 * The stream configurations supported in 'max resolution' mode are described by 1141 * <code>{@link CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP_MAXIMUM_RESOLUTION android.scaler.streamConfigurationMapMaximumResolution}</code>. 1142 * The maximum resolution mode pixel array size of a camera device 1143 * (<code>{@link CameraCharacteristics#SENSOR_INFO_PIXEL_ARRAY_SIZE android.sensor.info.pixelArraySize}</code>) with this capability, 1144 * will be at least 24 megapixels.</p> 1145 * 1146 * @see CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP 1147 * @see CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP_MAXIMUM_RESOLUTION 1148 * @see CameraCharacteristics#SENSOR_INFO_PIXEL_ARRAY_SIZE 1149 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 1150 */ 1151 public static final int REQUEST_AVAILABLE_CAPABILITIES_ULTRA_HIGH_RESOLUTION_SENSOR = 16; 1152 1153 /** 1154 * <p>The device supports reprocessing from the <code>RAW_SENSOR</code> format with a bayer pattern 1155 * given by {@link CameraCharacteristics#SENSOR_INFO_BINNING_FACTOR android.sensor.info.binningFactor} (m x n group of pixels with the same 1156 * color filter) to a remosaiced regular bayer pattern.</p> 1157 * <p>This capability will only be present for devices with 1158 * {@link android.hardware.camera2.CameraMetadata#REQUEST_AVAILABLE_CAPABILITIES_ULTRA_HIGH_RESOLUTION_SENSOR } 1159 * capability. When 1160 * {@link android.hardware.camera2.CameraMetadata#REQUEST_AVAILABLE_CAPABILITIES_ULTRA_HIGH_RESOLUTION_SENSOR } 1161 * devices do not advertise this capability, 1162 * {@link android.graphics.ImageFormat#RAW_SENSOR } images will already have a 1163 * regular bayer pattern.</p> 1164 * <p>If a <code>RAW_SENSOR</code> stream is requested along with another non-RAW stream in a 1165 * {@link android.hardware.camera2.CaptureRequest } (if multiple streams are supported 1166 * when {@link CaptureRequest#SENSOR_PIXEL_MODE android.sensor.pixelMode} is set to 1167 * {@link android.hardware.camera2.CameraMetadata#SENSOR_PIXEL_MODE_MAXIMUM_RESOLUTION }), 1168 * the <code>RAW_SENSOR</code> stream will have a regular bayer pattern.</p> 1169 * <p>This capability requires the camera device to support the following : 1170 * * The {@link android.hardware.camera2.params.StreamConfigurationMap } mentioned below 1171 * refers to the one, described by 1172 * <code>{@link CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP_MAXIMUM_RESOLUTION android.scaler.streamConfigurationMapMaximumResolution}</code>. 1173 * * One input stream is supported, that is, <code>{@link CameraCharacteristics#REQUEST_MAX_NUM_INPUT_STREAMS android.request.maxNumInputStreams} == 1</code>. 1174 * * {@link android.graphics.ImageFormat#RAW_SENSOR } is supported as an output/input 1175 * format, that is, {@link android.graphics.ImageFormat#RAW_SENSOR } is included in the 1176 * lists of formats returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputFormats } and {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputFormats }. 1177 * * {@link android.hardware.camera2.params.StreamConfigurationMap#getValidOutputFormatsForInput } 1178 * returns non-empty int[] for each supported input format returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputFormats }. 1179 * * Each size returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputSizes getInputSizes(ImageFormat.RAW_SENSOR)} is also included in {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputSizes getOutputSizes(ImageFormat.RAW_SENSOR)} 1180 * * Using {@link android.graphics.ImageFormat#RAW_SENSOR } does not cause a frame rate 1181 * drop relative to the sensor's maximum capture rate (at that resolution). 1182 * * No CaptureRequest controls will be applicable when a request has an input target 1183 * with {@link android.graphics.ImageFormat#RAW_SENSOR } format.</p> 1184 * 1185 * @see CameraCharacteristics#REQUEST_MAX_NUM_INPUT_STREAMS 1186 * @see CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP_MAXIMUM_RESOLUTION 1187 * @see CameraCharacteristics#SENSOR_INFO_BINNING_FACTOR 1188 * @see CaptureRequest#SENSOR_PIXEL_MODE 1189 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 1190 */ 1191 public static final int REQUEST_AVAILABLE_CAPABILITIES_REMOSAIC_REPROCESSING = 17; 1192 1193 // 1194 // Enumeration values for CameraCharacteristics#SCALER_CROPPING_TYPE 1195 // 1196 1197 /** 1198 * <p>The camera device only supports centered crop regions.</p> 1199 * @see CameraCharacteristics#SCALER_CROPPING_TYPE 1200 */ 1201 public static final int SCALER_CROPPING_TYPE_CENTER_ONLY = 0; 1202 1203 /** 1204 * <p>The camera device supports arbitrarily chosen crop regions.</p> 1205 * @see CameraCharacteristics#SCALER_CROPPING_TYPE 1206 */ 1207 public static final int SCALER_CROPPING_TYPE_FREEFORM = 1; 1208 1209 // 1210 // Enumeration values for CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT 1211 // 1212 1213 /** 1214 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT 1215 */ 1216 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_RGGB = 0; 1217 1218 /** 1219 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT 1220 */ 1221 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GRBG = 1; 1222 1223 /** 1224 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT 1225 */ 1226 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GBRG = 2; 1227 1228 /** 1229 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT 1230 */ 1231 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_BGGR = 3; 1232 1233 /** 1234 * <p>Sensor is not Bayer; output has 3 16-bit 1235 * values for each pixel, instead of just 1 16-bit value 1236 * per pixel.</p> 1237 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT 1238 */ 1239 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_RGB = 4; 1240 1241 /** 1242 * <p>Sensor doesn't have any Bayer color filter. 1243 * Such sensor captures visible light in monochrome. The exact weighting and 1244 * wavelengths captured is not specified, but generally only includes the visible 1245 * frequencies. This value implies a MONOCHROME camera.</p> 1246 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT 1247 */ 1248 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_MONO = 5; 1249 1250 /** 1251 * <p>Sensor has a near infrared filter capturing light with wavelength between 1252 * roughly 750nm and 1400nm, and the same filter covers the whole sensor array. This 1253 * value implies a MONOCHROME camera.</p> 1254 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT 1255 */ 1256 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_NIR = 6; 1257 1258 // 1259 // Enumeration values for CameraCharacteristics#SENSOR_INFO_TIMESTAMP_SOURCE 1260 // 1261 1262 /** 1263 * <p>Timestamps from {@link CaptureResult#SENSOR_TIMESTAMP android.sensor.timestamp} are in nanoseconds and monotonic, but can 1264 * not be compared to timestamps from other subsystems (e.g. accelerometer, gyro etc.), 1265 * or other instances of the same or different camera devices in the same system with 1266 * accuracy. However, the timestamps are roughly in the same timebase as 1267 * {@link android.os.SystemClock#uptimeMillis }. The accuracy is sufficient for tasks 1268 * like A/V synchronization for video recording, at least, and the timestamps can be 1269 * directly used together with timestamps from the audio subsystem for that task.</p> 1270 * <p>Timestamps between streams and results for a single camera instance are comparable, 1271 * and the timestamps for all buffers and the result metadata generated by a single 1272 * capture are identical.</p> 1273 * 1274 * @see CaptureResult#SENSOR_TIMESTAMP 1275 * @see CameraCharacteristics#SENSOR_INFO_TIMESTAMP_SOURCE 1276 */ 1277 public static final int SENSOR_INFO_TIMESTAMP_SOURCE_UNKNOWN = 0; 1278 1279 /** 1280 * <p>Timestamps from {@link CaptureResult#SENSOR_TIMESTAMP android.sensor.timestamp} are in the same timebase as 1281 * {@link android.os.SystemClock#elapsedRealtimeNanos }, 1282 * and they can be compared to other timestamps using that base.</p> 1283 * <p>When buffers from a REALTIME device are passed directly to a video encoder from the 1284 * camera, automatic compensation is done to account for differing timebases of the 1285 * audio and camera subsystems. If the application is receiving buffers and then later 1286 * sending them to a video encoder or other application where they are compared with 1287 * audio subsystem timestamps or similar, this compensation is not present. In those 1288 * cases, applications need to adjust the timestamps themselves. Since {@link android.os.SystemClock#elapsedRealtimeNanos } and {@link android.os.SystemClock#uptimeMillis } only diverge while the device is asleep, an 1289 * offset between the two sources can be measured once per active session and applied 1290 * to timestamps for sufficient accuracy for A/V sync.</p> 1291 * 1292 * @see CaptureResult#SENSOR_TIMESTAMP 1293 * @see CameraCharacteristics#SENSOR_INFO_TIMESTAMP_SOURCE 1294 */ 1295 public static final int SENSOR_INFO_TIMESTAMP_SOURCE_REALTIME = 1; 1296 1297 // 1298 // Enumeration values for CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1299 // 1300 1301 /** 1302 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1303 */ 1304 public static final int SENSOR_REFERENCE_ILLUMINANT1_DAYLIGHT = 1; 1305 1306 /** 1307 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1308 */ 1309 public static final int SENSOR_REFERENCE_ILLUMINANT1_FLUORESCENT = 2; 1310 1311 /** 1312 * <p>Incandescent light</p> 1313 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1314 */ 1315 public static final int SENSOR_REFERENCE_ILLUMINANT1_TUNGSTEN = 3; 1316 1317 /** 1318 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1319 */ 1320 public static final int SENSOR_REFERENCE_ILLUMINANT1_FLASH = 4; 1321 1322 /** 1323 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1324 */ 1325 public static final int SENSOR_REFERENCE_ILLUMINANT1_FINE_WEATHER = 9; 1326 1327 /** 1328 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1329 */ 1330 public static final int SENSOR_REFERENCE_ILLUMINANT1_CLOUDY_WEATHER = 10; 1331 1332 /** 1333 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1334 */ 1335 public static final int SENSOR_REFERENCE_ILLUMINANT1_SHADE = 11; 1336 1337 /** 1338 * <p>D 5700 - 7100K</p> 1339 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1340 */ 1341 public static final int SENSOR_REFERENCE_ILLUMINANT1_DAYLIGHT_FLUORESCENT = 12; 1342 1343 /** 1344 * <p>N 4600 - 5400K</p> 1345 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1346 */ 1347 public static final int SENSOR_REFERENCE_ILLUMINANT1_DAY_WHITE_FLUORESCENT = 13; 1348 1349 /** 1350 * <p>W 3900 - 4500K</p> 1351 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1352 */ 1353 public static final int SENSOR_REFERENCE_ILLUMINANT1_COOL_WHITE_FLUORESCENT = 14; 1354 1355 /** 1356 * <p>WW 3200 - 3700K</p> 1357 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1358 */ 1359 public static final int SENSOR_REFERENCE_ILLUMINANT1_WHITE_FLUORESCENT = 15; 1360 1361 /** 1362 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1363 */ 1364 public static final int SENSOR_REFERENCE_ILLUMINANT1_STANDARD_A = 17; 1365 1366 /** 1367 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1368 */ 1369 public static final int SENSOR_REFERENCE_ILLUMINANT1_STANDARD_B = 18; 1370 1371 /** 1372 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1373 */ 1374 public static final int SENSOR_REFERENCE_ILLUMINANT1_STANDARD_C = 19; 1375 1376 /** 1377 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1378 */ 1379 public static final int SENSOR_REFERENCE_ILLUMINANT1_D55 = 20; 1380 1381 /** 1382 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1383 */ 1384 public static final int SENSOR_REFERENCE_ILLUMINANT1_D65 = 21; 1385 1386 /** 1387 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1388 */ 1389 public static final int SENSOR_REFERENCE_ILLUMINANT1_D75 = 22; 1390 1391 /** 1392 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1393 */ 1394 public static final int SENSOR_REFERENCE_ILLUMINANT1_D50 = 23; 1395 1396 /** 1397 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 1398 */ 1399 public static final int SENSOR_REFERENCE_ILLUMINANT1_ISO_STUDIO_TUNGSTEN = 24; 1400 1401 // 1402 // Enumeration values for CameraCharacteristics#LED_AVAILABLE_LEDS 1403 // 1404 1405 /** 1406 * <p>android.led.transmit control is used.</p> 1407 * @see CameraCharacteristics#LED_AVAILABLE_LEDS 1408 * @hide 1409 */ 1410 public static final int LED_AVAILABLE_LEDS_TRANSMIT = 0; 1411 1412 // 1413 // Enumeration values for CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL 1414 // 1415 1416 /** 1417 * <p>This camera device does not have enough capabilities to qualify as a <code>FULL</code> device or 1418 * better.</p> 1419 * <p>Only the stream configurations listed in the <code>LEGACY</code> and <code>LIMITED</code> tables in the 1420 * {@link android.hardware.camera2.CameraDevice#createCaptureSession createCaptureSession} documentation are guaranteed to be supported.</p> 1421 * <p>All <code>LIMITED</code> devices support the <code>BACKWARDS_COMPATIBLE</code> capability, indicating basic 1422 * support for color image capture. The only exception is that the device may 1423 * alternatively support only the <code>DEPTH_OUTPUT</code> capability, if it can only output depth 1424 * measurements and not color images.</p> 1425 * <p><code>LIMITED</code> devices and above require the use of {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger} 1426 * to lock exposure metering (and calculate flash power, for cameras with flash) before 1427 * capturing a high-quality still image.</p> 1428 * <p>A <code>LIMITED</code> device that only lists the <code>BACKWARDS_COMPATIBLE</code> capability is only 1429 * required to support full-automatic operation and post-processing (<code>OFF</code> is not 1430 * supported for {@link CaptureRequest#CONTROL_AE_MODE android.control.aeMode}, {@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}, or 1431 * {@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode})</p> 1432 * <p>Additional capabilities may optionally be supported by a <code>LIMITED</code>-level device, and 1433 * can be checked for in {@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities}.</p> 1434 * 1435 * @see CaptureRequest#CONTROL_AE_MODE 1436 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER 1437 * @see CaptureRequest#CONTROL_AF_MODE 1438 * @see CaptureRequest#CONTROL_AWB_MODE 1439 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 1440 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL 1441 */ 1442 public static final int INFO_SUPPORTED_HARDWARE_LEVEL_LIMITED = 0; 1443 1444 /** 1445 * <p>This camera device is capable of supporting advanced imaging applications.</p> 1446 * <p>The stream configurations listed in the <code>FULL</code>, <code>LEGACY</code> and <code>LIMITED</code> tables in the 1447 * {@link android.hardware.camera2.CameraDevice#createCaptureSession createCaptureSession} documentation are guaranteed to be supported.</p> 1448 * <p>A <code>FULL</code> device will support below capabilities:</p> 1449 * <ul> 1450 * <li><code>BURST_CAPTURE</code> capability ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} contains 1451 * <code>BURST_CAPTURE</code>)</li> 1452 * <li>Per frame control ({@link CameraCharacteristics#SYNC_MAX_LATENCY android.sync.maxLatency} <code>==</code> PER_FRAME_CONTROL)</li> 1453 * <li>Manual sensor control ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} contains <code>MANUAL_SENSOR</code>)</li> 1454 * <li>Manual post-processing control ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} contains 1455 * <code>MANUAL_POST_PROCESSING</code>)</li> 1456 * <li>The required exposure time range defined in {@link CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE android.sensor.info.exposureTimeRange}</li> 1457 * <li>The required maxFrameDuration defined in {@link CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION android.sensor.info.maxFrameDuration}</li> 1458 * </ul> 1459 * <p>Note: 1460 * Pre-API level 23, FULL devices also supported arbitrary cropping region 1461 * ({@link CameraCharacteristics#SCALER_CROPPING_TYPE android.scaler.croppingType} <code>== FREEFORM</code>); this requirement was relaxed in API level 1462 * 23, and <code>FULL</code> devices may only support <code>CENTERED</code> cropping.</p> 1463 * 1464 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 1465 * @see CameraCharacteristics#SCALER_CROPPING_TYPE 1466 * @see CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE 1467 * @see CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION 1468 * @see CameraCharacteristics#SYNC_MAX_LATENCY 1469 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL 1470 */ 1471 public static final int INFO_SUPPORTED_HARDWARE_LEVEL_FULL = 1; 1472 1473 /** 1474 * <p>This camera device is running in backward compatibility mode.</p> 1475 * <p>Only the stream configurations listed in the <code>LEGACY</code> table in the {@link android.hardware.camera2.CameraDevice#createCaptureSession createCaptureSession} documentation are supported.</p> 1476 * <p>A <code>LEGACY</code> device does not support per-frame control, manual sensor control, manual 1477 * post-processing, arbitrary cropping regions, and has relaxed performance constraints. 1478 * No additional capabilities beyond <code>BACKWARD_COMPATIBLE</code> will ever be listed by a 1479 * <code>LEGACY</code> device in {@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities}.</p> 1480 * <p>In addition, the {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger} is not functional on <code>LEGACY</code> 1481 * devices. Instead, every request that includes a JPEG-format output target is treated 1482 * as triggering a still capture, internally executing a precapture trigger. This may 1483 * fire the flash for flash power metering during precapture, and then fire the flash 1484 * for the final capture, if a flash is available on the device and the AE mode is set to 1485 * enable the flash.</p> 1486 * <p>Devices that initially shipped with Android version {@link android.os.Build.VERSION_CODES#Q Q} or newer will not include any LEGACY-level devices.</p> 1487 * 1488 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER 1489 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 1490 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL 1491 */ 1492 public static final int INFO_SUPPORTED_HARDWARE_LEVEL_LEGACY = 2; 1493 1494 /** 1495 * <p>This camera device is capable of YUV reprocessing and RAW data capture, in addition to 1496 * FULL-level capabilities.</p> 1497 * <p>The stream configurations listed in the <code>LEVEL_3</code>, <code>RAW</code>, <code>FULL</code>, <code>LEGACY</code> and 1498 * <code>LIMITED</code> tables in the {@link android.hardware.camera2.CameraDevice#createCaptureSession createCaptureSession} documentation are guaranteed to be supported.</p> 1499 * <p>The following additional capabilities are guaranteed to be supported:</p> 1500 * <ul> 1501 * <li><code>YUV_REPROCESSING</code> capability ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} contains 1502 * <code>YUV_REPROCESSING</code>)</li> 1503 * <li><code>RAW</code> capability ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} contains 1504 * <code>RAW</code>)</li> 1505 * </ul> 1506 * 1507 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 1508 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL 1509 */ 1510 public static final int INFO_SUPPORTED_HARDWARE_LEVEL_3 = 3; 1511 1512 /** 1513 * <p>This camera device is backed by an external camera connected to this Android device.</p> 1514 * <p>The device has capability identical to a LIMITED level device, with the following 1515 * exceptions:</p> 1516 * <ul> 1517 * <li>The device may not report lens/sensor related information such as<ul> 1518 * <li>{@link CaptureRequest#LENS_FOCAL_LENGTH android.lens.focalLength}</li> 1519 * <li>{@link CameraCharacteristics#LENS_INFO_HYPERFOCAL_DISTANCE android.lens.info.hyperfocalDistance}</li> 1520 * <li>{@link CameraCharacteristics#SENSOR_INFO_PHYSICAL_SIZE android.sensor.info.physicalSize}</li> 1521 * <li>{@link CameraCharacteristics#SENSOR_INFO_WHITE_LEVEL android.sensor.info.whiteLevel}</li> 1522 * <li>{@link CameraCharacteristics#SENSOR_BLACK_LEVEL_PATTERN android.sensor.blackLevelPattern}</li> 1523 * <li>{@link CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT android.sensor.info.colorFilterArrangement}</li> 1524 * <li>{@link CaptureResult#SENSOR_ROLLING_SHUTTER_SKEW android.sensor.rollingShutterSkew}</li> 1525 * </ul> 1526 * </li> 1527 * <li>The device will report 0 for {@link CameraCharacteristics#SENSOR_ORIENTATION android.sensor.orientation}</li> 1528 * <li>The device has less guarantee on stable framerate, as the framerate partly depends 1529 * on the external camera being used.</li> 1530 * </ul> 1531 * 1532 * @see CaptureRequest#LENS_FOCAL_LENGTH 1533 * @see CameraCharacteristics#LENS_INFO_HYPERFOCAL_DISTANCE 1534 * @see CameraCharacteristics#SENSOR_BLACK_LEVEL_PATTERN 1535 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT 1536 * @see CameraCharacteristics#SENSOR_INFO_PHYSICAL_SIZE 1537 * @see CameraCharacteristics#SENSOR_INFO_WHITE_LEVEL 1538 * @see CameraCharacteristics#SENSOR_ORIENTATION 1539 * @see CaptureResult#SENSOR_ROLLING_SHUTTER_SKEW 1540 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL 1541 */ 1542 public static final int INFO_SUPPORTED_HARDWARE_LEVEL_EXTERNAL = 4; 1543 1544 // 1545 // Enumeration values for CameraCharacteristics#SYNC_MAX_LATENCY 1546 // 1547 1548 /** 1549 * <p>Every frame has the requests immediately applied.</p> 1550 * <p>Changing controls over multiple requests one after another will 1551 * produce results that have those controls applied atomically 1552 * each frame.</p> 1553 * <p>All FULL capability devices will have this as their maxLatency.</p> 1554 * @see CameraCharacteristics#SYNC_MAX_LATENCY 1555 */ 1556 public static final int SYNC_MAX_LATENCY_PER_FRAME_CONTROL = 0; 1557 1558 /** 1559 * <p>Each new frame has some subset (potentially the entire set) 1560 * of the past requests applied to the camera settings.</p> 1561 * <p>By submitting a series of identical requests, the camera device 1562 * will eventually have the camera settings applied, but it is 1563 * unknown when that exact point will be.</p> 1564 * <p>All LEGACY capability devices will have this as their maxLatency.</p> 1565 * @see CameraCharacteristics#SYNC_MAX_LATENCY 1566 */ 1567 public static final int SYNC_MAX_LATENCY_UNKNOWN = -1; 1568 1569 // 1570 // Enumeration values for CameraCharacteristics#LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE 1571 // 1572 1573 /** 1574 * <p>A software mechanism is used to synchronize between the physical cameras. As a result, 1575 * the timestamp of an image from a physical stream is only an approximation of the 1576 * image sensor start-of-exposure time.</p> 1577 * @see CameraCharacteristics#LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE 1578 */ 1579 public static final int LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE_APPROXIMATE = 0; 1580 1581 /** 1582 * <p>The camera device supports frame timestamp synchronization at the hardware level, 1583 * and the timestamp of a physical stream image accurately reflects its 1584 * start-of-exposure time.</p> 1585 * @see CameraCharacteristics#LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE 1586 */ 1587 public static final int LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE_CALIBRATED = 1; 1588 1589 // 1590 // Enumeration values for CaptureRequest#COLOR_CORRECTION_MODE 1591 // 1592 1593 /** 1594 * <p>Use the {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} matrix 1595 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} to do color conversion.</p> 1596 * <p>All advanced white balance adjustments (not specified 1597 * by our white balance pipeline) must be disabled.</p> 1598 * <p>If AWB is enabled with <code>{@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode} != OFF</code>, then 1599 * TRANSFORM_MATRIX is ignored. The camera device will override 1600 * this value to either FAST or HIGH_QUALITY.</p> 1601 * 1602 * @see CaptureRequest#COLOR_CORRECTION_GAINS 1603 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM 1604 * @see CaptureRequest#CONTROL_AWB_MODE 1605 * @see CaptureRequest#COLOR_CORRECTION_MODE 1606 */ 1607 public static final int COLOR_CORRECTION_MODE_TRANSFORM_MATRIX = 0; 1608 1609 /** 1610 * <p>Color correction processing must not slow down 1611 * capture rate relative to sensor raw output.</p> 1612 * <p>Advanced white balance adjustments above and beyond 1613 * the specified white balance pipeline may be applied.</p> 1614 * <p>If AWB is enabled with <code>{@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode} != OFF</code>, then 1615 * the camera device uses the last frame's AWB values 1616 * (or defaults if AWB has never been run).</p> 1617 * 1618 * @see CaptureRequest#CONTROL_AWB_MODE 1619 * @see CaptureRequest#COLOR_CORRECTION_MODE 1620 */ 1621 public static final int COLOR_CORRECTION_MODE_FAST = 1; 1622 1623 /** 1624 * <p>Color correction processing operates at improved 1625 * quality but the capture rate might be reduced (relative to sensor 1626 * raw output rate)</p> 1627 * <p>Advanced white balance adjustments above and beyond 1628 * the specified white balance pipeline may be applied.</p> 1629 * <p>If AWB is enabled with <code>{@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode} != OFF</code>, then 1630 * the camera device uses the last frame's AWB values 1631 * (or defaults if AWB has never been run).</p> 1632 * 1633 * @see CaptureRequest#CONTROL_AWB_MODE 1634 * @see CaptureRequest#COLOR_CORRECTION_MODE 1635 */ 1636 public static final int COLOR_CORRECTION_MODE_HIGH_QUALITY = 2; 1637 1638 // 1639 // Enumeration values for CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE 1640 // 1641 1642 /** 1643 * <p>No aberration correction is applied.</p> 1644 * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE 1645 */ 1646 public static final int COLOR_CORRECTION_ABERRATION_MODE_OFF = 0; 1647 1648 /** 1649 * <p>Aberration correction will not slow down capture rate 1650 * relative to sensor raw output.</p> 1651 * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE 1652 */ 1653 public static final int COLOR_CORRECTION_ABERRATION_MODE_FAST = 1; 1654 1655 /** 1656 * <p>Aberration correction operates at improved quality but the capture rate might be 1657 * reduced (relative to sensor raw output rate)</p> 1658 * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE 1659 */ 1660 public static final int COLOR_CORRECTION_ABERRATION_MODE_HIGH_QUALITY = 2; 1661 1662 // 1663 // Enumeration values for CaptureRequest#CONTROL_AE_ANTIBANDING_MODE 1664 // 1665 1666 /** 1667 * <p>The camera device will not adjust exposure duration to 1668 * avoid banding problems.</p> 1669 * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE 1670 */ 1671 public static final int CONTROL_AE_ANTIBANDING_MODE_OFF = 0; 1672 1673 /** 1674 * <p>The camera device will adjust exposure duration to 1675 * avoid banding problems with 50Hz illumination sources.</p> 1676 * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE 1677 */ 1678 public static final int CONTROL_AE_ANTIBANDING_MODE_50HZ = 1; 1679 1680 /** 1681 * <p>The camera device will adjust exposure duration to 1682 * avoid banding problems with 60Hz illumination 1683 * sources.</p> 1684 * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE 1685 */ 1686 public static final int CONTROL_AE_ANTIBANDING_MODE_60HZ = 2; 1687 1688 /** 1689 * <p>The camera device will automatically adapt its 1690 * antibanding routine to the current illumination 1691 * condition. This is the default mode if AUTO is 1692 * available on given camera device.</p> 1693 * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE 1694 */ 1695 public static final int CONTROL_AE_ANTIBANDING_MODE_AUTO = 3; 1696 1697 // 1698 // Enumeration values for CaptureRequest#CONTROL_AE_MODE 1699 // 1700 1701 /** 1702 * <p>The camera device's autoexposure routine is disabled.</p> 1703 * <p>The application-selected {@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}, 1704 * {@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity} and 1705 * {@link CaptureRequest#SENSOR_FRAME_DURATION android.sensor.frameDuration} are used by the camera 1706 * device, along with android.flash.* fields, if there's 1707 * a flash unit for this camera device.</p> 1708 * <p>Note that auto-white balance (AWB) and auto-focus (AF) 1709 * behavior is device dependent when AE is in OFF mode. 1710 * To have consistent behavior across different devices, 1711 * it is recommended to either set AWB and AF to OFF mode 1712 * or lock AWB and AF before setting AE to OFF. 1713 * See {@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode}, {@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}, 1714 * {@link CaptureRequest#CONTROL_AWB_LOCK android.control.awbLock}, and {@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger} 1715 * for more details.</p> 1716 * <p>LEGACY devices do not support the OFF mode and will 1717 * override attempts to use this value to ON.</p> 1718 * 1719 * @see CaptureRequest#CONTROL_AF_MODE 1720 * @see CaptureRequest#CONTROL_AF_TRIGGER 1721 * @see CaptureRequest#CONTROL_AWB_LOCK 1722 * @see CaptureRequest#CONTROL_AWB_MODE 1723 * @see CaptureRequest#SENSOR_EXPOSURE_TIME 1724 * @see CaptureRequest#SENSOR_FRAME_DURATION 1725 * @see CaptureRequest#SENSOR_SENSITIVITY 1726 * @see CaptureRequest#CONTROL_AE_MODE 1727 */ 1728 public static final int CONTROL_AE_MODE_OFF = 0; 1729 1730 /** 1731 * <p>The camera device's autoexposure routine is active, 1732 * with no flash control.</p> 1733 * <p>The application's values for 1734 * {@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}, 1735 * {@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}, and 1736 * {@link CaptureRequest#SENSOR_FRAME_DURATION android.sensor.frameDuration} are ignored. The 1737 * application has control over the various 1738 * android.flash.* fields.</p> 1739 * 1740 * @see CaptureRequest#SENSOR_EXPOSURE_TIME 1741 * @see CaptureRequest#SENSOR_FRAME_DURATION 1742 * @see CaptureRequest#SENSOR_SENSITIVITY 1743 * @see CaptureRequest#CONTROL_AE_MODE 1744 */ 1745 public static final int CONTROL_AE_MODE_ON = 1; 1746 1747 /** 1748 * <p>Like ON, except that the camera device also controls 1749 * the camera's flash unit, firing it in low-light 1750 * conditions.</p> 1751 * <p>The flash may be fired during a precapture sequence 1752 * (triggered by {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}) and 1753 * may be fired for captures for which the 1754 * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} field is set to 1755 * STILL_CAPTURE</p> 1756 * 1757 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER 1758 * @see CaptureRequest#CONTROL_CAPTURE_INTENT 1759 * @see CaptureRequest#CONTROL_AE_MODE 1760 */ 1761 public static final int CONTROL_AE_MODE_ON_AUTO_FLASH = 2; 1762 1763 /** 1764 * <p>Like ON, except that the camera device also controls 1765 * the camera's flash unit, always firing it for still 1766 * captures.</p> 1767 * <p>The flash may be fired during a precapture sequence 1768 * (triggered by {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}) and 1769 * will always be fired for captures for which the 1770 * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} field is set to 1771 * STILL_CAPTURE</p> 1772 * 1773 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER 1774 * @see CaptureRequest#CONTROL_CAPTURE_INTENT 1775 * @see CaptureRequest#CONTROL_AE_MODE 1776 */ 1777 public static final int CONTROL_AE_MODE_ON_ALWAYS_FLASH = 3; 1778 1779 /** 1780 * <p>Like ON_AUTO_FLASH, but with automatic red eye 1781 * reduction.</p> 1782 * <p>If deemed necessary by the camera device, a red eye 1783 * reduction flash will fire during the precapture 1784 * sequence.</p> 1785 * @see CaptureRequest#CONTROL_AE_MODE 1786 */ 1787 public static final int CONTROL_AE_MODE_ON_AUTO_FLASH_REDEYE = 4; 1788 1789 /** 1790 * <p>An external flash has been turned on.</p> 1791 * <p>It informs the camera device that an external flash has been turned on, and that 1792 * metering (and continuous focus if active) should be quickly recaculated to account 1793 * for the external flash. Otherwise, this mode acts like ON.</p> 1794 * <p>When the external flash is turned off, AE mode should be changed to one of the 1795 * other available AE modes.</p> 1796 * <p>If the camera device supports AE external flash mode, {@link CaptureResult#CONTROL_AE_STATE android.control.aeState} must 1797 * be FLASH_REQUIRED after the camera device finishes AE scan and it's too dark without 1798 * flash.</p> 1799 * 1800 * @see CaptureResult#CONTROL_AE_STATE 1801 * @see CaptureRequest#CONTROL_AE_MODE 1802 */ 1803 public static final int CONTROL_AE_MODE_ON_EXTERNAL_FLASH = 5; 1804 1805 // 1806 // Enumeration values for CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER 1807 // 1808 1809 /** 1810 * <p>The trigger is idle.</p> 1811 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER 1812 */ 1813 public static final int CONTROL_AE_PRECAPTURE_TRIGGER_IDLE = 0; 1814 1815 /** 1816 * <p>The precapture metering sequence will be started 1817 * by the camera device.</p> 1818 * <p>The exact effect of the precapture trigger depends on 1819 * the current AE mode and state.</p> 1820 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER 1821 */ 1822 public static final int CONTROL_AE_PRECAPTURE_TRIGGER_START = 1; 1823 1824 /** 1825 * <p>The camera device will cancel any currently active or completed 1826 * precapture metering sequence, the auto-exposure routine will return to its 1827 * initial state.</p> 1828 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER 1829 */ 1830 public static final int CONTROL_AE_PRECAPTURE_TRIGGER_CANCEL = 2; 1831 1832 // 1833 // Enumeration values for CaptureRequest#CONTROL_AF_MODE 1834 // 1835 1836 /** 1837 * <p>The auto-focus routine does not control the lens; 1838 * {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance} is controlled by the 1839 * application.</p> 1840 * 1841 * @see CaptureRequest#LENS_FOCUS_DISTANCE 1842 * @see CaptureRequest#CONTROL_AF_MODE 1843 */ 1844 public static final int CONTROL_AF_MODE_OFF = 0; 1845 1846 /** 1847 * <p>Basic automatic focus mode.</p> 1848 * <p>In this mode, the lens does not move unless 1849 * the autofocus trigger action is called. When that trigger 1850 * is activated, AF will transition to ACTIVE_SCAN, then to 1851 * the outcome of the scan (FOCUSED or NOT_FOCUSED).</p> 1852 * <p>Always supported if lens is not fixed focus.</p> 1853 * <p>Use {@link CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE android.lens.info.minimumFocusDistance} to determine if lens 1854 * is fixed-focus.</p> 1855 * <p>Triggering AF_CANCEL resets the lens position to default, 1856 * and sets the AF state to INACTIVE.</p> 1857 * 1858 * @see CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE 1859 * @see CaptureRequest#CONTROL_AF_MODE 1860 */ 1861 public static final int CONTROL_AF_MODE_AUTO = 1; 1862 1863 /** 1864 * <p>Close-up focusing mode.</p> 1865 * <p>In this mode, the lens does not move unless the 1866 * autofocus trigger action is called. When that trigger is 1867 * activated, AF will transition to ACTIVE_SCAN, then to 1868 * the outcome of the scan (FOCUSED or NOT_FOCUSED). This 1869 * mode is optimized for focusing on objects very close to 1870 * the camera.</p> 1871 * <p>When that trigger is activated, AF will transition to 1872 * ACTIVE_SCAN, then to the outcome of the scan (FOCUSED or 1873 * NOT_FOCUSED). Triggering cancel AF resets the lens 1874 * position to default, and sets the AF state to 1875 * INACTIVE.</p> 1876 * @see CaptureRequest#CONTROL_AF_MODE 1877 */ 1878 public static final int CONTROL_AF_MODE_MACRO = 2; 1879 1880 /** 1881 * <p>In this mode, the AF algorithm modifies the lens 1882 * position continually to attempt to provide a 1883 * constantly-in-focus image stream.</p> 1884 * <p>The focusing behavior should be suitable for good quality 1885 * video recording; typically this means slower focus 1886 * movement and no overshoots. When the AF trigger is not 1887 * involved, the AF algorithm should start in INACTIVE state, 1888 * and then transition into PASSIVE_SCAN and PASSIVE_FOCUSED 1889 * states as appropriate. When the AF trigger is activated, 1890 * the algorithm should immediately transition into 1891 * AF_FOCUSED or AF_NOT_FOCUSED as appropriate, and lock the 1892 * lens position until a cancel AF trigger is received.</p> 1893 * <p>Once cancel is received, the algorithm should transition 1894 * back to INACTIVE and resume passive scan. Note that this 1895 * behavior is not identical to CONTINUOUS_PICTURE, since an 1896 * ongoing PASSIVE_SCAN must immediately be 1897 * canceled.</p> 1898 * @see CaptureRequest#CONTROL_AF_MODE 1899 */ 1900 public static final int CONTROL_AF_MODE_CONTINUOUS_VIDEO = 3; 1901 1902 /** 1903 * <p>In this mode, the AF algorithm modifies the lens 1904 * position continually to attempt to provide a 1905 * constantly-in-focus image stream.</p> 1906 * <p>The focusing behavior should be suitable for still image 1907 * capture; typically this means focusing as fast as 1908 * possible. When the AF trigger is not involved, the AF 1909 * algorithm should start in INACTIVE state, and then 1910 * transition into PASSIVE_SCAN and PASSIVE_FOCUSED states as 1911 * appropriate as it attempts to maintain focus. When the AF 1912 * trigger is activated, the algorithm should finish its 1913 * PASSIVE_SCAN if active, and then transition into 1914 * AF_FOCUSED or AF_NOT_FOCUSED as appropriate, and lock the 1915 * lens position until a cancel AF trigger is received.</p> 1916 * <p>When the AF cancel trigger is activated, the algorithm 1917 * should transition back to INACTIVE and then act as if it 1918 * has just been started.</p> 1919 * @see CaptureRequest#CONTROL_AF_MODE 1920 */ 1921 public static final int CONTROL_AF_MODE_CONTINUOUS_PICTURE = 4; 1922 1923 /** 1924 * <p>Extended depth of field (digital focus) mode.</p> 1925 * <p>The camera device will produce images with an extended 1926 * depth of field automatically; no special focusing 1927 * operations need to be done before taking a picture.</p> 1928 * <p>AF triggers are ignored, and the AF state will always be 1929 * INACTIVE.</p> 1930 * @see CaptureRequest#CONTROL_AF_MODE 1931 */ 1932 public static final int CONTROL_AF_MODE_EDOF = 5; 1933 1934 // 1935 // Enumeration values for CaptureRequest#CONTROL_AF_TRIGGER 1936 // 1937 1938 /** 1939 * <p>The trigger is idle.</p> 1940 * @see CaptureRequest#CONTROL_AF_TRIGGER 1941 */ 1942 public static final int CONTROL_AF_TRIGGER_IDLE = 0; 1943 1944 /** 1945 * <p>Autofocus will trigger now.</p> 1946 * @see CaptureRequest#CONTROL_AF_TRIGGER 1947 */ 1948 public static final int CONTROL_AF_TRIGGER_START = 1; 1949 1950 /** 1951 * <p>Autofocus will return to its initial 1952 * state, and cancel any currently active trigger.</p> 1953 * @see CaptureRequest#CONTROL_AF_TRIGGER 1954 */ 1955 public static final int CONTROL_AF_TRIGGER_CANCEL = 2; 1956 1957 // 1958 // Enumeration values for CaptureRequest#CONTROL_AWB_MODE 1959 // 1960 1961 /** 1962 * <p>The camera device's auto-white balance routine is disabled.</p> 1963 * <p>The application-selected color transform matrix 1964 * ({@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}) and gains 1965 * ({@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains}) are used by the camera 1966 * device for manual white balance control.</p> 1967 * 1968 * @see CaptureRequest#COLOR_CORRECTION_GAINS 1969 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM 1970 * @see CaptureRequest#CONTROL_AWB_MODE 1971 */ 1972 public static final int CONTROL_AWB_MODE_OFF = 0; 1973 1974 /** 1975 * <p>The camera device's auto-white balance routine is active.</p> 1976 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} 1977 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. 1978 * For devices that support the MANUAL_POST_PROCESSING capability, the 1979 * values used by the camera device for the transform and gains 1980 * will be available in the capture result for this request.</p> 1981 * 1982 * @see CaptureRequest#COLOR_CORRECTION_GAINS 1983 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM 1984 * @see CaptureRequest#CONTROL_AWB_MODE 1985 */ 1986 public static final int CONTROL_AWB_MODE_AUTO = 1; 1987 1988 /** 1989 * <p>The camera device's auto-white balance routine is disabled; 1990 * the camera device uses incandescent light as the assumed scene 1991 * illumination for white balance.</p> 1992 * <p>While the exact white balance transforms are up to the 1993 * camera device, they will approximately match the CIE 1994 * standard illuminant A.</p> 1995 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} 1996 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. 1997 * For devices that support the MANUAL_POST_PROCESSING capability, the 1998 * values used by the camera device for the transform and gains 1999 * will be available in the capture result for this request.</p> 2000 * 2001 * @see CaptureRequest#COLOR_CORRECTION_GAINS 2002 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM 2003 * @see CaptureRequest#CONTROL_AWB_MODE 2004 */ 2005 public static final int CONTROL_AWB_MODE_INCANDESCENT = 2; 2006 2007 /** 2008 * <p>The camera device's auto-white balance routine is disabled; 2009 * the camera device uses fluorescent light as the assumed scene 2010 * illumination for white balance.</p> 2011 * <p>While the exact white balance transforms are up to the 2012 * camera device, they will approximately match the CIE 2013 * standard illuminant F2.</p> 2014 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} 2015 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. 2016 * For devices that support the MANUAL_POST_PROCESSING capability, the 2017 * values used by the camera device for the transform and gains 2018 * will be available in the capture result for this request.</p> 2019 * 2020 * @see CaptureRequest#COLOR_CORRECTION_GAINS 2021 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM 2022 * @see CaptureRequest#CONTROL_AWB_MODE 2023 */ 2024 public static final int CONTROL_AWB_MODE_FLUORESCENT = 3; 2025 2026 /** 2027 * <p>The camera device's auto-white balance routine is disabled; 2028 * the camera device uses warm fluorescent light as the assumed scene 2029 * illumination for white balance.</p> 2030 * <p>While the exact white balance transforms are up to the 2031 * camera device, they will approximately match the CIE 2032 * standard illuminant F4.</p> 2033 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} 2034 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. 2035 * For devices that support the MANUAL_POST_PROCESSING capability, the 2036 * values used by the camera device for the transform and gains 2037 * will be available in the capture result for this request.</p> 2038 * 2039 * @see CaptureRequest#COLOR_CORRECTION_GAINS 2040 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM 2041 * @see CaptureRequest#CONTROL_AWB_MODE 2042 */ 2043 public static final int CONTROL_AWB_MODE_WARM_FLUORESCENT = 4; 2044 2045 /** 2046 * <p>The camera device's auto-white balance routine is disabled; 2047 * the camera device uses daylight light as the assumed scene 2048 * illumination for white balance.</p> 2049 * <p>While the exact white balance transforms are up to the 2050 * camera device, they will approximately match the CIE 2051 * standard illuminant D65.</p> 2052 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} 2053 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. 2054 * For devices that support the MANUAL_POST_PROCESSING capability, the 2055 * values used by the camera device for the transform and gains 2056 * will be available in the capture result for this request.</p> 2057 * 2058 * @see CaptureRequest#COLOR_CORRECTION_GAINS 2059 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM 2060 * @see CaptureRequest#CONTROL_AWB_MODE 2061 */ 2062 public static final int CONTROL_AWB_MODE_DAYLIGHT = 5; 2063 2064 /** 2065 * <p>The camera device's auto-white balance routine is disabled; 2066 * the camera device uses cloudy daylight light as the assumed scene 2067 * illumination for white balance.</p> 2068 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} 2069 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. 2070 * For devices that support the MANUAL_POST_PROCESSING capability, the 2071 * values used by the camera device for the transform and gains 2072 * will be available in the capture result for this request.</p> 2073 * 2074 * @see CaptureRequest#COLOR_CORRECTION_GAINS 2075 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM 2076 * @see CaptureRequest#CONTROL_AWB_MODE 2077 */ 2078 public static final int CONTROL_AWB_MODE_CLOUDY_DAYLIGHT = 6; 2079 2080 /** 2081 * <p>The camera device's auto-white balance routine is disabled; 2082 * the camera device uses twilight light as the assumed scene 2083 * illumination for white balance.</p> 2084 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} 2085 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. 2086 * For devices that support the MANUAL_POST_PROCESSING capability, the 2087 * values used by the camera device for the transform and gains 2088 * will be available in the capture result for this request.</p> 2089 * 2090 * @see CaptureRequest#COLOR_CORRECTION_GAINS 2091 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM 2092 * @see CaptureRequest#CONTROL_AWB_MODE 2093 */ 2094 public static final int CONTROL_AWB_MODE_TWILIGHT = 7; 2095 2096 /** 2097 * <p>The camera device's auto-white balance routine is disabled; 2098 * the camera device uses shade light as the assumed scene 2099 * illumination for white balance.</p> 2100 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} 2101 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. 2102 * For devices that support the MANUAL_POST_PROCESSING capability, the 2103 * values used by the camera device for the transform and gains 2104 * will be available in the capture result for this request.</p> 2105 * 2106 * @see CaptureRequest#COLOR_CORRECTION_GAINS 2107 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM 2108 * @see CaptureRequest#CONTROL_AWB_MODE 2109 */ 2110 public static final int CONTROL_AWB_MODE_SHADE = 8; 2111 2112 // 2113 // Enumeration values for CaptureRequest#CONTROL_CAPTURE_INTENT 2114 // 2115 2116 /** 2117 * <p>The goal of this request doesn't fall into the other 2118 * categories. The camera device will default to preview-like 2119 * behavior.</p> 2120 * @see CaptureRequest#CONTROL_CAPTURE_INTENT 2121 */ 2122 public static final int CONTROL_CAPTURE_INTENT_CUSTOM = 0; 2123 2124 /** 2125 * <p>This request is for a preview-like use case.</p> 2126 * <p>The precapture trigger may be used to start off a metering 2127 * w/flash sequence.</p> 2128 * @see CaptureRequest#CONTROL_CAPTURE_INTENT 2129 */ 2130 public static final int CONTROL_CAPTURE_INTENT_PREVIEW = 1; 2131 2132 /** 2133 * <p>This request is for a still capture-type 2134 * use case.</p> 2135 * <p>If the flash unit is under automatic control, it may fire as needed.</p> 2136 * @see CaptureRequest#CONTROL_CAPTURE_INTENT 2137 */ 2138 public static final int CONTROL_CAPTURE_INTENT_STILL_CAPTURE = 2; 2139 2140 /** 2141 * <p>This request is for a video recording 2142 * use case.</p> 2143 * @see CaptureRequest#CONTROL_CAPTURE_INTENT 2144 */ 2145 public static final int CONTROL_CAPTURE_INTENT_VIDEO_RECORD = 3; 2146 2147 /** 2148 * <p>This request is for a video snapshot (still 2149 * image while recording video) use case.</p> 2150 * <p>The camera device should take the highest-quality image 2151 * possible (given the other settings) without disrupting the 2152 * frame rate of video recording. </p> 2153 * @see CaptureRequest#CONTROL_CAPTURE_INTENT 2154 */ 2155 public static final int CONTROL_CAPTURE_INTENT_VIDEO_SNAPSHOT = 4; 2156 2157 /** 2158 * <p>This request is for a ZSL usecase; the 2159 * application will stream full-resolution images and 2160 * reprocess one or several later for a final 2161 * capture.</p> 2162 * @see CaptureRequest#CONTROL_CAPTURE_INTENT 2163 */ 2164 public static final int CONTROL_CAPTURE_INTENT_ZERO_SHUTTER_LAG = 5; 2165 2166 /** 2167 * <p>This request is for manual capture use case where 2168 * the applications want to directly control the capture parameters.</p> 2169 * <p>For example, the application may wish to manually control 2170 * {@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}, {@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}, etc.</p> 2171 * 2172 * @see CaptureRequest#SENSOR_EXPOSURE_TIME 2173 * @see CaptureRequest#SENSOR_SENSITIVITY 2174 * @see CaptureRequest#CONTROL_CAPTURE_INTENT 2175 */ 2176 public static final int CONTROL_CAPTURE_INTENT_MANUAL = 6; 2177 2178 /** 2179 * <p>This request is for a motion tracking use case, where 2180 * the application will use camera and inertial sensor data to 2181 * locate and track objects in the world.</p> 2182 * <p>The camera device auto-exposure routine will limit the exposure time 2183 * of the camera to no more than 20 milliseconds, to minimize motion blur.</p> 2184 * @see CaptureRequest#CONTROL_CAPTURE_INTENT 2185 */ 2186 public static final int CONTROL_CAPTURE_INTENT_MOTION_TRACKING = 7; 2187 2188 // 2189 // Enumeration values for CaptureRequest#CONTROL_EFFECT_MODE 2190 // 2191 2192 /** 2193 * <p>No color effect will be applied.</p> 2194 * @see CaptureRequest#CONTROL_EFFECT_MODE 2195 */ 2196 public static final int CONTROL_EFFECT_MODE_OFF = 0; 2197 2198 /** 2199 * <p>A "monocolor" effect where the image is mapped into 2200 * a single color.</p> 2201 * <p>This will typically be grayscale.</p> 2202 * @see CaptureRequest#CONTROL_EFFECT_MODE 2203 */ 2204 public static final int CONTROL_EFFECT_MODE_MONO = 1; 2205 2206 /** 2207 * <p>A "photo-negative" effect where the image's colors 2208 * are inverted.</p> 2209 * @see CaptureRequest#CONTROL_EFFECT_MODE 2210 */ 2211 public static final int CONTROL_EFFECT_MODE_NEGATIVE = 2; 2212 2213 /** 2214 * <p>A "solarisation" effect (Sabattier effect) where the 2215 * image is wholly or partially reversed in 2216 * tone.</p> 2217 * @see CaptureRequest#CONTROL_EFFECT_MODE 2218 */ 2219 public static final int CONTROL_EFFECT_MODE_SOLARIZE = 3; 2220 2221 /** 2222 * <p>A "sepia" effect where the image is mapped into warm 2223 * gray, red, and brown tones.</p> 2224 * @see CaptureRequest#CONTROL_EFFECT_MODE 2225 */ 2226 public static final int CONTROL_EFFECT_MODE_SEPIA = 4; 2227 2228 /** 2229 * <p>A "posterization" effect where the image uses 2230 * discrete regions of tone rather than a continuous 2231 * gradient of tones.</p> 2232 * @see CaptureRequest#CONTROL_EFFECT_MODE 2233 */ 2234 public static final int CONTROL_EFFECT_MODE_POSTERIZE = 5; 2235 2236 /** 2237 * <p>A "whiteboard" effect where the image is typically displayed 2238 * as regions of white, with black or grey details.</p> 2239 * @see CaptureRequest#CONTROL_EFFECT_MODE 2240 */ 2241 public static final int CONTROL_EFFECT_MODE_WHITEBOARD = 6; 2242 2243 /** 2244 * <p>A "blackboard" effect where the image is typically displayed 2245 * as regions of black, with white or grey details.</p> 2246 * @see CaptureRequest#CONTROL_EFFECT_MODE 2247 */ 2248 public static final int CONTROL_EFFECT_MODE_BLACKBOARD = 7; 2249 2250 /** 2251 * <p>An "aqua" effect where a blue hue is added to the image.</p> 2252 * @see CaptureRequest#CONTROL_EFFECT_MODE 2253 */ 2254 public static final int CONTROL_EFFECT_MODE_AQUA = 8; 2255 2256 // 2257 // Enumeration values for CaptureRequest#CONTROL_MODE 2258 // 2259 2260 /** 2261 * <p>Full application control of pipeline.</p> 2262 * <p>All control by the device's metering and focusing (3A) 2263 * routines is disabled, and no other settings in 2264 * android.control.* have any effect, except that 2265 * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} may be used by the camera 2266 * device to select post-processing values for processing 2267 * blocks that do not allow for manual control, or are not 2268 * exposed by the camera API.</p> 2269 * <p>However, the camera device's 3A routines may continue to 2270 * collect statistics and update their internal state so that 2271 * when control is switched to AUTO mode, good control values 2272 * can be immediately applied.</p> 2273 * 2274 * @see CaptureRequest#CONTROL_CAPTURE_INTENT 2275 * @see CaptureRequest#CONTROL_MODE 2276 */ 2277 public static final int CONTROL_MODE_OFF = 0; 2278 2279 /** 2280 * <p>Use settings for each individual 3A routine.</p> 2281 * <p>Manual control of capture parameters is disabled. All 2282 * controls in android.control.* besides sceneMode take 2283 * effect.</p> 2284 * @see CaptureRequest#CONTROL_MODE 2285 */ 2286 public static final int CONTROL_MODE_AUTO = 1; 2287 2288 /** 2289 * <p>Use a specific scene mode.</p> 2290 * <p>Enabling this disables control.aeMode, control.awbMode and 2291 * control.afMode controls; the camera device will ignore 2292 * those settings while USE_SCENE_MODE is active (except for 2293 * FACE_PRIORITY scene mode). Other control entries are still active. 2294 * This setting can only be used if scene mode is supported (i.e. 2295 * {@link CameraCharacteristics#CONTROL_AVAILABLE_SCENE_MODES android.control.availableSceneModes} 2296 * contain some modes other than DISABLED).</p> 2297 * <p>For extended scene modes such as BOKEH, please use USE_EXTENDED_SCENE_MODE instead.</p> 2298 * 2299 * @see CameraCharacteristics#CONTROL_AVAILABLE_SCENE_MODES 2300 * @see CaptureRequest#CONTROL_MODE 2301 */ 2302 public static final int CONTROL_MODE_USE_SCENE_MODE = 2; 2303 2304 /** 2305 * <p>Same as OFF mode, except that this capture will not be 2306 * used by camera device background auto-exposure, auto-white balance and 2307 * auto-focus algorithms (3A) to update their statistics.</p> 2308 * <p>Specifically, the 3A routines are locked to the last 2309 * values set from a request with AUTO, OFF, or 2310 * USE_SCENE_MODE, and any statistics or state updates 2311 * collected from manual captures with OFF_KEEP_STATE will be 2312 * discarded by the camera device.</p> 2313 * @see CaptureRequest#CONTROL_MODE 2314 */ 2315 public static final int CONTROL_MODE_OFF_KEEP_STATE = 3; 2316 2317 /** 2318 * <p>Use a specific extended scene mode.</p> 2319 * <p>When extended scene mode is on, the camera device may override certain control 2320 * parameters, such as targetFpsRange, AE, AWB, and AF modes, to achieve best power and 2321 * quality tradeoffs. Only the mandatory stream combinations of LIMITED hardware level 2322 * are guaranteed.</p> 2323 * <p>This setting can only be used if extended scene mode is supported (i.e. 2324 * android.control.availableExtendedSceneModes 2325 * contains some modes other than DISABLED).</p> 2326 * @see CaptureRequest#CONTROL_MODE 2327 */ 2328 public static final int CONTROL_MODE_USE_EXTENDED_SCENE_MODE = 4; 2329 2330 // 2331 // Enumeration values for CaptureRequest#CONTROL_SCENE_MODE 2332 // 2333 2334 /** 2335 * <p>Indicates that no scene modes are set for a given capture request.</p> 2336 * @see CaptureRequest#CONTROL_SCENE_MODE 2337 */ 2338 public static final int CONTROL_SCENE_MODE_DISABLED = 0; 2339 2340 /** 2341 * <p>If face detection support exists, use face 2342 * detection data for auto-focus, auto-white balance, and 2343 * auto-exposure routines.</p> 2344 * <p>If face detection statistics are disabled 2345 * (i.e. {@link CaptureRequest#STATISTICS_FACE_DETECT_MODE android.statistics.faceDetectMode} is set to OFF), 2346 * this should still operate correctly (but will not return 2347 * face detection statistics to the framework).</p> 2348 * <p>Unlike the other scene modes, {@link CaptureRequest#CONTROL_AE_MODE android.control.aeMode}, 2349 * {@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode}, and {@link CaptureRequest#CONTROL_AF_MODE android.control.afMode} 2350 * remain active when FACE_PRIORITY is set.</p> 2351 * 2352 * @see CaptureRequest#CONTROL_AE_MODE 2353 * @see CaptureRequest#CONTROL_AF_MODE 2354 * @see CaptureRequest#CONTROL_AWB_MODE 2355 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE 2356 * @see CaptureRequest#CONTROL_SCENE_MODE 2357 */ 2358 public static final int CONTROL_SCENE_MODE_FACE_PRIORITY = 1; 2359 2360 /** 2361 * <p>Optimized for photos of quickly moving objects.</p> 2362 * <p>Similar to SPORTS.</p> 2363 * @see CaptureRequest#CONTROL_SCENE_MODE 2364 */ 2365 public static final int CONTROL_SCENE_MODE_ACTION = 2; 2366 2367 /** 2368 * <p>Optimized for still photos of people.</p> 2369 * @see CaptureRequest#CONTROL_SCENE_MODE 2370 */ 2371 public static final int CONTROL_SCENE_MODE_PORTRAIT = 3; 2372 2373 /** 2374 * <p>Optimized for photos of distant macroscopic objects.</p> 2375 * @see CaptureRequest#CONTROL_SCENE_MODE 2376 */ 2377 public static final int CONTROL_SCENE_MODE_LANDSCAPE = 4; 2378 2379 /** 2380 * <p>Optimized for low-light settings.</p> 2381 * @see CaptureRequest#CONTROL_SCENE_MODE 2382 */ 2383 public static final int CONTROL_SCENE_MODE_NIGHT = 5; 2384 2385 /** 2386 * <p>Optimized for still photos of people in low-light 2387 * settings.</p> 2388 * @see CaptureRequest#CONTROL_SCENE_MODE 2389 */ 2390 public static final int CONTROL_SCENE_MODE_NIGHT_PORTRAIT = 6; 2391 2392 /** 2393 * <p>Optimized for dim, indoor settings where flash must 2394 * remain off.</p> 2395 * @see CaptureRequest#CONTROL_SCENE_MODE 2396 */ 2397 public static final int CONTROL_SCENE_MODE_THEATRE = 7; 2398 2399 /** 2400 * <p>Optimized for bright, outdoor beach settings.</p> 2401 * @see CaptureRequest#CONTROL_SCENE_MODE 2402 */ 2403 public static final int CONTROL_SCENE_MODE_BEACH = 8; 2404 2405 /** 2406 * <p>Optimized for bright, outdoor settings containing snow.</p> 2407 * @see CaptureRequest#CONTROL_SCENE_MODE 2408 */ 2409 public static final int CONTROL_SCENE_MODE_SNOW = 9; 2410 2411 /** 2412 * <p>Optimized for scenes of the setting sun.</p> 2413 * @see CaptureRequest#CONTROL_SCENE_MODE 2414 */ 2415 public static final int CONTROL_SCENE_MODE_SUNSET = 10; 2416 2417 /** 2418 * <p>Optimized to avoid blurry photos due to small amounts of 2419 * device motion (for example: due to hand shake).</p> 2420 * @see CaptureRequest#CONTROL_SCENE_MODE 2421 */ 2422 public static final int CONTROL_SCENE_MODE_STEADYPHOTO = 11; 2423 2424 /** 2425 * <p>Optimized for nighttime photos of fireworks.</p> 2426 * @see CaptureRequest#CONTROL_SCENE_MODE 2427 */ 2428 public static final int CONTROL_SCENE_MODE_FIREWORKS = 12; 2429 2430 /** 2431 * <p>Optimized for photos of quickly moving people.</p> 2432 * <p>Similar to ACTION.</p> 2433 * @see CaptureRequest#CONTROL_SCENE_MODE 2434 */ 2435 public static final int CONTROL_SCENE_MODE_SPORTS = 13; 2436 2437 /** 2438 * <p>Optimized for dim, indoor settings with multiple moving 2439 * people.</p> 2440 * @see CaptureRequest#CONTROL_SCENE_MODE 2441 */ 2442 public static final int CONTROL_SCENE_MODE_PARTY = 14; 2443 2444 /** 2445 * <p>Optimized for dim settings where the main light source 2446 * is a candle.</p> 2447 * @see CaptureRequest#CONTROL_SCENE_MODE 2448 */ 2449 public static final int CONTROL_SCENE_MODE_CANDLELIGHT = 15; 2450 2451 /** 2452 * <p>Optimized for accurately capturing a photo of barcode 2453 * for use by camera applications that wish to read the 2454 * barcode value.</p> 2455 * @see CaptureRequest#CONTROL_SCENE_MODE 2456 */ 2457 public static final int CONTROL_SCENE_MODE_BARCODE = 16; 2458 2459 /** 2460 * <p>This is deprecated, please use {@link android.hardware.camera2.CameraDevice#createConstrainedHighSpeedCaptureSession } 2461 * and {@link android.hardware.camera2.CameraConstrainedHighSpeedCaptureSession#createHighSpeedRequestList } 2462 * for high speed video recording.</p> 2463 * <p>Optimized for high speed video recording (frame rate >=60fps) use case.</p> 2464 * <p>The supported high speed video sizes and fps ranges are specified in 2465 * android.control.availableHighSpeedVideoConfigurations. To get desired 2466 * output frame rates, the application is only allowed to select video size 2467 * and fps range combinations listed in this static metadata. The fps range 2468 * can be control via {@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange}.</p> 2469 * <p>In this mode, the camera device will override aeMode, awbMode, and afMode to 2470 * ON, ON, and CONTINUOUS_VIDEO, respectively. All post-processing block mode 2471 * controls will be overridden to be FAST. Therefore, no manual control of capture 2472 * and post-processing parameters is possible. All other controls operate the 2473 * same as when {@link CaptureRequest#CONTROL_MODE android.control.mode} == AUTO. This means that all other 2474 * android.control.* fields continue to work, such as</p> 2475 * <ul> 2476 * <li>{@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange}</li> 2477 * <li>{@link CaptureRequest#CONTROL_AE_EXPOSURE_COMPENSATION android.control.aeExposureCompensation}</li> 2478 * <li>{@link CaptureRequest#CONTROL_AE_LOCK android.control.aeLock}</li> 2479 * <li>{@link CaptureRequest#CONTROL_AWB_LOCK android.control.awbLock}</li> 2480 * <li>{@link CaptureRequest#CONTROL_EFFECT_MODE android.control.effectMode}</li> 2481 * <li>{@link CaptureRequest#CONTROL_AE_REGIONS android.control.aeRegions}</li> 2482 * <li>{@link CaptureRequest#CONTROL_AF_REGIONS android.control.afRegions}</li> 2483 * <li>{@link CaptureRequest#CONTROL_AWB_REGIONS android.control.awbRegions}</li> 2484 * <li>{@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}</li> 2485 * <li>{@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}</li> 2486 * <li>{@link CaptureRequest#CONTROL_ZOOM_RATIO android.control.zoomRatio}</li> 2487 * </ul> 2488 * <p>Outside of android.control.*, the following controls will work:</p> 2489 * <ul> 2490 * <li>{@link CaptureRequest#FLASH_MODE android.flash.mode} (automatic flash for still capture will not work since aeMode is ON)</li> 2491 * <li>{@link CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE android.lens.opticalStabilizationMode} (if it is supported)</li> 2492 * <li>{@link CaptureRequest#SCALER_CROP_REGION android.scaler.cropRegion}</li> 2493 * <li>{@link CaptureRequest#STATISTICS_FACE_DETECT_MODE android.statistics.faceDetectMode}</li> 2494 * </ul> 2495 * <p>For high speed recording use case, the actual maximum supported frame rate may 2496 * be lower than what camera can output, depending on the destination Surfaces for 2497 * the image data. For example, if the destination surface is from video encoder, 2498 * the application need check if the video encoder is capable of supporting the 2499 * high frame rate for a given video size, or it will end up with lower recording 2500 * frame rate. If the destination surface is from preview window, the preview frame 2501 * rate will be bounded by the screen refresh rate.</p> 2502 * <p>The camera device will only support up to 2 output high speed streams 2503 * (processed non-stalling format defined in android.request.maxNumOutputStreams) 2504 * in this mode. This control will be effective only if all of below conditions are true:</p> 2505 * <ul> 2506 * <li>The application created no more than maxNumHighSpeedStreams processed non-stalling 2507 * format output streams, where maxNumHighSpeedStreams is calculated as 2508 * min(2, android.request.maxNumOutputStreams[Processed (but not-stalling)]).</li> 2509 * <li>The stream sizes are selected from the sizes reported by 2510 * android.control.availableHighSpeedVideoConfigurations.</li> 2511 * <li>No processed non-stalling or raw streams are configured.</li> 2512 * </ul> 2513 * <p>When above conditions are NOT satistied, the controls of this mode and 2514 * {@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange} will be ignored by the camera device, 2515 * the camera device will fall back to {@link CaptureRequest#CONTROL_MODE android.control.mode} <code>==</code> AUTO, 2516 * and the returned capture result metadata will give the fps range choosen 2517 * by the camera device.</p> 2518 * <p>Switching into or out of this mode may trigger some camera ISP/sensor 2519 * reconfigurations, which may introduce extra latency. It is recommended that 2520 * the application avoids unnecessary scene mode switch as much as possible.</p> 2521 * 2522 * @see CaptureRequest#CONTROL_AE_EXPOSURE_COMPENSATION 2523 * @see CaptureRequest#CONTROL_AE_LOCK 2524 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER 2525 * @see CaptureRequest#CONTROL_AE_REGIONS 2526 * @see CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE 2527 * @see CaptureRequest#CONTROL_AF_REGIONS 2528 * @see CaptureRequest#CONTROL_AF_TRIGGER 2529 * @see CaptureRequest#CONTROL_AWB_LOCK 2530 * @see CaptureRequest#CONTROL_AWB_REGIONS 2531 * @see CaptureRequest#CONTROL_EFFECT_MODE 2532 * @see CaptureRequest#CONTROL_MODE 2533 * @see CaptureRequest#CONTROL_ZOOM_RATIO 2534 * @see CaptureRequest#FLASH_MODE 2535 * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE 2536 * @see CaptureRequest#SCALER_CROP_REGION 2537 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE 2538 * @see CaptureRequest#CONTROL_SCENE_MODE 2539 * @deprecated Please refer to this API documentation to find the alternatives 2540 */ 2541 @Deprecated 2542 public static final int CONTROL_SCENE_MODE_HIGH_SPEED_VIDEO = 17; 2543 2544 /** 2545 * <p>Turn on a device-specific high dynamic range (HDR) mode.</p> 2546 * <p>In this scene mode, the camera device captures images 2547 * that keep a larger range of scene illumination levels 2548 * visible in the final image. For example, when taking a 2549 * picture of a object in front of a bright window, both 2550 * the object and the scene through the window may be 2551 * visible when using HDR mode, while in normal AUTO mode, 2552 * one or the other may be poorly exposed. As a tradeoff, 2553 * HDR mode generally takes much longer to capture a single 2554 * image, has no user control, and may have other artifacts 2555 * depending on the HDR method used.</p> 2556 * <p>Therefore, HDR captures operate at a much slower rate 2557 * than regular captures.</p> 2558 * <p>In this mode, on LIMITED or FULL devices, when a request 2559 * is made with a {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} of 2560 * STILL_CAPTURE, the camera device will capture an image 2561 * using a high dynamic range capture technique. On LEGACY 2562 * devices, captures that target a JPEG-format output will 2563 * be captured with HDR, and the capture intent is not 2564 * relevant.</p> 2565 * <p>The HDR capture may involve the device capturing a burst 2566 * of images internally and combining them into one, or it 2567 * may involve the device using specialized high dynamic 2568 * range capture hardware. In all cases, a single image is 2569 * produced in response to a capture request submitted 2570 * while in HDR mode.</p> 2571 * <p>Since substantial post-processing is generally needed to 2572 * produce an HDR image, only YUV, PRIVATE, and JPEG 2573 * outputs are supported for LIMITED/FULL device HDR 2574 * captures, and only JPEG outputs are supported for LEGACY 2575 * HDR captures. Using a RAW output for HDR capture is not 2576 * supported.</p> 2577 * <p>Some devices may also support always-on HDR, which 2578 * applies HDR processing at full frame rate. For these 2579 * devices, intents other than STILL_CAPTURE will also 2580 * produce an HDR output with no frame rate impact compared 2581 * to normal operation, though the quality may be lower 2582 * than for STILL_CAPTURE intents.</p> 2583 * <p>If SCENE_MODE_HDR is used with unsupported output types 2584 * or capture intents, the images captured will be as if 2585 * the SCENE_MODE was not enabled at all.</p> 2586 * 2587 * @see CaptureRequest#CONTROL_CAPTURE_INTENT 2588 * @see CaptureRequest#CONTROL_SCENE_MODE 2589 */ 2590 public static final int CONTROL_SCENE_MODE_HDR = 18; 2591 2592 /** 2593 * <p>Same as FACE_PRIORITY scene mode, except that the camera 2594 * device will choose higher sensitivity values ({@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}) 2595 * under low light conditions.</p> 2596 * <p>The camera device may be tuned to expose the images in a reduced 2597 * sensitivity range to produce the best quality images. For example, 2598 * if the {@link CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE android.sensor.info.sensitivityRange} gives range of [100, 1600], 2599 * the camera device auto-exposure routine tuning process may limit the actual 2600 * exposure sensitivity range to [100, 1200] to ensure that the noise level isn't 2601 * exessive in order to preserve the image quality. Under this situation, the image under 2602 * low light may be under-exposed when the sensor max exposure time (bounded by the 2603 * {@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange} when {@link CaptureRequest#CONTROL_AE_MODE android.control.aeMode} is one of the 2604 * ON_* modes) and effective max sensitivity are reached. This scene mode allows the 2605 * camera device auto-exposure routine to increase the sensitivity up to the max 2606 * sensitivity specified by {@link CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE android.sensor.info.sensitivityRange} when the scene is too 2607 * dark and the max exposure time is reached. The captured images may be noisier 2608 * compared with the images captured in normal FACE_PRIORITY mode; therefore, it is 2609 * recommended that the application only use this scene mode when it is capable of 2610 * reducing the noise level of the captured images.</p> 2611 * <p>Unlike the other scene modes, {@link CaptureRequest#CONTROL_AE_MODE android.control.aeMode}, 2612 * {@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode}, and {@link CaptureRequest#CONTROL_AF_MODE android.control.afMode} 2613 * remain active when FACE_PRIORITY_LOW_LIGHT is set.</p> 2614 * 2615 * @see CaptureRequest#CONTROL_AE_MODE 2616 * @see CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE 2617 * @see CaptureRequest#CONTROL_AF_MODE 2618 * @see CaptureRequest#CONTROL_AWB_MODE 2619 * @see CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE 2620 * @see CaptureRequest#SENSOR_SENSITIVITY 2621 * @see CaptureRequest#CONTROL_SCENE_MODE 2622 * @hide 2623 */ 2624 public static final int CONTROL_SCENE_MODE_FACE_PRIORITY_LOW_LIGHT = 19; 2625 2626 /** 2627 * <p>Scene mode values within the range of 2628 * <code>[DEVICE_CUSTOM_START, DEVICE_CUSTOM_END]</code> are reserved for device specific 2629 * customized scene modes.</p> 2630 * @see CaptureRequest#CONTROL_SCENE_MODE 2631 * @hide 2632 */ 2633 public static final int CONTROL_SCENE_MODE_DEVICE_CUSTOM_START = 100; 2634 2635 /** 2636 * <p>Scene mode values within the range of 2637 * <code>[DEVICE_CUSTOM_START, DEVICE_CUSTOM_END]</code> are reserved for device specific 2638 * customized scene modes.</p> 2639 * @see CaptureRequest#CONTROL_SCENE_MODE 2640 * @hide 2641 */ 2642 public static final int CONTROL_SCENE_MODE_DEVICE_CUSTOM_END = 127; 2643 2644 // 2645 // Enumeration values for CaptureRequest#CONTROL_VIDEO_STABILIZATION_MODE 2646 // 2647 2648 /** 2649 * <p>Video stabilization is disabled.</p> 2650 * @see CaptureRequest#CONTROL_VIDEO_STABILIZATION_MODE 2651 */ 2652 public static final int CONTROL_VIDEO_STABILIZATION_MODE_OFF = 0; 2653 2654 /** 2655 * <p>Video stabilization is enabled.</p> 2656 * @see CaptureRequest#CONTROL_VIDEO_STABILIZATION_MODE 2657 */ 2658 public static final int CONTROL_VIDEO_STABILIZATION_MODE_ON = 1; 2659 2660 // 2661 // Enumeration values for CaptureRequest#CONTROL_EXTENDED_SCENE_MODE 2662 // 2663 2664 /** 2665 * <p>Extended scene mode is disabled.</p> 2666 * @see CaptureRequest#CONTROL_EXTENDED_SCENE_MODE 2667 */ 2668 public static final int CONTROL_EXTENDED_SCENE_MODE_DISABLED = 0; 2669 2670 /** 2671 * <p>High quality bokeh mode is enabled for all non-raw streams (including YUV, 2672 * JPEG, and IMPLEMENTATION_DEFINED) when capture intent is STILL_CAPTURE. Due to the 2673 * extra image processing, this mode may introduce additional stall to non-raw streams. 2674 * This mode should be used in high quality still capture use case.</p> 2675 * @see CaptureRequest#CONTROL_EXTENDED_SCENE_MODE 2676 */ 2677 public static final int CONTROL_EXTENDED_SCENE_MODE_BOKEH_STILL_CAPTURE = 1; 2678 2679 /** 2680 * <p>Bokeh effect must not slow down capture rate relative to sensor raw output, 2681 * and the effect is applied to all processed streams no larger than the maximum 2682 * streaming dimension. This mode should be used if performance and power are a 2683 * priority, such as video recording.</p> 2684 * @see CaptureRequest#CONTROL_EXTENDED_SCENE_MODE 2685 */ 2686 public static final int CONTROL_EXTENDED_SCENE_MODE_BOKEH_CONTINUOUS = 2; 2687 2688 /** 2689 * <p>Vendor defined extended scene modes. These depend on vendor implementation.</p> 2690 * @see CaptureRequest#CONTROL_EXTENDED_SCENE_MODE 2691 * @hide 2692 */ 2693 public static final int CONTROL_EXTENDED_SCENE_MODE_VENDOR_START = 0x40; 2694 2695 // 2696 // Enumeration values for CaptureRequest#EDGE_MODE 2697 // 2698 2699 /** 2700 * <p>No edge enhancement is applied.</p> 2701 * @see CaptureRequest#EDGE_MODE 2702 */ 2703 public static final int EDGE_MODE_OFF = 0; 2704 2705 /** 2706 * <p>Apply edge enhancement at a quality level that does not slow down frame rate 2707 * relative to sensor output. It may be the same as OFF if edge enhancement will 2708 * slow down frame rate relative to sensor.</p> 2709 * @see CaptureRequest#EDGE_MODE 2710 */ 2711 public static final int EDGE_MODE_FAST = 1; 2712 2713 /** 2714 * <p>Apply high-quality edge enhancement, at a cost of possibly reduced output frame rate.</p> 2715 * @see CaptureRequest#EDGE_MODE 2716 */ 2717 public static final int EDGE_MODE_HIGH_QUALITY = 2; 2718 2719 /** 2720 * <p>Edge enhancement is applied at different 2721 * levels for different output streams, based on resolution. Streams at maximum recording 2722 * resolution (see {@link android.hardware.camera2.CameraDevice#createCaptureSession }) 2723 * or below have edge enhancement applied, while higher-resolution streams have no edge 2724 * enhancement applied. The level of edge enhancement for low-resolution streams is tuned 2725 * so that frame rate is not impacted, and the quality is equal to or better than FAST 2726 * (since it is only applied to lower-resolution outputs, quality may improve from FAST).</p> 2727 * <p>This mode is intended to be used by applications operating in a zero-shutter-lag mode 2728 * with YUV or PRIVATE reprocessing, where the application continuously captures 2729 * high-resolution intermediate buffers into a circular buffer, from which a final image is 2730 * produced via reprocessing when a user takes a picture. For such a use case, the 2731 * high-resolution buffers must not have edge enhancement applied to maximize efficiency of 2732 * preview and to avoid double-applying enhancement when reprocessed, while low-resolution 2733 * buffers (used for recording or preview, generally) need edge enhancement applied for 2734 * reasonable preview quality.</p> 2735 * <p>This mode is guaranteed to be supported by devices that support either the 2736 * YUV_REPROCESSING or PRIVATE_REPROCESSING capabilities 2737 * ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} lists either of those capabilities) and it will 2738 * be the default mode for CAMERA3_TEMPLATE_ZERO_SHUTTER_LAG template.</p> 2739 * 2740 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 2741 * @see CaptureRequest#EDGE_MODE 2742 */ 2743 public static final int EDGE_MODE_ZERO_SHUTTER_LAG = 3; 2744 2745 // 2746 // Enumeration values for CaptureRequest#FLASH_MODE 2747 // 2748 2749 /** 2750 * <p>Do not fire the flash for this capture.</p> 2751 * @see CaptureRequest#FLASH_MODE 2752 */ 2753 public static final int FLASH_MODE_OFF = 0; 2754 2755 /** 2756 * <p>If the flash is available and charged, fire flash 2757 * for this capture.</p> 2758 * @see CaptureRequest#FLASH_MODE 2759 */ 2760 public static final int FLASH_MODE_SINGLE = 1; 2761 2762 /** 2763 * <p>Transition flash to continuously on.</p> 2764 * @see CaptureRequest#FLASH_MODE 2765 */ 2766 public static final int FLASH_MODE_TORCH = 2; 2767 2768 // 2769 // Enumeration values for CaptureRequest#HOT_PIXEL_MODE 2770 // 2771 2772 /** 2773 * <p>No hot pixel correction is applied.</p> 2774 * <p>The frame rate must not be reduced relative to sensor raw output 2775 * for this option.</p> 2776 * <p>The hotpixel map may be returned in {@link CaptureResult#STATISTICS_HOT_PIXEL_MAP android.statistics.hotPixelMap}.</p> 2777 * 2778 * @see CaptureResult#STATISTICS_HOT_PIXEL_MAP 2779 * @see CaptureRequest#HOT_PIXEL_MODE 2780 */ 2781 public static final int HOT_PIXEL_MODE_OFF = 0; 2782 2783 /** 2784 * <p>Hot pixel correction is applied, without reducing frame 2785 * rate relative to sensor raw output.</p> 2786 * <p>The hotpixel map may be returned in {@link CaptureResult#STATISTICS_HOT_PIXEL_MAP android.statistics.hotPixelMap}.</p> 2787 * 2788 * @see CaptureResult#STATISTICS_HOT_PIXEL_MAP 2789 * @see CaptureRequest#HOT_PIXEL_MODE 2790 */ 2791 public static final int HOT_PIXEL_MODE_FAST = 1; 2792 2793 /** 2794 * <p>High-quality hot pixel correction is applied, at a cost 2795 * of possibly reduced frame rate relative to sensor raw output.</p> 2796 * <p>The hotpixel map may be returned in {@link CaptureResult#STATISTICS_HOT_PIXEL_MAP android.statistics.hotPixelMap}.</p> 2797 * 2798 * @see CaptureResult#STATISTICS_HOT_PIXEL_MAP 2799 * @see CaptureRequest#HOT_PIXEL_MODE 2800 */ 2801 public static final int HOT_PIXEL_MODE_HIGH_QUALITY = 2; 2802 2803 // 2804 // Enumeration values for CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE 2805 // 2806 2807 /** 2808 * <p>Optical stabilization is unavailable.</p> 2809 * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE 2810 */ 2811 public static final int LENS_OPTICAL_STABILIZATION_MODE_OFF = 0; 2812 2813 /** 2814 * <p>Optical stabilization is enabled.</p> 2815 * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE 2816 */ 2817 public static final int LENS_OPTICAL_STABILIZATION_MODE_ON = 1; 2818 2819 // 2820 // Enumeration values for CaptureRequest#NOISE_REDUCTION_MODE 2821 // 2822 2823 /** 2824 * <p>No noise reduction is applied.</p> 2825 * @see CaptureRequest#NOISE_REDUCTION_MODE 2826 */ 2827 public static final int NOISE_REDUCTION_MODE_OFF = 0; 2828 2829 /** 2830 * <p>Noise reduction is applied without reducing frame rate relative to sensor 2831 * output. It may be the same as OFF if noise reduction will reduce frame rate 2832 * relative to sensor.</p> 2833 * @see CaptureRequest#NOISE_REDUCTION_MODE 2834 */ 2835 public static final int NOISE_REDUCTION_MODE_FAST = 1; 2836 2837 /** 2838 * <p>High-quality noise reduction is applied, at the cost of possibly reduced frame 2839 * rate relative to sensor output.</p> 2840 * @see CaptureRequest#NOISE_REDUCTION_MODE 2841 */ 2842 public static final int NOISE_REDUCTION_MODE_HIGH_QUALITY = 2; 2843 2844 /** 2845 * <p>MINIMAL noise reduction is applied without reducing frame rate relative to 2846 * sensor output. </p> 2847 * @see CaptureRequest#NOISE_REDUCTION_MODE 2848 */ 2849 public static final int NOISE_REDUCTION_MODE_MINIMAL = 3; 2850 2851 /** 2852 * <p>Noise reduction is applied at different levels for different output streams, 2853 * based on resolution. Streams at maximum recording resolution (see {@link android.hardware.camera2.CameraDevice#createCaptureSession }) 2854 * or below have noise reduction applied, while higher-resolution streams have MINIMAL (if 2855 * supported) or no noise reduction applied (if MINIMAL is not supported.) The degree of 2856 * noise reduction for low-resolution streams is tuned so that frame rate is not impacted, 2857 * and the quality is equal to or better than FAST (since it is only applied to 2858 * lower-resolution outputs, quality may improve from FAST).</p> 2859 * <p>This mode is intended to be used by applications operating in a zero-shutter-lag mode 2860 * with YUV or PRIVATE reprocessing, where the application continuously captures 2861 * high-resolution intermediate buffers into a circular buffer, from which a final image is 2862 * produced via reprocessing when a user takes a picture. For such a use case, the 2863 * high-resolution buffers must not have noise reduction applied to maximize efficiency of 2864 * preview and to avoid over-applying noise filtering when reprocessing, while 2865 * low-resolution buffers (used for recording or preview, generally) need noise reduction 2866 * applied for reasonable preview quality.</p> 2867 * <p>This mode is guaranteed to be supported by devices that support either the 2868 * YUV_REPROCESSING or PRIVATE_REPROCESSING capabilities 2869 * ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} lists either of those capabilities) and it will 2870 * be the default mode for CAMERA3_TEMPLATE_ZERO_SHUTTER_LAG template.</p> 2871 * 2872 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES 2873 * @see CaptureRequest#NOISE_REDUCTION_MODE 2874 */ 2875 public static final int NOISE_REDUCTION_MODE_ZERO_SHUTTER_LAG = 4; 2876 2877 // 2878 // Enumeration values for CaptureRequest#SCALER_ROTATE_AND_CROP 2879 // 2880 2881 /** 2882 * <p>No rotate and crop is applied. Processed outputs are in the sensor orientation.</p> 2883 * @see CaptureRequest#SCALER_ROTATE_AND_CROP 2884 */ 2885 public static final int SCALER_ROTATE_AND_CROP_NONE = 0; 2886 2887 /** 2888 * <p>Processed images are rotated by 90 degrees clockwise, and then cropped 2889 * to the original aspect ratio.</p> 2890 * @see CaptureRequest#SCALER_ROTATE_AND_CROP 2891 */ 2892 public static final int SCALER_ROTATE_AND_CROP_90 = 1; 2893 2894 /** 2895 * <p>Processed images are rotated by 180 degrees. Since the aspect ratio does not 2896 * change, no cropping is performed.</p> 2897 * @see CaptureRequest#SCALER_ROTATE_AND_CROP 2898 */ 2899 public static final int SCALER_ROTATE_AND_CROP_180 = 2; 2900 2901 /** 2902 * <p>Processed images are rotated by 270 degrees clockwise, and then cropped 2903 * to the original aspect ratio.</p> 2904 * @see CaptureRequest#SCALER_ROTATE_AND_CROP 2905 */ 2906 public static final int SCALER_ROTATE_AND_CROP_270 = 3; 2907 2908 /** 2909 * <p>The camera API automatically selects the best concrete value for 2910 * rotate-and-crop based on the application's support for resizability and the current 2911 * multi-window mode.</p> 2912 * <p>If the application does not support resizing but the display mode for its main 2913 * Activity is not in a typical orientation, the camera API will set <code>ROTATE_AND_CROP_90</code> 2914 * or some other supported rotation value, depending on device configuration, 2915 * to ensure preview and captured images are correctly shown to the user. Otherwise, 2916 * <code>ROTATE_AND_CROP_NONE</code> will be selected.</p> 2917 * <p>When a value other than NONE is selected, several metadata fields will also be parsed 2918 * differently to ensure that coordinates are correctly handled for features like drawing 2919 * face detection boxes or passing in tap-to-focus coordinates. The camera API will 2920 * convert positions in the active array coordinate system to/from the cropped-and-rotated 2921 * coordinate system to make the operation transparent for applications.</p> 2922 * <p>No coordinate mapping will be done when the application selects a non-AUTO mode.</p> 2923 * @see CaptureRequest#SCALER_ROTATE_AND_CROP 2924 */ 2925 public static final int SCALER_ROTATE_AND_CROP_AUTO = 4; 2926 2927 // 2928 // Enumeration values for CaptureRequest#SENSOR_TEST_PATTERN_MODE 2929 // 2930 2931 /** 2932 * <p>No test pattern mode is used, and the camera 2933 * device returns captures from the image sensor.</p> 2934 * <p>This is the default if the key is not set.</p> 2935 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE 2936 */ 2937 public static final int SENSOR_TEST_PATTERN_MODE_OFF = 0; 2938 2939 /** 2940 * <p>Each pixel in <code>[R, G_even, G_odd, B]</code> is replaced by its 2941 * respective color channel provided in 2942 * {@link CaptureRequest#SENSOR_TEST_PATTERN_DATA android.sensor.testPatternData}.</p> 2943 * <p>For example:</p> 2944 * <pre><code>{@link CaptureRequest#SENSOR_TEST_PATTERN_DATA android.sensor.testPatternData} = [0, 0xFFFFFFFF, 0xFFFFFFFF, 0] 2945 * </code></pre> 2946 * <p>All green pixels are 100% green. All red/blue pixels are black.</p> 2947 * <pre><code>{@link CaptureRequest#SENSOR_TEST_PATTERN_DATA android.sensor.testPatternData} = [0xFFFFFFFF, 0, 0xFFFFFFFF, 0] 2948 * </code></pre> 2949 * <p>All red pixels are 100% red. Only the odd green pixels 2950 * are 100% green. All blue pixels are 100% black.</p> 2951 * 2952 * @see CaptureRequest#SENSOR_TEST_PATTERN_DATA 2953 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE 2954 */ 2955 public static final int SENSOR_TEST_PATTERN_MODE_SOLID_COLOR = 1; 2956 2957 /** 2958 * <p>All pixel data is replaced with an 8-bar color pattern.</p> 2959 * <p>The vertical bars (left-to-right) are as follows:</p> 2960 * <ul> 2961 * <li>100% white</li> 2962 * <li>yellow</li> 2963 * <li>cyan</li> 2964 * <li>green</li> 2965 * <li>magenta</li> 2966 * <li>red</li> 2967 * <li>blue</li> 2968 * <li>black</li> 2969 * </ul> 2970 * <p>In general the image would look like the following:</p> 2971 * <pre><code>W Y C G M R B K 2972 * W Y C G M R B K 2973 * W Y C G M R B K 2974 * W Y C G M R B K 2975 * W Y C G M R B K 2976 * . . . . . . . . 2977 * . . . . . . . . 2978 * . . . . . . . . 2979 * 2980 * (B = Blue, K = Black) 2981 * </code></pre> 2982 * <p>Each bar should take up 1/8 of the sensor pixel array width. 2983 * When this is not possible, the bar size should be rounded 2984 * down to the nearest integer and the pattern can repeat 2985 * on the right side.</p> 2986 * <p>Each bar's height must always take up the full sensor 2987 * pixel array height.</p> 2988 * <p>Each pixel in this test pattern must be set to either 2989 * 0% intensity or 100% intensity.</p> 2990 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE 2991 */ 2992 public static final int SENSOR_TEST_PATTERN_MODE_COLOR_BARS = 2; 2993 2994 /** 2995 * <p>The test pattern is similar to COLOR_BARS, except that 2996 * each bar should start at its specified color at the top, 2997 * and fade to gray at the bottom.</p> 2998 * <p>Furthermore each bar is further subdivided into a left and 2999 * right half. The left half should have a smooth gradient, 3000 * and the right half should have a quantized gradient.</p> 3001 * <p>In particular, the right half's should consist of blocks of the 3002 * same color for 1/16th active sensor pixel array width.</p> 3003 * <p>The least significant bits in the quantized gradient should 3004 * be copied from the most significant bits of the smooth gradient.</p> 3005 * <p>The height of each bar should always be a multiple of 128. 3006 * When this is not the case, the pattern should repeat at the bottom 3007 * of the image.</p> 3008 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE 3009 */ 3010 public static final int SENSOR_TEST_PATTERN_MODE_COLOR_BARS_FADE_TO_GRAY = 3; 3011 3012 /** 3013 * <p>All pixel data is replaced by a pseudo-random sequence 3014 * generated from a PN9 512-bit sequence (typically implemented 3015 * in hardware with a linear feedback shift register).</p> 3016 * <p>The generator should be reset at the beginning of each frame, 3017 * and thus each subsequent raw frame with this test pattern should 3018 * be exactly the same as the last.</p> 3019 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE 3020 */ 3021 public static final int SENSOR_TEST_PATTERN_MODE_PN9 = 4; 3022 3023 /** 3024 * <p>All pixel data is replaced by 0% intensity (black) values.</p> 3025 * <p>This test pattern is identical to SOLID_COLOR with a value of <code>[0, 0, 0, 0]</code> for 3026 * {@link CaptureRequest#SENSOR_TEST_PATTERN_DATA android.sensor.testPatternData}. It is recommended that devices implement full 3027 * SOLID_COLOR support instead, but BLACK can be used to provide minimal support for a 3028 * test pattern suitable for privacy use cases.</p> 3029 * 3030 * @see CaptureRequest#SENSOR_TEST_PATTERN_DATA 3031 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE 3032 * @hide 3033 */ 3034 @TestApi 3035 public static final int SENSOR_TEST_PATTERN_MODE_BLACK = 5; 3036 3037 /** 3038 * <p>The first custom test pattern. All custom patterns that are 3039 * available only on this camera device are at least this numeric 3040 * value.</p> 3041 * <p>All of the custom test patterns will be static 3042 * (that is the raw image must not vary from frame to frame).</p> 3043 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE 3044 */ 3045 public static final int SENSOR_TEST_PATTERN_MODE_CUSTOM1 = 256; 3046 3047 // 3048 // Enumeration values for CaptureRequest#SENSOR_PIXEL_MODE 3049 // 3050 3051 /** 3052 * <p>This is the default sensor pixel mode. This is the only sensor pixel mode 3053 * supported unless a camera device advertises 3054 * {@link android.hardware.camera2.CameraMetadata#REQUEST_AVAILABLE_CAPABILITIES_ULTRA_HIGH_RESOLUTION_SENSOR }.</p> 3055 * @see CaptureRequest#SENSOR_PIXEL_MODE 3056 */ 3057 public static final int SENSOR_PIXEL_MODE_DEFAULT = 0; 3058 3059 /** 3060 * <p>This sensor pixel mode is offered by devices with capability 3061 * {@link android.hardware.camera2.CameraMetadata#REQUEST_AVAILABLE_CAPABILITIES_ULTRA_HIGH_RESOLUTION_SENSOR }. 3062 * In this mode, sensors typically do not bin pixels, as a result can offer larger 3063 * image sizes.</p> 3064 * @see CaptureRequest#SENSOR_PIXEL_MODE 3065 */ 3066 public static final int SENSOR_PIXEL_MODE_MAXIMUM_RESOLUTION = 1; 3067 3068 // 3069 // Enumeration values for CaptureRequest#SHADING_MODE 3070 // 3071 3072 /** 3073 * <p>No lens shading correction is applied.</p> 3074 * @see CaptureRequest#SHADING_MODE 3075 */ 3076 public static final int SHADING_MODE_OFF = 0; 3077 3078 /** 3079 * <p>Apply lens shading corrections, without slowing 3080 * frame rate relative to sensor raw output</p> 3081 * @see CaptureRequest#SHADING_MODE 3082 */ 3083 public static final int SHADING_MODE_FAST = 1; 3084 3085 /** 3086 * <p>Apply high-quality lens shading correction, at the 3087 * cost of possibly reduced frame rate.</p> 3088 * @see CaptureRequest#SHADING_MODE 3089 */ 3090 public static final int SHADING_MODE_HIGH_QUALITY = 2; 3091 3092 // 3093 // Enumeration values for CaptureRequest#STATISTICS_FACE_DETECT_MODE 3094 // 3095 3096 /** 3097 * <p>Do not include face detection statistics in capture 3098 * results.</p> 3099 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE 3100 */ 3101 public static final int STATISTICS_FACE_DETECT_MODE_OFF = 0; 3102 3103 /** 3104 * <p>Return face rectangle and confidence values only.</p> 3105 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE 3106 */ 3107 public static final int STATISTICS_FACE_DETECT_MODE_SIMPLE = 1; 3108 3109 /** 3110 * <p>Return all face 3111 * metadata.</p> 3112 * <p>In this mode, face rectangles, scores, landmarks, and face IDs are all valid.</p> 3113 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE 3114 */ 3115 public static final int STATISTICS_FACE_DETECT_MODE_FULL = 2; 3116 3117 // 3118 // Enumeration values for CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE 3119 // 3120 3121 /** 3122 * <p>Do not include a lens shading map in the capture result.</p> 3123 * @see CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE 3124 */ 3125 public static final int STATISTICS_LENS_SHADING_MAP_MODE_OFF = 0; 3126 3127 /** 3128 * <p>Include a lens shading map in the capture result.</p> 3129 * @see CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE 3130 */ 3131 public static final int STATISTICS_LENS_SHADING_MAP_MODE_ON = 1; 3132 3133 // 3134 // Enumeration values for CaptureRequest#STATISTICS_OIS_DATA_MODE 3135 // 3136 3137 /** 3138 * <p>Do not include OIS data in the capture result.</p> 3139 * @see CaptureRequest#STATISTICS_OIS_DATA_MODE 3140 */ 3141 public static final int STATISTICS_OIS_DATA_MODE_OFF = 0; 3142 3143 /** 3144 * <p>Include OIS data in the capture result.</p> 3145 * <p>{@link CaptureResult#STATISTICS_OIS_SAMPLES android.statistics.oisSamples} provides OIS sample data in the 3146 * output result metadata.</p> 3147 * 3148 * @see CaptureResult#STATISTICS_OIS_SAMPLES 3149 * @see CaptureRequest#STATISTICS_OIS_DATA_MODE 3150 */ 3151 public static final int STATISTICS_OIS_DATA_MODE_ON = 1; 3152 3153 // 3154 // Enumeration values for CaptureRequest#TONEMAP_MODE 3155 // 3156 3157 /** 3158 * <p>Use the tone mapping curve specified in 3159 * the {@link CaptureRequest#TONEMAP_CURVE android.tonemap.curve}* entries.</p> 3160 * <p>All color enhancement and tonemapping must be disabled, except 3161 * for applying the tonemapping curve specified by 3162 * {@link CaptureRequest#TONEMAP_CURVE android.tonemap.curve}.</p> 3163 * <p>Must not slow down frame rate relative to raw 3164 * sensor output.</p> 3165 * 3166 * @see CaptureRequest#TONEMAP_CURVE 3167 * @see CaptureRequest#TONEMAP_MODE 3168 */ 3169 public static final int TONEMAP_MODE_CONTRAST_CURVE = 0; 3170 3171 /** 3172 * <p>Advanced gamma mapping and color enhancement may be applied, without 3173 * reducing frame rate compared to raw sensor output.</p> 3174 * @see CaptureRequest#TONEMAP_MODE 3175 */ 3176 public static final int TONEMAP_MODE_FAST = 1; 3177 3178 /** 3179 * <p>High-quality gamma mapping and color enhancement will be applied, at 3180 * the cost of possibly reduced frame rate compared to raw sensor output.</p> 3181 * @see CaptureRequest#TONEMAP_MODE 3182 */ 3183 public static final int TONEMAP_MODE_HIGH_QUALITY = 2; 3184 3185 /** 3186 * <p>Use the gamma value specified in {@link CaptureRequest#TONEMAP_GAMMA android.tonemap.gamma} to peform 3187 * tonemapping.</p> 3188 * <p>All color enhancement and tonemapping must be disabled, except 3189 * for applying the tonemapping curve specified by {@link CaptureRequest#TONEMAP_GAMMA android.tonemap.gamma}.</p> 3190 * <p>Must not slow down frame rate relative to raw sensor output.</p> 3191 * 3192 * @see CaptureRequest#TONEMAP_GAMMA 3193 * @see CaptureRequest#TONEMAP_MODE 3194 */ 3195 public static final int TONEMAP_MODE_GAMMA_VALUE = 3; 3196 3197 /** 3198 * <p>Use the preset tonemapping curve specified in 3199 * {@link CaptureRequest#TONEMAP_PRESET_CURVE android.tonemap.presetCurve} to peform tonemapping.</p> 3200 * <p>All color enhancement and tonemapping must be disabled, except 3201 * for applying the tonemapping curve specified by 3202 * {@link CaptureRequest#TONEMAP_PRESET_CURVE android.tonemap.presetCurve}.</p> 3203 * <p>Must not slow down frame rate relative to raw sensor output.</p> 3204 * 3205 * @see CaptureRequest#TONEMAP_PRESET_CURVE 3206 * @see CaptureRequest#TONEMAP_MODE 3207 */ 3208 public static final int TONEMAP_MODE_PRESET_CURVE = 4; 3209 3210 // 3211 // Enumeration values for CaptureRequest#TONEMAP_PRESET_CURVE 3212 // 3213 3214 /** 3215 * <p>Tonemapping curve is defined by sRGB</p> 3216 * @see CaptureRequest#TONEMAP_PRESET_CURVE 3217 */ 3218 public static final int TONEMAP_PRESET_CURVE_SRGB = 0; 3219 3220 /** 3221 * <p>Tonemapping curve is defined by ITU-R BT.709</p> 3222 * @see CaptureRequest#TONEMAP_PRESET_CURVE 3223 */ 3224 public static final int TONEMAP_PRESET_CURVE_REC709 = 1; 3225 3226 // 3227 // Enumeration values for CaptureRequest#DISTORTION_CORRECTION_MODE 3228 // 3229 3230 /** 3231 * <p>No distortion correction is applied.</p> 3232 * @see CaptureRequest#DISTORTION_CORRECTION_MODE 3233 */ 3234 public static final int DISTORTION_CORRECTION_MODE_OFF = 0; 3235 3236 /** 3237 * <p>Lens distortion correction is applied without reducing frame rate 3238 * relative to sensor output. It may be the same as OFF if distortion correction would 3239 * reduce frame rate relative to sensor.</p> 3240 * @see CaptureRequest#DISTORTION_CORRECTION_MODE 3241 */ 3242 public static final int DISTORTION_CORRECTION_MODE_FAST = 1; 3243 3244 /** 3245 * <p>High-quality distortion correction is applied, at the cost of 3246 * possibly reduced frame rate relative to sensor output.</p> 3247 * @see CaptureRequest#DISTORTION_CORRECTION_MODE 3248 */ 3249 public static final int DISTORTION_CORRECTION_MODE_HIGH_QUALITY = 2; 3250 3251 // 3252 // Enumeration values for CaptureResult#CONTROL_AE_STATE 3253 // 3254 3255 /** 3256 * <p>AE is off or recently reset.</p> 3257 * <p>When a camera device is opened, it starts in 3258 * this state. This is a transient state, the camera device may skip reporting 3259 * this state in capture result.</p> 3260 * @see CaptureResult#CONTROL_AE_STATE 3261 */ 3262 public static final int CONTROL_AE_STATE_INACTIVE = 0; 3263 3264 /** 3265 * <p>AE doesn't yet have a good set of control values 3266 * for the current scene.</p> 3267 * <p>This is a transient state, the camera device may skip 3268 * reporting this state in capture result.</p> 3269 * @see CaptureResult#CONTROL_AE_STATE 3270 */ 3271 public static final int CONTROL_AE_STATE_SEARCHING = 1; 3272 3273 /** 3274 * <p>AE has a good set of control values for the 3275 * current scene.</p> 3276 * @see CaptureResult#CONTROL_AE_STATE 3277 */ 3278 public static final int CONTROL_AE_STATE_CONVERGED = 2; 3279 3280 /** 3281 * <p>AE has been locked.</p> 3282 * @see CaptureResult#CONTROL_AE_STATE 3283 */ 3284 public static final int CONTROL_AE_STATE_LOCKED = 3; 3285 3286 /** 3287 * <p>AE has a good set of control values, but flash 3288 * needs to be fired for good quality still 3289 * capture.</p> 3290 * @see CaptureResult#CONTROL_AE_STATE 3291 */ 3292 public static final int CONTROL_AE_STATE_FLASH_REQUIRED = 4; 3293 3294 /** 3295 * <p>AE has been asked to do a precapture sequence 3296 * and is currently executing it.</p> 3297 * <p>Precapture can be triggered through setting 3298 * {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger} to START. Currently 3299 * active and completed (if it causes camera device internal AE lock) precapture 3300 * metering sequence can be canceled through setting 3301 * {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger} to CANCEL.</p> 3302 * <p>Once PRECAPTURE completes, AE will transition to CONVERGED 3303 * or FLASH_REQUIRED as appropriate. This is a transient 3304 * state, the camera device may skip reporting this state in 3305 * capture result.</p> 3306 * 3307 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER 3308 * @see CaptureResult#CONTROL_AE_STATE 3309 */ 3310 public static final int CONTROL_AE_STATE_PRECAPTURE = 5; 3311 3312 // 3313 // Enumeration values for CaptureResult#CONTROL_AF_STATE 3314 // 3315 3316 /** 3317 * <p>AF is off or has not yet tried to scan/been asked 3318 * to scan.</p> 3319 * <p>When a camera device is opened, it starts in this 3320 * state. This is a transient state, the camera device may 3321 * skip reporting this state in capture 3322 * result.</p> 3323 * @see CaptureResult#CONTROL_AF_STATE 3324 */ 3325 public static final int CONTROL_AF_STATE_INACTIVE = 0; 3326 3327 /** 3328 * <p>AF is currently performing an AF scan initiated the 3329 * camera device in a continuous autofocus mode.</p> 3330 * <p>Only used by CONTINUOUS_* AF modes. This is a transient 3331 * state, the camera device may skip reporting this state in 3332 * capture result.</p> 3333 * @see CaptureResult#CONTROL_AF_STATE 3334 */ 3335 public static final int CONTROL_AF_STATE_PASSIVE_SCAN = 1; 3336 3337 /** 3338 * <p>AF currently believes it is in focus, but may 3339 * restart scanning at any time.</p> 3340 * <p>Only used by CONTINUOUS_* AF modes. This is a transient 3341 * state, the camera device may skip reporting this state in 3342 * capture result.</p> 3343 * @see CaptureResult#CONTROL_AF_STATE 3344 */ 3345 public static final int CONTROL_AF_STATE_PASSIVE_FOCUSED = 2; 3346 3347 /** 3348 * <p>AF is performing an AF scan because it was 3349 * triggered by AF trigger.</p> 3350 * <p>Only used by AUTO or MACRO AF modes. This is a transient 3351 * state, the camera device may skip reporting this state in 3352 * capture result.</p> 3353 * @see CaptureResult#CONTROL_AF_STATE 3354 */ 3355 public static final int CONTROL_AF_STATE_ACTIVE_SCAN = 3; 3356 3357 /** 3358 * <p>AF believes it is focused correctly and has locked 3359 * focus.</p> 3360 * <p>This state is reached only after an explicit START AF trigger has been 3361 * sent ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}), when good focus has been obtained.</p> 3362 * <p>The lens will remain stationary until the AF mode ({@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}) is changed or 3363 * a new AF trigger is sent to the camera device ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}).</p> 3364 * 3365 * @see CaptureRequest#CONTROL_AF_MODE 3366 * @see CaptureRequest#CONTROL_AF_TRIGGER 3367 * @see CaptureResult#CONTROL_AF_STATE 3368 */ 3369 public static final int CONTROL_AF_STATE_FOCUSED_LOCKED = 4; 3370 3371 /** 3372 * <p>AF has failed to focus successfully and has locked 3373 * focus.</p> 3374 * <p>This state is reached only after an explicit START AF trigger has been 3375 * sent ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}), when good focus cannot be obtained.</p> 3376 * <p>The lens will remain stationary until the AF mode ({@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}) is changed or 3377 * a new AF trigger is sent to the camera device ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}).</p> 3378 * 3379 * @see CaptureRequest#CONTROL_AF_MODE 3380 * @see CaptureRequest#CONTROL_AF_TRIGGER 3381 * @see CaptureResult#CONTROL_AF_STATE 3382 */ 3383 public static final int CONTROL_AF_STATE_NOT_FOCUSED_LOCKED = 5; 3384 3385 /** 3386 * <p>AF finished a passive scan without finding focus, 3387 * and may restart scanning at any time.</p> 3388 * <p>Only used by CONTINUOUS_* AF modes. This is a transient state, the camera 3389 * device may skip reporting this state in capture result.</p> 3390 * <p>LEGACY camera devices do not support this state. When a passive 3391 * scan has finished, it will always go to PASSIVE_FOCUSED.</p> 3392 * @see CaptureResult#CONTROL_AF_STATE 3393 */ 3394 public static final int CONTROL_AF_STATE_PASSIVE_UNFOCUSED = 6; 3395 3396 // 3397 // Enumeration values for CaptureResult#CONTROL_AWB_STATE 3398 // 3399 3400 /** 3401 * <p>AWB is not in auto mode, or has not yet started metering.</p> 3402 * <p>When a camera device is opened, it starts in this 3403 * state. This is a transient state, the camera device may 3404 * skip reporting this state in capture 3405 * result.</p> 3406 * @see CaptureResult#CONTROL_AWB_STATE 3407 */ 3408 public static final int CONTROL_AWB_STATE_INACTIVE = 0; 3409 3410 /** 3411 * <p>AWB doesn't yet have a good set of control 3412 * values for the current scene.</p> 3413 * <p>This is a transient state, the camera device 3414 * may skip reporting this state in capture result.</p> 3415 * @see CaptureResult#CONTROL_AWB_STATE 3416 */ 3417 public static final int CONTROL_AWB_STATE_SEARCHING = 1; 3418 3419 /** 3420 * <p>AWB has a good set of control values for the 3421 * current scene.</p> 3422 * @see CaptureResult#CONTROL_AWB_STATE 3423 */ 3424 public static final int CONTROL_AWB_STATE_CONVERGED = 2; 3425 3426 /** 3427 * <p>AWB has been locked.</p> 3428 * @see CaptureResult#CONTROL_AWB_STATE 3429 */ 3430 public static final int CONTROL_AWB_STATE_LOCKED = 3; 3431 3432 // 3433 // Enumeration values for CaptureResult#CONTROL_AF_SCENE_CHANGE 3434 // 3435 3436 /** 3437 * <p>Scene change is not detected within the AF region(s).</p> 3438 * @see CaptureResult#CONTROL_AF_SCENE_CHANGE 3439 */ 3440 public static final int CONTROL_AF_SCENE_CHANGE_NOT_DETECTED = 0; 3441 3442 /** 3443 * <p>Scene change is detected within the AF region(s).</p> 3444 * @see CaptureResult#CONTROL_AF_SCENE_CHANGE 3445 */ 3446 public static final int CONTROL_AF_SCENE_CHANGE_DETECTED = 1; 3447 3448 // 3449 // Enumeration values for CaptureResult#FLASH_STATE 3450 // 3451 3452 /** 3453 * <p>No flash on camera.</p> 3454 * @see CaptureResult#FLASH_STATE 3455 */ 3456 public static final int FLASH_STATE_UNAVAILABLE = 0; 3457 3458 /** 3459 * <p>Flash is charging and cannot be fired.</p> 3460 * @see CaptureResult#FLASH_STATE 3461 */ 3462 public static final int FLASH_STATE_CHARGING = 1; 3463 3464 /** 3465 * <p>Flash is ready to fire.</p> 3466 * @see CaptureResult#FLASH_STATE 3467 */ 3468 public static final int FLASH_STATE_READY = 2; 3469 3470 /** 3471 * <p>Flash fired for this capture.</p> 3472 * @see CaptureResult#FLASH_STATE 3473 */ 3474 public static final int FLASH_STATE_FIRED = 3; 3475 3476 /** 3477 * <p>Flash partially illuminated this frame.</p> 3478 * <p>This is usually due to the next or previous frame having 3479 * the flash fire, and the flash spilling into this capture 3480 * due to hardware limitations.</p> 3481 * @see CaptureResult#FLASH_STATE 3482 */ 3483 public static final int FLASH_STATE_PARTIAL = 4; 3484 3485 // 3486 // Enumeration values for CaptureResult#LENS_STATE 3487 // 3488 3489 /** 3490 * <p>The lens parameters ({@link CaptureRequest#LENS_FOCAL_LENGTH android.lens.focalLength}, {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance}, 3491 * {@link CaptureRequest#LENS_FILTER_DENSITY android.lens.filterDensity} and {@link CaptureRequest#LENS_APERTURE android.lens.aperture}) are not changing.</p> 3492 * 3493 * @see CaptureRequest#LENS_APERTURE 3494 * @see CaptureRequest#LENS_FILTER_DENSITY 3495 * @see CaptureRequest#LENS_FOCAL_LENGTH 3496 * @see CaptureRequest#LENS_FOCUS_DISTANCE 3497 * @see CaptureResult#LENS_STATE 3498 */ 3499 public static final int LENS_STATE_STATIONARY = 0; 3500 3501 /** 3502 * <p>One or several of the lens parameters 3503 * ({@link CaptureRequest#LENS_FOCAL_LENGTH android.lens.focalLength}, {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance}, 3504 * {@link CaptureRequest#LENS_FILTER_DENSITY android.lens.filterDensity} or {@link CaptureRequest#LENS_APERTURE android.lens.aperture}) is 3505 * currently changing.</p> 3506 * 3507 * @see CaptureRequest#LENS_APERTURE 3508 * @see CaptureRequest#LENS_FILTER_DENSITY 3509 * @see CaptureRequest#LENS_FOCAL_LENGTH 3510 * @see CaptureRequest#LENS_FOCUS_DISTANCE 3511 * @see CaptureResult#LENS_STATE 3512 */ 3513 public static final int LENS_STATE_MOVING = 1; 3514 3515 // 3516 // Enumeration values for CaptureResult#STATISTICS_SCENE_FLICKER 3517 // 3518 3519 /** 3520 * <p>The camera device does not detect any flickering illumination 3521 * in the current scene.</p> 3522 * @see CaptureResult#STATISTICS_SCENE_FLICKER 3523 */ 3524 public static final int STATISTICS_SCENE_FLICKER_NONE = 0; 3525 3526 /** 3527 * <p>The camera device detects illumination flickering at 50Hz 3528 * in the current scene.</p> 3529 * @see CaptureResult#STATISTICS_SCENE_FLICKER 3530 */ 3531 public static final int STATISTICS_SCENE_FLICKER_50HZ = 1; 3532 3533 /** 3534 * <p>The camera device detects illumination flickering at 60Hz 3535 * in the current scene.</p> 3536 * @see CaptureResult#STATISTICS_SCENE_FLICKER 3537 */ 3538 public static final int STATISTICS_SCENE_FLICKER_60HZ = 2; 3539 3540 // 3541 // Enumeration values for CaptureResult#SYNC_FRAME_NUMBER 3542 // 3543 3544 /** 3545 * <p>The current result is not yet fully synchronized to any request.</p> 3546 * <p>Synchronization is in progress, and reading metadata from this 3547 * result may include a mix of data that have taken effect since the 3548 * last synchronization time.</p> 3549 * <p>In some future result, within {@link CameraCharacteristics#SYNC_MAX_LATENCY android.sync.maxLatency} frames, 3550 * this value will update to the actual frame number frame number 3551 * the result is guaranteed to be synchronized to (as long as the 3552 * request settings remain constant).</p> 3553 * 3554 * @see CameraCharacteristics#SYNC_MAX_LATENCY 3555 * @see CaptureResult#SYNC_FRAME_NUMBER 3556 * @hide 3557 */ 3558 public static final int SYNC_FRAME_NUMBER_CONVERGING = -1; 3559 3560 /** 3561 * <p>The current result's synchronization status is unknown.</p> 3562 * <p>The result may have already converged, or it may be in 3563 * progress. Reading from this result may include some mix 3564 * of settings from past requests.</p> 3565 * <p>After a settings change, the new settings will eventually all 3566 * take effect for the output buffers and results. However, this 3567 * value will not change when that happens. Altering settings 3568 * rapidly may provide outcomes using mixes of settings from recent 3569 * requests.</p> 3570 * <p>This value is intended primarily for backwards compatibility with 3571 * the older camera implementations (for android.hardware.Camera).</p> 3572 * @see CaptureResult#SYNC_FRAME_NUMBER 3573 * @hide 3574 */ 3575 public static final int SYNC_FRAME_NUMBER_UNKNOWN = -2; 3576 3577 /*~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~ 3578 * End generated code 3579 *~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~O@*/ 3580 3581 } 3582