Eino-Ville Talvala | b267554 | 2012-12-12 13:29:45 -0800 | [diff] [blame] | 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 | |
Eino-Ville Talvala | 2f1a2e4 | 2013-07-25 17:12:05 -0700 | [diff] [blame] | 17 | package android.hardware.camera2; |
Eino-Ville Talvala | b267554 | 2012-12-12 13:29:45 -0800 | [diff] [blame] | 18 | |
Igor Murashkin | cc542a4 | 2014-06-25 11:52:23 -0700 | [diff] [blame] | 19 | import android.hardware.camera2.impl.CameraMetadataNative; |
Igor Murashkin | 6c76f58 | 2014-07-15 17:19:49 -0700 | [diff] [blame] | 20 | import android.hardware.camera2.impl.PublicKey; |
| 21 | import android.hardware.camera2.impl.SyntheticKey; |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 22 | import android.util.Log; |
Eino-Ville Talvala | b267554 | 2012-12-12 13:29:45 -0800 | [diff] [blame] | 23 | |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 24 | import java.lang.reflect.Field; |
Igor Murashkin | 03fdb14 | 2013-09-30 12:14:58 -0700 | [diff] [blame] | 25 | import java.lang.reflect.Modifier; |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 26 | import java.util.ArrayList; |
Igor Murashkin | cc542a4 | 2014-06-25 11:52:23 -0700 | [diff] [blame] | 27 | import java.util.Arrays; |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 28 | import java.util.Collections; |
| 29 | import java.util.List; |
| 30 | |
Eino-Ville Talvala | b267554 | 2012-12-12 13:29:45 -0800 | [diff] [blame] | 31 | /** |
| 32 | * The base class for camera controls and information. |
| 33 | * |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 34 | * <p> |
Eino-Ville Talvala | b267554 | 2012-12-12 13:29:45 -0800 | [diff] [blame] | 35 | * This class defines the basic key/value map used for querying for camera |
| 36 | * characteristics or capture results, and for setting camera request |
| 37 | * parameters. |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 38 | * </p> |
| 39 | * |
| 40 | * <p> |
| 41 | * All instances of CameraMetadata are immutable. The list of keys with {@link #getKeys()} |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 42 | * never changes, nor do the values returned by any key with {@code #get} throughout |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 43 | * the lifetime of the object. |
| 44 | * </p> |
Eino-Ville Talvala | b267554 | 2012-12-12 13:29:45 -0800 | [diff] [blame] | 45 | * |
| 46 | * @see CameraDevice |
| 47 | * @see CameraManager |
Igor Murashkin | 68f4006 | 2013-09-10 12:15:54 -0700 | [diff] [blame] | 48 | * @see CameraCharacteristics |
Eino-Ville Talvala | b267554 | 2012-12-12 13:29:45 -0800 | [diff] [blame] | 49 | **/ |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 50 | public abstract class CameraMetadata<TKey> { |
| 51 | |
| 52 | private static final String TAG = "CameraMetadataAb"; |
Igor Murashkin | 696bbee | 2014-08-07 18:02:51 -0700 | [diff] [blame^] | 53 | private static final boolean VERBOSE = Log.isLoggable(TAG, Log.VERBOSE); |
Igor Murashkin | 7072550 | 2013-06-25 20:27:06 +0000 | [diff] [blame] | 54 | |
Eino-Ville Talvala | b267554 | 2012-12-12 13:29:45 -0800 | [diff] [blame] | 55 | /** |
Igor Murashkin | 68f4006 | 2013-09-10 12:15:54 -0700 | [diff] [blame] | 56 | * Set a camera metadata field to a value. The field definitions can be |
| 57 | * found in {@link CameraCharacteristics}, {@link CaptureResult}, and |
| 58 | * {@link CaptureRequest}. |
| 59 | * |
| 60 | * @param key The metadata field to write. |
| 61 | * @param value The value to set the field to, which must be of a matching |
| 62 | * type to the key. |
| 63 | * |
Eino-Ville Talvala | 70c2207 | 2013-08-27 12:09:04 -0700 | [diff] [blame] | 64 | * @hide |
Eino-Ville Talvala | b267554 | 2012-12-12 13:29:45 -0800 | [diff] [blame] | 65 | */ |
Eino-Ville Talvala | 70c2207 | 2013-08-27 12:09:04 -0700 | [diff] [blame] | 66 | protected CameraMetadata() { |
Eino-Ville Talvala | b267554 | 2012-12-12 13:29:45 -0800 | [diff] [blame] | 67 | } |
| 68 | |
| 69 | /** |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 70 | * Get a camera metadata field value. |
| 71 | * |
| 72 | * <p>The field definitions can be |
Igor Murashkin | 68f4006 | 2013-09-10 12:15:54 -0700 | [diff] [blame] | 73 | * found in {@link CameraCharacteristics}, {@link CaptureResult}, and |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 74 | * {@link CaptureRequest}.</p> |
| 75 | * |
| 76 | * <p>Querying the value for the same key more than once will return a value |
| 77 | * which is equal to the previous queried value.</p> |
Eino-Ville Talvala | b267554 | 2012-12-12 13:29:45 -0800 | [diff] [blame] | 78 | * |
Igor Murashkin | b519cc5 | 2013-07-02 11:23:44 -0700 | [diff] [blame] | 79 | * @throws IllegalArgumentException if the key was not valid |
| 80 | * |
Benjamin Hendricks | 24eb8a3 | 2013-08-15 12:46:22 -0700 | [diff] [blame] | 81 | * @param key The metadata field to read. |
| 82 | * @return The value of that key, or {@code null} if the field is not set. |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 83 | * |
| 84 | * @hide |
Eino-Ville Talvala | b267554 | 2012-12-12 13:29:45 -0800 | [diff] [blame] | 85 | */ |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 86 | protected abstract <T> T getProtected(TKey key); |
| 87 | |
| 88 | /** |
| 89 | * @hide |
| 90 | */ |
| 91 | protected abstract Class<TKey> getKeyClass(); |
Eino-Ville Talvala | b267554 | 2012-12-12 13:29:45 -0800 | [diff] [blame] | 92 | |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 93 | /** |
| 94 | * Returns a list of the keys contained in this map. |
| 95 | * |
| 96 | * <p>The list returned is not modifiable, so any attempts to modify it will throw |
| 97 | * a {@code UnsupportedOperationException}.</p> |
| 98 | * |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 99 | * <p>All values retrieved by a key from this list with {@code #get} are guaranteed to be |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 100 | * non-{@code null}. Each key is only listed once in the list. The order of the keys |
| 101 | * is undefined.</p> |
| 102 | * |
| 103 | * @return List of the keys contained in this map. |
| 104 | */ |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 105 | @SuppressWarnings("unchecked") |
| 106 | public List<TKey> getKeys() { |
| 107 | Class<CameraMetadata<TKey>> thisClass = (Class<CameraMetadata<TKey>>) getClass(); |
Igor Murashkin | cc542a4 | 2014-06-25 11:52:23 -0700 | [diff] [blame] | 108 | return Collections.unmodifiableList( |
| 109 | getKeysStatic(thisClass, getKeyClass(), this, /*filterTags*/null)); |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 110 | } |
| 111 | |
| 112 | /** |
| 113 | * Return a list of all the Key<?> that are declared as a field inside of the class |
| 114 | * {@code type}. |
| 115 | * |
| 116 | * <p> |
| 117 | * Optionally, if {@code instance} is not null, then filter out any keys with null values. |
| 118 | * </p> |
Igor Murashkin | cc542a4 | 2014-06-25 11:52:23 -0700 | [diff] [blame] | 119 | * |
| 120 | * <p> |
| 121 | * Optionally, if {@code filterTags} is not {@code null}, then filter out any keys |
| 122 | * whose native {@code tag} is not in {@code filterTags}. The {@code filterTags} array will be |
| 123 | * sorted as a side effect. |
| 124 | * </p> |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 125 | */ |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 126 | /*package*/ @SuppressWarnings("unchecked") |
| 127 | static <TKey> ArrayList<TKey> getKeysStatic( |
| 128 | Class<?> type, Class<TKey> keyClass, |
Igor Murashkin | cc542a4 | 2014-06-25 11:52:23 -0700 | [diff] [blame] | 129 | CameraMetadata<TKey> instance, |
| 130 | int[] filterTags) { |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 131 | |
| 132 | if (VERBOSE) Log.v(TAG, "getKeysStatic for " + type); |
| 133 | |
Igor Murashkin | 696bbee | 2014-08-07 18:02:51 -0700 | [diff] [blame^] | 134 | // TotalCaptureResult does not have any of the keys on it, use CaptureResult instead |
| 135 | if (type.equals(TotalCaptureResult.class)) { |
| 136 | type = CaptureResult.class; |
| 137 | } |
| 138 | |
Igor Murashkin | cc542a4 | 2014-06-25 11:52:23 -0700 | [diff] [blame] | 139 | if (filterTags != null) { |
| 140 | Arrays.sort(filterTags); |
| 141 | } |
| 142 | |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 143 | ArrayList<TKey> keyList = new ArrayList<TKey>(); |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 144 | |
| 145 | Field[] fields = type.getDeclaredFields(); |
| 146 | for (Field field : fields) { |
Igor Murashkin | 03fdb14 | 2013-09-30 12:14:58 -0700 | [diff] [blame] | 147 | // Filter for Keys that are public |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 148 | if (field.getType().isAssignableFrom(keyClass) && |
Igor Murashkin | 03fdb14 | 2013-09-30 12:14:58 -0700 | [diff] [blame] | 149 | (field.getModifiers() & Modifier.PUBLIC) != 0) { |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 150 | |
| 151 | TKey key; |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 152 | try { |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 153 | key = (TKey) field.get(instance); |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 154 | } catch (IllegalAccessException e) { |
| 155 | throw new AssertionError("Can't get IllegalAccessException", e); |
| 156 | } catch (IllegalArgumentException e) { |
| 157 | throw new AssertionError("Can't get IllegalArgumentException", e); |
| 158 | } |
Igor Murashkin | d6d6515 | 2014-05-19 16:31:02 -0700 | [diff] [blame] | 159 | |
| 160 | if (instance == null || instance.getProtected(key) != null) { |
Igor Murashkin | 6c76f58 | 2014-07-15 17:19:49 -0700 | [diff] [blame] | 161 | if (shouldKeyBeAdded(key, field, filterTags)) { |
Igor Murashkin | cc542a4 | 2014-06-25 11:52:23 -0700 | [diff] [blame] | 162 | keyList.add(key); |
| 163 | |
| 164 | if (VERBOSE) { |
| 165 | Log.v(TAG, "getKeysStatic - key was added - " + key); |
| 166 | } |
| 167 | } else if (VERBOSE) { |
| 168 | Log.v(TAG, "getKeysStatic - key was filtered - " + key); |
| 169 | } |
Igor Murashkin | 7a36a0f | 2013-09-10 18:13:09 -0700 | [diff] [blame] | 170 | } |
| 171 | } |
| 172 | } |
| 173 | |
| 174 | return keyList; |
| 175 | } |
| 176 | |
Igor Murashkin | cc542a4 | 2014-06-25 11:52:23 -0700 | [diff] [blame] | 177 | @SuppressWarnings("rawtypes") |
Igor Murashkin | 6c76f58 | 2014-07-15 17:19:49 -0700 | [diff] [blame] | 178 | private static <TKey> boolean shouldKeyBeAdded(TKey key, Field field, int[] filterTags) { |
Igor Murashkin | cc542a4 | 2014-06-25 11:52:23 -0700 | [diff] [blame] | 179 | if (key == null) { |
| 180 | throw new NullPointerException("key must not be null"); |
| 181 | } |
| 182 | |
| 183 | CameraMetadataNative.Key nativeKey; |
| 184 | |
| 185 | /* |
| 186 | * Get the native key from the public api key |
| 187 | */ |
| 188 | if (key instanceof CameraCharacteristics.Key) { |
| 189 | nativeKey = ((CameraCharacteristics.Key)key).getNativeKey(); |
| 190 | } else if (key instanceof CaptureResult.Key) { |
| 191 | nativeKey = ((CaptureResult.Key)key).getNativeKey(); |
| 192 | } else if (key instanceof CaptureRequest.Key) { |
| 193 | nativeKey = ((CaptureRequest.Key)key).getNativeKey(); |
| 194 | } else { |
| 195 | // Reject fields that aren't a key |
| 196 | throw new IllegalArgumentException("key type must be that of a metadata key"); |
| 197 | } |
| 198 | |
Igor Murashkin | 6c76f58 | 2014-07-15 17:19:49 -0700 | [diff] [blame] | 199 | if (field.getAnnotation(PublicKey.class) == null) { |
| 200 | // Never expose @hide keys up to the API user |
| 201 | return false; |
| 202 | } |
| 203 | |
Igor Murashkin | cc542a4 | 2014-06-25 11:52:23 -0700 | [diff] [blame] | 204 | // No filtering necessary |
| 205 | if (filterTags == null) { |
| 206 | return true; |
| 207 | } |
| 208 | |
Igor Murashkin | 6c76f58 | 2014-07-15 17:19:49 -0700 | [diff] [blame] | 209 | if (field.getAnnotation(SyntheticKey.class) != null) { |
| 210 | // This key is synthetic, so calling #getTag will throw IAE |
| 211 | |
| 212 | // TODO: don't just assume all public+synthetic keys are always available |
| 213 | return true; |
| 214 | } |
| 215 | |
| 216 | /* |
| 217 | * Regular key: look up it's native tag and see if it's in filterTags |
| 218 | */ |
| 219 | |
Igor Murashkin | cc542a4 | 2014-06-25 11:52:23 -0700 | [diff] [blame] | 220 | int keyTag = nativeKey.getTag(); |
| 221 | |
| 222 | // non-negative result is returned iff the value is in the array |
| 223 | return Arrays.binarySearch(filterTags, keyTag) >= 0; |
| 224 | } |
| 225 | |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 226 | /*@O~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~ |
| 227 | * The enum values below this point are generated from metadata |
| 228 | * definitions in /system/media/camera/docs. Do not modify by hand or |
| 229 | * modify the comment blocks at the start or end. |
| 230 | *~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~*/ |
| 231 | |
| 232 | // |
Zhijun He | ff41393 | 2014-02-07 15:44:30 -0800 | [diff] [blame] | 233 | // Enumeration values for CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION |
| 234 | // |
| 235 | |
| 236 | /** |
| 237 | * <p>The lens focus distance is not accurate, and the units used for |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 238 | * {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance} do not correspond to any physical units.</p> |
| 239 | * <p>Setting the lens to the same focus distance on separate occasions may |
Zhijun He | ff41393 | 2014-02-07 15:44:30 -0800 | [diff] [blame] | 240 | * result in a different real focus distance, depending on factors such |
| 241 | * as the orientation of the device, the age of the focusing mechanism, |
| 242 | * and the device temperature. The focus distance value will still be |
| 243 | * in the range of <code>[0, {@link CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE android.lens.info.minimumFocusDistance}]</code>, where 0 |
| 244 | * represents the farthest focus.</p> |
| 245 | * |
| 246 | * @see CaptureRequest#LENS_FOCUS_DISTANCE |
| 247 | * @see CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE |
| 248 | * @see CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION |
| 249 | */ |
| 250 | public static final int LENS_INFO_FOCUS_DISTANCE_CALIBRATION_UNCALIBRATED = 0; |
| 251 | |
| 252 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 253 | * <p>The lens focus distance is measured in diopters.</p> |
| 254 | * <p>However, setting the lens to the same focus distance |
| 255 | * on separate occasions may result in a different real |
| 256 | * focus distance, depending on factors such as the |
| 257 | * orientation of the device, the age of the focusing |
| 258 | * mechanism, and the device temperature.</p> |
Zhijun He | ff41393 | 2014-02-07 15:44:30 -0800 | [diff] [blame] | 259 | * @see CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION |
| 260 | */ |
| 261 | public static final int LENS_INFO_FOCUS_DISTANCE_CALIBRATION_APPROXIMATE = 1; |
| 262 | |
| 263 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 264 | * <p>The lens focus distance is measured in diopters, and |
| 265 | * is calibrated.</p> |
| 266 | * <p>The lens mechanism is calibrated so that setting the |
| 267 | * same focus distance is repeatable on multiple |
| 268 | * occasions with good accuracy, and the focus distance |
| 269 | * corresponds to the real physical distance to the plane |
| 270 | * of best focus.</p> |
Zhijun He | ff41393 | 2014-02-07 15:44:30 -0800 | [diff] [blame] | 271 | * @see CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION |
| 272 | */ |
| 273 | public static final int LENS_INFO_FOCUS_DISTANCE_CALIBRATION_CALIBRATED = 2; |
| 274 | |
| 275 | // |
Igor Murashkin | 68f4006 | 2013-09-10 12:15:54 -0700 | [diff] [blame] | 276 | // Enumeration values for CameraCharacteristics#LENS_FACING |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 277 | // |
| 278 | |
| 279 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 280 | * <p>The camera device faces the same direction as the device's screen.</p> |
Igor Murashkin | 68f4006 | 2013-09-10 12:15:54 -0700 | [diff] [blame] | 281 | * @see CameraCharacteristics#LENS_FACING |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 282 | */ |
| 283 | public static final int LENS_FACING_FRONT = 0; |
| 284 | |
| 285 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 286 | * <p>The camera device faces the opposite direction as the device's screen.</p> |
Igor Murashkin | 68f4006 | 2013-09-10 12:15:54 -0700 | [diff] [blame] | 287 | * @see CameraCharacteristics#LENS_FACING |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 288 | */ |
| 289 | public static final int LENS_FACING_BACK = 1; |
| 290 | |
| 291 | // |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 292 | // Enumeration values for CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES |
| 293 | // |
| 294 | |
| 295 | /** |
| 296 | * <p>The minimal set of capabilities that every camera |
| 297 | * device (regardless of {@link CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL android.info.supportedHardwareLevel}) |
Eino-Ville Talvala | 08bc3b0 | 2014-07-09 10:07:36 -0700 | [diff] [blame] | 298 | * supports.</p> |
| 299 | * <p>This capability is listed by all devices, and |
| 300 | * indicates that the camera device has a feature set |
| 301 | * that's comparable to the baseline requirements for the |
| 302 | * older android.hardware.Camera API.</p> |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 303 | * |
| 304 | * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL |
| 305 | * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES |
| 306 | */ |
| 307 | public static final int REQUEST_AVAILABLE_CAPABILITIES_BACKWARD_COMPATIBLE = 0; |
| 308 | |
| 309 | /** |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 310 | * <p>The camera device can be manually controlled (3A algorithms such |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 311 | * as auto-exposure, and auto-focus can be bypassed). |
Zhijun He | 50f7243 | 2014-05-28 13:52:04 -0700 | [diff] [blame] | 312 | * The camera device supports basic manual control of the sensor image |
| 313 | * acquisition related stages. This means the following controls are |
| 314 | * guaranteed to be supported:</p> |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 315 | * <ul> |
Zhijun He | 50f7243 | 2014-05-28 13:52:04 -0700 | [diff] [blame] | 316 | * <li>Manual frame duration control<ul> |
| 317 | * <li>{@link CaptureRequest#SENSOR_FRAME_DURATION android.sensor.frameDuration}</li> |
| 318 | * <li>{@link CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION android.sensor.info.maxFrameDuration}</li> |
Zhijun He | 50f7243 | 2014-05-28 13:52:04 -0700 | [diff] [blame] | 319 | * </ul> |
| 320 | * </li> |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 321 | * <li>Manual exposure control<ul> |
| 322 | * <li>{@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}</li> |
| 323 | * <li>{@link CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE android.sensor.info.exposureTimeRange}</li> |
| 324 | * </ul> |
| 325 | * </li> |
| 326 | * <li>Manual sensitivity control<ul> |
| 327 | * <li>{@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}</li> |
| 328 | * <li>{@link CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE android.sensor.info.sensitivityRange}</li> |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 329 | * </ul> |
| 330 | * </li> |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 331 | * <li>Manual lens control (if the lens is adjustable)<ul> |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 332 | * <li>android.lens.*</li> |
| 333 | * </ul> |
| 334 | * </li> |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 335 | * <li>Manual flash control (if a flash unit is present)<ul> |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 336 | * <li>android.flash.*</li> |
| 337 | * </ul> |
| 338 | * </li> |
| 339 | * <li>Manual black level locking<ul> |
| 340 | * <li>{@link CaptureRequest#BLACK_LEVEL_LOCK android.blackLevel.lock}</li> |
| 341 | * </ul> |
| 342 | * </li> |
| 343 | * </ul> |
| 344 | * <p>If any of the above 3A algorithms are enabled, then the camera |
| 345 | * device will accurately report the values applied by 3A in the |
| 346 | * result.</p> |
Zhijun He | 50f7243 | 2014-05-28 13:52:04 -0700 | [diff] [blame] | 347 | * <p>A given camera device may also support additional manual sensor controls, |
| 348 | * but this capability only covers the above list of controls.</p> |
Ruben Brunk | 3e4fed2 | 2014-06-18 17:08:42 -0700 | [diff] [blame] | 349 | * <p>If this is supported, {@link CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP android.scaler.streamConfigurationMap} will |
| 350 | * additionally return a min frame duration that is greater than |
| 351 | * zero for each supported size-format combination.</p> |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 352 | * |
| 353 | * @see CaptureRequest#BLACK_LEVEL_LOCK |
Zhijun He | 50f7243 | 2014-05-28 13:52:04 -0700 | [diff] [blame] | 354 | * @see CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 355 | * @see CaptureRequest#SENSOR_EXPOSURE_TIME |
Zhijun He | 50f7243 | 2014-05-28 13:52:04 -0700 | [diff] [blame] | 356 | * @see CaptureRequest#SENSOR_FRAME_DURATION |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 357 | * @see CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE |
Zhijun He | 50f7243 | 2014-05-28 13:52:04 -0700 | [diff] [blame] | 358 | * @see CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 359 | * @see CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE |
| 360 | * @see CaptureRequest#SENSOR_SENSITIVITY |
| 361 | * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES |
| 362 | */ |
Eino-Ville Talvala | 08bc3b0 | 2014-07-09 10:07:36 -0700 | [diff] [blame] | 363 | public static final int REQUEST_AVAILABLE_CAPABILITIES_MANUAL_SENSOR = 1; |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 364 | |
| 365 | /** |
Zhijun He | 50f7243 | 2014-05-28 13:52:04 -0700 | [diff] [blame] | 366 | * <p>The camera device post-processing stages can be manually controlled. |
| 367 | * The camera device supports basic manual control of the image post-processing |
| 368 | * stages. This means the following controls are guaranteed to be supported:</p> |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 369 | * <ul> |
| 370 | * <li>Manual tonemap control<ul> |
Yin-Chia Yeh | 8490ace | 2014-05-27 10:04:54 -0700 | [diff] [blame] | 371 | * <li>{@link CaptureRequest#TONEMAP_CURVE android.tonemap.curve}</li> |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 372 | * <li>{@link CaptureRequest#TONEMAP_MODE android.tonemap.mode}</li> |
| 373 | * <li>{@link CameraCharacteristics#TONEMAP_MAX_CURVE_POINTS android.tonemap.maxCurvePoints}</li> |
| 374 | * </ul> |
| 375 | * </li> |
| 376 | * <li>Manual white balance control<ul> |
| 377 | * <li>{@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}</li> |
| 378 | * <li>{@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains}</li> |
| 379 | * </ul> |
| 380 | * </li> |
Zhijun He | 28288ca | 2014-06-25 15:49:13 -0700 | [diff] [blame] | 381 | * <li>Manual lens shading map control<ul> |
| 382 | * <li>{@link CaptureRequest#SHADING_MODE android.shading.mode}</li> |
| 383 | * <li>{@link CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE android.statistics.lensShadingMapMode}</li> |
Ruben Brunk | 5749368 | 2014-05-27 18:58:08 -0700 | [diff] [blame] | 384 | * <li>android.statistics.lensShadingMap</li> |
| 385 | * <li>android.lens.info.shadingMapSize</li> |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 386 | * </ul> |
| 387 | * </li> |
Zhijun He | a05e59d | 2014-07-08 18:27:47 -0700 | [diff] [blame] | 388 | * <li>Manual aberration correction control (if aberration correction is supported)<ul> |
| 389 | * <li>{@link CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE android.colorCorrection.aberrationCorrectionMode}</li> |
| 390 | * <li>{@link CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_CORRECTION_MODES android.colorCorrection.availableAberrationCorrectionModes}</li> |
| 391 | * </ul> |
| 392 | * </li> |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 393 | * </ul> |
| 394 | * <p>If auto white balance is enabled, then the camera device |
| 395 | * will accurately report the values applied by AWB in the result.</p> |
Zhijun He | 50f7243 | 2014-05-28 13:52:04 -0700 | [diff] [blame] | 396 | * <p>A given camera device may also support additional post-processing |
| 397 | * controls, but this capability only covers the above list of controls.</p> |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 398 | * |
Zhijun He | a05e59d | 2014-07-08 18:27:47 -0700 | [diff] [blame] | 399 | * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE |
| 400 | * @see CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_CORRECTION_MODES |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 401 | * @see CaptureRequest#COLOR_CORRECTION_GAINS |
| 402 | * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM |
Zhijun He | 28288ca | 2014-06-25 15:49:13 -0700 | [diff] [blame] | 403 | * @see CaptureRequest#SHADING_MODE |
| 404 | * @see CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE |
Yin-Chia Yeh | 8490ace | 2014-05-27 10:04:54 -0700 | [diff] [blame] | 405 | * @see CaptureRequest#TONEMAP_CURVE |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 406 | * @see CameraCharacteristics#TONEMAP_MAX_CURVE_POINTS |
| 407 | * @see CaptureRequest#TONEMAP_MODE |
| 408 | * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES |
| 409 | */ |
Eino-Ville Talvala | 08bc3b0 | 2014-07-09 10:07:36 -0700 | [diff] [blame] | 410 | public static final int REQUEST_AVAILABLE_CAPABILITIES_MANUAL_POST_PROCESSING = 2; |
| 411 | |
| 412 | /** |
Eino-Ville Talvala | 611fece | 2014-07-10 17:29:38 -0700 | [diff] [blame] | 413 | * <p>The camera device supports outputting RAW buffers and |
| 414 | * metadata for interpreting them.</p> |
| 415 | * <p>Devices supporting the RAW capability allow both for |
| 416 | * saving DNG files, and for direct application processing of |
| 417 | * raw sensor images.</p> |
Eino-Ville Talvala | 08bc3b0 | 2014-07-09 10:07:36 -0700 | [diff] [blame] | 418 | * <ul> |
| 419 | * <li>RAW_SENSOR is supported as an output format.</li> |
| 420 | * <li>The maximum available resolution for RAW_SENSOR streams |
| 421 | * will match either the value in |
| 422 | * {@link CameraCharacteristics#SENSOR_INFO_PIXEL_ARRAY_SIZE android.sensor.info.pixelArraySize} or |
| 423 | * {@link CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE android.sensor.info.activeArraySize}.</li> |
| 424 | * <li>All DNG-related optional metadata entries are provided |
| 425 | * by the camera device.</li> |
| 426 | * </ul> |
| 427 | * |
| 428 | * @see CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE |
| 429 | * @see CameraCharacteristics#SENSOR_INFO_PIXEL_ARRAY_SIZE |
| 430 | * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES |
| 431 | */ |
Eino-Ville Talvala | 611fece | 2014-07-10 17:29:38 -0700 | [diff] [blame] | 432 | public static final int REQUEST_AVAILABLE_CAPABILITIES_RAW = 3; |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 433 | |
| 434 | /** |
| 435 | * <p>The camera device supports the Zero Shutter Lag use case.</p> |
| 436 | * <ul> |
| 437 | * <li>At least one input stream can be used.</li> |
| 438 | * <li>RAW_OPAQUE is supported as an output/input format</li> |
| 439 | * <li>Using RAW_OPAQUE does not cause a frame rate drop |
| 440 | * relative to the sensor's maximum capture rate (at that |
| 441 | * resolution).</li> |
| 442 | * <li>RAW_OPAQUE will be reprocessable into both YUV_420_888 |
| 443 | * and JPEG formats.</li> |
| 444 | * <li>The maximum available resolution for RAW_OPAQUE streams |
| 445 | * (both input/output) will match the maximum available |
| 446 | * resolution of JPEG streams.</li> |
| 447 | * </ul> |
| 448 | * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 449 | * @hide |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 450 | */ |
| 451 | public static final int REQUEST_AVAILABLE_CAPABILITIES_ZSL = 4; |
| 452 | |
Igor Murashkin | e46c0da | 2014-02-07 18:34:37 -0800 | [diff] [blame] | 453 | // |
Zhijun He | 1498615 | 2014-05-22 21:17:37 -0700 | [diff] [blame] | 454 | // Enumeration values for CameraCharacteristics#SCALER_CROPPING_TYPE |
| 455 | // |
| 456 | |
| 457 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 458 | * <p>The camera device only supports centered crop regions.</p> |
Zhijun He | 1498615 | 2014-05-22 21:17:37 -0700 | [diff] [blame] | 459 | * @see CameraCharacteristics#SCALER_CROPPING_TYPE |
| 460 | */ |
| 461 | public static final int SCALER_CROPPING_TYPE_CENTER_ONLY = 0; |
| 462 | |
| 463 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 464 | * <p>The camera device supports arbitrarily chosen crop regions.</p> |
Zhijun He | 1498615 | 2014-05-22 21:17:37 -0700 | [diff] [blame] | 465 | * @see CameraCharacteristics#SCALER_CROPPING_TYPE |
| 466 | */ |
| 467 | public static final int SCALER_CROPPING_TYPE_FREEFORM = 1; |
| 468 | |
| 469 | // |
Zhijun He | d178496 | 2014-04-08 17:41:46 -0700 | [diff] [blame] | 470 | // Enumeration values for CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT |
| 471 | // |
| 472 | |
| 473 | /** |
| 474 | * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT |
| 475 | */ |
| 476 | public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_RGGB = 0; |
| 477 | |
| 478 | /** |
| 479 | * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT |
| 480 | */ |
| 481 | public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GRBG = 1; |
| 482 | |
| 483 | /** |
| 484 | * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT |
| 485 | */ |
| 486 | public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GBRG = 2; |
| 487 | |
| 488 | /** |
| 489 | * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT |
| 490 | */ |
| 491 | public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_BGGR = 3; |
| 492 | |
| 493 | /** |
| 494 | * <p>Sensor is not Bayer; output has 3 16-bit |
| 495 | * values for each pixel, instead of just 1 16-bit value |
| 496 | * per pixel.</p> |
| 497 | * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT |
| 498 | */ |
| 499 | public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_RGB = 4; |
| 500 | |
| 501 | // |
Eino-Ville Talvala | abd9d3c | 2014-07-28 13:01:52 -0700 | [diff] [blame] | 502 | // Enumeration values for CameraCharacteristics#SENSOR_INFO_TIMESTAMP_SOURCE |
Zhijun He | 45fa43a1 | 2014-06-13 18:29:37 -0700 | [diff] [blame] | 503 | // |
| 504 | |
| 505 | /** |
| 506 | * <p>Timestamps from {@link CaptureResult#SENSOR_TIMESTAMP android.sensor.timestamp} are in nanoseconds and monotonic, |
| 507 | * but can not be compared to timestamps from other subsystems |
| 508 | * (e.g. accelerometer, gyro etc.), or other instances of the same or different |
| 509 | * camera devices in the same system. Timestamps between streams and results for |
| 510 | * a single camera instance are comparable, and the timestamps for all buffers |
| 511 | * and the result metadata generated by a single capture are identical.</p> |
| 512 | * |
| 513 | * @see CaptureResult#SENSOR_TIMESTAMP |
Eino-Ville Talvala | abd9d3c | 2014-07-28 13:01:52 -0700 | [diff] [blame] | 514 | * @see CameraCharacteristics#SENSOR_INFO_TIMESTAMP_SOURCE |
Zhijun He | 45fa43a1 | 2014-06-13 18:29:37 -0700 | [diff] [blame] | 515 | */ |
Eino-Ville Talvala | abd9d3c | 2014-07-28 13:01:52 -0700 | [diff] [blame] | 516 | public static final int SENSOR_INFO_TIMESTAMP_SOURCE_UNKNOWN = 0; |
Zhijun He | 45fa43a1 | 2014-06-13 18:29:37 -0700 | [diff] [blame] | 517 | |
| 518 | /** |
| 519 | * <p>Timestamps from {@link CaptureResult#SENSOR_TIMESTAMP android.sensor.timestamp} are in the same timebase as |
| 520 | * android.os.SystemClock#elapsedRealtimeNanos(), |
| 521 | * and they can be compared to other timestamps using that base.</p> |
| 522 | * |
| 523 | * @see CaptureResult#SENSOR_TIMESTAMP |
Eino-Ville Talvala | abd9d3c | 2014-07-28 13:01:52 -0700 | [diff] [blame] | 524 | * @see CameraCharacteristics#SENSOR_INFO_TIMESTAMP_SOURCE |
Zhijun He | 45fa43a1 | 2014-06-13 18:29:37 -0700 | [diff] [blame] | 525 | */ |
Eino-Ville Talvala | abd9d3c | 2014-07-28 13:01:52 -0700 | [diff] [blame] | 526 | public static final int SENSOR_INFO_TIMESTAMP_SOURCE_REALTIME = 1; |
Zhijun He | 45fa43a1 | 2014-06-13 18:29:37 -0700 | [diff] [blame] | 527 | |
| 528 | // |
Ruben Brunk | 7c06236 | 2014-04-15 23:53:53 -0700 | [diff] [blame] | 529 | // Enumeration values for CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 530 | // |
| 531 | |
| 532 | /** |
| 533 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 534 | */ |
| 535 | public static final int SENSOR_REFERENCE_ILLUMINANT1_DAYLIGHT = 1; |
| 536 | |
| 537 | /** |
| 538 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 539 | */ |
| 540 | public static final int SENSOR_REFERENCE_ILLUMINANT1_FLUORESCENT = 2; |
| 541 | |
| 542 | /** |
| 543 | * <p>Incandescent light</p> |
| 544 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 545 | */ |
| 546 | public static final int SENSOR_REFERENCE_ILLUMINANT1_TUNGSTEN = 3; |
| 547 | |
| 548 | /** |
| 549 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 550 | */ |
| 551 | public static final int SENSOR_REFERENCE_ILLUMINANT1_FLASH = 4; |
| 552 | |
| 553 | /** |
| 554 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 555 | */ |
| 556 | public static final int SENSOR_REFERENCE_ILLUMINANT1_FINE_WEATHER = 9; |
| 557 | |
| 558 | /** |
| 559 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 560 | */ |
| 561 | public static final int SENSOR_REFERENCE_ILLUMINANT1_CLOUDY_WEATHER = 10; |
| 562 | |
| 563 | /** |
| 564 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 565 | */ |
| 566 | public static final int SENSOR_REFERENCE_ILLUMINANT1_SHADE = 11; |
| 567 | |
| 568 | /** |
| 569 | * <p>D 5700 - 7100K</p> |
| 570 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 571 | */ |
| 572 | public static final int SENSOR_REFERENCE_ILLUMINANT1_DAYLIGHT_FLUORESCENT = 12; |
| 573 | |
| 574 | /** |
| 575 | * <p>N 4600 - 5400K</p> |
| 576 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 577 | */ |
| 578 | public static final int SENSOR_REFERENCE_ILLUMINANT1_DAY_WHITE_FLUORESCENT = 13; |
| 579 | |
| 580 | /** |
| 581 | * <p>W 3900 - 4500K</p> |
| 582 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 583 | */ |
| 584 | public static final int SENSOR_REFERENCE_ILLUMINANT1_COOL_WHITE_FLUORESCENT = 14; |
| 585 | |
| 586 | /** |
| 587 | * <p>WW 3200 - 3700K</p> |
| 588 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 589 | */ |
| 590 | public static final int SENSOR_REFERENCE_ILLUMINANT1_WHITE_FLUORESCENT = 15; |
| 591 | |
| 592 | /** |
| 593 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 594 | */ |
| 595 | public static final int SENSOR_REFERENCE_ILLUMINANT1_STANDARD_A = 17; |
| 596 | |
| 597 | /** |
| 598 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 599 | */ |
| 600 | public static final int SENSOR_REFERENCE_ILLUMINANT1_STANDARD_B = 18; |
| 601 | |
| 602 | /** |
| 603 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 604 | */ |
| 605 | public static final int SENSOR_REFERENCE_ILLUMINANT1_STANDARD_C = 19; |
| 606 | |
| 607 | /** |
| 608 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 609 | */ |
| 610 | public static final int SENSOR_REFERENCE_ILLUMINANT1_D55 = 20; |
| 611 | |
| 612 | /** |
| 613 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 614 | */ |
| 615 | public static final int SENSOR_REFERENCE_ILLUMINANT1_D65 = 21; |
| 616 | |
| 617 | /** |
| 618 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 619 | */ |
| 620 | public static final int SENSOR_REFERENCE_ILLUMINANT1_D75 = 22; |
| 621 | |
| 622 | /** |
| 623 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 624 | */ |
| 625 | public static final int SENSOR_REFERENCE_ILLUMINANT1_D50 = 23; |
| 626 | |
| 627 | /** |
| 628 | * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1 |
| 629 | */ |
| 630 | public static final int SENSOR_REFERENCE_ILLUMINANT1_ISO_STUDIO_TUNGSTEN = 24; |
| 631 | |
| 632 | // |
Igor Murashkin | 68f4006 | 2013-09-10 12:15:54 -0700 | [diff] [blame] | 633 | // Enumeration values for CameraCharacteristics#LED_AVAILABLE_LEDS |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 634 | // |
| 635 | |
| 636 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 637 | * <p>android.led.transmit control is used.</p> |
Igor Murashkin | 68f4006 | 2013-09-10 12:15:54 -0700 | [diff] [blame] | 638 | * @see CameraCharacteristics#LED_AVAILABLE_LEDS |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 639 | * @hide |
| 640 | */ |
| 641 | public static final int LED_AVAILABLE_LEDS_TRANSMIT = 0; |
| 642 | |
| 643 | // |
Igor Murashkin | 68f4006 | 2013-09-10 12:15:54 -0700 | [diff] [blame] | 644 | // Enumeration values for CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 645 | // |
| 646 | |
| 647 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 648 | * <p>This camera device has only limited capabilities.</p> |
Igor Murashkin | 68f4006 | 2013-09-10 12:15:54 -0700 | [diff] [blame] | 649 | * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 650 | */ |
| 651 | public static final int INFO_SUPPORTED_HARDWARE_LEVEL_LIMITED = 0; |
| 652 | |
| 653 | /** |
Ruben Brunk | 4a61a86 | 2014-07-01 16:00:26 -0700 | [diff] [blame] | 654 | * <p>This camera device is capable of supporting advanced imaging applications.</p> |
Igor Murashkin | 68f4006 | 2013-09-10 12:15:54 -0700 | [diff] [blame] | 655 | * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 656 | */ |
| 657 | public static final int INFO_SUPPORTED_HARDWARE_LEVEL_FULL = 1; |
| 658 | |
Ruben Brunk | 4a61a86 | 2014-07-01 16:00:26 -0700 | [diff] [blame] | 659 | /** |
| 660 | * <p>This camera device is running in backward compatibility mode.</p> |
| 661 | * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL |
| 662 | */ |
| 663 | public static final int INFO_SUPPORTED_HARDWARE_LEVEL_LEGACY = 2; |
| 664 | |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 665 | // |
Igor Murashkin | 3865a84 | 2014-01-17 18:18:39 -0800 | [diff] [blame] | 666 | // Enumeration values for CameraCharacteristics#SYNC_MAX_LATENCY |
| 667 | // |
| 668 | |
| 669 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 670 | * <p>Every frame has the requests immediately applied.</p> |
| 671 | * <p>Furthermore for all results, |
Igor Murashkin | bdf366c | 2014-07-25 16:54:20 -0700 | [diff] [blame] | 672 | * <code>android.sync.frameNumber == CaptureResult#getFrameNumber()</code></p> |
Igor Murashkin | 3865a84 | 2014-01-17 18:18:39 -0800 | [diff] [blame] | 673 | * <p>Changing controls over multiple requests one after another will |
| 674 | * produce results that have those controls applied atomically |
| 675 | * each frame.</p> |
| 676 | * <p>All FULL capability devices will have this as their maxLatency.</p> |
| 677 | * @see CameraCharacteristics#SYNC_MAX_LATENCY |
| 678 | */ |
| 679 | public static final int SYNC_MAX_LATENCY_PER_FRAME_CONTROL = 0; |
| 680 | |
| 681 | /** |
| 682 | * <p>Each new frame has some subset (potentially the entire set) |
| 683 | * of the past requests applied to the camera settings.</p> |
| 684 | * <p>By submitting a series of identical requests, the camera device |
| 685 | * will eventually have the camera settings applied, but it is |
| 686 | * unknown when that exact point will be.</p> |
Igor Murashkin | bdf366c | 2014-07-25 16:54:20 -0700 | [diff] [blame] | 687 | * <p>All LEGACY capability devices will have this as their maxLatency.</p> |
Igor Murashkin | 3865a84 | 2014-01-17 18:18:39 -0800 | [diff] [blame] | 688 | * @see CameraCharacteristics#SYNC_MAX_LATENCY |
| 689 | */ |
| 690 | public static final int SYNC_MAX_LATENCY_UNKNOWN = -1; |
| 691 | |
| 692 | // |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 693 | // Enumeration values for CaptureRequest#COLOR_CORRECTION_MODE |
| 694 | // |
| 695 | |
| 696 | /** |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 697 | * <p>Use the {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} matrix |
Igor Murashkin | 7d2a5c5 | 2014-01-17 15:07:52 -0800 | [diff] [blame] | 698 | * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} to do color conversion.</p> |
| 699 | * <p>All advanced white balance adjustments (not specified |
| 700 | * by our white balance pipeline) must be disabled.</p> |
| 701 | * <p>If AWB is enabled with <code>{@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode} != OFF</code>, then |
| 702 | * TRANSFORM_MATRIX is ignored. The camera device will override |
| 703 | * this value to either FAST or HIGH_QUALITY.</p> |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 704 | * |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 705 | * @see CaptureRequest#COLOR_CORRECTION_GAINS |
Eino-Ville Talvala | 265b34c | 2014-01-16 16:18:52 -0800 | [diff] [blame] | 706 | * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM |
Igor Murashkin | 7d2a5c5 | 2014-01-17 15:07:52 -0800 | [diff] [blame] | 707 | * @see CaptureRequest#CONTROL_AWB_MODE |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 708 | * @see CaptureRequest#COLOR_CORRECTION_MODE |
| 709 | */ |
| 710 | public static final int COLOR_CORRECTION_MODE_TRANSFORM_MATRIX = 0; |
| 711 | |
| 712 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 713 | * <p>Color correction processing must not slow down |
| 714 | * capture rate relative to sensor raw output.</p> |
Igor Murashkin | 7d2a5c5 | 2014-01-17 15:07:52 -0800 | [diff] [blame] | 715 | * <p>Advanced white balance adjustments above and beyond |
| 716 | * the specified white balance pipeline may be applied.</p> |
| 717 | * <p>If AWB is enabled with <code>{@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode} != OFF</code>, then |
| 718 | * the camera device uses the last frame's AWB values |
| 719 | * (or defaults if AWB has never been run).</p> |
| 720 | * |
| 721 | * @see CaptureRequest#CONTROL_AWB_MODE |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 722 | * @see CaptureRequest#COLOR_CORRECTION_MODE |
| 723 | */ |
| 724 | public static final int COLOR_CORRECTION_MODE_FAST = 1; |
| 725 | |
| 726 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 727 | * <p>Color correction processing operates at improved |
| 728 | * quality but reduced capture rate (relative to sensor raw |
| 729 | * output).</p> |
Igor Murashkin | 7d2a5c5 | 2014-01-17 15:07:52 -0800 | [diff] [blame] | 730 | * <p>Advanced white balance adjustments above and beyond |
| 731 | * the specified white balance pipeline may be applied.</p> |
| 732 | * <p>If AWB is enabled with <code>{@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode} != OFF</code>, then |
| 733 | * the camera device uses the last frame's AWB values |
| 734 | * (or defaults if AWB has never been run).</p> |
| 735 | * |
| 736 | * @see CaptureRequest#CONTROL_AWB_MODE |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 737 | * @see CaptureRequest#COLOR_CORRECTION_MODE |
| 738 | */ |
| 739 | public static final int COLOR_CORRECTION_MODE_HIGH_QUALITY = 2; |
| 740 | |
| 741 | // |
Zhijun He | a05e59d | 2014-07-08 18:27:47 -0700 | [diff] [blame] | 742 | // Enumeration values for CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE |
| 743 | // |
| 744 | |
| 745 | /** |
| 746 | * <p>No aberration correction is applied.</p> |
| 747 | * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE |
| 748 | */ |
| 749 | public static final int COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_OFF = 0; |
| 750 | |
| 751 | /** |
| 752 | * <p>Aberration correction will not slow down capture rate |
| 753 | * relative to sensor raw output.</p> |
| 754 | * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE |
| 755 | */ |
| 756 | public static final int COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_FAST = 1; |
| 757 | |
| 758 | /** |
| 759 | * <p>Aberration correction operates at improved quality but reduced |
| 760 | * capture rate (relative to sensor raw output).</p> |
| 761 | * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_CORRECTION_MODE |
| 762 | */ |
| 763 | public static final int COLOR_CORRECTION_ABERRATION_CORRECTION_MODE_HIGH_QUALITY = 2; |
| 764 | |
| 765 | // |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 766 | // Enumeration values for CaptureRequest#CONTROL_AE_ANTIBANDING_MODE |
| 767 | // |
| 768 | |
| 769 | /** |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 770 | * <p>The camera device will not adjust exposure duration to |
| 771 | * avoid banding problems.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 772 | * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE |
| 773 | */ |
| 774 | public static final int CONTROL_AE_ANTIBANDING_MODE_OFF = 0; |
| 775 | |
| 776 | /** |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 777 | * <p>The camera device will adjust exposure duration to |
| 778 | * avoid banding problems with 50Hz illumination sources.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 779 | * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE |
| 780 | */ |
| 781 | public static final int CONTROL_AE_ANTIBANDING_MODE_50HZ = 1; |
| 782 | |
| 783 | /** |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 784 | * <p>The camera device will adjust exposure duration to |
| 785 | * avoid banding problems with 60Hz illumination |
| 786 | * sources.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 787 | * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE |
| 788 | */ |
| 789 | public static final int CONTROL_AE_ANTIBANDING_MODE_60HZ = 2; |
| 790 | |
| 791 | /** |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 792 | * <p>The camera device will automatically adapt its |
| 793 | * antibanding routine to the current illumination |
| 794 | * conditions. This is the default.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 795 | * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE |
| 796 | */ |
| 797 | public static final int CONTROL_AE_ANTIBANDING_MODE_AUTO = 3; |
| 798 | |
| 799 | // |
| 800 | // Enumeration values for CaptureRequest#CONTROL_AE_MODE |
| 801 | // |
| 802 | |
| 803 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 804 | * <p>The camera device's autoexposure routine is disabled.</p> |
| 805 | * <p>The application-selected {@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}, |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 806 | * {@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity} and |
| 807 | * {@link CaptureRequest#SENSOR_FRAME_DURATION android.sensor.frameDuration} are used by the camera |
| 808 | * device, along with android.flash.* fields, if there's |
| 809 | * a flash unit for this camera device.</p> |
| 810 | * |
Zhijun He | 5f2a47f | 2014-01-16 15:44:41 -0800 | [diff] [blame] | 811 | * @see CaptureRequest#SENSOR_EXPOSURE_TIME |
Eino-Ville Talvala | 265b34c | 2014-01-16 16:18:52 -0800 | [diff] [blame] | 812 | * @see CaptureRequest#SENSOR_FRAME_DURATION |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 813 | * @see CaptureRequest#SENSOR_SENSITIVITY |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 814 | * @see CaptureRequest#CONTROL_AE_MODE |
| 815 | */ |
| 816 | public static final int CONTROL_AE_MODE_OFF = 0; |
| 817 | |
| 818 | /** |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 819 | * <p>The camera device's autoexposure routine is active, |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 820 | * with no flash control.</p> |
| 821 | * <p>The application's values for |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 822 | * {@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}, |
| 823 | * {@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}, and |
| 824 | * {@link CaptureRequest#SENSOR_FRAME_DURATION android.sensor.frameDuration} are ignored. The |
| 825 | * application has control over the various |
| 826 | * android.flash.* fields.</p> |
| 827 | * |
Zhijun He | 5f2a47f | 2014-01-16 15:44:41 -0800 | [diff] [blame] | 828 | * @see CaptureRequest#SENSOR_EXPOSURE_TIME |
Eino-Ville Talvala | 265b34c | 2014-01-16 16:18:52 -0800 | [diff] [blame] | 829 | * @see CaptureRequest#SENSOR_FRAME_DURATION |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 830 | * @see CaptureRequest#SENSOR_SENSITIVITY |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 831 | * @see CaptureRequest#CONTROL_AE_MODE |
| 832 | */ |
| 833 | public static final int CONTROL_AE_MODE_ON = 1; |
| 834 | |
| 835 | /** |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 836 | * <p>Like ON, except that the camera device also controls |
| 837 | * the camera's flash unit, firing it in low-light |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 838 | * conditions.</p> |
| 839 | * <p>The flash may be fired during a precapture sequence |
| 840 | * (triggered by {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}) and |
| 841 | * may be fired for captures for which the |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 842 | * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} field is set to |
| 843 | * STILL_CAPTURE</p> |
| 844 | * |
Igor Murashkin | 3242f4f | 2014-01-15 12:27:41 -0800 | [diff] [blame] | 845 | * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER |
Zhijun He | 5f2a47f | 2014-01-16 15:44:41 -0800 | [diff] [blame] | 846 | * @see CaptureRequest#CONTROL_CAPTURE_INTENT |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 847 | * @see CaptureRequest#CONTROL_AE_MODE |
| 848 | */ |
| 849 | public static final int CONTROL_AE_MODE_ON_AUTO_FLASH = 2; |
| 850 | |
| 851 | /** |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 852 | * <p>Like ON, except that the camera device also controls |
| 853 | * the camera's flash unit, always firing it for still |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 854 | * captures.</p> |
| 855 | * <p>The flash may be fired during a precapture sequence |
| 856 | * (triggered by {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}) and |
| 857 | * will always be fired for captures for which the |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 858 | * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} field is set to |
| 859 | * STILL_CAPTURE</p> |
| 860 | * |
Igor Murashkin | 3242f4f | 2014-01-15 12:27:41 -0800 | [diff] [blame] | 861 | * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER |
Zhijun He | 5f2a47f | 2014-01-16 15:44:41 -0800 | [diff] [blame] | 862 | * @see CaptureRequest#CONTROL_CAPTURE_INTENT |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 863 | * @see CaptureRequest#CONTROL_AE_MODE |
| 864 | */ |
| 865 | public static final int CONTROL_AE_MODE_ON_ALWAYS_FLASH = 3; |
| 866 | |
| 867 | /** |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 868 | * <p>Like ON_AUTO_FLASH, but with automatic red eye |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 869 | * reduction.</p> |
| 870 | * <p>If deemed necessary by the camera device, a red eye |
| 871 | * reduction flash will fire during the precapture |
| 872 | * sequence.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 873 | * @see CaptureRequest#CONTROL_AE_MODE |
| 874 | */ |
| 875 | public static final int CONTROL_AE_MODE_ON_AUTO_FLASH_REDEYE = 4; |
| 876 | |
| 877 | // |
| 878 | // Enumeration values for CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER |
| 879 | // |
| 880 | |
| 881 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 882 | * <p>The trigger is idle.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 883 | * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER |
| 884 | */ |
| 885 | public static final int CONTROL_AE_PRECAPTURE_TRIGGER_IDLE = 0; |
| 886 | |
| 887 | /** |
Zhijun He | 228f4f9 | 2014-01-16 17:22:05 -0800 | [diff] [blame] | 888 | * <p>The precapture metering sequence will be started |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 889 | * by the camera device.</p> |
| 890 | * <p>The exact effect of the precapture trigger depends on |
| 891 | * the current AE mode and state.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 892 | * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER |
| 893 | */ |
| 894 | public static final int CONTROL_AE_PRECAPTURE_TRIGGER_START = 1; |
| 895 | |
| 896 | // |
| 897 | // Enumeration values for CaptureRequest#CONTROL_AF_MODE |
| 898 | // |
| 899 | |
| 900 | /** |
Zhijun He | f353742 | 2013-12-16 16:56:35 -0800 | [diff] [blame] | 901 | * <p>The auto-focus routine does not control the lens; |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 902 | * {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance} is controlled by the |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 903 | * application.</p> |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 904 | * |
| 905 | * @see CaptureRequest#LENS_FOCUS_DISTANCE |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 906 | * @see CaptureRequest#CONTROL_AF_MODE |
| 907 | */ |
| 908 | public static final int CONTROL_AF_MODE_OFF = 0; |
| 909 | |
| 910 | /** |
Eino-Ville Talvala | b67a3b3 | 2014-06-06 13:07:20 -0700 | [diff] [blame] | 911 | * <p>Basic automatic focus mode.</p> |
| 912 | * <p>In this mode, the lens does not move unless |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 913 | * the autofocus trigger action is called. When that trigger |
Eino-Ville Talvala | b67a3b3 | 2014-06-06 13:07:20 -0700 | [diff] [blame] | 914 | * is activated, AF will transition to ACTIVE_SCAN, then to |
Zhijun He | f353742 | 2013-12-16 16:56:35 -0800 | [diff] [blame] | 915 | * the outcome of the scan (FOCUSED or NOT_FOCUSED).</p> |
Eino-Ville Talvala | b67a3b3 | 2014-06-06 13:07:20 -0700 | [diff] [blame] | 916 | * <p>Always supported if lens is not fixed focus.</p> |
| 917 | * <p>Use {@link CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE android.lens.info.minimumFocusDistance} to determine if lens |
| 918 | * is fixed-focus.</p> |
Zhijun He | f353742 | 2013-12-16 16:56:35 -0800 | [diff] [blame] | 919 | * <p>Triggering AF_CANCEL resets the lens position to default, |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 920 | * and sets the AF state to INACTIVE.</p> |
Eino-Ville Talvala | 0da8bf5 | 2014-01-08 16:18:35 -0800 | [diff] [blame] | 921 | * |
| 922 | * @see CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 923 | * @see CaptureRequest#CONTROL_AF_MODE |
| 924 | */ |
| 925 | public static final int CONTROL_AF_MODE_AUTO = 1; |
| 926 | |
| 927 | /** |
Eino-Ville Talvala | b67a3b3 | 2014-06-06 13:07:20 -0700 | [diff] [blame] | 928 | * <p>Close-up focusing mode.</p> |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 929 | * <p>In this mode, the lens does not move unless the |
Eino-Ville Talvala | b67a3b3 | 2014-06-06 13:07:20 -0700 | [diff] [blame] | 930 | * autofocus trigger action is called. When that trigger is |
| 931 | * activated, AF will transition to ACTIVE_SCAN, then to |
| 932 | * the outcome of the scan (FOCUSED or NOT_FOCUSED). This |
| 933 | * mode is optimized for focusing on objects very close to |
| 934 | * the camera.</p> |
| 935 | * <p>When that trigger is activated, AF will transition to |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 936 | * ACTIVE_SCAN, then to the outcome of the scan (FOCUSED or |
Eino-Ville Talvala | b67a3b3 | 2014-06-06 13:07:20 -0700 | [diff] [blame] | 937 | * NOT_FOCUSED). Triggering cancel AF resets the lens |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 938 | * position to default, and sets the AF state to |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 939 | * INACTIVE.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 940 | * @see CaptureRequest#CONTROL_AF_MODE |
| 941 | */ |
| 942 | public static final int CONTROL_AF_MODE_MACRO = 2; |
| 943 | |
| 944 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 945 | * <p>In this mode, the AF algorithm modifies the lens |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 946 | * position continually to attempt to provide a |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 947 | * constantly-in-focus image stream.</p> |
| 948 | * <p>The focusing behavior should be suitable for good quality |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 949 | * video recording; typically this means slower focus |
| 950 | * movement and no overshoots. When the AF trigger is not |
| 951 | * involved, the AF algorithm should start in INACTIVE state, |
| 952 | * and then transition into PASSIVE_SCAN and PASSIVE_FOCUSED |
| 953 | * states as appropriate. When the AF trigger is activated, |
| 954 | * the algorithm should immediately transition into |
| 955 | * AF_FOCUSED or AF_NOT_FOCUSED as appropriate, and lock the |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 956 | * lens position until a cancel AF trigger is received.</p> |
| 957 | * <p>Once cancel is received, the algorithm should transition |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 958 | * back to INACTIVE and resume passive scan. Note that this |
| 959 | * behavior is not identical to CONTINUOUS_PICTURE, since an |
| 960 | * ongoing PASSIVE_SCAN must immediately be |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 961 | * canceled.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 962 | * @see CaptureRequest#CONTROL_AF_MODE |
| 963 | */ |
| 964 | public static final int CONTROL_AF_MODE_CONTINUOUS_VIDEO = 3; |
| 965 | |
| 966 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 967 | * <p>In this mode, the AF algorithm modifies the lens |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 968 | * position continually to attempt to provide a |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 969 | * constantly-in-focus image stream.</p> |
| 970 | * <p>The focusing behavior should be suitable for still image |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 971 | * capture; typically this means focusing as fast as |
| 972 | * possible. When the AF trigger is not involved, the AF |
| 973 | * algorithm should start in INACTIVE state, and then |
| 974 | * transition into PASSIVE_SCAN and PASSIVE_FOCUSED states as |
| 975 | * appropriate as it attempts to maintain focus. When the AF |
| 976 | * trigger is activated, the algorithm should finish its |
| 977 | * PASSIVE_SCAN if active, and then transition into |
| 978 | * AF_FOCUSED or AF_NOT_FOCUSED as appropriate, and lock the |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 979 | * lens position until a cancel AF trigger is received.</p> |
| 980 | * <p>When the AF cancel trigger is activated, the algorithm |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 981 | * should transition back to INACTIVE and then act as if it |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 982 | * has just been started.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 983 | * @see CaptureRequest#CONTROL_AF_MODE |
| 984 | */ |
| 985 | public static final int CONTROL_AF_MODE_CONTINUOUS_PICTURE = 4; |
| 986 | |
| 987 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 988 | * <p>Extended depth of field (digital focus) mode.</p> |
| 989 | * <p>The camera device will produce images with an extended |
| 990 | * depth of field automatically; no special focusing |
| 991 | * operations need to be done before taking a picture.</p> |
| 992 | * <p>AF triggers are ignored, and the AF state will always be |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 993 | * INACTIVE.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 994 | * @see CaptureRequest#CONTROL_AF_MODE |
| 995 | */ |
| 996 | public static final int CONTROL_AF_MODE_EDOF = 5; |
| 997 | |
| 998 | // |
| 999 | // Enumeration values for CaptureRequest#CONTROL_AF_TRIGGER |
| 1000 | // |
| 1001 | |
| 1002 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 1003 | * <p>The trigger is idle.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1004 | * @see CaptureRequest#CONTROL_AF_TRIGGER |
| 1005 | */ |
| 1006 | public static final int CONTROL_AF_TRIGGER_IDLE = 0; |
| 1007 | |
| 1008 | /** |
Zhijun He | 228f4f9 | 2014-01-16 17:22:05 -0800 | [diff] [blame] | 1009 | * <p>Autofocus will trigger now.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1010 | * @see CaptureRequest#CONTROL_AF_TRIGGER |
| 1011 | */ |
| 1012 | public static final int CONTROL_AF_TRIGGER_START = 1; |
| 1013 | |
| 1014 | /** |
Zhijun He | 228f4f9 | 2014-01-16 17:22:05 -0800 | [diff] [blame] | 1015 | * <p>Autofocus will return to its initial |
| 1016 | * state, and cancel any currently active trigger.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1017 | * @see CaptureRequest#CONTROL_AF_TRIGGER |
| 1018 | */ |
| 1019 | public static final int CONTROL_AF_TRIGGER_CANCEL = 2; |
| 1020 | |
| 1021 | // |
| 1022 | // Enumeration values for CaptureRequest#CONTROL_AWB_MODE |
| 1023 | // |
| 1024 | |
| 1025 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1026 | * <p>The camera device's auto-white balance routine is disabled.</p> |
| 1027 | * <p>The application-selected color transform matrix |
Zhijun He | 399f05d | 2014-01-15 11:31:30 -0800 | [diff] [blame] | 1028 | * ({@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}) and gains |
| 1029 | * ({@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains}) are used by the camera |
| 1030 | * device for manual white balance control.</p> |
| 1031 | * |
Zhijun He | 399f05d | 2014-01-15 11:31:30 -0800 | [diff] [blame] | 1032 | * @see CaptureRequest#COLOR_CORRECTION_GAINS |
Eino-Ville Talvala | 265b34c | 2014-01-16 16:18:52 -0800 | [diff] [blame] | 1033 | * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1034 | * @see CaptureRequest#CONTROL_AWB_MODE |
| 1035 | */ |
| 1036 | public static final int CONTROL_AWB_MODE_OFF = 0; |
| 1037 | |
| 1038 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1039 | * <p>The camera device's auto-white balance routine is active.</p> |
| 1040 | * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} |
| 1041 | * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. |
| 1042 | * For devices that support the MANUAL_POST_PROCESSING capability, the |
| 1043 | * values used by the camera device for the transform and gains |
| 1044 | * will be available in the capture result for this request.</p> |
Zhijun He | 399f05d | 2014-01-15 11:31:30 -0800 | [diff] [blame] | 1045 | * |
| 1046 | * @see CaptureRequest#COLOR_CORRECTION_GAINS |
Eino-Ville Talvala | d8fd679 | 2014-02-10 12:41:04 -0800 | [diff] [blame] | 1047 | * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1048 | * @see CaptureRequest#CONTROL_AWB_MODE |
| 1049 | */ |
| 1050 | public static final int CONTROL_AWB_MODE_AUTO = 1; |
| 1051 | |
| 1052 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1053 | * <p>The camera device's auto-white balance routine is disabled; |
Zhijun He | 399f05d | 2014-01-15 11:31:30 -0800 | [diff] [blame] | 1054 | * the camera device uses incandescent light as the assumed scene |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1055 | * illumination for white balance.</p> |
| 1056 | * <p>While the exact white balance transforms are up to the |
| 1057 | * camera device, they will approximately match the CIE |
| 1058 | * standard illuminant A.</p> |
| 1059 | * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} |
| 1060 | * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. |
| 1061 | * For devices that support the MANUAL_POST_PROCESSING capability, the |
| 1062 | * values used by the camera device for the transform and gains |
| 1063 | * will be available in the capture result for this request.</p> |
| 1064 | * |
| 1065 | * @see CaptureRequest#COLOR_CORRECTION_GAINS |
| 1066 | * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1067 | * @see CaptureRequest#CONTROL_AWB_MODE |
| 1068 | */ |
| 1069 | public static final int CONTROL_AWB_MODE_INCANDESCENT = 2; |
| 1070 | |
| 1071 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1072 | * <p>The camera device's auto-white balance routine is disabled; |
Zhijun He | 399f05d | 2014-01-15 11:31:30 -0800 | [diff] [blame] | 1073 | * the camera device uses fluorescent light as the assumed scene |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1074 | * illumination for white balance.</p> |
| 1075 | * <p>While the exact white balance transforms are up to the |
| 1076 | * camera device, they will approximately match the CIE |
| 1077 | * standard illuminant F2.</p> |
| 1078 | * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} |
| 1079 | * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. |
| 1080 | * For devices that support the MANUAL_POST_PROCESSING capability, the |
| 1081 | * values used by the camera device for the transform and gains |
| 1082 | * will be available in the capture result for this request.</p> |
| 1083 | * |
| 1084 | * @see CaptureRequest#COLOR_CORRECTION_GAINS |
| 1085 | * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1086 | * @see CaptureRequest#CONTROL_AWB_MODE |
| 1087 | */ |
| 1088 | public static final int CONTROL_AWB_MODE_FLUORESCENT = 3; |
| 1089 | |
| 1090 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1091 | * <p>The camera device's auto-white balance routine is disabled; |
Zhijun He | 399f05d | 2014-01-15 11:31:30 -0800 | [diff] [blame] | 1092 | * the camera device uses warm fluorescent light as the assumed scene |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1093 | * illumination for white balance.</p> |
| 1094 | * <p>While the exact white balance transforms are up to the |
| 1095 | * camera device, they will approximately match the CIE |
| 1096 | * standard illuminant F4.</p> |
| 1097 | * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} |
| 1098 | * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. |
| 1099 | * For devices that support the MANUAL_POST_PROCESSING capability, the |
| 1100 | * values used by the camera device for the transform and gains |
| 1101 | * will be available in the capture result for this request.</p> |
| 1102 | * |
| 1103 | * @see CaptureRequest#COLOR_CORRECTION_GAINS |
| 1104 | * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1105 | * @see CaptureRequest#CONTROL_AWB_MODE |
| 1106 | */ |
| 1107 | public static final int CONTROL_AWB_MODE_WARM_FLUORESCENT = 4; |
| 1108 | |
| 1109 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1110 | * <p>The camera device's auto-white balance routine is disabled; |
Zhijun He | 399f05d | 2014-01-15 11:31:30 -0800 | [diff] [blame] | 1111 | * the camera device uses daylight light as the assumed scene |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1112 | * illumination for white balance.</p> |
| 1113 | * <p>While the exact white balance transforms are up to the |
| 1114 | * camera device, they will approximately match the CIE |
| 1115 | * standard illuminant D65.</p> |
| 1116 | * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} |
| 1117 | * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. |
| 1118 | * For devices that support the MANUAL_POST_PROCESSING capability, the |
| 1119 | * values used by the camera device for the transform and gains |
| 1120 | * will be available in the capture result for this request.</p> |
| 1121 | * |
| 1122 | * @see CaptureRequest#COLOR_CORRECTION_GAINS |
| 1123 | * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1124 | * @see CaptureRequest#CONTROL_AWB_MODE |
| 1125 | */ |
| 1126 | public static final int CONTROL_AWB_MODE_DAYLIGHT = 5; |
| 1127 | |
| 1128 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1129 | * <p>The camera device's auto-white balance routine is disabled; |
Zhijun He | 399f05d | 2014-01-15 11:31:30 -0800 | [diff] [blame] | 1130 | * the camera device uses cloudy daylight light as the assumed scene |
| 1131 | * illumination for white balance.</p> |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1132 | * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} |
| 1133 | * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. |
| 1134 | * For devices that support the MANUAL_POST_PROCESSING capability, the |
| 1135 | * values used by the camera device for the transform and gains |
| 1136 | * will be available in the capture result for this request.</p> |
| 1137 | * |
| 1138 | * @see CaptureRequest#COLOR_CORRECTION_GAINS |
| 1139 | * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1140 | * @see CaptureRequest#CONTROL_AWB_MODE |
| 1141 | */ |
| 1142 | public static final int CONTROL_AWB_MODE_CLOUDY_DAYLIGHT = 6; |
| 1143 | |
| 1144 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1145 | * <p>The camera device's auto-white balance routine is disabled; |
Zhijun He | 399f05d | 2014-01-15 11:31:30 -0800 | [diff] [blame] | 1146 | * the camera device uses twilight light as the assumed scene |
| 1147 | * illumination for white balance.</p> |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1148 | * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} |
| 1149 | * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. |
| 1150 | * For devices that support the MANUAL_POST_PROCESSING capability, the |
| 1151 | * values used by the camera device for the transform and gains |
| 1152 | * will be available in the capture result for this request.</p> |
| 1153 | * |
| 1154 | * @see CaptureRequest#COLOR_CORRECTION_GAINS |
| 1155 | * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1156 | * @see CaptureRequest#CONTROL_AWB_MODE |
| 1157 | */ |
| 1158 | public static final int CONTROL_AWB_MODE_TWILIGHT = 7; |
| 1159 | |
| 1160 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1161 | * <p>The camera device's auto-white balance routine is disabled; |
Zhijun He | 399f05d | 2014-01-15 11:31:30 -0800 | [diff] [blame] | 1162 | * the camera device uses shade light as the assumed scene |
| 1163 | * illumination for white balance.</p> |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1164 | * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} |
| 1165 | * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored. |
| 1166 | * For devices that support the MANUAL_POST_PROCESSING capability, the |
| 1167 | * values used by the camera device for the transform and gains |
| 1168 | * will be available in the capture result for this request.</p> |
| 1169 | * |
| 1170 | * @see CaptureRequest#COLOR_CORRECTION_GAINS |
| 1171 | * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1172 | * @see CaptureRequest#CONTROL_AWB_MODE |
| 1173 | */ |
| 1174 | public static final int CONTROL_AWB_MODE_SHADE = 8; |
| 1175 | |
| 1176 | // |
| 1177 | // Enumeration values for CaptureRequest#CONTROL_CAPTURE_INTENT |
| 1178 | // |
| 1179 | |
| 1180 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1181 | * <p>The goal of this request doesn't fall into the other |
| 1182 | * categories. The camera device will default to preview-like |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 1183 | * behavior.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1184 | * @see CaptureRequest#CONTROL_CAPTURE_INTENT |
| 1185 | */ |
| 1186 | public static final int CONTROL_CAPTURE_INTENT_CUSTOM = 0; |
| 1187 | |
| 1188 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1189 | * <p>This request is for a preview-like use case.</p> |
| 1190 | * <p>The precapture trigger may be used to start off a metering |
| 1191 | * w/flash sequence.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1192 | * @see CaptureRequest#CONTROL_CAPTURE_INTENT |
| 1193 | */ |
| 1194 | public static final int CONTROL_CAPTURE_INTENT_PREVIEW = 1; |
| 1195 | |
| 1196 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 1197 | * <p>This request is for a still capture-type |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1198 | * use case.</p> |
| 1199 | * <p>If the flash unit is under automatic control, it may fire as needed.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1200 | * @see CaptureRequest#CONTROL_CAPTURE_INTENT |
| 1201 | */ |
| 1202 | public static final int CONTROL_CAPTURE_INTENT_STILL_CAPTURE = 2; |
| 1203 | |
| 1204 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 1205 | * <p>This request is for a video recording |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1206 | * use case.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1207 | * @see CaptureRequest#CONTROL_CAPTURE_INTENT |
| 1208 | */ |
| 1209 | public static final int CONTROL_CAPTURE_INTENT_VIDEO_RECORD = 3; |
| 1210 | |
| 1211 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 1212 | * <p>This request is for a video snapshot (still |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1213 | * image while recording video) use case.</p> |
| 1214 | * <p>The camera device should take the highest-quality image |
| 1215 | * possible (given the other settings) without disrupting the |
Eino-Ville Talvala | abd9d3c | 2014-07-28 13:01:52 -0700 | [diff] [blame] | 1216 | * frame rate of video recording. </p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1217 | * @see CaptureRequest#CONTROL_CAPTURE_INTENT |
| 1218 | */ |
| 1219 | public static final int CONTROL_CAPTURE_INTENT_VIDEO_SNAPSHOT = 4; |
| 1220 | |
| 1221 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 1222 | * <p>This request is for a ZSL usecase; the |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1223 | * application will stream full-resolution images and |
| 1224 | * reprocess one or several later for a final |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1225 | * capture.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1226 | * @see CaptureRequest#CONTROL_CAPTURE_INTENT |
| 1227 | */ |
| 1228 | public static final int CONTROL_CAPTURE_INTENT_ZERO_SHUTTER_LAG = 5; |
| 1229 | |
Zhijun He | e30adb7 | 2014-04-09 19:04:31 -0700 | [diff] [blame] | 1230 | /** |
| 1231 | * <p>This request is for manual capture use case where |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1232 | * the applications want to directly control the capture parameters.</p> |
| 1233 | * <p>For example, the application may wish to manually control |
| 1234 | * {@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}, {@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}, etc.</p> |
Zhijun He | e30adb7 | 2014-04-09 19:04:31 -0700 | [diff] [blame] | 1235 | * |
| 1236 | * @see CaptureRequest#SENSOR_EXPOSURE_TIME |
| 1237 | * @see CaptureRequest#SENSOR_SENSITIVITY |
| 1238 | * @see CaptureRequest#CONTROL_CAPTURE_INTENT |
| 1239 | */ |
| 1240 | public static final int CONTROL_CAPTURE_INTENT_MANUAL = 6; |
| 1241 | |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1242 | // |
| 1243 | // Enumeration values for CaptureRequest#CONTROL_EFFECT_MODE |
| 1244 | // |
| 1245 | |
| 1246 | /** |
Ruben Brunk | 5f1dcfe | 2014-01-17 16:42:51 -0800 | [diff] [blame] | 1247 | * <p>No color effect will be applied.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1248 | * @see CaptureRequest#CONTROL_EFFECT_MODE |
| 1249 | */ |
| 1250 | public static final int CONTROL_EFFECT_MODE_OFF = 0; |
| 1251 | |
| 1252 | /** |
Ruben Brunk | 5f1dcfe | 2014-01-17 16:42:51 -0800 | [diff] [blame] | 1253 | * <p>A "monocolor" effect where the image is mapped into |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1254 | * a single color.</p> |
| 1255 | * <p>This will typically be grayscale.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1256 | * @see CaptureRequest#CONTROL_EFFECT_MODE |
| 1257 | */ |
| 1258 | public static final int CONTROL_EFFECT_MODE_MONO = 1; |
| 1259 | |
| 1260 | /** |
Ruben Brunk | 5f1dcfe | 2014-01-17 16:42:51 -0800 | [diff] [blame] | 1261 | * <p>A "photo-negative" effect where the image's colors |
| 1262 | * are inverted.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1263 | * @see CaptureRequest#CONTROL_EFFECT_MODE |
| 1264 | */ |
| 1265 | public static final int CONTROL_EFFECT_MODE_NEGATIVE = 2; |
| 1266 | |
| 1267 | /** |
Ruben Brunk | 5f1dcfe | 2014-01-17 16:42:51 -0800 | [diff] [blame] | 1268 | * <p>A "solarisation" effect (Sabattier effect) where the |
| 1269 | * image is wholly or partially reversed in |
| 1270 | * tone.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1271 | * @see CaptureRequest#CONTROL_EFFECT_MODE |
| 1272 | */ |
| 1273 | public static final int CONTROL_EFFECT_MODE_SOLARIZE = 3; |
| 1274 | |
| 1275 | /** |
Ruben Brunk | 5f1dcfe | 2014-01-17 16:42:51 -0800 | [diff] [blame] | 1276 | * <p>A "sepia" effect where the image is mapped into warm |
| 1277 | * gray, red, and brown tones.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1278 | * @see CaptureRequest#CONTROL_EFFECT_MODE |
| 1279 | */ |
| 1280 | public static final int CONTROL_EFFECT_MODE_SEPIA = 4; |
| 1281 | |
| 1282 | /** |
Ruben Brunk | 5f1dcfe | 2014-01-17 16:42:51 -0800 | [diff] [blame] | 1283 | * <p>A "posterization" effect where the image uses |
| 1284 | * discrete regions of tone rather than a continuous |
| 1285 | * gradient of tones.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1286 | * @see CaptureRequest#CONTROL_EFFECT_MODE |
| 1287 | */ |
| 1288 | public static final int CONTROL_EFFECT_MODE_POSTERIZE = 5; |
| 1289 | |
| 1290 | /** |
Ruben Brunk | 5f1dcfe | 2014-01-17 16:42:51 -0800 | [diff] [blame] | 1291 | * <p>A "whiteboard" effect where the image is typically displayed |
| 1292 | * as regions of white, with black or grey details.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1293 | * @see CaptureRequest#CONTROL_EFFECT_MODE |
| 1294 | */ |
| 1295 | public static final int CONTROL_EFFECT_MODE_WHITEBOARD = 6; |
| 1296 | |
| 1297 | /** |
Ruben Brunk | 5f1dcfe | 2014-01-17 16:42:51 -0800 | [diff] [blame] | 1298 | * <p>A "blackboard" effect where the image is typically displayed |
| 1299 | * as regions of black, with white or grey details.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1300 | * @see CaptureRequest#CONTROL_EFFECT_MODE |
| 1301 | */ |
| 1302 | public static final int CONTROL_EFFECT_MODE_BLACKBOARD = 7; |
| 1303 | |
| 1304 | /** |
Ruben Brunk | 5f1dcfe | 2014-01-17 16:42:51 -0800 | [diff] [blame] | 1305 | * <p>An "aqua" effect where a blue hue is added to the image.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1306 | * @see CaptureRequest#CONTROL_EFFECT_MODE |
| 1307 | */ |
| 1308 | public static final int CONTROL_EFFECT_MODE_AQUA = 8; |
| 1309 | |
| 1310 | // |
| 1311 | // Enumeration values for CaptureRequest#CONTROL_MODE |
| 1312 | // |
| 1313 | |
| 1314 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1315 | * <p>Full application control of pipeline.</p> |
| 1316 | * <p>All control by the device's metering and focusing (3A) |
| 1317 | * routines is disabled, and no other settings in |
| 1318 | * android.control.* have any effect, except that |
| 1319 | * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} may be used by the camera |
| 1320 | * device to select post-processing values for processing |
| 1321 | * blocks that do not allow for manual control, or are not |
| 1322 | * exposed by the camera API.</p> |
| 1323 | * <p>However, the camera device's 3A routines may continue to |
| 1324 | * collect statistics and update their internal state so that |
| 1325 | * when control is switched to AUTO mode, good control values |
| 1326 | * can be immediately applied.</p> |
| 1327 | * |
| 1328 | * @see CaptureRequest#CONTROL_CAPTURE_INTENT |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1329 | * @see CaptureRequest#CONTROL_MODE |
| 1330 | */ |
| 1331 | public static final int CONTROL_MODE_OFF = 0; |
| 1332 | |
| 1333 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1334 | * <p>Use settings for each individual 3A routine.</p> |
| 1335 | * <p>Manual control of capture parameters is disabled. All |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1336 | * controls in android.control.* besides sceneMode take |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1337 | * effect.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1338 | * @see CaptureRequest#CONTROL_MODE |
| 1339 | */ |
| 1340 | public static final int CONTROL_MODE_AUTO = 1; |
| 1341 | |
| 1342 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1343 | * <p>Use a specific scene mode.</p> |
| 1344 | * <p>Enabling this disables control.aeMode, control.awbMode and |
| 1345 | * control.afMode controls; the camera device will ignore |
| 1346 | * those settings while USE_SCENE_MODE is active (except for |
| 1347 | * FACE_PRIORITY scene mode). Other control entries are still |
| 1348 | * active. This setting can only be used if scene mode is |
| 1349 | * supported (i.e. {@link CameraCharacteristics#CONTROL_AVAILABLE_SCENE_MODES android.control.availableSceneModes} |
| 1350 | * contain some modes other than DISABLED).</p> |
Zhijun He | a486624 | 2014-03-27 23:51:34 -0700 | [diff] [blame] | 1351 | * |
| 1352 | * @see CameraCharacteristics#CONTROL_AVAILABLE_SCENE_MODES |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1353 | * @see CaptureRequest#CONTROL_MODE |
| 1354 | */ |
| 1355 | public static final int CONTROL_MODE_USE_SCENE_MODE = 2; |
| 1356 | |
Zhijun He | 2d5e897 | 2014-02-07 16:13:46 -0800 | [diff] [blame] | 1357 | /** |
| 1358 | * <p>Same as OFF mode, except that this capture will not be |
| 1359 | * used by camera device background auto-exposure, auto-white balance and |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1360 | * auto-focus algorithms (3A) to update their statistics.</p> |
| 1361 | * <p>Specifically, the 3A routines are locked to the last |
| 1362 | * values set from a request with AUTO, OFF, or |
| 1363 | * USE_SCENE_MODE, and any statistics or state updates |
| 1364 | * collected from manual captures with OFF_KEEP_STATE will be |
| 1365 | * discarded by the camera device.</p> |
Zhijun He | 2d5e897 | 2014-02-07 16:13:46 -0800 | [diff] [blame] | 1366 | * @see CaptureRequest#CONTROL_MODE |
| 1367 | */ |
| 1368 | public static final int CONTROL_MODE_OFF_KEEP_STATE = 3; |
| 1369 | |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1370 | // |
| 1371 | // Enumeration values for CaptureRequest#CONTROL_SCENE_MODE |
| 1372 | // |
| 1373 | |
| 1374 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1375 | * <p>Indicates that no scene modes are set for a given capture request.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1376 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1377 | */ |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1378 | public static final int CONTROL_SCENE_MODE_DISABLED = 0; |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1379 | |
| 1380 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1381 | * <p>If face detection support exists, use face |
| 1382 | * detection data for auto-focus, auto-white balance, and |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1383 | * auto-exposure routines.</p> |
| 1384 | * <p>If face detection statistics are disabled |
| 1385 | * (i.e. {@link CaptureRequest#STATISTICS_FACE_DETECT_MODE android.statistics.faceDetectMode} is set to OFF), |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1386 | * this should still operate correctly (but will not return |
| 1387 | * face detection statistics to the framework).</p> |
| 1388 | * <p>Unlike the other scene modes, {@link CaptureRequest#CONTROL_AE_MODE android.control.aeMode}, |
Eino-Ville Talvala | d8fd679 | 2014-02-10 12:41:04 -0800 | [diff] [blame] | 1389 | * {@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode}, and {@link CaptureRequest#CONTROL_AF_MODE android.control.afMode} |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1390 | * remain active when FACE_PRIORITY is set.</p> |
| 1391 | * |
| 1392 | * @see CaptureRequest#CONTROL_AE_MODE |
Eino-Ville Talvala | d8fd679 | 2014-02-10 12:41:04 -0800 | [diff] [blame] | 1393 | * @see CaptureRequest#CONTROL_AF_MODE |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1394 | * @see CaptureRequest#CONTROL_AWB_MODE |
| 1395 | * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1396 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1397 | */ |
| 1398 | public static final int CONTROL_SCENE_MODE_FACE_PRIORITY = 1; |
| 1399 | |
| 1400 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1401 | * <p>Optimized for photos of quickly moving objects.</p> |
| 1402 | * <p>Similar to SPORTS.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1403 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1404 | */ |
| 1405 | public static final int CONTROL_SCENE_MODE_ACTION = 2; |
| 1406 | |
| 1407 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1408 | * <p>Optimized for still photos of people.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1409 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1410 | */ |
| 1411 | public static final int CONTROL_SCENE_MODE_PORTRAIT = 3; |
| 1412 | |
| 1413 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1414 | * <p>Optimized for photos of distant macroscopic objects.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1415 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1416 | */ |
| 1417 | public static final int CONTROL_SCENE_MODE_LANDSCAPE = 4; |
| 1418 | |
| 1419 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1420 | * <p>Optimized for low-light settings.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1421 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1422 | */ |
| 1423 | public static final int CONTROL_SCENE_MODE_NIGHT = 5; |
| 1424 | |
| 1425 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1426 | * <p>Optimized for still photos of people in low-light |
| 1427 | * settings.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1428 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1429 | */ |
| 1430 | public static final int CONTROL_SCENE_MODE_NIGHT_PORTRAIT = 6; |
| 1431 | |
| 1432 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1433 | * <p>Optimized for dim, indoor settings where flash must |
| 1434 | * remain off.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1435 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1436 | */ |
| 1437 | public static final int CONTROL_SCENE_MODE_THEATRE = 7; |
| 1438 | |
| 1439 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1440 | * <p>Optimized for bright, outdoor beach settings.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1441 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1442 | */ |
| 1443 | public static final int CONTROL_SCENE_MODE_BEACH = 8; |
| 1444 | |
| 1445 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1446 | * <p>Optimized for bright, outdoor settings containing snow.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1447 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1448 | */ |
| 1449 | public static final int CONTROL_SCENE_MODE_SNOW = 9; |
| 1450 | |
| 1451 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1452 | * <p>Optimized for scenes of the setting sun.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1453 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1454 | */ |
| 1455 | public static final int CONTROL_SCENE_MODE_SUNSET = 10; |
| 1456 | |
| 1457 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1458 | * <p>Optimized to avoid blurry photos due to small amounts of |
| 1459 | * device motion (for example: due to hand shake).</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1460 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1461 | */ |
| 1462 | public static final int CONTROL_SCENE_MODE_STEADYPHOTO = 11; |
| 1463 | |
| 1464 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1465 | * <p>Optimized for nighttime photos of fireworks.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1466 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1467 | */ |
| 1468 | public static final int CONTROL_SCENE_MODE_FIREWORKS = 12; |
| 1469 | |
| 1470 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1471 | * <p>Optimized for photos of quickly moving people.</p> |
| 1472 | * <p>Similar to ACTION.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1473 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1474 | */ |
| 1475 | public static final int CONTROL_SCENE_MODE_SPORTS = 13; |
| 1476 | |
| 1477 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1478 | * <p>Optimized for dim, indoor settings with multiple moving |
| 1479 | * people.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1480 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1481 | */ |
| 1482 | public static final int CONTROL_SCENE_MODE_PARTY = 14; |
| 1483 | |
| 1484 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1485 | * <p>Optimized for dim settings where the main light source |
| 1486 | * is a flame.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1487 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1488 | */ |
| 1489 | public static final int CONTROL_SCENE_MODE_CANDLELIGHT = 15; |
| 1490 | |
| 1491 | /** |
Ruben Brunk | e667936 | 2014-01-17 17:05:54 -0800 | [diff] [blame] | 1492 | * <p>Optimized for accurately capturing a photo of barcode |
| 1493 | * for use by camera applications that wish to read the |
| 1494 | * barcode value.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1495 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1496 | */ |
| 1497 | public static final int CONTROL_SCENE_MODE_BARCODE = 16; |
| 1498 | |
Zhijun He | e040418 | 2014-06-26 13:17:09 -0700 | [diff] [blame] | 1499 | /** |
| 1500 | * <p>Optimized for high speed video recording (frame rate >=60fps) use case.</p> |
| 1501 | * <p>The supported high speed video sizes and fps ranges are specified in |
| 1502 | * android.control.availableHighSpeedVideoConfigurations. To get desired |
| 1503 | * output frame rates, the application is only allowed to select video size |
| 1504 | * and fps range combinations listed in this static metadata. The fps range |
| 1505 | * can be control via {@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange}.</p> |
| 1506 | * <p>In this mode, the camera device will override aeMode, awbMode, and afMode to |
| 1507 | * ON, ON, and CONTINUOUS_VIDEO, respectively. All post-processing block mode |
| 1508 | * controls will be overridden to be FAST. Therefore, no manual control of capture |
| 1509 | * and post-processing parameters is possible. All other controls operate the |
| 1510 | * same as when {@link CaptureRequest#CONTROL_MODE android.control.mode} == AUTO. This means that all other |
| 1511 | * android.control.* fields continue to work, such as</p> |
| 1512 | * <ul> |
| 1513 | * <li>{@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange}</li> |
| 1514 | * <li>{@link CaptureRequest#CONTROL_AE_EXPOSURE_COMPENSATION android.control.aeExposureCompensation}</li> |
| 1515 | * <li>{@link CaptureRequest#CONTROL_AE_LOCK android.control.aeLock}</li> |
| 1516 | * <li>{@link CaptureRequest#CONTROL_AWB_LOCK android.control.awbLock}</li> |
| 1517 | * <li>{@link CaptureRequest#CONTROL_EFFECT_MODE android.control.effectMode}</li> |
| 1518 | * <li>{@link CaptureRequest#CONTROL_AE_REGIONS android.control.aeRegions}</li> |
| 1519 | * <li>{@link CaptureRequest#CONTROL_AF_REGIONS android.control.afRegions}</li> |
| 1520 | * <li>{@link CaptureRequest#CONTROL_AWB_REGIONS android.control.awbRegions}</li> |
| 1521 | * <li>{@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}</li> |
| 1522 | * <li>{@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}</li> |
| 1523 | * </ul> |
| 1524 | * <p>Outside of android.control.*, the following controls will work:</p> |
| 1525 | * <ul> |
| 1526 | * <li>{@link CaptureRequest#FLASH_MODE android.flash.mode} (automatic flash for still capture will not work since aeMode is ON)</li> |
| 1527 | * <li>{@link CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE android.lens.opticalStabilizationMode} (if it is supported)</li> |
| 1528 | * <li>{@link CaptureRequest#SCALER_CROP_REGION android.scaler.cropRegion}</li> |
| 1529 | * <li>{@link CaptureRequest#STATISTICS_FACE_DETECT_MODE android.statistics.faceDetectMode}</li> |
| 1530 | * </ul> |
| 1531 | * <p>For high speed recording use case, the actual maximum supported frame rate may |
| 1532 | * be lower than what camera can output, depending on the destination Surfaces for |
| 1533 | * the image data. For example, if the destination surface is from video encoder, |
| 1534 | * the application need check if the video encoder is capable of supporting the |
| 1535 | * high frame rate for a given video size, or it will end up with lower recording |
| 1536 | * frame rate. If the destination surface is from preview window, the preview frame |
| 1537 | * rate will be bounded by the screen refresh rate.</p> |
| 1538 | * <p>The camera device will only support up to 2 output high speed streams |
| 1539 | * (processed non-stalling format defined in android.request.maxNumOutputStreams) |
| 1540 | * in this mode. This control will be effective only if all of below conditions are true:</p> |
| 1541 | * <ul> |
| 1542 | * <li>The application created no more than maxNumHighSpeedStreams processed non-stalling |
| 1543 | * format output streams, where maxNumHighSpeedStreams is calculated as |
| 1544 | * min(2, android.request.maxNumOutputStreams[Processed (but not-stalling)]).</li> |
| 1545 | * <li>The stream sizes are selected from the sizes reported by |
| 1546 | * android.control.availableHighSpeedVideoConfigurations.</li> |
| 1547 | * <li>No processed non-stalling or raw streams are configured.</li> |
| 1548 | * </ul> |
| 1549 | * <p>When above conditions are NOT satistied, the controls of this mode and |
| 1550 | * {@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange} will be ignored by the camera device, |
| 1551 | * the camera device will fall back to {@link CaptureRequest#CONTROL_MODE android.control.mode} <code>==</code> AUTO, |
| 1552 | * and the returned capture result metadata will give the fps range choosen |
| 1553 | * by the camera device.</p> |
| 1554 | * <p>Switching into or out of this mode may trigger some camera ISP/sensor |
| 1555 | * reconfigurations, which may introduce extra latency. It is recommended that |
| 1556 | * the application avoids unnecessary scene mode switch as much as possible.</p> |
| 1557 | * |
| 1558 | * @see CaptureRequest#CONTROL_AE_EXPOSURE_COMPENSATION |
| 1559 | * @see CaptureRequest#CONTROL_AE_LOCK |
| 1560 | * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER |
| 1561 | * @see CaptureRequest#CONTROL_AE_REGIONS |
| 1562 | * @see CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE |
| 1563 | * @see CaptureRequest#CONTROL_AF_REGIONS |
| 1564 | * @see CaptureRequest#CONTROL_AF_TRIGGER |
| 1565 | * @see CaptureRequest#CONTROL_AWB_LOCK |
| 1566 | * @see CaptureRequest#CONTROL_AWB_REGIONS |
| 1567 | * @see CaptureRequest#CONTROL_EFFECT_MODE |
| 1568 | * @see CaptureRequest#CONTROL_MODE |
| 1569 | * @see CaptureRequest#FLASH_MODE |
| 1570 | * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE |
| 1571 | * @see CaptureRequest#SCALER_CROP_REGION |
| 1572 | * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE |
| 1573 | * @see CaptureRequest#CONTROL_SCENE_MODE |
| 1574 | */ |
| 1575 | public static final int CONTROL_SCENE_MODE_HIGH_SPEED_VIDEO = 17; |
| 1576 | |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1577 | // |
Zhijun He | 4793af5 | 2014-05-05 10:39:12 -0700 | [diff] [blame] | 1578 | // Enumeration values for CaptureRequest#CONTROL_VIDEO_STABILIZATION_MODE |
| 1579 | // |
| 1580 | |
| 1581 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1582 | * <p>Video stabilization is disabled.</p> |
Zhijun He | 4793af5 | 2014-05-05 10:39:12 -0700 | [diff] [blame] | 1583 | * @see CaptureRequest#CONTROL_VIDEO_STABILIZATION_MODE |
| 1584 | */ |
| 1585 | public static final int CONTROL_VIDEO_STABILIZATION_MODE_OFF = 0; |
| 1586 | |
| 1587 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1588 | * <p>Video stabilization is enabled.</p> |
Zhijun He | 4793af5 | 2014-05-05 10:39:12 -0700 | [diff] [blame] | 1589 | * @see CaptureRequest#CONTROL_VIDEO_STABILIZATION_MODE |
| 1590 | */ |
| 1591 | public static final int CONTROL_VIDEO_STABILIZATION_MODE_ON = 1; |
| 1592 | |
| 1593 | // |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1594 | // Enumeration values for CaptureRequest#EDGE_MODE |
| 1595 | // |
| 1596 | |
| 1597 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1598 | * <p>No edge enhancement is applied.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1599 | * @see CaptureRequest#EDGE_MODE |
| 1600 | */ |
| 1601 | public static final int EDGE_MODE_OFF = 0; |
| 1602 | |
| 1603 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1604 | * <p>Apply edge enhancement at a quality level that does not slow down frame rate relative to sensor |
Zhijun He | 2807936 | 2013-12-17 10:35:40 -0800 | [diff] [blame] | 1605 | * output</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1606 | * @see CaptureRequest#EDGE_MODE |
| 1607 | */ |
| 1608 | public static final int EDGE_MODE_FAST = 1; |
| 1609 | |
| 1610 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1611 | * <p>Apply high-quality edge enhancement, at a cost of reducing output frame rate.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1612 | * @see CaptureRequest#EDGE_MODE |
| 1613 | */ |
| 1614 | public static final int EDGE_MODE_HIGH_QUALITY = 2; |
| 1615 | |
| 1616 | // |
| 1617 | // Enumeration values for CaptureRequest#FLASH_MODE |
| 1618 | // |
| 1619 | |
| 1620 | /** |
Zhijun He | 66d065a | 2014-01-16 18:18:50 -0800 | [diff] [blame] | 1621 | * <p>Do not fire the flash for this capture.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1622 | * @see CaptureRequest#FLASH_MODE |
| 1623 | */ |
| 1624 | public static final int FLASH_MODE_OFF = 0; |
| 1625 | |
| 1626 | /** |
Zhijun He | 66d065a | 2014-01-16 18:18:50 -0800 | [diff] [blame] | 1627 | * <p>If the flash is available and charged, fire flash |
Zhijun He | 8949225 | 2014-05-23 13:49:59 -0700 | [diff] [blame] | 1628 | * for this capture.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1629 | * @see CaptureRequest#FLASH_MODE |
| 1630 | */ |
| 1631 | public static final int FLASH_MODE_SINGLE = 1; |
| 1632 | |
| 1633 | /** |
Zhijun He | 66d065a | 2014-01-16 18:18:50 -0800 | [diff] [blame] | 1634 | * <p>Transition flash to continuously on.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1635 | * @see CaptureRequest#FLASH_MODE |
| 1636 | */ |
| 1637 | public static final int FLASH_MODE_TORCH = 2; |
| 1638 | |
| 1639 | // |
Ruben Brunk | eba1b3a | 2014-02-07 18:23:50 -0800 | [diff] [blame] | 1640 | // Enumeration values for CaptureRequest#HOT_PIXEL_MODE |
| 1641 | // |
| 1642 | |
| 1643 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1644 | * <p>No hot pixel correction is applied.</p> |
Ruben Brunk | eba1b3a | 2014-02-07 18:23:50 -0800 | [diff] [blame] | 1645 | * <p>The frame rate must not be reduced relative to sensor raw output |
| 1646 | * for this option.</p> |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1647 | * <p>The hotpixel map may be returned in {@link CaptureResult#STATISTICS_HOT_PIXEL_MAP android.statistics.hotPixelMap}.</p> |
Ruben Brunk | 9d454fd | 2014-03-04 14:11:52 -0800 | [diff] [blame] | 1648 | * |
| 1649 | * @see CaptureResult#STATISTICS_HOT_PIXEL_MAP |
Ruben Brunk | eba1b3a | 2014-02-07 18:23:50 -0800 | [diff] [blame] | 1650 | * @see CaptureRequest#HOT_PIXEL_MODE |
| 1651 | */ |
| 1652 | public static final int HOT_PIXEL_MODE_OFF = 0; |
| 1653 | |
| 1654 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1655 | * <p>Hot pixel correction is applied, without reducing frame |
| 1656 | * rate relative to sensor raw output.</p> |
| 1657 | * <p>The hotpixel map may be returned in {@link CaptureResult#STATISTICS_HOT_PIXEL_MAP android.statistics.hotPixelMap}.</p> |
Ruben Brunk | 9d454fd | 2014-03-04 14:11:52 -0800 | [diff] [blame] | 1658 | * |
| 1659 | * @see CaptureResult#STATISTICS_HOT_PIXEL_MAP |
Ruben Brunk | eba1b3a | 2014-02-07 18:23:50 -0800 | [diff] [blame] | 1660 | * @see CaptureRequest#HOT_PIXEL_MODE |
| 1661 | */ |
| 1662 | public static final int HOT_PIXEL_MODE_FAST = 1; |
| 1663 | |
| 1664 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1665 | * <p>High-quality hot pixel correction is applied, at a cost |
| 1666 | * of reducing frame rate relative to sensor raw output.</p> |
| 1667 | * <p>The hotpixel map may be returned in {@link CaptureResult#STATISTICS_HOT_PIXEL_MAP android.statistics.hotPixelMap}.</p> |
Ruben Brunk | 9d454fd | 2014-03-04 14:11:52 -0800 | [diff] [blame] | 1668 | * |
| 1669 | * @see CaptureResult#STATISTICS_HOT_PIXEL_MAP |
Ruben Brunk | eba1b3a | 2014-02-07 18:23:50 -0800 | [diff] [blame] | 1670 | * @see CaptureRequest#HOT_PIXEL_MODE |
| 1671 | */ |
| 1672 | public static final int HOT_PIXEL_MODE_HIGH_QUALITY = 2; |
| 1673 | |
| 1674 | // |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1675 | // Enumeration values for CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE |
| 1676 | // |
| 1677 | |
| 1678 | /** |
Ruben Brunk | 00849b3 | 2014-01-17 18:30:23 -0800 | [diff] [blame] | 1679 | * <p>Optical stabilization is unavailable.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1680 | * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE |
| 1681 | */ |
| 1682 | public static final int LENS_OPTICAL_STABILIZATION_MODE_OFF = 0; |
| 1683 | |
| 1684 | /** |
Ruben Brunk | 00849b3 | 2014-01-17 18:30:23 -0800 | [diff] [blame] | 1685 | * <p>Optical stabilization is enabled.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1686 | * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE |
| 1687 | */ |
| 1688 | public static final int LENS_OPTICAL_STABILIZATION_MODE_ON = 1; |
| 1689 | |
| 1690 | // |
| 1691 | // Enumeration values for CaptureRequest#NOISE_REDUCTION_MODE |
| 1692 | // |
| 1693 | |
| 1694 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1695 | * <p>No noise reduction is applied.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1696 | * @see CaptureRequest#NOISE_REDUCTION_MODE |
| 1697 | */ |
| 1698 | public static final int NOISE_REDUCTION_MODE_OFF = 0; |
| 1699 | |
| 1700 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1701 | * <p>Noise reduction is applied without reducing frame rate relative to sensor |
| 1702 | * output.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1703 | * @see CaptureRequest#NOISE_REDUCTION_MODE |
| 1704 | */ |
| 1705 | public static final int NOISE_REDUCTION_MODE_FAST = 1; |
| 1706 | |
| 1707 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1708 | * <p>High-quality noise reduction is applied, at the cost of reducing frame rate |
| 1709 | * relative to sensor output.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1710 | * @see CaptureRequest#NOISE_REDUCTION_MODE |
| 1711 | */ |
| 1712 | public static final int NOISE_REDUCTION_MODE_HIGH_QUALITY = 2; |
| 1713 | |
| 1714 | // |
Igor Murashkin | c127f05 | 2014-01-17 18:06:02 -0800 | [diff] [blame] | 1715 | // Enumeration values for CaptureRequest#SENSOR_TEST_PATTERN_MODE |
| 1716 | // |
| 1717 | |
| 1718 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1719 | * <p>No test pattern mode is used, and the camera |
Igor Murashkin | c127f05 | 2014-01-17 18:06:02 -0800 | [diff] [blame] | 1720 | * device returns captures from the image sensor.</p> |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1721 | * <p>This is the default if the key is not set.</p> |
Igor Murashkin | c127f05 | 2014-01-17 18:06:02 -0800 | [diff] [blame] | 1722 | * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE |
| 1723 | */ |
| 1724 | public static final int SENSOR_TEST_PATTERN_MODE_OFF = 0; |
| 1725 | |
| 1726 | /** |
| 1727 | * <p>Each pixel in <code>[R, G_even, G_odd, B]</code> is replaced by its |
| 1728 | * respective color channel provided in |
| 1729 | * {@link CaptureRequest#SENSOR_TEST_PATTERN_DATA android.sensor.testPatternData}.</p> |
| 1730 | * <p>For example:</p> |
| 1731 | * <pre><code>android.testPatternData = [0, 0xFFFFFFFF, 0xFFFFFFFF, 0] |
| 1732 | * </code></pre> |
| 1733 | * <p>All green pixels are 100% green. All red/blue pixels are black.</p> |
| 1734 | * <pre><code>android.testPatternData = [0xFFFFFFFF, 0, 0xFFFFFFFF, 0] |
| 1735 | * </code></pre> |
| 1736 | * <p>All red pixels are 100% red. Only the odd green pixels |
| 1737 | * are 100% green. All blue pixels are 100% black.</p> |
| 1738 | * |
| 1739 | * @see CaptureRequest#SENSOR_TEST_PATTERN_DATA |
| 1740 | * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE |
| 1741 | */ |
| 1742 | public static final int SENSOR_TEST_PATTERN_MODE_SOLID_COLOR = 1; |
| 1743 | |
| 1744 | /** |
| 1745 | * <p>All pixel data is replaced with an 8-bar color pattern.</p> |
| 1746 | * <p>The vertical bars (left-to-right) are as follows:</p> |
| 1747 | * <ul> |
| 1748 | * <li>100% white</li> |
| 1749 | * <li>yellow</li> |
| 1750 | * <li>cyan</li> |
| 1751 | * <li>green</li> |
| 1752 | * <li>magenta</li> |
| 1753 | * <li>red</li> |
| 1754 | * <li>blue</li> |
| 1755 | * <li>black</li> |
| 1756 | * </ul> |
| 1757 | * <p>In general the image would look like the following:</p> |
| 1758 | * <pre><code>W Y C G M R B K |
| 1759 | * W Y C G M R B K |
| 1760 | * W Y C G M R B K |
| 1761 | * W Y C G M R B K |
| 1762 | * W Y C G M R B K |
| 1763 | * . . . . . . . . |
| 1764 | * . . . . . . . . |
| 1765 | * . . . . . . . . |
| 1766 | * |
| 1767 | * (B = Blue, K = Black) |
| 1768 | * </code></pre> |
| 1769 | * <p>Each bar should take up 1/8 of the sensor pixel array width. |
| 1770 | * When this is not possible, the bar size should be rounded |
| 1771 | * down to the nearest integer and the pattern can repeat |
| 1772 | * on the right side.</p> |
| 1773 | * <p>Each bar's height must always take up the full sensor |
| 1774 | * pixel array height.</p> |
| 1775 | * <p>Each pixel in this test pattern must be set to either |
| 1776 | * 0% intensity or 100% intensity.</p> |
| 1777 | * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE |
| 1778 | */ |
| 1779 | public static final int SENSOR_TEST_PATTERN_MODE_COLOR_BARS = 2; |
| 1780 | |
| 1781 | /** |
| 1782 | * <p>The test pattern is similar to COLOR_BARS, except that |
| 1783 | * each bar should start at its specified color at the top, |
| 1784 | * and fade to gray at the bottom.</p> |
| 1785 | * <p>Furthermore each bar is further subdivided into a left and |
| 1786 | * right half. The left half should have a smooth gradient, |
| 1787 | * and the right half should have a quantized gradient.</p> |
| 1788 | * <p>In particular, the right half's should consist of blocks of the |
| 1789 | * same color for 1/16th active sensor pixel array width.</p> |
| 1790 | * <p>The least significant bits in the quantized gradient should |
| 1791 | * be copied from the most significant bits of the smooth gradient.</p> |
| 1792 | * <p>The height of each bar should always be a multiple of 128. |
| 1793 | * When this is not the case, the pattern should repeat at the bottom |
| 1794 | * of the image.</p> |
| 1795 | * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE |
| 1796 | */ |
| 1797 | public static final int SENSOR_TEST_PATTERN_MODE_COLOR_BARS_FADE_TO_GRAY = 3; |
| 1798 | |
| 1799 | /** |
| 1800 | * <p>All pixel data is replaced by a pseudo-random sequence |
| 1801 | * generated from a PN9 512-bit sequence (typically implemented |
| 1802 | * in hardware with a linear feedback shift register).</p> |
| 1803 | * <p>The generator should be reset at the beginning of each frame, |
| 1804 | * and thus each subsequent raw frame with this test pattern should |
| 1805 | * be exactly the same as the last.</p> |
| 1806 | * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE |
| 1807 | */ |
| 1808 | public static final int SENSOR_TEST_PATTERN_MODE_PN9 = 4; |
| 1809 | |
| 1810 | /** |
| 1811 | * <p>The first custom test pattern. All custom patterns that are |
| 1812 | * available only on this camera device are at least this numeric |
| 1813 | * value.</p> |
| 1814 | * <p>All of the custom test patterns will be static |
| 1815 | * (that is the raw image must not vary from frame to frame).</p> |
| 1816 | * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE |
| 1817 | */ |
| 1818 | public static final int SENSOR_TEST_PATTERN_MODE_CUSTOM1 = 256; |
| 1819 | |
| 1820 | // |
Zhijun He | ba93fe6 | 2014-01-17 16:43:05 -0800 | [diff] [blame] | 1821 | // Enumeration values for CaptureRequest#SHADING_MODE |
| 1822 | // |
| 1823 | |
| 1824 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1825 | * <p>No lens shading correction is applied.</p> |
Zhijun He | ba93fe6 | 2014-01-17 16:43:05 -0800 | [diff] [blame] | 1826 | * @see CaptureRequest#SHADING_MODE |
Zhijun He | ba93fe6 | 2014-01-17 16:43:05 -0800 | [diff] [blame] | 1827 | */ |
| 1828 | public static final int SHADING_MODE_OFF = 0; |
| 1829 | |
| 1830 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1831 | * <p>Apply lens shading corrections, without slowing |
| 1832 | * frame rate relative to sensor raw output</p> |
Zhijun He | ba93fe6 | 2014-01-17 16:43:05 -0800 | [diff] [blame] | 1833 | * @see CaptureRequest#SHADING_MODE |
Zhijun He | ba93fe6 | 2014-01-17 16:43:05 -0800 | [diff] [blame] | 1834 | */ |
| 1835 | public static final int SHADING_MODE_FAST = 1; |
| 1836 | |
| 1837 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1838 | * <p>Apply high-quality lens shading correction, at the |
| 1839 | * cost of reduced frame rate.</p> |
Zhijun He | ba93fe6 | 2014-01-17 16:43:05 -0800 | [diff] [blame] | 1840 | * @see CaptureRequest#SHADING_MODE |
Zhijun He | ba93fe6 | 2014-01-17 16:43:05 -0800 | [diff] [blame] | 1841 | */ |
| 1842 | public static final int SHADING_MODE_HIGH_QUALITY = 2; |
| 1843 | |
| 1844 | // |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1845 | // Enumeration values for CaptureRequest#STATISTICS_FACE_DETECT_MODE |
| 1846 | // |
| 1847 | |
| 1848 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1849 | * <p>Do not include face detection statistics in capture |
| 1850 | * results.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1851 | * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE |
| 1852 | */ |
| 1853 | public static final int STATISTICS_FACE_DETECT_MODE_OFF = 0; |
| 1854 | |
| 1855 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1856 | * <p>Return face rectangle and confidence values only.</p> |
| 1857 | * <p>In this mode, only android.statistics.faceRectangles and |
| 1858 | * android.statistics.faceScores outputs are valid.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1859 | * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE |
| 1860 | */ |
| 1861 | public static final int STATISTICS_FACE_DETECT_MODE_SIMPLE = 1; |
| 1862 | |
| 1863 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1864 | * <p>Return all face |
| 1865 | * metadata.</p> |
| 1866 | * <p>In this mode, |
| 1867 | * android.statistics.faceRectangles, |
| 1868 | * android.statistics.faceScores, |
| 1869 | * android.statistics.faceIds, and |
| 1870 | * android.statistics.faceLandmarks outputs are valid.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1871 | * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE |
| 1872 | */ |
| 1873 | public static final int STATISTICS_FACE_DETECT_MODE_FULL = 2; |
| 1874 | |
| 1875 | // |
Eino-Ville Talvala | d96748b | 2013-09-12 11:11:27 -0700 | [diff] [blame] | 1876 | // Enumeration values for CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE |
| 1877 | // |
| 1878 | |
| 1879 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1880 | * <p>Do not include a lens shading map in the capture result.</p> |
Eino-Ville Talvala | d96748b | 2013-09-12 11:11:27 -0700 | [diff] [blame] | 1881 | * @see CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE |
| 1882 | */ |
| 1883 | public static final int STATISTICS_LENS_SHADING_MAP_MODE_OFF = 0; |
| 1884 | |
| 1885 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1886 | * <p>Include a lens shading map in the capture result.</p> |
Eino-Ville Talvala | d96748b | 2013-09-12 11:11:27 -0700 | [diff] [blame] | 1887 | * @see CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE |
| 1888 | */ |
| 1889 | public static final int STATISTICS_LENS_SHADING_MAP_MODE_ON = 1; |
| 1890 | |
| 1891 | // |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1892 | // Enumeration values for CaptureRequest#TONEMAP_MODE |
| 1893 | // |
| 1894 | |
| 1895 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 1896 | * <p>Use the tone mapping curve specified in |
Yin-Chia Yeh | 8490ace | 2014-05-27 10:04:54 -0700 | [diff] [blame] | 1897 | * the {@link CaptureRequest#TONEMAP_CURVE android.tonemap.curve}* entries.</p> |
Igor Murashkin | e006093 | 2014-01-17 17:24:11 -0800 | [diff] [blame] | 1898 | * <p>All color enhancement and tonemapping must be disabled, except |
| 1899 | * for applying the tonemapping curve specified by |
Yin-Chia Yeh | 8490ace | 2014-05-27 10:04:54 -0700 | [diff] [blame] | 1900 | * {@link CaptureRequest#TONEMAP_CURVE android.tonemap.curve}.</p> |
Igor Murashkin | e006093 | 2014-01-17 17:24:11 -0800 | [diff] [blame] | 1901 | * <p>Must not slow down frame rate relative to raw |
| 1902 | * sensor output.</p> |
| 1903 | * |
Yin-Chia Yeh | 8490ace | 2014-05-27 10:04:54 -0700 | [diff] [blame] | 1904 | * @see CaptureRequest#TONEMAP_CURVE |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1905 | * @see CaptureRequest#TONEMAP_MODE |
| 1906 | */ |
| 1907 | public static final int TONEMAP_MODE_CONTRAST_CURVE = 0; |
| 1908 | |
| 1909 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1910 | * <p>Advanced gamma mapping and color enhancement may be applied, without |
| 1911 | * reducing frame rate compared to raw sensor output.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1912 | * @see CaptureRequest#TONEMAP_MODE |
| 1913 | */ |
| 1914 | public static final int TONEMAP_MODE_FAST = 1; |
| 1915 | |
| 1916 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1917 | * <p>High-quality gamma mapping and color enhancement will be applied, at |
| 1918 | * the cost of reduced frame rate compared to raw sensor output.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1919 | * @see CaptureRequest#TONEMAP_MODE |
| 1920 | */ |
| 1921 | public static final int TONEMAP_MODE_HIGH_QUALITY = 2; |
| 1922 | |
| 1923 | // |
| 1924 | // Enumeration values for CaptureResult#CONTROL_AE_STATE |
| 1925 | // |
| 1926 | |
| 1927 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1928 | * <p>AE is off or recently reset.</p> |
| 1929 | * <p>When a camera device is opened, it starts in |
Zhijun He | 60b19dc | 2014-02-24 10:19:20 -0800 | [diff] [blame] | 1930 | * this state. This is a transient state, the camera device may skip reporting |
| 1931 | * this state in capture result.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1932 | * @see CaptureResult#CONTROL_AE_STATE |
| 1933 | */ |
| 1934 | public static final int CONTROL_AE_STATE_INACTIVE = 0; |
| 1935 | |
| 1936 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 1937 | * <p>AE doesn't yet have a good set of control values |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1938 | * for the current scene.</p> |
| 1939 | * <p>This is a transient state, the camera device may skip |
Zhijun He | 60b19dc | 2014-02-24 10:19:20 -0800 | [diff] [blame] | 1940 | * reporting this state in capture result.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1941 | * @see CaptureResult#CONTROL_AE_STATE |
| 1942 | */ |
| 1943 | public static final int CONTROL_AE_STATE_SEARCHING = 1; |
| 1944 | |
| 1945 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 1946 | * <p>AE has a good set of control values for the |
Zhijun He | 228f4f9 | 2014-01-16 17:22:05 -0800 | [diff] [blame] | 1947 | * current scene.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1948 | * @see CaptureResult#CONTROL_AE_STATE |
| 1949 | */ |
| 1950 | public static final int CONTROL_AE_STATE_CONVERGED = 2; |
| 1951 | |
| 1952 | /** |
Zhijun He | 228f4f9 | 2014-01-16 17:22:05 -0800 | [diff] [blame] | 1953 | * <p>AE has been locked.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1954 | * @see CaptureResult#CONTROL_AE_STATE |
| 1955 | */ |
| 1956 | public static final int CONTROL_AE_STATE_LOCKED = 3; |
| 1957 | |
| 1958 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 1959 | * <p>AE has a good set of control values, but flash |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1960 | * needs to be fired for good quality still |
Zhijun He | 228f4f9 | 2014-01-16 17:22:05 -0800 | [diff] [blame] | 1961 | * capture.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1962 | * @see CaptureResult#CONTROL_AE_STATE |
| 1963 | */ |
| 1964 | public static final int CONTROL_AE_STATE_FLASH_REQUIRED = 4; |
| 1965 | |
| 1966 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 1967 | * <p>AE has been asked to do a precapture sequence |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1968 | * and is currently executing it.</p> |
| 1969 | * <p>Precapture can be triggered through setting |
| 1970 | * {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger} to START.</p> |
| 1971 | * <p>Once PRECAPTURE completes, AE will transition to CONVERGED |
| 1972 | * or FLASH_REQUIRED as appropriate. This is a transient |
| 1973 | * state, the camera device may skip reporting this state in |
| 1974 | * capture result.</p> |
Zhijun He | 228f4f9 | 2014-01-16 17:22:05 -0800 | [diff] [blame] | 1975 | * |
| 1976 | * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1977 | * @see CaptureResult#CONTROL_AE_STATE |
| 1978 | */ |
| 1979 | public static final int CONTROL_AE_STATE_PRECAPTURE = 5; |
| 1980 | |
| 1981 | // |
| 1982 | // Enumeration values for CaptureResult#CONTROL_AF_STATE |
| 1983 | // |
| 1984 | |
| 1985 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1986 | * <p>AF is off or has not yet tried to scan/been asked |
| 1987 | * to scan.</p> |
| 1988 | * <p>When a camera device is opened, it starts in this |
| 1989 | * state. This is a transient state, the camera device may |
| 1990 | * skip reporting this state in capture |
| 1991 | * result.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 1992 | * @see CaptureResult#CONTROL_AF_STATE |
| 1993 | */ |
| 1994 | public static final int CONTROL_AF_STATE_INACTIVE = 0; |
| 1995 | |
| 1996 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 1997 | * <p>AF is currently performing an AF scan initiated the |
| 1998 | * camera device in a continuous autofocus mode.</p> |
| 1999 | * <p>Only used by CONTINUOUS_* AF modes. This is a transient |
| 2000 | * state, the camera device may skip reporting this state in |
| 2001 | * capture result.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2002 | * @see CaptureResult#CONTROL_AF_STATE |
| 2003 | */ |
| 2004 | public static final int CONTROL_AF_STATE_PASSIVE_SCAN = 1; |
| 2005 | |
| 2006 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2007 | * <p>AF currently believes it is in focus, but may |
| 2008 | * restart scanning at any time.</p> |
| 2009 | * <p>Only used by CONTINUOUS_* AF modes. This is a transient |
| 2010 | * state, the camera device may skip reporting this state in |
| 2011 | * capture result.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2012 | * @see CaptureResult#CONTROL_AF_STATE |
| 2013 | */ |
| 2014 | public static final int CONTROL_AF_STATE_PASSIVE_FOCUSED = 2; |
| 2015 | |
| 2016 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2017 | * <p>AF is performing an AF scan because it was |
| 2018 | * triggered by AF trigger.</p> |
| 2019 | * <p>Only used by AUTO or MACRO AF modes. This is a transient |
| 2020 | * state, the camera device may skip reporting this state in |
| 2021 | * capture result.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2022 | * @see CaptureResult#CONTROL_AF_STATE |
| 2023 | */ |
| 2024 | public static final int CONTROL_AF_STATE_ACTIVE_SCAN = 3; |
| 2025 | |
| 2026 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2027 | * <p>AF believes it is focused correctly and has locked |
| 2028 | * focus.</p> |
| 2029 | * <p>This state is reached only after an explicit START AF trigger has been |
| 2030 | * sent ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}), when good focus has been obtained.</p> |
| 2031 | * <p>The lens will remain stationary until the AF mode ({@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}) is changed or |
| 2032 | * a new AF trigger is sent to the camera device ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}).</p> |
| 2033 | * |
| 2034 | * @see CaptureRequest#CONTROL_AF_MODE |
| 2035 | * @see CaptureRequest#CONTROL_AF_TRIGGER |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2036 | * @see CaptureResult#CONTROL_AF_STATE |
| 2037 | */ |
| 2038 | public static final int CONTROL_AF_STATE_FOCUSED_LOCKED = 4; |
| 2039 | |
| 2040 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2041 | * <p>AF has failed to focus successfully and has locked |
| 2042 | * focus.</p> |
| 2043 | * <p>This state is reached only after an explicit START AF trigger has been |
| 2044 | * sent ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}), when good focus cannot be obtained.</p> |
| 2045 | * <p>The lens will remain stationary until the AF mode ({@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}) is changed or |
| 2046 | * a new AF trigger is sent to the camera device ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}).</p> |
| 2047 | * |
| 2048 | * @see CaptureRequest#CONTROL_AF_MODE |
| 2049 | * @see CaptureRequest#CONTROL_AF_TRIGGER |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2050 | * @see CaptureResult#CONTROL_AF_STATE |
| 2051 | */ |
| 2052 | public static final int CONTROL_AF_STATE_NOT_FOCUSED_LOCKED = 5; |
| 2053 | |
Eino-Ville Talvala | 9f880f7 | 2013-09-20 17:50:41 -0700 | [diff] [blame] | 2054 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2055 | * <p>AF finished a passive scan without finding focus, |
| 2056 | * and may restart scanning at any time.</p> |
| 2057 | * <p>Only used by CONTINUOUS_* AF modes. This is a transient state, the camera |
Zhijun He | 60b19dc | 2014-02-24 10:19:20 -0800 | [diff] [blame] | 2058 | * device may skip reporting this state in capture result.</p> |
Eino-Ville Talvala | 9f880f7 | 2013-09-20 17:50:41 -0700 | [diff] [blame] | 2059 | * @see CaptureResult#CONTROL_AF_STATE |
| 2060 | */ |
| 2061 | public static final int CONTROL_AF_STATE_PASSIVE_UNFOCUSED = 6; |
| 2062 | |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2063 | // |
| 2064 | // Enumeration values for CaptureResult#CONTROL_AWB_STATE |
| 2065 | // |
| 2066 | |
| 2067 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2068 | * <p>AWB is not in auto mode, or has not yet started metering.</p> |
| 2069 | * <p>When a camera device is opened, it starts in this |
| 2070 | * state. This is a transient state, the camera device may |
| 2071 | * skip reporting this state in capture |
| 2072 | * result.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2073 | * @see CaptureResult#CONTROL_AWB_STATE |
| 2074 | */ |
| 2075 | public static final int CONTROL_AWB_STATE_INACTIVE = 0; |
| 2076 | |
| 2077 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 2078 | * <p>AWB doesn't yet have a good set of control |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2079 | * values for the current scene.</p> |
| 2080 | * <p>This is a transient state, the camera device |
Zhijun He | 60b19dc | 2014-02-24 10:19:20 -0800 | [diff] [blame] | 2081 | * may skip reporting this state in capture result.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2082 | * @see CaptureResult#CONTROL_AWB_STATE |
| 2083 | */ |
| 2084 | public static final int CONTROL_AWB_STATE_SEARCHING = 1; |
| 2085 | |
| 2086 | /** |
Igor Murashkin | ace5bf0 | 2013-12-10 17:36:40 -0800 | [diff] [blame] | 2087 | * <p>AWB has a good set of control values for the |
Zhijun He | 228f4f9 | 2014-01-16 17:22:05 -0800 | [diff] [blame] | 2088 | * current scene.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2089 | * @see CaptureResult#CONTROL_AWB_STATE |
| 2090 | */ |
| 2091 | public static final int CONTROL_AWB_STATE_CONVERGED = 2; |
| 2092 | |
| 2093 | /** |
Zhijun He | 228f4f9 | 2014-01-16 17:22:05 -0800 | [diff] [blame] | 2094 | * <p>AWB has been locked.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2095 | * @see CaptureResult#CONTROL_AWB_STATE |
| 2096 | */ |
| 2097 | public static final int CONTROL_AWB_STATE_LOCKED = 3; |
| 2098 | |
| 2099 | // |
| 2100 | // Enumeration values for CaptureResult#FLASH_STATE |
| 2101 | // |
| 2102 | |
| 2103 | /** |
Zhijun He | 8dda727 | 2014-03-25 13:49:30 -0700 | [diff] [blame] | 2104 | * <p>No flash on camera.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2105 | * @see CaptureResult#FLASH_STATE |
| 2106 | */ |
| 2107 | public static final int FLASH_STATE_UNAVAILABLE = 0; |
| 2108 | |
| 2109 | /** |
Zhijun He | 8dda727 | 2014-03-25 13:49:30 -0700 | [diff] [blame] | 2110 | * <p>Flash is charging and cannot be fired.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2111 | * @see CaptureResult#FLASH_STATE |
| 2112 | */ |
| 2113 | public static final int FLASH_STATE_CHARGING = 1; |
| 2114 | |
| 2115 | /** |
Zhijun He | 8dda727 | 2014-03-25 13:49:30 -0700 | [diff] [blame] | 2116 | * <p>Flash is ready to fire.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2117 | * @see CaptureResult#FLASH_STATE |
| 2118 | */ |
| 2119 | public static final int FLASH_STATE_READY = 2; |
| 2120 | |
| 2121 | /** |
Zhijun He | 8dda727 | 2014-03-25 13:49:30 -0700 | [diff] [blame] | 2122 | * <p>Flash fired for this capture.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2123 | * @see CaptureResult#FLASH_STATE |
| 2124 | */ |
| 2125 | public static final int FLASH_STATE_FIRED = 3; |
| 2126 | |
Zhijun He | 8dda727 | 2014-03-25 13:49:30 -0700 | [diff] [blame] | 2127 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2128 | * <p>Flash partially illuminated this frame.</p> |
| 2129 | * <p>This is usually due to the next or previous frame having |
| 2130 | * the flash fire, and the flash spilling into this capture |
Zhijun He | 8dda727 | 2014-03-25 13:49:30 -0700 | [diff] [blame] | 2131 | * due to hardware limitations.</p> |
| 2132 | * @see CaptureResult#FLASH_STATE |
| 2133 | */ |
| 2134 | public static final int FLASH_STATE_PARTIAL = 4; |
| 2135 | |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2136 | // |
| 2137 | // Enumeration values for CaptureResult#LENS_STATE |
| 2138 | // |
| 2139 | |
| 2140 | /** |
Eino-Ville Talvala | d8fd679 | 2014-02-10 12:41:04 -0800 | [diff] [blame] | 2141 | * <p>The lens parameters ({@link CaptureRequest#LENS_FOCAL_LENGTH android.lens.focalLength}, {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance}, |
| 2142 | * {@link CaptureRequest#LENS_FILTER_DENSITY android.lens.filterDensity} and {@link CaptureRequest#LENS_APERTURE android.lens.aperture}) are not changing.</p> |
Zhijun He | ca1b73a | 2014-02-03 12:39:53 -0800 | [diff] [blame] | 2143 | * |
| 2144 | * @see CaptureRequest#LENS_APERTURE |
Eino-Ville Talvala | d8fd679 | 2014-02-10 12:41:04 -0800 | [diff] [blame] | 2145 | * @see CaptureRequest#LENS_FILTER_DENSITY |
Zhijun He | ca1b73a | 2014-02-03 12:39:53 -0800 | [diff] [blame] | 2146 | * @see CaptureRequest#LENS_FOCAL_LENGTH |
Eino-Ville Talvala | d8fd679 | 2014-02-10 12:41:04 -0800 | [diff] [blame] | 2147 | * @see CaptureRequest#LENS_FOCUS_DISTANCE |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2148 | * @see CaptureResult#LENS_STATE |
| 2149 | */ |
| 2150 | public static final int LENS_STATE_STATIONARY = 0; |
| 2151 | |
Igor Murashkin | 9ea4ae6 | 2013-09-11 21:40:11 -0700 | [diff] [blame] | 2152 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2153 | * <p>One or several of the lens parameters |
| 2154 | * ({@link CaptureRequest#LENS_FOCAL_LENGTH android.lens.focalLength}, {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance}, |
| 2155 | * {@link CaptureRequest#LENS_FILTER_DENSITY android.lens.filterDensity} or {@link CaptureRequest#LENS_APERTURE android.lens.aperture}) is |
| 2156 | * currently changing.</p> |
Zhijun He | ca1b73a | 2014-02-03 12:39:53 -0800 | [diff] [blame] | 2157 | * |
| 2158 | * @see CaptureRequest#LENS_APERTURE |
Eino-Ville Talvala | d8fd679 | 2014-02-10 12:41:04 -0800 | [diff] [blame] | 2159 | * @see CaptureRequest#LENS_FILTER_DENSITY |
Zhijun He | ca1b73a | 2014-02-03 12:39:53 -0800 | [diff] [blame] | 2160 | * @see CaptureRequest#LENS_FOCAL_LENGTH |
Eino-Ville Talvala | d8fd679 | 2014-02-10 12:41:04 -0800 | [diff] [blame] | 2161 | * @see CaptureRequest#LENS_FOCUS_DISTANCE |
Igor Murashkin | 9ea4ae6 | 2013-09-11 21:40:11 -0700 | [diff] [blame] | 2162 | * @see CaptureResult#LENS_STATE |
| 2163 | */ |
| 2164 | public static final int LENS_STATE_MOVING = 1; |
| 2165 | |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2166 | // |
| 2167 | // Enumeration values for CaptureResult#STATISTICS_SCENE_FLICKER |
| 2168 | // |
| 2169 | |
| 2170 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2171 | * <p>The camera device does not detect any flickering illumination |
| 2172 | * in the current scene.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2173 | * @see CaptureResult#STATISTICS_SCENE_FLICKER |
| 2174 | */ |
| 2175 | public static final int STATISTICS_SCENE_FLICKER_NONE = 0; |
| 2176 | |
| 2177 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2178 | * <p>The camera device detects illumination flickering at 50Hz |
| 2179 | * in the current scene.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2180 | * @see CaptureResult#STATISTICS_SCENE_FLICKER |
| 2181 | */ |
| 2182 | public static final int STATISTICS_SCENE_FLICKER_50HZ = 1; |
| 2183 | |
| 2184 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2185 | * <p>The camera device detects illumination flickering at 60Hz |
| 2186 | * in the current scene.</p> |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2187 | * @see CaptureResult#STATISTICS_SCENE_FLICKER |
| 2188 | */ |
| 2189 | public static final int STATISTICS_SCENE_FLICKER_60HZ = 2; |
| 2190 | |
Igor Murashkin | 3865a84 | 2014-01-17 18:18:39 -0800 | [diff] [blame] | 2191 | // |
| 2192 | // Enumeration values for CaptureResult#SYNC_FRAME_NUMBER |
| 2193 | // |
| 2194 | |
| 2195 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2196 | * <p>The current result is not yet fully synchronized to any request.</p> |
| 2197 | * <p>Synchronization is in progress, and reading metadata from this |
Igor Murashkin | 3865a84 | 2014-01-17 18:18:39 -0800 | [diff] [blame] | 2198 | * result may include a mix of data that have taken effect since the |
| 2199 | * last synchronization time.</p> |
| 2200 | * <p>In some future result, within {@link CameraCharacteristics#SYNC_MAX_LATENCY android.sync.maxLatency} frames, |
| 2201 | * this value will update to the actual frame number frame number |
| 2202 | * the result is guaranteed to be synchronized to (as long as the |
| 2203 | * request settings remain constant).</p> |
| 2204 | * |
| 2205 | * @see CameraCharacteristics#SYNC_MAX_LATENCY |
| 2206 | * @see CaptureResult#SYNC_FRAME_NUMBER |
| 2207 | * @hide |
| 2208 | */ |
| 2209 | public static final int SYNC_FRAME_NUMBER_CONVERGING = -1; |
| 2210 | |
| 2211 | /** |
Eino-Ville Talvala | e600d6a | 2014-06-09 14:25:50 -0700 | [diff] [blame] | 2212 | * <p>The current result's synchronization status is unknown.</p> |
| 2213 | * <p>The result may have already converged, or it may be in |
| 2214 | * progress. Reading from this result may include some mix |
| 2215 | * of settings from past requests.</p> |
Igor Murashkin | 3865a84 | 2014-01-17 18:18:39 -0800 | [diff] [blame] | 2216 | * <p>After a settings change, the new settings will eventually all |
| 2217 | * take effect for the output buffers and results. However, this |
| 2218 | * value will not change when that happens. Altering settings |
| 2219 | * rapidly may provide outcomes using mixes of settings from recent |
| 2220 | * requests.</p> |
| 2221 | * <p>This value is intended primarily for backwards compatibility with |
| 2222 | * the older camera implementations (for android.hardware.Camera).</p> |
| 2223 | * @see CaptureResult#SYNC_FRAME_NUMBER |
| 2224 | * @hide |
| 2225 | */ |
| 2226 | public static final int SYNC_FRAME_NUMBER_UNKNOWN = -2; |
| 2227 | |
Eino-Ville Talvala | 5a32b20c | 2013-08-08 12:38:36 -0700 | [diff] [blame] | 2228 | /*~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~ |
| 2229 | * End generated code |
| 2230 | *~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~O@*/ |
| 2231 | |
Igor Murashkin | b519cc5 | 2013-07-02 11:23:44 -0700 | [diff] [blame] | 2232 | } |