blob: 486b054e1c0041af3c354ac6543f424f376071b5 [file] [log] [blame]
Eino-Ville Talvalab2675542012-12-12 13:29:45 -08001/*
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 Talvala2f1a2e42013-07-25 17:12:05 -070017package android.hardware.camera2;
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080018
Eino-Ville Talvala8b905572015-05-14 15:43:01 -070019import android.annotation.NonNull;
Igor Murashkincc542a42014-06-25 11:52:23 -070020import android.hardware.camera2.impl.CameraMetadataNative;
Igor Murashkin6c76f582014-07-15 17:19:49 -070021import android.hardware.camera2.impl.PublicKey;
22import android.hardware.camera2.impl.SyntheticKey;
Igor Murashkind6d65152014-05-19 16:31:02 -070023import android.util.Log;
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080024
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070025import java.lang.reflect.Field;
Igor Murashkin03fdb142013-09-30 12:14:58 -070026import java.lang.reflect.Modifier;
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070027import java.util.ArrayList;
Igor Murashkincc542a42014-06-25 11:52:23 -070028import java.util.Arrays;
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070029import java.util.Collections;
30import java.util.List;
31
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080032/**
33 * The base class for camera controls and information.
34 *
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070035 * <p>
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080036 * This class defines the basic key/value map used for querying for camera
37 * characteristics or capture results, and for setting camera request
38 * parameters.
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070039 * </p>
40 *
41 * <p>
42 * All instances of CameraMetadata are immutable. The list of keys with {@link #getKeys()}
Igor Murashkind6d65152014-05-19 16:31:02 -070043 * never changes, nor do the values returned by any key with {@code #get} throughout
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070044 * the lifetime of the object.
45 * </p>
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080046 *
47 * @see CameraDevice
48 * @see CameraManager
Igor Murashkin68f40062013-09-10 12:15:54 -070049 * @see CameraCharacteristics
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080050 **/
Igor Murashkind6d65152014-05-19 16:31:02 -070051public abstract class CameraMetadata<TKey> {
52
53 private static final String TAG = "CameraMetadataAb";
Eino-Ville Talvalaa78791f2015-06-01 12:39:54 -070054 private static final boolean DEBUG = false;
Emilian Peevde62d842017-03-23 19:20:40 +000055 private CameraMetadataNative mNativeInstance = null;
Igor Murashkin70725502013-06-25 20:27:06 +000056
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080057 /**
Igor Murashkin68f40062013-09-10 12:15:54 -070058 * Set a camera metadata field to a value. The field definitions can be
59 * found in {@link CameraCharacteristics}, {@link CaptureResult}, and
60 * {@link CaptureRequest}.
61 *
62 * @param key The metadata field to write.
63 * @param value The value to set the field to, which must be of a matching
64 * type to the key.
65 *
Eino-Ville Talvala70c22072013-08-27 12:09:04 -070066 * @hide
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080067 */
Eino-Ville Talvala70c22072013-08-27 12:09:04 -070068 protected CameraMetadata() {
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080069 }
70
71 /**
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070072 * Get a camera metadata field value.
73 *
74 * <p>The field definitions can be
Igor Murashkin68f40062013-09-10 12:15:54 -070075 * found in {@link CameraCharacteristics}, {@link CaptureResult}, and
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070076 * {@link CaptureRequest}.</p>
77 *
78 * <p>Querying the value for the same key more than once will return a value
79 * which is equal to the previous queried value.</p>
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080080 *
Igor Murashkinb519cc52013-07-02 11:23:44 -070081 * @throws IllegalArgumentException if the key was not valid
82 *
Benjamin Hendricks24eb8a32013-08-15 12:46:22 -070083 * @param key The metadata field to read.
84 * @return The value of that key, or {@code null} if the field is not set.
Igor Murashkind6d65152014-05-19 16:31:02 -070085 *
86 * @hide
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080087 */
Igor Murashkind6d65152014-05-19 16:31:02 -070088 protected abstract <T> T getProtected(TKey key);
89
90 /**
91 * @hide
92 */
Emilian Peevde62d842017-03-23 19:20:40 +000093 protected void setNativeInstance(CameraMetadataNative nativeInstance) {
94 mNativeInstance = nativeInstance;
95 }
96
97 /**
98 * @hide
99 */
Igor Murashkind6d65152014-05-19 16:31:02 -0700100 protected abstract Class<TKey> getKeyClass();
Eino-Ville Talvalab2675542012-12-12 13:29:45 -0800101
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700102 /**
103 * Returns a list of the keys contained in this map.
104 *
105 * <p>The list returned is not modifiable, so any attempts to modify it will throw
106 * a {@code UnsupportedOperationException}.</p>
107 *
Igor Murashkind6d65152014-05-19 16:31:02 -0700108 * <p>All values retrieved by a key from this list with {@code #get} are guaranteed to be
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700109 * non-{@code null}. Each key is only listed once in the list. The order of the keys
110 * is undefined.</p>
111 *
112 * @return List of the keys contained in this map.
113 */
Igor Murashkind6d65152014-05-19 16:31:02 -0700114 @SuppressWarnings("unchecked")
Eino-Ville Talvala8b905572015-05-14 15:43:01 -0700115 @NonNull
Igor Murashkind6d65152014-05-19 16:31:02 -0700116 public List<TKey> getKeys() {
117 Class<CameraMetadata<TKey>> thisClass = (Class<CameraMetadata<TKey>>) getClass();
Igor Murashkincc542a42014-06-25 11:52:23 -0700118 return Collections.unmodifiableList(
Emilian Peeva7fea4c2018-09-03 16:37:06 +0100119 getKeys(thisClass, getKeyClass(), this, /*filterTags*/null,
120 /*includeSynthetic*/ true));
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700121 }
122
123 /**
124 * Return a list of all the Key<?> that are declared as a field inside of the class
125 * {@code type}.
126 *
127 * <p>
128 * Optionally, if {@code instance} is not null, then filter out any keys with null values.
129 * </p>
Igor Murashkincc542a42014-06-25 11:52:23 -0700130 *
131 * <p>
132 * Optionally, if {@code filterTags} is not {@code null}, then filter out any keys
133 * whose native {@code tag} is not in {@code filterTags}. The {@code filterTags} array will be
134 * sorted as a side effect.
Emilian Peeva7fea4c2018-09-03 16:37:06 +0100135 * {@code includeSynthetic} Includes public syntenthic fields by default.
Igor Murashkincc542a42014-06-25 11:52:23 -0700136 * </p>
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700137 */
Igor Murashkind6d65152014-05-19 16:31:02 -0700138 /*package*/ @SuppressWarnings("unchecked")
Emilian Peevde62d842017-03-23 19:20:40 +0000139 <TKey> ArrayList<TKey> getKeys(
Igor Murashkind6d65152014-05-19 16:31:02 -0700140 Class<?> type, Class<TKey> keyClass,
Igor Murashkincc542a42014-06-25 11:52:23 -0700141 CameraMetadata<TKey> instance,
Emilian Peeva7fea4c2018-09-03 16:37:06 +0100142 int[] filterTags, boolean includeSynthetic) {
Igor Murashkind6d65152014-05-19 16:31:02 -0700143
Eino-Ville Talvalaa78791f2015-06-01 12:39:54 -0700144 if (DEBUG) Log.v(TAG, "getKeysStatic for " + type);
Igor Murashkind6d65152014-05-19 16:31:02 -0700145
Igor Murashkin696bbee2014-08-07 18:02:51 -0700146 // TotalCaptureResult does not have any of the keys on it, use CaptureResult instead
147 if (type.equals(TotalCaptureResult.class)) {
148 type = CaptureResult.class;
149 }
150
Igor Murashkincc542a42014-06-25 11:52:23 -0700151 if (filterTags != null) {
152 Arrays.sort(filterTags);
153 }
154
Igor Murashkind6d65152014-05-19 16:31:02 -0700155 ArrayList<TKey> keyList = new ArrayList<TKey>();
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700156
157 Field[] fields = type.getDeclaredFields();
158 for (Field field : fields) {
Igor Murashkin03fdb142013-09-30 12:14:58 -0700159 // Filter for Keys that are public
Igor Murashkind6d65152014-05-19 16:31:02 -0700160 if (field.getType().isAssignableFrom(keyClass) &&
Igor Murashkin03fdb142013-09-30 12:14:58 -0700161 (field.getModifiers() & Modifier.PUBLIC) != 0) {
Igor Murashkind6d65152014-05-19 16:31:02 -0700162
163 TKey key;
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700164 try {
Igor Murashkind6d65152014-05-19 16:31:02 -0700165 key = (TKey) field.get(instance);
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700166 } catch (IllegalAccessException e) {
167 throw new AssertionError("Can't get IllegalAccessException", e);
168 } catch (IllegalArgumentException e) {
169 throw new AssertionError("Can't get IllegalArgumentException", e);
170 }
Igor Murashkind6d65152014-05-19 16:31:02 -0700171
172 if (instance == null || instance.getProtected(key) != null) {
Emilian Peeva7fea4c2018-09-03 16:37:06 +0100173 if (shouldKeyBeAdded(key, field, filterTags, includeSynthetic)) {
Igor Murashkincc542a42014-06-25 11:52:23 -0700174 keyList.add(key);
175
Eino-Ville Talvalaa78791f2015-06-01 12:39:54 -0700176 if (DEBUG) {
Igor Murashkincc542a42014-06-25 11:52:23 -0700177 Log.v(TAG, "getKeysStatic - key was added - " + key);
178 }
Eino-Ville Talvalaa78791f2015-06-01 12:39:54 -0700179 } else if (DEBUG) {
Igor Murashkincc542a42014-06-25 11:52:23 -0700180 Log.v(TAG, "getKeysStatic - key was filtered - " + key);
181 }
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700182 }
183 }
184 }
185
Emilian Peevde62d842017-03-23 19:20:40 +0000186 if (null == mNativeInstance) {
187 return keyList;
188 }
189
190 ArrayList<TKey> vendorKeys = mNativeInstance.getAllVendorKeys(keyClass);
Ruben Brunkc620eb72015-07-29 18:19:11 -0700191
192 if (vendorKeys != null) {
193 for (TKey k : vendorKeys) {
194 String keyName;
Emilian Peevde62d842017-03-23 19:20:40 +0000195 long vendorId;
Ruben Brunkc620eb72015-07-29 18:19:11 -0700196 if (k instanceof CaptureRequest.Key<?>) {
197 keyName = ((CaptureRequest.Key<?>) k).getName();
Emilian Peevde62d842017-03-23 19:20:40 +0000198 vendorId = ((CaptureRequest.Key<?>) k).getVendorId();
Ruben Brunkc620eb72015-07-29 18:19:11 -0700199 } else if (k instanceof CaptureResult.Key<?>) {
200 keyName = ((CaptureResult.Key<?>) k).getName();
Emilian Peevde62d842017-03-23 19:20:40 +0000201 vendorId = ((CaptureResult.Key<?>) k).getVendorId();
Ruben Brunkc620eb72015-07-29 18:19:11 -0700202 } else if (k instanceof CameraCharacteristics.Key<?>) {
203 keyName = ((CameraCharacteristics.Key<?>) k).getName();
Emilian Peevde62d842017-03-23 19:20:40 +0000204 vendorId = ((CameraCharacteristics.Key<?>) k).getVendorId();
Ruben Brunkc620eb72015-07-29 18:19:11 -0700205 } else {
206 continue;
207 }
208
209 if (filterTags == null || Arrays.binarySearch(filterTags,
Emilian Peevde62d842017-03-23 19:20:40 +0000210 CameraMetadataNative.getTag(keyName, vendorId)) >= 0) {
Ruben Brunkc620eb72015-07-29 18:19:11 -0700211 keyList.add(k);
212 }
213 }
214 }
215
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700216 return keyList;
217 }
218
Igor Murashkincc542a42014-06-25 11:52:23 -0700219 @SuppressWarnings("rawtypes")
Emilian Peeva7fea4c2018-09-03 16:37:06 +0100220 private static <TKey> boolean shouldKeyBeAdded(TKey key, Field field, int[] filterTags,
221 boolean includeSynthetic) {
Igor Murashkincc542a42014-06-25 11:52:23 -0700222 if (key == null) {
223 throw new NullPointerException("key must not be null");
224 }
225
226 CameraMetadataNative.Key nativeKey;
227
228 /*
229 * Get the native key from the public api key
230 */
231 if (key instanceof CameraCharacteristics.Key) {
232 nativeKey = ((CameraCharacteristics.Key)key).getNativeKey();
233 } else if (key instanceof CaptureResult.Key) {
234 nativeKey = ((CaptureResult.Key)key).getNativeKey();
235 } else if (key instanceof CaptureRequest.Key) {
236 nativeKey = ((CaptureRequest.Key)key).getNativeKey();
237 } else {
238 // Reject fields that aren't a key
239 throw new IllegalArgumentException("key type must be that of a metadata key");
240 }
241
Igor Murashkin6c76f582014-07-15 17:19:49 -0700242 if (field.getAnnotation(PublicKey.class) == null) {
243 // Never expose @hide keys up to the API user
244 return false;
245 }
246
Igor Murashkincc542a42014-06-25 11:52:23 -0700247 // No filtering necessary
248 if (filterTags == null) {
249 return true;
250 }
251
Igor Murashkin6c76f582014-07-15 17:19:49 -0700252 if (field.getAnnotation(SyntheticKey.class) != null) {
253 // This key is synthetic, so calling #getTag will throw IAE
254
Emilian Peeva7fea4c2018-09-03 16:37:06 +0100255 return includeSynthetic;
Igor Murashkin6c76f582014-07-15 17:19:49 -0700256 }
257
258 /*
259 * Regular key: look up it's native tag and see if it's in filterTags
260 */
261
Igor Murashkincc542a42014-06-25 11:52:23 -0700262 int keyTag = nativeKey.getTag();
263
264 // non-negative result is returned iff the value is in the array
265 return Arrays.binarySearch(filterTags, keyTag) >= 0;
266 }
267
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700268 /*@O~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~
269 * The enum values below this point are generated from metadata
270 * definitions in /system/media/camera/docs. Do not modify by hand or
271 * modify the comment blocks at the start or end.
272 *~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~*/
273
274 //
Zhijun Heff413932014-02-07 15:44:30 -0800275 // Enumeration values for CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION
276 //
277
278 /**
279 * <p>The lens focus distance is not accurate, and the units used for
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700280 * {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance} do not correspond to any physical units.</p>
281 * <p>Setting the lens to the same focus distance on separate occasions may
Zhijun Heff413932014-02-07 15:44:30 -0800282 * result in a different real focus distance, depending on factors such
283 * as the orientation of the device, the age of the focusing mechanism,
284 * and the device temperature. The focus distance value will still be
285 * in the range of <code>[0, {@link CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE android.lens.info.minimumFocusDistance}]</code>, where 0
286 * represents the farthest focus.</p>
287 *
288 * @see CaptureRequest#LENS_FOCUS_DISTANCE
289 * @see CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE
290 * @see CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION
291 */
292 public static final int LENS_INFO_FOCUS_DISTANCE_CALIBRATION_UNCALIBRATED = 0;
293
294 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700295 * <p>The lens focus distance is measured in diopters.</p>
296 * <p>However, setting the lens to the same focus distance
297 * on separate occasions may result in a different real
298 * focus distance, depending on factors such as the
299 * orientation of the device, the age of the focusing
300 * mechanism, and the device temperature.</p>
Zhijun Heff413932014-02-07 15:44:30 -0800301 * @see CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION
302 */
303 public static final int LENS_INFO_FOCUS_DISTANCE_CALIBRATION_APPROXIMATE = 1;
304
305 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700306 * <p>The lens focus distance is measured in diopters, and
307 * is calibrated.</p>
308 * <p>The lens mechanism is calibrated so that setting the
309 * same focus distance is repeatable on multiple
310 * occasions with good accuracy, and the focus distance
311 * corresponds to the real physical distance to the plane
312 * of best focus.</p>
Zhijun Heff413932014-02-07 15:44:30 -0800313 * @see CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION
314 */
315 public static final int LENS_INFO_FOCUS_DISTANCE_CALIBRATION_CALIBRATED = 2;
316
317 //
Igor Murashkin68f40062013-09-10 12:15:54 -0700318 // Enumeration values for CameraCharacteristics#LENS_FACING
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700319 //
320
321 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700322 * <p>The camera device faces the same direction as the device's screen.</p>
Igor Murashkin68f40062013-09-10 12:15:54 -0700323 * @see CameraCharacteristics#LENS_FACING
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700324 */
325 public static final int LENS_FACING_FRONT = 0;
326
327 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700328 * <p>The camera device faces the opposite direction as the device's screen.</p>
Igor Murashkin68f40062013-09-10 12:15:54 -0700329 * @see CameraCharacteristics#LENS_FACING
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700330 */
331 public static final int LENS_FACING_BACK = 1;
332
Zhijun He503e8152015-01-12 15:16:56 -0800333 /**
334 * <p>The camera device is an external camera, and has no fixed facing relative to the
335 * device's screen.</p>
336 * @see CameraCharacteristics#LENS_FACING
337 */
338 public static final int LENS_FACING_EXTERNAL = 2;
339
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700340 //
Eino-Ville Talvalaec99efa2017-11-29 15:35:42 -0800341 // Enumeration values for CameraCharacteristics#LENS_POSE_REFERENCE
342 //
343
344 /**
345 * <p>The value of {@link CameraCharacteristics#LENS_POSE_TRANSLATION android.lens.poseTranslation} is relative to the optical center of
346 * the largest camera device facing the same direction as this camera.</p>
Eino-Ville Talvala601e0f62018-02-05 16:25:40 -0800347 * <p>This is the default value for API levels before Android P.</p>
Eino-Ville Talvalaec99efa2017-11-29 15:35:42 -0800348 *
349 * @see CameraCharacteristics#LENS_POSE_TRANSLATION
350 * @see CameraCharacteristics#LENS_POSE_REFERENCE
351 */
352 public static final int LENS_POSE_REFERENCE_PRIMARY_CAMERA = 0;
353
354 /**
355 * <p>The value of {@link CameraCharacteristics#LENS_POSE_TRANSLATION android.lens.poseTranslation} is relative to the position of the
356 * primary gyroscope of this Android device.</p>
Eino-Ville Talvalaec99efa2017-11-29 15:35:42 -0800357 *
358 * @see CameraCharacteristics#LENS_POSE_TRANSLATION
359 * @see CameraCharacteristics#LENS_POSE_REFERENCE
360 */
361 public static final int LENS_POSE_REFERENCE_GYROSCOPE = 1;
362
363 //
Igor Murashkine46c0da2014-02-07 18:34:37 -0800364 // Enumeration values for CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
365 //
366
367 /**
368 * <p>The minimal set of capabilities that every camera
369 * device (regardless of {@link CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL android.info.supportedHardwareLevel})
Eino-Ville Talvala08bc3b02014-07-09 10:07:36 -0700370 * supports.</p>
Eino-Ville Talvala0b7b03b2015-04-13 17:29:52 -0700371 * <p>This capability is listed by all normal devices, and
Eino-Ville Talvala08bc3b02014-07-09 10:07:36 -0700372 * indicates that the camera device has a feature set
373 * that's comparable to the baseline requirements for the
374 * older android.hardware.Camera API.</p>
Eino-Ville Talvala0b7b03b2015-04-13 17:29:52 -0700375 * <p>Devices with the DEPTH_OUTPUT capability might not list this
376 * capability, indicating that they support only depth measurement,
377 * not standard color output.</p>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800378 *
379 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
380 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
381 */
382 public static final int REQUEST_AVAILABLE_CAPABILITIES_BACKWARD_COMPATIBLE = 0;
383
384 /**
Igor Murashkine46c0da2014-02-07 18:34:37 -0800385 * <p>The camera device can be manually controlled (3A algorithms such
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700386 * as auto-exposure, and auto-focus can be bypassed).
Zhijun He50f72432014-05-28 13:52:04 -0700387 * The camera device supports basic manual control of the sensor image
388 * acquisition related stages. This means the following controls are
389 * guaranteed to be supported:</p>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800390 * <ul>
Zhijun He50f72432014-05-28 13:52:04 -0700391 * <li>Manual frame duration control<ul>
392 * <li>{@link CaptureRequest#SENSOR_FRAME_DURATION android.sensor.frameDuration}</li>
393 * <li>{@link CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION android.sensor.info.maxFrameDuration}</li>
Zhijun He50f72432014-05-28 13:52:04 -0700394 * </ul>
395 * </li>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800396 * <li>Manual exposure control<ul>
397 * <li>{@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}</li>
398 * <li>{@link CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE android.sensor.info.exposureTimeRange}</li>
399 * </ul>
400 * </li>
401 * <li>Manual sensitivity control<ul>
402 * <li>{@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}</li>
403 * <li>{@link CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE android.sensor.info.sensitivityRange}</li>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800404 * </ul>
405 * </li>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700406 * <li>Manual lens control (if the lens is adjustable)<ul>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800407 * <li>android.lens.*</li>
408 * </ul>
409 * </li>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700410 * <li>Manual flash control (if a flash unit is present)<ul>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800411 * <li>android.flash.*</li>
412 * </ul>
413 * </li>
414 * <li>Manual black level locking<ul>
415 * <li>{@link CaptureRequest#BLACK_LEVEL_LOCK android.blackLevel.lock}</li>
416 * </ul>
417 * </li>
Yin-Chia Yeh7e3e4312015-04-02 14:34:30 -0700418 * <li>Auto exposure lock<ul>
419 * <li>{@link CaptureRequest#CONTROL_AE_LOCK android.control.aeLock}</li>
420 * </ul>
421 * </li>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800422 * </ul>
423 * <p>If any of the above 3A algorithms are enabled, then the camera
424 * device will accurately report the values applied by 3A in the
425 * result.</p>
Zhijun He50f72432014-05-28 13:52:04 -0700426 * <p>A given camera device may also support additional manual sensor controls,
427 * but this capability only covers the above list of controls.</p>
Ruben Brunk3e4fed22014-06-18 17:08:42 -0700428 * <p>If this is supported, {@link CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP android.scaler.streamConfigurationMap} will
429 * additionally return a min frame duration that is greater than
430 * zero for each supported size-format combination.</p>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800431 *
432 * @see CaptureRequest#BLACK_LEVEL_LOCK
Yin-Chia Yeh7e3e4312015-04-02 14:34:30 -0700433 * @see CaptureRequest#CONTROL_AE_LOCK
Zhijun He50f72432014-05-28 13:52:04 -0700434 * @see CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP
Igor Murashkine46c0da2014-02-07 18:34:37 -0800435 * @see CaptureRequest#SENSOR_EXPOSURE_TIME
Zhijun He50f72432014-05-28 13:52:04 -0700436 * @see CaptureRequest#SENSOR_FRAME_DURATION
Igor Murashkine46c0da2014-02-07 18:34:37 -0800437 * @see CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE
Zhijun He50f72432014-05-28 13:52:04 -0700438 * @see CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION
Igor Murashkine46c0da2014-02-07 18:34:37 -0800439 * @see CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE
440 * @see CaptureRequest#SENSOR_SENSITIVITY
441 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
442 */
Eino-Ville Talvala08bc3b02014-07-09 10:07:36 -0700443 public static final int REQUEST_AVAILABLE_CAPABILITIES_MANUAL_SENSOR = 1;
Igor Murashkine46c0da2014-02-07 18:34:37 -0800444
445 /**
Zhijun He50f72432014-05-28 13:52:04 -0700446 * <p>The camera device post-processing stages can be manually controlled.
447 * The camera device supports basic manual control of the image post-processing
448 * stages. This means the following controls are guaranteed to be supported:</p>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800449 * <ul>
Yin-Chia Yeh956c52b2015-02-06 11:23:25 -0800450 * <li>
451 * <p>Manual tonemap control</p>
452 * <ul>
Yin-Chia Yeh8490ace2014-05-27 10:04:54 -0700453 * <li>{@link CaptureRequest#TONEMAP_CURVE android.tonemap.curve}</li>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800454 * <li>{@link CaptureRequest#TONEMAP_MODE android.tonemap.mode}</li>
455 * <li>{@link CameraCharacteristics#TONEMAP_MAX_CURVE_POINTS android.tonemap.maxCurvePoints}</li>
Yin-Chia Yeh03d50da2015-05-06 00:10:11 -0700456 * <li>{@link CaptureRequest#TONEMAP_GAMMA android.tonemap.gamma}</li>
457 * <li>{@link CaptureRequest#TONEMAP_PRESET_CURVE android.tonemap.presetCurve}</li>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800458 * </ul>
459 * </li>
Yin-Chia Yeh956c52b2015-02-06 11:23:25 -0800460 * <li>
461 * <p>Manual white balance control</p>
462 * <ul>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800463 * <li>{@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}</li>
464 * <li>{@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains}</li>
465 * </ul>
466 * </li>
Zhijun He28288ca2014-06-25 15:49:13 -0700467 * <li>Manual lens shading map control<ul>
468 * <li>{@link CaptureRequest#SHADING_MODE android.shading.mode}</li>
469 * <li>{@link CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE android.statistics.lensShadingMapMode}</li>
Ruben Brunk57493682014-05-27 18:58:08 -0700470 * <li>android.statistics.lensShadingMap</li>
471 * <li>android.lens.info.shadingMapSize</li>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800472 * </ul>
473 * </li>
Zhijun Hea05e59d2014-07-08 18:27:47 -0700474 * <li>Manual aberration correction control (if aberration correction is supported)<ul>
Zhijun He9e4e4392014-08-18 11:12:32 -0700475 * <li>{@link CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE android.colorCorrection.aberrationMode}</li>
476 * <li>{@link CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES android.colorCorrection.availableAberrationModes}</li>
Zhijun Hea05e59d2014-07-08 18:27:47 -0700477 * </ul>
478 * </li>
Yin-Chia Yeh7e3e4312015-04-02 14:34:30 -0700479 * <li>Auto white balance lock<ul>
480 * <li>{@link CaptureRequest#CONTROL_AWB_LOCK android.control.awbLock}</li>
481 * </ul>
482 * </li>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800483 * </ul>
484 * <p>If auto white balance is enabled, then the camera device
485 * will accurately report the values applied by AWB in the result.</p>
Zhijun He50f72432014-05-28 13:52:04 -0700486 * <p>A given camera device may also support additional post-processing
487 * controls, but this capability only covers the above list of controls.</p>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800488 *
Zhijun He9e4e4392014-08-18 11:12:32 -0700489 * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE
490 * @see CameraCharacteristics#COLOR_CORRECTION_AVAILABLE_ABERRATION_MODES
Igor Murashkine46c0da2014-02-07 18:34:37 -0800491 * @see CaptureRequest#COLOR_CORRECTION_GAINS
492 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Yin-Chia Yeh7e3e4312015-04-02 14:34:30 -0700493 * @see CaptureRequest#CONTROL_AWB_LOCK
Zhijun He28288ca2014-06-25 15:49:13 -0700494 * @see CaptureRequest#SHADING_MODE
495 * @see CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE
Yin-Chia Yeh8490ace2014-05-27 10:04:54 -0700496 * @see CaptureRequest#TONEMAP_CURVE
Yin-Chia Yeh03d50da2015-05-06 00:10:11 -0700497 * @see CaptureRequest#TONEMAP_GAMMA
Igor Murashkine46c0da2014-02-07 18:34:37 -0800498 * @see CameraCharacteristics#TONEMAP_MAX_CURVE_POINTS
499 * @see CaptureRequest#TONEMAP_MODE
Yin-Chia Yeh03d50da2015-05-06 00:10:11 -0700500 * @see CaptureRequest#TONEMAP_PRESET_CURVE
Igor Murashkine46c0da2014-02-07 18:34:37 -0800501 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
502 */
Eino-Ville Talvala08bc3b02014-07-09 10:07:36 -0700503 public static final int REQUEST_AVAILABLE_CAPABILITIES_MANUAL_POST_PROCESSING = 2;
504
505 /**
Eino-Ville Talvala611fece2014-07-10 17:29:38 -0700506 * <p>The camera device supports outputting RAW buffers and
507 * metadata for interpreting them.</p>
508 * <p>Devices supporting the RAW capability allow both for
509 * saving DNG files, and for direct application processing of
510 * raw sensor images.</p>
Eino-Ville Talvala08bc3b02014-07-09 10:07:36 -0700511 * <ul>
512 * <li>RAW_SENSOR is supported as an output format.</li>
513 * <li>The maximum available resolution for RAW_SENSOR streams
Eino-Ville Talvalafd3e2892014-10-06 10:23:55 -0700514 * will match either the value in
515 * {@link CameraCharacteristics#SENSOR_INFO_PIXEL_ARRAY_SIZE android.sensor.info.pixelArraySize} or
Eino-Ville Talvalad8407272015-11-08 18:27:20 -0800516 * {@link CameraCharacteristics#SENSOR_INFO_PRE_CORRECTION_ACTIVE_ARRAY_SIZE android.sensor.info.preCorrectionActiveArraySize}.</li>
Eino-Ville Talvala08bc3b02014-07-09 10:07:36 -0700517 * <li>All DNG-related optional metadata entries are provided
Eino-Ville Talvalafd3e2892014-10-06 10:23:55 -0700518 * by the camera device.</li>
Eino-Ville Talvala08bc3b02014-07-09 10:07:36 -0700519 * </ul>
520 *
Eino-Ville Talvala08bc3b02014-07-09 10:07:36 -0700521 * @see CameraCharacteristics#SENSOR_INFO_PIXEL_ARRAY_SIZE
Eino-Ville Talvalad8407272015-11-08 18:27:20 -0800522 * @see CameraCharacteristics#SENSOR_INFO_PRE_CORRECTION_ACTIVE_ARRAY_SIZE
Eino-Ville Talvala08bc3b02014-07-09 10:07:36 -0700523 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
524 */
Eino-Ville Talvala611fece2014-07-10 17:29:38 -0700525 public static final int REQUEST_AVAILABLE_CAPABILITIES_RAW = 3;
Igor Murashkine46c0da2014-02-07 18:34:37 -0800526
527 /**
Zhijun He0e99c222015-01-29 15:26:05 -0800528 * <p>The camera device supports the Zero Shutter Lag reprocessing use case.</p>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800529 * <ul>
Zhijun He0e99c222015-01-29 15:26:05 -0800530 * <li>One input stream is supported, that is, <code>{@link CameraCharacteristics#REQUEST_MAX_NUM_INPUT_STREAMS android.request.maxNumInputStreams} == 1</code>.</li>
Eino-Ville Talvalab6eb52f2015-04-16 16:39:45 -0700531 * <li>{@link android.graphics.ImageFormat#PRIVATE } is supported as an output/input format,
532 * that is, {@link android.graphics.ImageFormat#PRIVATE } is included in the lists of
533 * formats returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputFormats } and {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputFormats }.</li>
534 * <li>{@link android.hardware.camera2.params.StreamConfigurationMap#getValidOutputFormatsForInput }
535 * returns non empty int[] for each supported input format returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputFormats }.</li>
536 * <li>Each size returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputSizes getInputSizes(ImageFormat.PRIVATE)} is also included in {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputSizes getOutputSizes(ImageFormat.PRIVATE)}</li>
537 * <li>Using {@link android.graphics.ImageFormat#PRIVATE } does not cause a frame rate drop
538 * relative to the sensor's maximum capture rate (at that resolution).</li>
539 * <li>{@link android.graphics.ImageFormat#PRIVATE } will be reprocessable into both
540 * {@link android.graphics.ImageFormat#YUV_420_888 } and
541 * {@link android.graphics.ImageFormat#JPEG } formats.</li>
Chien-Yu Chen8062d312015-05-12 14:24:10 -0700542 * <li>The maximum available resolution for PRIVATE streams
Eino-Ville Talvalafd3e2892014-10-06 10:23:55 -0700543 * (both input/output) will match the maximum available
544 * resolution of JPEG streams.</li>
Zhijun He513f7c32015-04-24 18:23:54 -0700545 * <li>Static metadata {@link CameraCharacteristics#REPROCESS_MAX_CAPTURE_STALL android.reprocess.maxCaptureStall}.</li>
Zhijun He0e99c222015-01-29 15:26:05 -0800546 * <li>Only below controls are effective for reprocessing requests and
547 * will be present in capture results, other controls in reprocess
548 * requests will be ignored by the camera device.<ul>
549 * <li>android.jpeg.*</li>
550 * <li>{@link CaptureRequest#NOISE_REDUCTION_MODE android.noiseReduction.mode}</li>
551 * <li>{@link CaptureRequest#EDGE_MODE android.edge.mode}</li>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800552 * </ul>
Zhijun He0e99c222015-01-29 15:26:05 -0800553 * </li>
Eino-Ville Talvala0dd17502015-07-07 10:43:07 -0700554 * <li>{@link CameraCharacteristics#NOISE_REDUCTION_AVAILABLE_NOISE_REDUCTION_MODES android.noiseReduction.availableNoiseReductionModes} and
555 * {@link CameraCharacteristics#EDGE_AVAILABLE_EDGE_MODES android.edge.availableEdgeModes} will both list ZERO_SHUTTER_LAG as a supported mode.</li>
Zhijun He0e99c222015-01-29 15:26:05 -0800556 * </ul>
557 *
Eino-Ville Talvala0dd17502015-07-07 10:43:07 -0700558 * @see CameraCharacteristics#EDGE_AVAILABLE_EDGE_MODES
Zhijun He0e99c222015-01-29 15:26:05 -0800559 * @see CaptureRequest#EDGE_MODE
Eino-Ville Talvala0dd17502015-07-07 10:43:07 -0700560 * @see CameraCharacteristics#NOISE_REDUCTION_AVAILABLE_NOISE_REDUCTION_MODES
Zhijun He0e99c222015-01-29 15:26:05 -0800561 * @see CaptureRequest#NOISE_REDUCTION_MODE
Zhijun He513f7c32015-04-24 18:23:54 -0700562 * @see CameraCharacteristics#REPROCESS_MAX_CAPTURE_STALL
Zhijun He0e99c222015-01-29 15:26:05 -0800563 * @see CameraCharacteristics#REQUEST_MAX_NUM_INPUT_STREAMS
Igor Murashkine46c0da2014-02-07 18:34:37 -0800564 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
565 */
Chien-Yu Chen8062d312015-05-12 14:24:10 -0700566 public static final int REQUEST_AVAILABLE_CAPABILITIES_PRIVATE_REPROCESSING = 4;
Igor Murashkine46c0da2014-02-07 18:34:37 -0800567
Ruben Brunk0c22e692014-11-11 12:00:34 -0800568 /**
569 * <p>The camera device supports accurately reporting the sensor settings for many of
570 * the sensor controls while the built-in 3A algorithm is running. This allows
571 * reporting of sensor settings even when these settings cannot be manually changed.</p>
572 * <p>The values reported for the following controls are guaranteed to be available
573 * in the CaptureResult, including when 3A is enabled:</p>
574 * <ul>
575 * <li>Exposure control<ul>
576 * <li>{@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}</li>
577 * </ul>
578 * </li>
579 * <li>Sensitivity control<ul>
580 * <li>{@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}</li>
581 * </ul>
582 * </li>
583 * <li>Lens controls (if the lens is adjustable)<ul>
584 * <li>{@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance}</li>
585 * <li>{@link CaptureRequest#LENS_APERTURE android.lens.aperture}</li>
586 * </ul>
587 * </li>
588 * </ul>
589 * <p>This capability is a subset of the MANUAL_SENSOR control capability, and will
590 * always be included if the MANUAL_SENSOR capability is available.</p>
591 *
592 * @see CaptureRequest#LENS_APERTURE
593 * @see CaptureRequest#LENS_FOCUS_DISTANCE
594 * @see CaptureRequest#SENSOR_EXPOSURE_TIME
595 * @see CaptureRequest#SENSOR_SENSITIVITY
596 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
597 */
598 public static final int REQUEST_AVAILABLE_CAPABILITIES_READ_SENSOR_SETTINGS = 5;
599
Eino-Ville Talvala126a7462014-11-04 16:31:01 -0800600 /**
Eino-Ville Talvala0819c752015-06-17 11:34:41 -0700601 * <p>The camera device supports capturing high-resolution images at &gt;= 20 frames per
602 * second, in at least the uncompressed YUV format, when post-processing settings are set
603 * to FAST. Additionally, maximum-resolution images can be captured at &gt;= 10 frames
604 * per second. Here, 'high resolution' means at least 8 megapixels, or the maximum
605 * resolution of the device, whichever is smaller.</p>
606 * <p>More specifically, this means that a size matching the camera device's active array
607 * size is listed as a supported size for the {@link android.graphics.ImageFormat#YUV_420_888 } format in either {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputSizes } or {@link android.hardware.camera2.params.StreamConfigurationMap#getHighResolutionOutputSizes },
608 * with a minimum frame duration for that format and size of either &lt;= 1/20 s, or
609 * &lt;= 1/10 s, respectively; and the {@link CameraCharacteristics#CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES android.control.aeAvailableTargetFpsRanges} entry
610 * lists at least one FPS range where the minimum FPS is &gt;= 1 / minimumFrameDuration
611 * for the maximum-size YUV_420_888 format. If that maximum size is listed in {@link android.hardware.camera2.params.StreamConfigurationMap#getHighResolutionOutputSizes },
612 * then the list of resolutions for YUV_420_888 from {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputSizes } contains at
613 * least one resolution &gt;= 8 megapixels, with a minimum frame duration of &lt;= 1/20
614 * s.</p>
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -0800615 * <p>If the device supports the {@link android.graphics.ImageFormat#RAW10 }, {@link android.graphics.ImageFormat#RAW12 }, then those can also be
616 * captured at the same rate as the maximum-size YUV_420_888 resolution is.</p>
Eino-Ville Talvala0819c752015-06-17 11:34:41 -0700617 * <p>If the device supports the PRIVATE_REPROCESSING capability, then the same guarantees
618 * as for the YUV_420_888 format also apply to the {@link android.graphics.ImageFormat#PRIVATE } format.</p>
619 * <p>In addition, the {@link CameraCharacteristics#SYNC_MAX_LATENCY android.sync.maxLatency} field is guaranted to have a value between 0
620 * and 4, inclusive. {@link CameraCharacteristics#CONTROL_AE_LOCK_AVAILABLE android.control.aeLockAvailable} and {@link CameraCharacteristics#CONTROL_AWB_LOCK_AVAILABLE android.control.awbLockAvailable}
621 * are also guaranteed to be <code>true</code> so burst capture with these two locks ON yields
622 * consistent image output.</p>
Eino-Ville Talvala126a7462014-11-04 16:31:01 -0800623 *
Eino-Ville Talvala8d709f32014-11-17 11:28:38 -0800624 * @see CameraCharacteristics#CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES
Yin-Chia Yeh7e3e4312015-04-02 14:34:30 -0700625 * @see CameraCharacteristics#CONTROL_AE_LOCK_AVAILABLE
626 * @see CameraCharacteristics#CONTROL_AWB_LOCK_AVAILABLE
Eino-Ville Talvala126a7462014-11-04 16:31:01 -0800627 * @see CameraCharacteristics#SYNC_MAX_LATENCY
628 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
629 */
630 public static final int REQUEST_AVAILABLE_CAPABILITIES_BURST_CAPTURE = 6;
631
Zhijun He0e99c222015-01-29 15:26:05 -0800632 /**
Chien-Yu Chen0a551f12015-04-03 17:57:35 -0700633 * <p>The camera device supports the YUV_420_888 reprocessing use case, similar as
Chien-Yu Chen8062d312015-05-12 14:24:10 -0700634 * PRIVATE_REPROCESSING, This capability requires the camera device to support the
Zhijun He0e99c222015-01-29 15:26:05 -0800635 * following:</p>
636 * <ul>
637 * <li>One input stream is supported, that is, <code>{@link CameraCharacteristics#REQUEST_MAX_NUM_INPUT_STREAMS android.request.maxNumInputStreams} == 1</code>.</li>
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -0800638 * <li>{@link android.graphics.ImageFormat#YUV_420_888 } is supported as an output/input
639 * format, that is, YUV_420_888 is included in the lists of formats returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputFormats } and {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputFormats }.</li>
Eino-Ville Talvalab6eb52f2015-04-16 16:39:45 -0700640 * <li>{@link android.hardware.camera2.params.StreamConfigurationMap#getValidOutputFormatsForInput }
641 * returns non-empty int[] for each supported input format returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputFormats }.</li>
642 * <li>Each size returned by {@link android.hardware.camera2.params.StreamConfigurationMap#getInputSizes getInputSizes(YUV_420_888)} is also included in {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputSizes getOutputSizes(YUV_420_888)}</li>
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -0800643 * <li>Using {@link android.graphics.ImageFormat#YUV_420_888 } does not cause a frame rate
644 * drop relative to the sensor's maximum capture rate (at that resolution).</li>
Eino-Ville Talvalab6eb52f2015-04-16 16:39:45 -0700645 * <li>{@link android.graphics.ImageFormat#YUV_420_888 } will be reprocessable into both
646 * {@link android.graphics.ImageFormat#YUV_420_888 } and {@link android.graphics.ImageFormat#JPEG } formats.</li>
647 * <li>The maximum available resolution for {@link android.graphics.ImageFormat#YUV_420_888 } streams (both input/output) will match the
648 * maximum available resolution of {@link android.graphics.ImageFormat#JPEG } streams.</li>
Zhijun He513f7c32015-04-24 18:23:54 -0700649 * <li>Static metadata {@link CameraCharacteristics#REPROCESS_MAX_CAPTURE_STALL android.reprocess.maxCaptureStall}.</li>
Eino-Ville Talvalab6eb52f2015-04-16 16:39:45 -0700650 * <li>Only the below controls are effective for reprocessing requests and will be present
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -0800651 * in capture results. The reprocess requests are from the original capture results
652 * that are associated with the intermediate {@link android.graphics.ImageFormat#YUV_420_888 } output buffers. All other controls in the
653 * reprocess requests will be ignored by the camera device.<ul>
Zhijun He0e99c222015-01-29 15:26:05 -0800654 * <li>android.jpeg.*</li>
655 * <li>{@link CaptureRequest#NOISE_REDUCTION_MODE android.noiseReduction.mode}</li>
656 * <li>{@link CaptureRequest#EDGE_MODE android.edge.mode}</li>
657 * <li>{@link CaptureRequest#REPROCESS_EFFECTIVE_EXPOSURE_FACTOR android.reprocess.effectiveExposureFactor}</li>
658 * </ul>
659 * </li>
Eino-Ville Talvala0dd17502015-07-07 10:43:07 -0700660 * <li>{@link CameraCharacteristics#NOISE_REDUCTION_AVAILABLE_NOISE_REDUCTION_MODES android.noiseReduction.availableNoiseReductionModes} and
661 * {@link CameraCharacteristics#EDGE_AVAILABLE_EDGE_MODES android.edge.availableEdgeModes} will both list ZERO_SHUTTER_LAG as a supported mode.</li>
Zhijun He0e99c222015-01-29 15:26:05 -0800662 * </ul>
663 *
Eino-Ville Talvala0dd17502015-07-07 10:43:07 -0700664 * @see CameraCharacteristics#EDGE_AVAILABLE_EDGE_MODES
Zhijun He0e99c222015-01-29 15:26:05 -0800665 * @see CaptureRequest#EDGE_MODE
Eino-Ville Talvala0dd17502015-07-07 10:43:07 -0700666 * @see CameraCharacteristics#NOISE_REDUCTION_AVAILABLE_NOISE_REDUCTION_MODES
Zhijun He0e99c222015-01-29 15:26:05 -0800667 * @see CaptureRequest#NOISE_REDUCTION_MODE
668 * @see CaptureRequest#REPROCESS_EFFECTIVE_EXPOSURE_FACTOR
Zhijun He513f7c32015-04-24 18:23:54 -0700669 * @see CameraCharacteristics#REPROCESS_MAX_CAPTURE_STALL
Zhijun He0e99c222015-01-29 15:26:05 -0800670 * @see CameraCharacteristics#REQUEST_MAX_NUM_INPUT_STREAMS
671 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
672 */
673 public static final int REQUEST_AVAILABLE_CAPABILITIES_YUV_REPROCESSING = 7;
674
Eino-Ville Talvala0b7b03b2015-04-13 17:29:52 -0700675 /**
676 * <p>The camera device can produce depth measurements from its field of view.</p>
677 * <p>This capability requires the camera device to support the following:</p>
678 * <ul>
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -0800679 * <li>{@link android.graphics.ImageFormat#DEPTH16 } is supported as
680 * an output format.</li>
681 * <li>{@link android.graphics.ImageFormat#DEPTH_POINT_CLOUD } is
682 * optionally supported as an output format.</li>
683 * <li>This camera device, and all camera devices with the same {@link CameraCharacteristics#LENS_FACING android.lens.facing}, will
684 * list the following calibration metadata entries in both {@link android.hardware.camera2.CameraCharacteristics }
685 * and {@link android.hardware.camera2.CaptureResult }:<ul>
Eino-Ville Talvala0b7b03b2015-04-13 17:29:52 -0700686 * <li>{@link CameraCharacteristics#LENS_POSE_TRANSLATION android.lens.poseTranslation}</li>
687 * <li>{@link CameraCharacteristics#LENS_POSE_ROTATION android.lens.poseRotation}</li>
Eino-Ville Talvalaabf0b8b2015-08-19 16:21:15 -0700688 * <li>{@link CameraCharacteristics#LENS_INTRINSIC_CALIBRATION android.lens.intrinsicCalibration}</li>
Eino-Ville Talvala915f5042018-03-13 19:08:01 -0700689 * <li>{@link CameraCharacteristics#LENS_DISTORTION android.lens.distortion}</li>
Eino-Ville Talvala0b7b03b2015-04-13 17:29:52 -0700690 * </ul>
691 * </li>
692 * <li>The {@link CameraCharacteristics#DEPTH_DEPTH_IS_EXCLUSIVE android.depth.depthIsExclusive} entry is listed by this device.</li>
Eino-Ville Talvalaec99efa2017-11-29 15:35:42 -0800693 * <li>As of Android P, the {@link CameraCharacteristics#LENS_POSE_REFERENCE android.lens.poseReference} entry is listed by this device.</li>
Eino-Ville Talvala0b7b03b2015-04-13 17:29:52 -0700694 * <li>A LIMITED camera with only the DEPTH_OUTPUT capability does not have to support
695 * normal YUV_420_888, JPEG, and PRIV-format outputs. It only has to support the DEPTH16
696 * format.</li>
697 * </ul>
698 * <p>Generally, depth output operates at a slower frame rate than standard color capture,
699 * so the DEPTH16 and DEPTH_POINT_CLOUD formats will commonly have a stall duration that
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -0800700 * should be accounted for (see {@link android.hardware.camera2.params.StreamConfigurationMap#getOutputStallDuration }).
Eino-Ville Talvalab6eb52f2015-04-16 16:39:45 -0700701 * On a device that supports both depth and color-based output, to enable smooth preview,
702 * using a repeating burst is recommended, where a depth-output target is only included
703 * once every N frames, where N is the ratio between preview output rate and depth output
Eino-Ville Talvala0b7b03b2015-04-13 17:29:52 -0700704 * rate, including depth stall time.</p>
705 *
706 * @see CameraCharacteristics#DEPTH_DEPTH_IS_EXCLUSIVE
Eino-Ville Talvala915f5042018-03-13 19:08:01 -0700707 * @see CameraCharacteristics#LENS_DISTORTION
Eino-Ville Talvalab6eb52f2015-04-16 16:39:45 -0700708 * @see CameraCharacteristics#LENS_FACING
Eino-Ville Talvalaabf0b8b2015-08-19 16:21:15 -0700709 * @see CameraCharacteristics#LENS_INTRINSIC_CALIBRATION
Eino-Ville Talvalaec99efa2017-11-29 15:35:42 -0800710 * @see CameraCharacteristics#LENS_POSE_REFERENCE
Eino-Ville Talvala0b7b03b2015-04-13 17:29:52 -0700711 * @see CameraCharacteristics#LENS_POSE_ROTATION
712 * @see CameraCharacteristics#LENS_POSE_TRANSLATION
713 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
714 */
715 public static final int REQUEST_AVAILABLE_CAPABILITIES_DEPTH_OUTPUT = 8;
716
Zhijun Hefab663e2015-05-26 19:46:31 -0700717 /**
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -0800718 * <p>The device supports constrained high speed video recording (frame rate &gt;=120fps) use
719 * case. The camera device will support high speed capture session created by {@link android.hardware.camera2.CameraDevice#createConstrainedHighSpeedCaptureSession }, which
720 * only accepts high speed request lists created by {@link android.hardware.camera2.CameraConstrainedHighSpeedCaptureSession#createHighSpeedRequestList }.</p>
721 * <p>A camera device can still support high speed video streaming by advertising the high
722 * speed FPS ranges in {@link CameraCharacteristics#CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES android.control.aeAvailableTargetFpsRanges}. For this case, all
723 * normal capture request per frame control and synchronization requirements will apply
724 * to the high speed fps ranges, the same as all other fps ranges. This capability
725 * describes the capability of a specialized operating mode with many limitations (see
726 * below), which is only targeted at high speed video recording.</p>
727 * <p>The supported high speed video sizes and fps ranges are specified in {@link android.hardware.camera2.params.StreamConfigurationMap#getHighSpeedVideoFpsRanges }.
728 * To get desired output frame rates, the application is only allowed to select video
729 * size and FPS range combinations provided by {@link android.hardware.camera2.params.StreamConfigurationMap#getHighSpeedVideoSizes }. The
730 * fps range can be controlled via {@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange}.</p>
Zhijun Hefab663e2015-05-26 19:46:31 -0700731 * <p>In this capability, the camera device will override aeMode, awbMode, and afMode to
Zhijun Heee2ebde2015-06-16 19:58:11 -0700732 * ON, AUTO, and CONTINUOUS_VIDEO, respectively. All post-processing block mode
Zhijun Hefab663e2015-05-26 19:46:31 -0700733 * controls will be overridden to be FAST. Therefore, no manual control of capture
734 * and post-processing parameters is possible. All other controls operate the
735 * same as when {@link CaptureRequest#CONTROL_MODE android.control.mode} == AUTO. This means that all other
736 * android.control.* fields continue to work, such as</p>
737 * <ul>
738 * <li>{@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange}</li>
739 * <li>{@link CaptureRequest#CONTROL_AE_EXPOSURE_COMPENSATION android.control.aeExposureCompensation}</li>
740 * <li>{@link CaptureRequest#CONTROL_AE_LOCK android.control.aeLock}</li>
741 * <li>{@link CaptureRequest#CONTROL_AWB_LOCK android.control.awbLock}</li>
742 * <li>{@link CaptureRequest#CONTROL_EFFECT_MODE android.control.effectMode}</li>
743 * <li>{@link CaptureRequest#CONTROL_AE_REGIONS android.control.aeRegions}</li>
744 * <li>{@link CaptureRequest#CONTROL_AF_REGIONS android.control.afRegions}</li>
745 * <li>{@link CaptureRequest#CONTROL_AWB_REGIONS android.control.awbRegions}</li>
746 * <li>{@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}</li>
747 * <li>{@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}</li>
748 * </ul>
749 * <p>Outside of android.control.*, the following controls will work:</p>
750 * <ul>
751 * <li>{@link CaptureRequest#FLASH_MODE android.flash.mode} (TORCH mode only, automatic flash for still capture will not
752 * work since aeMode is ON)</li>
753 * <li>{@link CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE android.lens.opticalStabilizationMode} (if it is supported)</li>
754 * <li>{@link CaptureRequest#SCALER_CROP_REGION android.scaler.cropRegion}</li>
755 * <li>{@link CaptureRequest#STATISTICS_FACE_DETECT_MODE android.statistics.faceDetectMode} (if it is supported)</li>
756 * </ul>
757 * <p>For high speed recording use case, the actual maximum supported frame rate may
758 * be lower than what camera can output, depending on the destination Surfaces for
759 * the image data. For example, if the destination surface is from video encoder,
760 * the application need check if the video encoder is capable of supporting the
761 * high frame rate for a given video size, or it will end up with lower recording
762 * frame rate. If the destination surface is from preview window, the actual preview frame
763 * rate will be bounded by the screen refresh rate.</p>
764 * <p>The camera device will only support up to 2 high speed simultaneous output surfaces
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -0800765 * (preview and recording surfaces) in this mode. Above controls will be effective only
766 * if all of below conditions are true:</p>
Zhijun Hefab663e2015-05-26 19:46:31 -0700767 * <ul>
768 * <li>The application creates a camera capture session with no more than 2 surfaces via
769 * {@link android.hardware.camera2.CameraDevice#createConstrainedHighSpeedCaptureSession }. The
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -0800770 * targeted surfaces must be preview surface (either from {@link android.view.SurfaceView } or {@link android.graphics.SurfaceTexture }) or recording
771 * surface(either from {@link android.media.MediaRecorder#getSurface } or {@link android.media.MediaCodec#createInputSurface }).</li>
Zhijun Hefab663e2015-05-26 19:46:31 -0700772 * <li>The stream sizes are selected from the sizes reported by
773 * {@link android.hardware.camera2.params.StreamConfigurationMap#getHighSpeedVideoSizes }.</li>
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -0800774 * <li>The FPS ranges are selected from {@link android.hardware.camera2.params.StreamConfigurationMap#getHighSpeedVideoFpsRanges }.</li>
Zhijun Hefab663e2015-05-26 19:46:31 -0700775 * </ul>
Eino-Ville Talvala639fffe2015-06-30 10:34:48 -0700776 * <p>When above conditions are NOT satistied,
Zhijun Hefab663e2015-05-26 19:46:31 -0700777 * {@link android.hardware.camera2.CameraDevice#createConstrainedHighSpeedCaptureSession }
Eino-Ville Talvala639fffe2015-06-30 10:34:48 -0700778 * will fail.</p>
Zhijun Hefab663e2015-05-26 19:46:31 -0700779 * <p>Switching to a FPS range that has different maximum FPS may trigger some camera device
780 * reconfigurations, which may introduce extra latency. It is recommended that
781 * the application avoids unnecessary maximum target FPS changes as much as possible
782 * during high speed streaming.</p>
783 *
784 * @see CameraCharacteristics#CONTROL_AE_AVAILABLE_TARGET_FPS_RANGES
785 * @see CaptureRequest#CONTROL_AE_EXPOSURE_COMPENSATION
786 * @see CaptureRequest#CONTROL_AE_LOCK
787 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
788 * @see CaptureRequest#CONTROL_AE_REGIONS
789 * @see CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE
790 * @see CaptureRequest#CONTROL_AF_REGIONS
791 * @see CaptureRequest#CONTROL_AF_TRIGGER
792 * @see CaptureRequest#CONTROL_AWB_LOCK
793 * @see CaptureRequest#CONTROL_AWB_REGIONS
794 * @see CaptureRequest#CONTROL_EFFECT_MODE
795 * @see CaptureRequest#CONTROL_MODE
796 * @see CaptureRequest#FLASH_MODE
797 * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE
798 * @see CaptureRequest#SCALER_CROP_REGION
799 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE
800 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
801 */
802 public static final int REQUEST_AVAILABLE_CAPABILITIES_CONSTRAINED_HIGH_SPEED_VIDEO = 9;
803
Eino-Ville Talvalaec99efa2017-11-29 15:35:42 -0800804 /**
Eino-Ville Talvala601e0f62018-02-05 16:25:40 -0800805 * <p>The camera device supports the MOTION_TRACKING value for
806 * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent}, which limits maximum exposure time to 20 ms.</p>
807 * <p>This limits the motion blur of capture images, resulting in better image tracking
808 * results for use cases such as image stabilization or augmented reality.</p>
Eino-Ville Talvalaec99efa2017-11-29 15:35:42 -0800809 *
Eino-Ville Talvalaec99efa2017-11-29 15:35:42 -0800810 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
Eino-Ville Talvalaec99efa2017-11-29 15:35:42 -0800811 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
812 */
813 public static final int REQUEST_AVAILABLE_CAPABILITIES_MOTION_TRACKING = 10;
814
Shuzhen Wang23d29382017-11-26 17:24:56 -0800815 /**
Shuzhen Wang123deefc2018-08-20 12:00:05 -0700816 * <p>The camera device is a logical camera backed by two or more physical cameras. In
817 * API level 28, the physical cameras must also be exposed to the application via
818 * {@link android.hardware.camera2.CameraManager#getCameraIdList }. Starting from API
819 * level 29, some or all physical cameras may not be independently exposed to the
820 * application, in which case the physical camera IDs will not be available in
821 * {@link android.hardware.camera2.CameraManager#getCameraIdList }. But the application
822 * can still query the physical cameras' characteristics by calling
823 * {@link android.hardware.camera2.CameraManager#getCameraCharacteristics }.</p>
Shuzhen Wanga57c2742018-05-23 11:19:59 -0700824 * <p>Camera application shouldn't assume that there are at most 1 rear camera and 1 front
825 * camera in the system. For an application that switches between front and back cameras,
826 * the recommendation is to switch between the first rear camera and the first front
827 * camera in the list of supported camera devices.</p>
Shuzhen Wang23d29382017-11-26 17:24:56 -0800828 * <p>This capability requires the camera device to support the following:</p>
829 * <ul>
Shuzhen Wangde23d282018-08-15 14:01:45 -0700830 * <li>The IDs of underlying physical cameras are returned via
831 * {@link android.hardware.camera2.CameraCharacteristics#getPhysicalCameraIds }.</li>
832 * <li>This camera device must list static metadata
833 * {@link CameraCharacteristics#LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE android.logicalMultiCamera.sensorSyncType} in
834 * {@link android.hardware.camera2.CameraCharacteristics }.</li>
Shuzhen Wang23d29382017-11-26 17:24:56 -0800835 * <li>The underlying physical cameras' static metadata must list the following entries,
836 * so that the application can correlate pixels from the physical streams:<ul>
837 * <li>{@link CameraCharacteristics#LENS_POSE_REFERENCE android.lens.poseReference}</li>
838 * <li>{@link CameraCharacteristics#LENS_POSE_ROTATION android.lens.poseRotation}</li>
839 * <li>{@link CameraCharacteristics#LENS_POSE_TRANSLATION android.lens.poseTranslation}</li>
840 * <li>{@link CameraCharacteristics#LENS_INTRINSIC_CALIBRATION android.lens.intrinsicCalibration}</li>
Eino-Ville Talvala915f5042018-03-13 19:08:01 -0700841 * <li>{@link CameraCharacteristics#LENS_DISTORTION android.lens.distortion}</li>
Shuzhen Wang23d29382017-11-26 17:24:56 -0800842 * </ul>
843 * </li>
Shuzhen Wang03d36e22018-02-13 17:34:59 -0800844 * <li>The SENSOR_INFO_TIMESTAMP_SOURCE of the logical device and physical devices must be
845 * the same.</li>
Shuzhen Wang23d29382017-11-26 17:24:56 -0800846 * <li>The logical camera device must be LIMITED or higher device.</li>
847 * </ul>
848 * <p>Both the logical camera device and its underlying physical devices support the
849 * mandatory stream combinations required for their device levels.</p>
850 * <p>Additionally, for each guaranteed stream combination, the logical camera supports:</p>
851 * <ul>
Shuzhen Wang03d36e22018-02-13 17:34:59 -0800852 * <li>For each guaranteed stream combination, the logical camera supports replacing one
853 * logical {@link android.graphics.ImageFormat#YUV_420_888 YUV_420_888}
Shuzhen Wang23d29382017-11-26 17:24:56 -0800854 * or raw stream with two physical streams of the same size and format, each from a
855 * separate physical camera, given that the size and format are supported by both
856 * physical cameras.</li>
Shuzhen Wang03d36e22018-02-13 17:34:59 -0800857 * <li>If the logical camera doesn't advertise RAW capability, but the underlying physical
858 * cameras do, the logical camera will support guaranteed stream combinations for RAW
859 * capability, except that the RAW streams will be physical streams, each from a separate
860 * physical camera. This is usually the case when the physical cameras have different
861 * sensor sizes.</li>
Shuzhen Wang23d29382017-11-26 17:24:56 -0800862 * </ul>
863 * <p>Using physical streams in place of a logical stream of the same size and format will
864 * not slow down the frame rate of the capture, as long as the minimum frame duration
865 * of the physical and logical streams are the same.</p>
866 *
Eino-Ville Talvala915f5042018-03-13 19:08:01 -0700867 * @see CameraCharacteristics#LENS_DISTORTION
Shuzhen Wang23d29382017-11-26 17:24:56 -0800868 * @see CameraCharacteristics#LENS_INTRINSIC_CALIBRATION
869 * @see CameraCharacteristics#LENS_POSE_REFERENCE
870 * @see CameraCharacteristics#LENS_POSE_ROTATION
871 * @see CameraCharacteristics#LENS_POSE_TRANSLATION
Shuzhen Wang23d29382017-11-26 17:24:56 -0800872 * @see CameraCharacteristics#LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE
873 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
874 */
875 public static final int REQUEST_AVAILABLE_CAPABILITIES_LOGICAL_MULTI_CAMERA = 11;
876
Shuzhen Wang51248bf2018-03-22 00:04:45 -0700877 /**
878 * <p>The camera device is a monochrome camera that doesn't contain a color filter array,
Hidenari Koshimae3a385f82018-04-11 18:37:44 +0900879 * and the pixel values on U and V planes are all 128.</p>
Shuzhen Wang51248bf2018-03-22 00:04:45 -0700880 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
881 */
882 public static final int REQUEST_AVAILABLE_CAPABILITIES_MONOCHROME = 12;
883
Igor Murashkine46c0da2014-02-07 18:34:37 -0800884 //
Zhijun He14986152014-05-22 21:17:37 -0700885 // Enumeration values for CameraCharacteristics#SCALER_CROPPING_TYPE
886 //
887
888 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700889 * <p>The camera device only supports centered crop regions.</p>
Zhijun He14986152014-05-22 21:17:37 -0700890 * @see CameraCharacteristics#SCALER_CROPPING_TYPE
891 */
892 public static final int SCALER_CROPPING_TYPE_CENTER_ONLY = 0;
893
894 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700895 * <p>The camera device supports arbitrarily chosen crop regions.</p>
Zhijun He14986152014-05-22 21:17:37 -0700896 * @see CameraCharacteristics#SCALER_CROPPING_TYPE
897 */
898 public static final int SCALER_CROPPING_TYPE_FREEFORM = 1;
899
900 //
Zhijun Hed1784962014-04-08 17:41:46 -0700901 // Enumeration values for CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT
902 //
903
904 /**
905 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT
906 */
907 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_RGGB = 0;
908
909 /**
910 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT
911 */
912 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GRBG = 1;
913
914 /**
915 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT
916 */
917 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GBRG = 2;
918
919 /**
920 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT
921 */
922 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_BGGR = 3;
923
924 /**
925 * <p>Sensor is not Bayer; output has 3 16-bit
926 * values for each pixel, instead of just 1 16-bit value
927 * per pixel.</p>
928 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT
929 */
930 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_RGB = 4;
931
932 //
Eino-Ville Talvalaabd9d3c2014-07-28 13:01:52 -0700933 // Enumeration values for CameraCharacteristics#SENSOR_INFO_TIMESTAMP_SOURCE
Zhijun He45fa43a12014-06-13 18:29:37 -0700934 //
935
936 /**
937 * <p>Timestamps from {@link CaptureResult#SENSOR_TIMESTAMP android.sensor.timestamp} are in nanoseconds and monotonic,
938 * but can not be compared to timestamps from other subsystems
939 * (e.g. accelerometer, gyro etc.), or other instances of the same or different
940 * camera devices in the same system. Timestamps between streams and results for
941 * a single camera instance are comparable, and the timestamps for all buffers
942 * and the result metadata generated by a single capture are identical.</p>
943 *
944 * @see CaptureResult#SENSOR_TIMESTAMP
Eino-Ville Talvalaabd9d3c2014-07-28 13:01:52 -0700945 * @see CameraCharacteristics#SENSOR_INFO_TIMESTAMP_SOURCE
Zhijun He45fa43a12014-06-13 18:29:37 -0700946 */
Eino-Ville Talvalaabd9d3c2014-07-28 13:01:52 -0700947 public static final int SENSOR_INFO_TIMESTAMP_SOURCE_UNKNOWN = 0;
Zhijun He45fa43a12014-06-13 18:29:37 -0700948
949 /**
950 * <p>Timestamps from {@link CaptureResult#SENSOR_TIMESTAMP android.sensor.timestamp} are in the same timebase as
Eino-Ville Talvalab6eb52f2015-04-16 16:39:45 -0700951 * {@link android.os.SystemClock#elapsedRealtimeNanos },
Zhijun He45fa43a12014-06-13 18:29:37 -0700952 * and they can be compared to other timestamps using that base.</p>
953 *
954 * @see CaptureResult#SENSOR_TIMESTAMP
Eino-Ville Talvalaabd9d3c2014-07-28 13:01:52 -0700955 * @see CameraCharacteristics#SENSOR_INFO_TIMESTAMP_SOURCE
Zhijun He45fa43a12014-06-13 18:29:37 -0700956 */
Eino-Ville Talvalaabd9d3c2014-07-28 13:01:52 -0700957 public static final int SENSOR_INFO_TIMESTAMP_SOURCE_REALTIME = 1;
Zhijun He45fa43a12014-06-13 18:29:37 -0700958
959 //
Ruben Brunk7c062362014-04-15 23:53:53 -0700960 // Enumeration values for CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
961 //
962
963 /**
964 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
965 */
966 public static final int SENSOR_REFERENCE_ILLUMINANT1_DAYLIGHT = 1;
967
968 /**
969 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
970 */
971 public static final int SENSOR_REFERENCE_ILLUMINANT1_FLUORESCENT = 2;
972
973 /**
974 * <p>Incandescent light</p>
975 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
976 */
977 public static final int SENSOR_REFERENCE_ILLUMINANT1_TUNGSTEN = 3;
978
979 /**
980 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
981 */
982 public static final int SENSOR_REFERENCE_ILLUMINANT1_FLASH = 4;
983
984 /**
985 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
986 */
987 public static final int SENSOR_REFERENCE_ILLUMINANT1_FINE_WEATHER = 9;
988
989 /**
990 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
991 */
992 public static final int SENSOR_REFERENCE_ILLUMINANT1_CLOUDY_WEATHER = 10;
993
994 /**
995 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
996 */
997 public static final int SENSOR_REFERENCE_ILLUMINANT1_SHADE = 11;
998
999 /**
1000 * <p>D 5700 - 7100K</p>
1001 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
1002 */
1003 public static final int SENSOR_REFERENCE_ILLUMINANT1_DAYLIGHT_FLUORESCENT = 12;
1004
1005 /**
1006 * <p>N 4600 - 5400K</p>
1007 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
1008 */
1009 public static final int SENSOR_REFERENCE_ILLUMINANT1_DAY_WHITE_FLUORESCENT = 13;
1010
1011 /**
1012 * <p>W 3900 - 4500K</p>
1013 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
1014 */
1015 public static final int SENSOR_REFERENCE_ILLUMINANT1_COOL_WHITE_FLUORESCENT = 14;
1016
1017 /**
1018 * <p>WW 3200 - 3700K</p>
1019 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
1020 */
1021 public static final int SENSOR_REFERENCE_ILLUMINANT1_WHITE_FLUORESCENT = 15;
1022
1023 /**
1024 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
1025 */
1026 public static final int SENSOR_REFERENCE_ILLUMINANT1_STANDARD_A = 17;
1027
1028 /**
1029 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
1030 */
1031 public static final int SENSOR_REFERENCE_ILLUMINANT1_STANDARD_B = 18;
1032
1033 /**
1034 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
1035 */
1036 public static final int SENSOR_REFERENCE_ILLUMINANT1_STANDARD_C = 19;
1037
1038 /**
1039 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
1040 */
1041 public static final int SENSOR_REFERENCE_ILLUMINANT1_D55 = 20;
1042
1043 /**
1044 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
1045 */
1046 public static final int SENSOR_REFERENCE_ILLUMINANT1_D65 = 21;
1047
1048 /**
1049 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
1050 */
1051 public static final int SENSOR_REFERENCE_ILLUMINANT1_D75 = 22;
1052
1053 /**
1054 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
1055 */
1056 public static final int SENSOR_REFERENCE_ILLUMINANT1_D50 = 23;
1057
1058 /**
1059 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
1060 */
1061 public static final int SENSOR_REFERENCE_ILLUMINANT1_ISO_STUDIO_TUNGSTEN = 24;
1062
1063 //
Igor Murashkin68f40062013-09-10 12:15:54 -07001064 // Enumeration values for CameraCharacteristics#LED_AVAILABLE_LEDS
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001065 //
1066
1067 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001068 * <p>android.led.transmit control is used.</p>
Igor Murashkin68f40062013-09-10 12:15:54 -07001069 * @see CameraCharacteristics#LED_AVAILABLE_LEDS
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001070 * @hide
1071 */
1072 public static final int LED_AVAILABLE_LEDS_TRANSMIT = 0;
1073
1074 //
Igor Murashkin68f40062013-09-10 12:15:54 -07001075 // Enumeration values for CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001076 //
1077
1078 /**
Eino-Ville Talvala7c6d73f2016-01-21 13:55:11 -08001079 * <p>This camera device does not have enough capabilities to qualify as a <code>FULL</code> device or
1080 * better.</p>
1081 * <p>Only the stream configurations listed in the <code>LEGACY</code> and <code>LIMITED</code> tables in the
1082 * {@link android.hardware.camera2.CameraDevice#createCaptureSession createCaptureSession} documentation are guaranteed to be supported.</p>
1083 * <p>All <code>LIMITED</code> devices support the <code>BACKWARDS_COMPATIBLE</code> capability, indicating basic
1084 * support for color image capture. The only exception is that the device may
1085 * alternatively support only the <code>DEPTH_OUTPUT</code> capability, if it can only output depth
1086 * measurements and not color images.</p>
1087 * <p><code>LIMITED</code> devices and above require the use of {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}
1088 * to lock exposure metering (and calculate flash power, for cameras with flash) before
1089 * capturing a high-quality still image.</p>
1090 * <p>A <code>LIMITED</code> device that only lists the <code>BACKWARDS_COMPATIBLE</code> capability is only
1091 * required to support full-automatic operation and post-processing (<code>OFF</code> is not
1092 * supported for {@link CaptureRequest#CONTROL_AE_MODE android.control.aeMode}, {@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}, or
1093 * {@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode})</p>
1094 * <p>Additional capabilities may optionally be supported by a <code>LIMITED</code>-level device, and
1095 * can be checked for in {@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities}.</p>
1096 *
1097 * @see CaptureRequest#CONTROL_AE_MODE
1098 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
1099 * @see CaptureRequest#CONTROL_AF_MODE
1100 * @see CaptureRequest#CONTROL_AWB_MODE
1101 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
Igor Murashkin68f40062013-09-10 12:15:54 -07001102 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001103 */
1104 public static final int INFO_SUPPORTED_HARDWARE_LEVEL_LIMITED = 0;
1105
1106 /**
Ruben Brunk4a61a862014-07-01 16:00:26 -07001107 * <p>This camera device is capable of supporting advanced imaging applications.</p>
Eino-Ville Talvala7c6d73f2016-01-21 13:55:11 -08001108 * <p>The stream configurations listed in the <code>FULL</code>, <code>LEGACY</code> and <code>LIMITED</code> tables in the
1109 * {@link android.hardware.camera2.CameraDevice#createCaptureSession createCaptureSession} documentation are guaranteed to be supported.</p>
1110 * <p>A <code>FULL</code> device will support below capabilities:</p>
1111 * <ul>
1112 * <li><code>BURST_CAPTURE</code> capability ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} contains
1113 * <code>BURST_CAPTURE</code>)</li>
1114 * <li>Per frame control ({@link CameraCharacteristics#SYNC_MAX_LATENCY android.sync.maxLatency} <code>==</code> PER_FRAME_CONTROL)</li>
1115 * <li>Manual sensor control ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} contains <code>MANUAL_SENSOR</code>)</li>
1116 * <li>Manual post-processing control ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} contains
1117 * <code>MANUAL_POST_PROCESSING</code>)</li>
1118 * <li>The required exposure time range defined in {@link CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE android.sensor.info.exposureTimeRange}</li>
1119 * <li>The required maxFrameDuration defined in {@link CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION android.sensor.info.maxFrameDuration}</li>
1120 * </ul>
1121 * <p>Note:
1122 * Pre-API level 23, FULL devices also supported arbitrary cropping region
1123 * ({@link CameraCharacteristics#SCALER_CROPPING_TYPE android.scaler.croppingType} <code>== FREEFORM</code>); this requirement was relaxed in API level
1124 * 23, and <code>FULL</code> devices may only support <code>CENTERED</code> cropping.</p>
1125 *
1126 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
1127 * @see CameraCharacteristics#SCALER_CROPPING_TYPE
1128 * @see CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE
1129 * @see CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION
1130 * @see CameraCharacteristics#SYNC_MAX_LATENCY
Igor Murashkin68f40062013-09-10 12:15:54 -07001131 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001132 */
1133 public static final int INFO_SUPPORTED_HARDWARE_LEVEL_FULL = 1;
1134
Ruben Brunk4a61a862014-07-01 16:00:26 -07001135 /**
1136 * <p>This camera device is running in backward compatibility mode.</p>
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -08001137 * <p>Only the stream configurations listed in the <code>LEGACY</code> table in the {@link android.hardware.camera2.CameraDevice#createCaptureSession createCaptureSession} documentation are supported.</p>
Eino-Ville Talvala7c6d73f2016-01-21 13:55:11 -08001138 * <p>A <code>LEGACY</code> device does not support per-frame control, manual sensor control, manual
1139 * post-processing, arbitrary cropping regions, and has relaxed performance constraints.
1140 * No additional capabilities beyond <code>BACKWARD_COMPATIBLE</code> will ever be listed by a
1141 * <code>LEGACY</code> device in {@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities}.</p>
1142 * <p>In addition, the {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger} is not functional on <code>LEGACY</code>
1143 * devices. Instead, every request that includes a JPEG-format output target is treated
1144 * as triggering a still capture, internally executing a precapture trigger. This may
1145 * fire the flash for flash power metering during precapture, and then fire the flash
1146 * for the final capture, if a flash is available on the device and the AE mode is set to
1147 * enable the flash.</p>
1148 *
1149 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
1150 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
Ruben Brunk4a61a862014-07-01 16:00:26 -07001151 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
1152 */
1153 public static final int INFO_SUPPORTED_HARDWARE_LEVEL_LEGACY = 2;
1154
Eino-Ville Talvala7c6d73f2016-01-21 13:55:11 -08001155 /**
1156 * <p>This camera device is capable of YUV reprocessing and RAW data capture, in addition to
1157 * FULL-level capabilities.</p>
1158 * <p>The stream configurations listed in the <code>LEVEL_3</code>, <code>RAW</code>, <code>FULL</code>, <code>LEGACY</code> and
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -08001159 * <code>LIMITED</code> tables in the {@link android.hardware.camera2.CameraDevice#createCaptureSession createCaptureSession} documentation are guaranteed to be supported.</p>
Eino-Ville Talvala7c6d73f2016-01-21 13:55:11 -08001160 * <p>The following additional capabilities are guaranteed to be supported:</p>
1161 * <ul>
1162 * <li><code>YUV_REPROCESSING</code> capability ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} contains
1163 * <code>YUV_REPROCESSING</code>)</li>
1164 * <li><code>RAW</code> capability ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} contains
1165 * <code>RAW</code>)</li>
1166 * </ul>
1167 *
1168 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
1169 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
1170 */
1171 public static final int INFO_SUPPORTED_HARDWARE_LEVEL_3 = 3;
1172
Yin-Chia Yeh43cea5a2018-01-19 11:38:12 -08001173 /**
1174 * <p>This camera device is backed by an external camera connected to this Android device.</p>
1175 * <p>The device has capability identical to a LIMITED level device, with the following
1176 * exceptions:</p>
1177 * <ul>
1178 * <li>The device may not report lens/sensor related information such as<ul>
1179 * <li>{@link CaptureRequest#LENS_FOCAL_LENGTH android.lens.focalLength}</li>
1180 * <li>{@link CameraCharacteristics#LENS_INFO_HYPERFOCAL_DISTANCE android.lens.info.hyperfocalDistance}</li>
1181 * <li>{@link CameraCharacteristics#SENSOR_INFO_PHYSICAL_SIZE android.sensor.info.physicalSize}</li>
1182 * <li>{@link CameraCharacteristics#SENSOR_INFO_WHITE_LEVEL android.sensor.info.whiteLevel}</li>
1183 * <li>{@link CameraCharacteristics#SENSOR_BLACK_LEVEL_PATTERN android.sensor.blackLevelPattern}</li>
1184 * <li>{@link CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT android.sensor.info.colorFilterArrangement}</li>
1185 * <li>{@link CaptureResult#SENSOR_ROLLING_SHUTTER_SKEW android.sensor.rollingShutterSkew}</li>
1186 * </ul>
1187 * </li>
1188 * <li>The device will report 0 for {@link CameraCharacteristics#SENSOR_ORIENTATION android.sensor.orientation}</li>
1189 * <li>The device has less guarantee on stable framerate, as the framerate partly depends
1190 * on the external camera being used.</li>
1191 * </ul>
1192 *
1193 * @see CaptureRequest#LENS_FOCAL_LENGTH
1194 * @see CameraCharacteristics#LENS_INFO_HYPERFOCAL_DISTANCE
1195 * @see CameraCharacteristics#SENSOR_BLACK_LEVEL_PATTERN
1196 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT
1197 * @see CameraCharacteristics#SENSOR_INFO_PHYSICAL_SIZE
1198 * @see CameraCharacteristics#SENSOR_INFO_WHITE_LEVEL
1199 * @see CameraCharacteristics#SENSOR_ORIENTATION
1200 * @see CaptureResult#SENSOR_ROLLING_SHUTTER_SKEW
1201 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
1202 */
1203 public static final int INFO_SUPPORTED_HARDWARE_LEVEL_EXTERNAL = 4;
1204
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001205 //
Igor Murashkin3865a842014-01-17 18:18:39 -08001206 // Enumeration values for CameraCharacteristics#SYNC_MAX_LATENCY
1207 //
1208
1209 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001210 * <p>Every frame has the requests immediately applied.</p>
Igor Murashkin3865a842014-01-17 18:18:39 -08001211 * <p>Changing controls over multiple requests one after another will
1212 * produce results that have those controls applied atomically
1213 * each frame.</p>
1214 * <p>All FULL capability devices will have this as their maxLatency.</p>
1215 * @see CameraCharacteristics#SYNC_MAX_LATENCY
1216 */
1217 public static final int SYNC_MAX_LATENCY_PER_FRAME_CONTROL = 0;
1218
1219 /**
1220 * <p>Each new frame has some subset (potentially the entire set)
1221 * of the past requests applied to the camera settings.</p>
1222 * <p>By submitting a series of identical requests, the camera device
1223 * will eventually have the camera settings applied, but it is
1224 * unknown when that exact point will be.</p>
Igor Murashkinbdf366c2014-07-25 16:54:20 -07001225 * <p>All LEGACY capability devices will have this as their maxLatency.</p>
Igor Murashkin3865a842014-01-17 18:18:39 -08001226 * @see CameraCharacteristics#SYNC_MAX_LATENCY
1227 */
1228 public static final int SYNC_MAX_LATENCY_UNKNOWN = -1;
1229
1230 //
Shuzhen Wang23d29382017-11-26 17:24:56 -08001231 // Enumeration values for CameraCharacteristics#LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE
1232 //
1233
1234 /**
1235 * <p>A software mechanism is used to synchronize between the physical cameras. As a result,
1236 * the timestamp of an image from a physical stream is only an approximation of the
1237 * image sensor start-of-exposure time.</p>
1238 * @see CameraCharacteristics#LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE
1239 */
1240 public static final int LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE_APPROXIMATE = 0;
1241
1242 /**
1243 * <p>The camera device supports frame timestamp synchronization at the hardware level,
1244 * and the timestamp of a physical stream image accurately reflects its
1245 * start-of-exposure time.</p>
1246 * @see CameraCharacteristics#LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE
1247 */
1248 public static final int LOGICAL_MULTI_CAMERA_SENSOR_SYNC_TYPE_CALIBRATED = 1;
1249
1250 //
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001251 // Enumeration values for CaptureRequest#COLOR_CORRECTION_MODE
1252 //
1253
1254 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001255 * <p>Use the {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} matrix
Igor Murashkin7d2a5c52014-01-17 15:07:52 -08001256 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} to do color conversion.</p>
1257 * <p>All advanced white balance adjustments (not specified
1258 * by our white balance pipeline) must be disabled.</p>
1259 * <p>If AWB is enabled with <code>{@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode} != OFF</code>, then
1260 * TRANSFORM_MATRIX is ignored. The camera device will override
1261 * this value to either FAST or HIGH_QUALITY.</p>
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001262 *
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001263 * @see CaptureRequest#COLOR_CORRECTION_GAINS
Eino-Ville Talvala265b34c2014-01-16 16:18:52 -08001264 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Igor Murashkin7d2a5c52014-01-17 15:07:52 -08001265 * @see CaptureRequest#CONTROL_AWB_MODE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001266 * @see CaptureRequest#COLOR_CORRECTION_MODE
1267 */
1268 public static final int COLOR_CORRECTION_MODE_TRANSFORM_MATRIX = 0;
1269
1270 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001271 * <p>Color correction processing must not slow down
1272 * capture rate relative to sensor raw output.</p>
Igor Murashkin7d2a5c52014-01-17 15:07:52 -08001273 * <p>Advanced white balance adjustments above and beyond
1274 * the specified white balance pipeline may be applied.</p>
1275 * <p>If AWB is enabled with <code>{@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode} != OFF</code>, then
1276 * the camera device uses the last frame's AWB values
1277 * (or defaults if AWB has never been run).</p>
1278 *
1279 * @see CaptureRequest#CONTROL_AWB_MODE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001280 * @see CaptureRequest#COLOR_CORRECTION_MODE
1281 */
1282 public static final int COLOR_CORRECTION_MODE_FAST = 1;
1283
1284 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001285 * <p>Color correction processing operates at improved
Yin-Chia Yehfba08dd2015-04-02 14:05:14 -07001286 * quality but the capture rate might be reduced (relative to sensor
1287 * raw output rate)</p>
Igor Murashkin7d2a5c52014-01-17 15:07:52 -08001288 * <p>Advanced white balance adjustments above and beyond
1289 * the specified white balance pipeline may be applied.</p>
1290 * <p>If AWB is enabled with <code>{@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode} != OFF</code>, then
1291 * the camera device uses the last frame's AWB values
1292 * (or defaults if AWB has never been run).</p>
1293 *
1294 * @see CaptureRequest#CONTROL_AWB_MODE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001295 * @see CaptureRequest#COLOR_CORRECTION_MODE
1296 */
1297 public static final int COLOR_CORRECTION_MODE_HIGH_QUALITY = 2;
1298
1299 //
Zhijun He9e4e4392014-08-18 11:12:32 -07001300 // Enumeration values for CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE
Zhijun Hea05e59d2014-07-08 18:27:47 -07001301 //
1302
1303 /**
1304 * <p>No aberration correction is applied.</p>
Zhijun He9e4e4392014-08-18 11:12:32 -07001305 * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE
Zhijun Hea05e59d2014-07-08 18:27:47 -07001306 */
Zhijun He9e4e4392014-08-18 11:12:32 -07001307 public static final int COLOR_CORRECTION_ABERRATION_MODE_OFF = 0;
Zhijun Hea05e59d2014-07-08 18:27:47 -07001308
1309 /**
1310 * <p>Aberration correction will not slow down capture rate
1311 * relative to sensor raw output.</p>
Zhijun He9e4e4392014-08-18 11:12:32 -07001312 * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE
Zhijun Hea05e59d2014-07-08 18:27:47 -07001313 */
Zhijun He9e4e4392014-08-18 11:12:32 -07001314 public static final int COLOR_CORRECTION_ABERRATION_MODE_FAST = 1;
Zhijun Hea05e59d2014-07-08 18:27:47 -07001315
1316 /**
Yin-Chia Yehfba08dd2015-04-02 14:05:14 -07001317 * <p>Aberration correction operates at improved quality but the capture rate might be
1318 * reduced (relative to sensor raw output rate)</p>
Zhijun He9e4e4392014-08-18 11:12:32 -07001319 * @see CaptureRequest#COLOR_CORRECTION_ABERRATION_MODE
Zhijun Hea05e59d2014-07-08 18:27:47 -07001320 */
Zhijun He9e4e4392014-08-18 11:12:32 -07001321 public static final int COLOR_CORRECTION_ABERRATION_MODE_HIGH_QUALITY = 2;
Zhijun Hea05e59d2014-07-08 18:27:47 -07001322
1323 //
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001324 // Enumeration values for CaptureRequest#CONTROL_AE_ANTIBANDING_MODE
1325 //
1326
1327 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001328 * <p>The camera device will not adjust exposure duration to
1329 * avoid banding problems.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001330 * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE
1331 */
1332 public static final int CONTROL_AE_ANTIBANDING_MODE_OFF = 0;
1333
1334 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001335 * <p>The camera device will adjust exposure duration to
1336 * avoid banding problems with 50Hz illumination sources.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001337 * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE
1338 */
1339 public static final int CONTROL_AE_ANTIBANDING_MODE_50HZ = 1;
1340
1341 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001342 * <p>The camera device will adjust exposure duration to
1343 * avoid banding problems with 60Hz illumination
1344 * sources.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001345 * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE
1346 */
1347 public static final int CONTROL_AE_ANTIBANDING_MODE_60HZ = 2;
1348
1349 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001350 * <p>The camera device will automatically adapt its
1351 * antibanding routine to the current illumination
Yin-Chia Yeh7b2cae62014-11-25 11:54:18 -08001352 * condition. This is the default mode if AUTO is
1353 * available on given camera device.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001354 * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE
1355 */
1356 public static final int CONTROL_AE_ANTIBANDING_MODE_AUTO = 3;
1357
1358 //
1359 // Enumeration values for CaptureRequest#CONTROL_AE_MODE
1360 //
1361
1362 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001363 * <p>The camera device's autoexposure routine is disabled.</p>
1364 * <p>The application-selected {@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime},
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001365 * {@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity} and
1366 * {@link CaptureRequest#SENSOR_FRAME_DURATION android.sensor.frameDuration} are used by the camera
1367 * device, along with android.flash.* fields, if there's
1368 * a flash unit for this camera device.</p>
Yin-Chia Yeh7144b5d2014-11-12 11:42:49 -08001369 * <p>Note that auto-white balance (AWB) and auto-focus (AF)
1370 * behavior is device dependent when AE is in OFF mode.
1371 * To have consistent behavior across different devices,
1372 * it is recommended to either set AWB and AF to OFF mode
1373 * or lock AWB and AF before setting AE to OFF.
1374 * See {@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode}, {@link CaptureRequest#CONTROL_AF_MODE android.control.afMode},
1375 * {@link CaptureRequest#CONTROL_AWB_LOCK android.control.awbLock}, and {@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}
1376 * for more details.</p>
Igor Murashkin4b8cd6b2014-10-02 16:00:52 -07001377 * <p>LEGACY devices do not support the OFF mode and will
1378 * override attempts to use this value to ON.</p>
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001379 *
Yin-Chia Yeh7144b5d2014-11-12 11:42:49 -08001380 * @see CaptureRequest#CONTROL_AF_MODE
1381 * @see CaptureRequest#CONTROL_AF_TRIGGER
1382 * @see CaptureRequest#CONTROL_AWB_LOCK
1383 * @see CaptureRequest#CONTROL_AWB_MODE
Zhijun He5f2a47f2014-01-16 15:44:41 -08001384 * @see CaptureRequest#SENSOR_EXPOSURE_TIME
Eino-Ville Talvala265b34c2014-01-16 16:18:52 -08001385 * @see CaptureRequest#SENSOR_FRAME_DURATION
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001386 * @see CaptureRequest#SENSOR_SENSITIVITY
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001387 * @see CaptureRequest#CONTROL_AE_MODE
1388 */
1389 public static final int CONTROL_AE_MODE_OFF = 0;
1390
1391 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001392 * <p>The camera device's autoexposure routine is active,
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001393 * with no flash control.</p>
1394 * <p>The application's values for
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001395 * {@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime},
1396 * {@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}, and
1397 * {@link CaptureRequest#SENSOR_FRAME_DURATION android.sensor.frameDuration} are ignored. The
1398 * application has control over the various
1399 * android.flash.* fields.</p>
1400 *
Zhijun He5f2a47f2014-01-16 15:44:41 -08001401 * @see CaptureRequest#SENSOR_EXPOSURE_TIME
Eino-Ville Talvala265b34c2014-01-16 16:18:52 -08001402 * @see CaptureRequest#SENSOR_FRAME_DURATION
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001403 * @see CaptureRequest#SENSOR_SENSITIVITY
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001404 * @see CaptureRequest#CONTROL_AE_MODE
1405 */
1406 public static final int CONTROL_AE_MODE_ON = 1;
1407
1408 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001409 * <p>Like ON, except that the camera device also controls
1410 * the camera's flash unit, firing it in low-light
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001411 * conditions.</p>
1412 * <p>The flash may be fired during a precapture sequence
1413 * (triggered by {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}) and
1414 * may be fired for captures for which the
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001415 * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} field is set to
1416 * STILL_CAPTURE</p>
1417 *
Igor Murashkin3242f4f2014-01-15 12:27:41 -08001418 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
Zhijun He5f2a47f2014-01-16 15:44:41 -08001419 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001420 * @see CaptureRequest#CONTROL_AE_MODE
1421 */
1422 public static final int CONTROL_AE_MODE_ON_AUTO_FLASH = 2;
1423
1424 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001425 * <p>Like ON, except that the camera device also controls
1426 * the camera's flash unit, always firing it for still
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001427 * captures.</p>
1428 * <p>The flash may be fired during a precapture sequence
1429 * (triggered by {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}) and
1430 * will always be fired for captures for which the
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001431 * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} field is set to
1432 * STILL_CAPTURE</p>
1433 *
Igor Murashkin3242f4f2014-01-15 12:27:41 -08001434 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
Zhijun He5f2a47f2014-01-16 15:44:41 -08001435 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001436 * @see CaptureRequest#CONTROL_AE_MODE
1437 */
1438 public static final int CONTROL_AE_MODE_ON_ALWAYS_FLASH = 3;
1439
1440 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001441 * <p>Like ON_AUTO_FLASH, but with automatic red eye
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001442 * reduction.</p>
1443 * <p>If deemed necessary by the camera device, a red eye
1444 * reduction flash will fire during the precapture
1445 * sequence.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001446 * @see CaptureRequest#CONTROL_AE_MODE
1447 */
1448 public static final int CONTROL_AE_MODE_ON_AUTO_FLASH_REDEYE = 4;
1449
Chien-Yu Chen2cf33572018-01-11 11:35:41 -08001450 /**
1451 * <p>An external flash has been turned on.</p>
1452 * <p>It informs the camera device that an external flash has been turned on, and that
1453 * metering (and continuous focus if active) should be quickly recaculated to account
1454 * for the external flash. Otherwise, this mode acts like ON.</p>
1455 * <p>When the external flash is turned off, AE mode should be changed to one of the
1456 * other available AE modes.</p>
Chien-Yu Chenc9ca7222018-03-15 11:14:29 -07001457 * <p>If the camera device supports AE external flash mode, {@link CaptureResult#CONTROL_AE_STATE android.control.aeState} must
1458 * be FLASH_REQUIRED after the camera device finishes AE scan and it's too dark without
Chien-Yu Chen2cf33572018-01-11 11:35:41 -08001459 * flash.</p>
Chien-Yu Chenc9ca7222018-03-15 11:14:29 -07001460 *
1461 * @see CaptureResult#CONTROL_AE_STATE
Chien-Yu Chen2cf33572018-01-11 11:35:41 -08001462 * @see CaptureRequest#CONTROL_AE_MODE
1463 */
1464 public static final int CONTROL_AE_MODE_ON_EXTERNAL_FLASH = 5;
1465
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001466 //
1467 // Enumeration values for CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
1468 //
1469
1470 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001471 * <p>The trigger is idle.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001472 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
1473 */
1474 public static final int CONTROL_AE_PRECAPTURE_TRIGGER_IDLE = 0;
1475
1476 /**
Zhijun He228f4f92014-01-16 17:22:05 -08001477 * <p>The precapture metering sequence will be started
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001478 * by the camera device.</p>
1479 * <p>The exact effect of the precapture trigger depends on
1480 * the current AE mode and state.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001481 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
1482 */
1483 public static final int CONTROL_AE_PRECAPTURE_TRIGGER_START = 1;
1484
Zhijun Hefa95b042015-02-09 10:40:49 -08001485 /**
1486 * <p>The camera device will cancel any currently active or completed
1487 * precapture metering sequence, the auto-exposure routine will return to its
1488 * initial state.</p>
1489 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
1490 */
1491 public static final int CONTROL_AE_PRECAPTURE_TRIGGER_CANCEL = 2;
1492
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001493 //
1494 // Enumeration values for CaptureRequest#CONTROL_AF_MODE
1495 //
1496
1497 /**
Zhijun Hef3537422013-12-16 16:56:35 -08001498 * <p>The auto-focus routine does not control the lens;
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001499 * {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance} is controlled by the
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001500 * application.</p>
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001501 *
1502 * @see CaptureRequest#LENS_FOCUS_DISTANCE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001503 * @see CaptureRequest#CONTROL_AF_MODE
1504 */
1505 public static final int CONTROL_AF_MODE_OFF = 0;
1506
1507 /**
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -07001508 * <p>Basic automatic focus mode.</p>
1509 * <p>In this mode, the lens does not move unless
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001510 * the autofocus trigger action is called. When that trigger
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -07001511 * is activated, AF will transition to ACTIVE_SCAN, then to
Zhijun Hef3537422013-12-16 16:56:35 -08001512 * the outcome of the scan (FOCUSED or NOT_FOCUSED).</p>
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -07001513 * <p>Always supported if lens is not fixed focus.</p>
1514 * <p>Use {@link CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE android.lens.info.minimumFocusDistance} to determine if lens
1515 * is fixed-focus.</p>
Zhijun Hef3537422013-12-16 16:56:35 -08001516 * <p>Triggering AF_CANCEL resets the lens position to default,
Igor Murashkinace5bf02013-12-10 17:36:40 -08001517 * and sets the AF state to INACTIVE.</p>
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -08001518 *
1519 * @see CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001520 * @see CaptureRequest#CONTROL_AF_MODE
1521 */
1522 public static final int CONTROL_AF_MODE_AUTO = 1;
1523
1524 /**
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -07001525 * <p>Close-up focusing mode.</p>
Igor Murashkinace5bf02013-12-10 17:36:40 -08001526 * <p>In this mode, the lens does not move unless the
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -07001527 * autofocus trigger action is called. When that trigger is
1528 * activated, AF will transition to ACTIVE_SCAN, then to
1529 * the outcome of the scan (FOCUSED or NOT_FOCUSED). This
1530 * mode is optimized for focusing on objects very close to
1531 * the camera.</p>
1532 * <p>When that trigger is activated, AF will transition to
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001533 * ACTIVE_SCAN, then to the outcome of the scan (FOCUSED or
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -07001534 * NOT_FOCUSED). Triggering cancel AF resets the lens
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001535 * position to default, and sets the AF state to
Igor Murashkinace5bf02013-12-10 17:36:40 -08001536 * INACTIVE.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001537 * @see CaptureRequest#CONTROL_AF_MODE
1538 */
1539 public static final int CONTROL_AF_MODE_MACRO = 2;
1540
1541 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001542 * <p>In this mode, the AF algorithm modifies the lens
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001543 * position continually to attempt to provide a
Igor Murashkinace5bf02013-12-10 17:36:40 -08001544 * constantly-in-focus image stream.</p>
1545 * <p>The focusing behavior should be suitable for good quality
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001546 * video recording; typically this means slower focus
1547 * movement and no overshoots. When the AF trigger is not
1548 * involved, the AF algorithm should start in INACTIVE state,
1549 * and then transition into PASSIVE_SCAN and PASSIVE_FOCUSED
1550 * states as appropriate. When the AF trigger is activated,
1551 * the algorithm should immediately transition into
1552 * AF_FOCUSED or AF_NOT_FOCUSED as appropriate, and lock the
Igor Murashkinace5bf02013-12-10 17:36:40 -08001553 * lens position until a cancel AF trigger is received.</p>
1554 * <p>Once cancel is received, the algorithm should transition
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001555 * back to INACTIVE and resume passive scan. Note that this
1556 * behavior is not identical to CONTINUOUS_PICTURE, since an
1557 * ongoing PASSIVE_SCAN must immediately be
Igor Murashkinace5bf02013-12-10 17:36:40 -08001558 * canceled.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001559 * @see CaptureRequest#CONTROL_AF_MODE
1560 */
1561 public static final int CONTROL_AF_MODE_CONTINUOUS_VIDEO = 3;
1562
1563 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001564 * <p>In this mode, the AF algorithm modifies the lens
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001565 * position continually to attempt to provide a
Igor Murashkinace5bf02013-12-10 17:36:40 -08001566 * constantly-in-focus image stream.</p>
1567 * <p>The focusing behavior should be suitable for still image
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001568 * capture; typically this means focusing as fast as
1569 * possible. When the AF trigger is not involved, the AF
1570 * algorithm should start in INACTIVE state, and then
1571 * transition into PASSIVE_SCAN and PASSIVE_FOCUSED states as
1572 * appropriate as it attempts to maintain focus. When the AF
1573 * trigger is activated, the algorithm should finish its
1574 * PASSIVE_SCAN if active, and then transition into
1575 * AF_FOCUSED or AF_NOT_FOCUSED as appropriate, and lock the
Igor Murashkinace5bf02013-12-10 17:36:40 -08001576 * lens position until a cancel AF trigger is received.</p>
1577 * <p>When the AF cancel trigger is activated, the algorithm
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001578 * should transition back to INACTIVE and then act as if it
Igor Murashkinace5bf02013-12-10 17:36:40 -08001579 * has just been started.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001580 * @see CaptureRequest#CONTROL_AF_MODE
1581 */
1582 public static final int CONTROL_AF_MODE_CONTINUOUS_PICTURE = 4;
1583
1584 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001585 * <p>Extended depth of field (digital focus) mode.</p>
1586 * <p>The camera device will produce images with an extended
1587 * depth of field automatically; no special focusing
1588 * operations need to be done before taking a picture.</p>
1589 * <p>AF triggers are ignored, and the AF state will always be
Igor Murashkinace5bf02013-12-10 17:36:40 -08001590 * INACTIVE.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001591 * @see CaptureRequest#CONTROL_AF_MODE
1592 */
1593 public static final int CONTROL_AF_MODE_EDOF = 5;
1594
1595 //
1596 // Enumeration values for CaptureRequest#CONTROL_AF_TRIGGER
1597 //
1598
1599 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001600 * <p>The trigger is idle.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001601 * @see CaptureRequest#CONTROL_AF_TRIGGER
1602 */
1603 public static final int CONTROL_AF_TRIGGER_IDLE = 0;
1604
1605 /**
Zhijun He228f4f92014-01-16 17:22:05 -08001606 * <p>Autofocus will trigger now.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001607 * @see CaptureRequest#CONTROL_AF_TRIGGER
1608 */
1609 public static final int CONTROL_AF_TRIGGER_START = 1;
1610
1611 /**
Zhijun He228f4f92014-01-16 17:22:05 -08001612 * <p>Autofocus will return to its initial
1613 * state, and cancel any currently active trigger.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001614 * @see CaptureRequest#CONTROL_AF_TRIGGER
1615 */
1616 public static final int CONTROL_AF_TRIGGER_CANCEL = 2;
1617
1618 //
1619 // Enumeration values for CaptureRequest#CONTROL_AWB_MODE
1620 //
1621
1622 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001623 * <p>The camera device's auto-white balance routine is disabled.</p>
1624 * <p>The application-selected color transform matrix
Zhijun He399f05d2014-01-15 11:31:30 -08001625 * ({@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}) and gains
1626 * ({@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains}) are used by the camera
1627 * device for manual white balance control.</p>
1628 *
Zhijun He399f05d2014-01-15 11:31:30 -08001629 * @see CaptureRequest#COLOR_CORRECTION_GAINS
Eino-Ville Talvala265b34c2014-01-16 16:18:52 -08001630 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001631 * @see CaptureRequest#CONTROL_AWB_MODE
1632 */
1633 public static final int CONTROL_AWB_MODE_OFF = 0;
1634
1635 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001636 * <p>The camera device's auto-white balance routine is active.</p>
1637 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
1638 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
1639 * For devices that support the MANUAL_POST_PROCESSING capability, the
1640 * values used by the camera device for the transform and gains
1641 * will be available in the capture result for this request.</p>
Zhijun He399f05d2014-01-15 11:31:30 -08001642 *
1643 * @see CaptureRequest#COLOR_CORRECTION_GAINS
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08001644 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001645 * @see CaptureRequest#CONTROL_AWB_MODE
1646 */
1647 public static final int CONTROL_AWB_MODE_AUTO = 1;
1648
1649 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001650 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -08001651 * the camera device uses incandescent light as the assumed scene
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001652 * illumination for white balance.</p>
1653 * <p>While the exact white balance transforms are up to the
1654 * camera device, they will approximately match the CIE
1655 * standard illuminant A.</p>
1656 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
1657 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
1658 * For devices that support the MANUAL_POST_PROCESSING capability, the
1659 * values used by the camera device for the transform and gains
1660 * will be available in the capture result for this request.</p>
1661 *
1662 * @see CaptureRequest#COLOR_CORRECTION_GAINS
1663 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001664 * @see CaptureRequest#CONTROL_AWB_MODE
1665 */
1666 public static final int CONTROL_AWB_MODE_INCANDESCENT = 2;
1667
1668 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001669 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -08001670 * the camera device uses fluorescent light as the assumed scene
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001671 * illumination for white balance.</p>
1672 * <p>While the exact white balance transforms are up to the
1673 * camera device, they will approximately match the CIE
1674 * standard illuminant F2.</p>
1675 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
1676 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
1677 * For devices that support the MANUAL_POST_PROCESSING capability, the
1678 * values used by the camera device for the transform and gains
1679 * will be available in the capture result for this request.</p>
1680 *
1681 * @see CaptureRequest#COLOR_CORRECTION_GAINS
1682 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001683 * @see CaptureRequest#CONTROL_AWB_MODE
1684 */
1685 public static final int CONTROL_AWB_MODE_FLUORESCENT = 3;
1686
1687 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001688 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -08001689 * the camera device uses warm fluorescent light as the assumed scene
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001690 * illumination for white balance.</p>
1691 * <p>While the exact white balance transforms are up to the
1692 * camera device, they will approximately match the CIE
1693 * standard illuminant F4.</p>
1694 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
1695 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
1696 * For devices that support the MANUAL_POST_PROCESSING capability, the
1697 * values used by the camera device for the transform and gains
1698 * will be available in the capture result for this request.</p>
1699 *
1700 * @see CaptureRequest#COLOR_CORRECTION_GAINS
1701 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001702 * @see CaptureRequest#CONTROL_AWB_MODE
1703 */
1704 public static final int CONTROL_AWB_MODE_WARM_FLUORESCENT = 4;
1705
1706 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001707 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -08001708 * the camera device uses daylight light as the assumed scene
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001709 * illumination for white balance.</p>
1710 * <p>While the exact white balance transforms are up to the
1711 * camera device, they will approximately match the CIE
1712 * standard illuminant D65.</p>
1713 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
1714 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
1715 * For devices that support the MANUAL_POST_PROCESSING capability, the
1716 * values used by the camera device for the transform and gains
1717 * will be available in the capture result for this request.</p>
1718 *
1719 * @see CaptureRequest#COLOR_CORRECTION_GAINS
1720 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001721 * @see CaptureRequest#CONTROL_AWB_MODE
1722 */
1723 public static final int CONTROL_AWB_MODE_DAYLIGHT = 5;
1724
1725 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001726 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -08001727 * the camera device uses cloudy daylight light as the assumed scene
1728 * illumination for white balance.</p>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001729 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
1730 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
1731 * For devices that support the MANUAL_POST_PROCESSING capability, the
1732 * values used by the camera device for the transform and gains
1733 * will be available in the capture result for this request.</p>
1734 *
1735 * @see CaptureRequest#COLOR_CORRECTION_GAINS
1736 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001737 * @see CaptureRequest#CONTROL_AWB_MODE
1738 */
1739 public static final int CONTROL_AWB_MODE_CLOUDY_DAYLIGHT = 6;
1740
1741 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001742 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -08001743 * the camera device uses twilight light as the assumed scene
1744 * illumination for white balance.</p>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001745 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
1746 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
1747 * For devices that support the MANUAL_POST_PROCESSING capability, the
1748 * values used by the camera device for the transform and gains
1749 * will be available in the capture result for this request.</p>
1750 *
1751 * @see CaptureRequest#COLOR_CORRECTION_GAINS
1752 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001753 * @see CaptureRequest#CONTROL_AWB_MODE
1754 */
1755 public static final int CONTROL_AWB_MODE_TWILIGHT = 7;
1756
1757 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001758 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -08001759 * the camera device uses shade light as the assumed scene
1760 * illumination for white balance.</p>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001761 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
1762 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
1763 * For devices that support the MANUAL_POST_PROCESSING capability, the
1764 * values used by the camera device for the transform and gains
1765 * will be available in the capture result for this request.</p>
1766 *
1767 * @see CaptureRequest#COLOR_CORRECTION_GAINS
1768 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001769 * @see CaptureRequest#CONTROL_AWB_MODE
1770 */
1771 public static final int CONTROL_AWB_MODE_SHADE = 8;
1772
1773 //
1774 // Enumeration values for CaptureRequest#CONTROL_CAPTURE_INTENT
1775 //
1776
1777 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001778 * <p>The goal of this request doesn't fall into the other
1779 * categories. The camera device will default to preview-like
Igor Murashkinace5bf02013-12-10 17:36:40 -08001780 * behavior.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001781 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1782 */
1783 public static final int CONTROL_CAPTURE_INTENT_CUSTOM = 0;
1784
1785 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001786 * <p>This request is for a preview-like use case.</p>
1787 * <p>The precapture trigger may be used to start off a metering
1788 * w/flash sequence.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001789 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1790 */
1791 public static final int CONTROL_CAPTURE_INTENT_PREVIEW = 1;
1792
1793 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001794 * <p>This request is for a still capture-type
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001795 * use case.</p>
1796 * <p>If the flash unit is under automatic control, it may fire as needed.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001797 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1798 */
1799 public static final int CONTROL_CAPTURE_INTENT_STILL_CAPTURE = 2;
1800
1801 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001802 * <p>This request is for a video recording
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001803 * use case.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001804 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1805 */
1806 public static final int CONTROL_CAPTURE_INTENT_VIDEO_RECORD = 3;
1807
1808 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001809 * <p>This request is for a video snapshot (still
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001810 * image while recording video) use case.</p>
1811 * <p>The camera device should take the highest-quality image
1812 * possible (given the other settings) without disrupting the
Eino-Ville Talvala126a7462014-11-04 16:31:01 -08001813 * frame rate of video recording. </p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001814 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1815 */
1816 public static final int CONTROL_CAPTURE_INTENT_VIDEO_SNAPSHOT = 4;
1817
1818 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001819 * <p>This request is for a ZSL usecase; the
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001820 * application will stream full-resolution images and
1821 * reprocess one or several later for a final
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001822 * capture.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001823 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1824 */
1825 public static final int CONTROL_CAPTURE_INTENT_ZERO_SHUTTER_LAG = 5;
1826
Zhijun Hee30adb72014-04-09 19:04:31 -07001827 /**
1828 * <p>This request is for manual capture use case where
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001829 * the applications want to directly control the capture parameters.</p>
1830 * <p>For example, the application may wish to manually control
1831 * {@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}, {@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}, etc.</p>
Zhijun Hee30adb72014-04-09 19:04:31 -07001832 *
1833 * @see CaptureRequest#SENSOR_EXPOSURE_TIME
1834 * @see CaptureRequest#SENSOR_SENSITIVITY
1835 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1836 */
1837 public static final int CONTROL_CAPTURE_INTENT_MANUAL = 6;
1838
Eino-Ville Talvalaec99efa2017-11-29 15:35:42 -08001839 /**
1840 * <p>This request is for a motion tracking use case, where
1841 * the application will use camera and inertial sensor data to
1842 * locate and track objects in the world.</p>
1843 * <p>The camera device auto-exposure routine will limit the exposure time
1844 * of the camera to no more than 20 milliseconds, to minimize motion blur.</p>
1845 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1846 */
1847 public static final int CONTROL_CAPTURE_INTENT_MOTION_TRACKING = 7;
1848
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001849 //
1850 // Enumeration values for CaptureRequest#CONTROL_EFFECT_MODE
1851 //
1852
1853 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001854 * <p>No color effect will be applied.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001855 * @see CaptureRequest#CONTROL_EFFECT_MODE
1856 */
1857 public static final int CONTROL_EFFECT_MODE_OFF = 0;
1858
1859 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001860 * <p>A "monocolor" effect where the image is mapped into
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001861 * a single color.</p>
1862 * <p>This will typically be grayscale.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001863 * @see CaptureRequest#CONTROL_EFFECT_MODE
1864 */
1865 public static final int CONTROL_EFFECT_MODE_MONO = 1;
1866
1867 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001868 * <p>A "photo-negative" effect where the image's colors
1869 * are inverted.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001870 * @see CaptureRequest#CONTROL_EFFECT_MODE
1871 */
1872 public static final int CONTROL_EFFECT_MODE_NEGATIVE = 2;
1873
1874 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001875 * <p>A "solarisation" effect (Sabattier effect) where the
1876 * image is wholly or partially reversed in
1877 * tone.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001878 * @see CaptureRequest#CONTROL_EFFECT_MODE
1879 */
1880 public static final int CONTROL_EFFECT_MODE_SOLARIZE = 3;
1881
1882 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001883 * <p>A "sepia" effect where the image is mapped into warm
1884 * gray, red, and brown tones.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001885 * @see CaptureRequest#CONTROL_EFFECT_MODE
1886 */
1887 public static final int CONTROL_EFFECT_MODE_SEPIA = 4;
1888
1889 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001890 * <p>A "posterization" effect where the image uses
1891 * discrete regions of tone rather than a continuous
1892 * gradient of tones.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001893 * @see CaptureRequest#CONTROL_EFFECT_MODE
1894 */
1895 public static final int CONTROL_EFFECT_MODE_POSTERIZE = 5;
1896
1897 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001898 * <p>A "whiteboard" effect where the image is typically displayed
1899 * as regions of white, with black or grey details.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001900 * @see CaptureRequest#CONTROL_EFFECT_MODE
1901 */
1902 public static final int CONTROL_EFFECT_MODE_WHITEBOARD = 6;
1903
1904 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001905 * <p>A "blackboard" effect where the image is typically displayed
1906 * as regions of black, with white or grey details.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001907 * @see CaptureRequest#CONTROL_EFFECT_MODE
1908 */
1909 public static final int CONTROL_EFFECT_MODE_BLACKBOARD = 7;
1910
1911 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001912 * <p>An "aqua" effect where a blue hue is added to the image.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001913 * @see CaptureRequest#CONTROL_EFFECT_MODE
1914 */
1915 public static final int CONTROL_EFFECT_MODE_AQUA = 8;
1916
1917 //
1918 // Enumeration values for CaptureRequest#CONTROL_MODE
1919 //
1920
1921 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001922 * <p>Full application control of pipeline.</p>
1923 * <p>All control by the device's metering and focusing (3A)
1924 * routines is disabled, and no other settings in
1925 * android.control.* have any effect, except that
1926 * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} may be used by the camera
1927 * device to select post-processing values for processing
1928 * blocks that do not allow for manual control, or are not
1929 * exposed by the camera API.</p>
1930 * <p>However, the camera device's 3A routines may continue to
1931 * collect statistics and update their internal state so that
1932 * when control is switched to AUTO mode, good control values
1933 * can be immediately applied.</p>
1934 *
1935 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001936 * @see CaptureRequest#CONTROL_MODE
1937 */
1938 public static final int CONTROL_MODE_OFF = 0;
1939
1940 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001941 * <p>Use settings for each individual 3A routine.</p>
1942 * <p>Manual control of capture parameters is disabled. All
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001943 * controls in android.control.* besides sceneMode take
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001944 * effect.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001945 * @see CaptureRequest#CONTROL_MODE
1946 */
1947 public static final int CONTROL_MODE_AUTO = 1;
1948
1949 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001950 * <p>Use a specific scene mode.</p>
1951 * <p>Enabling this disables control.aeMode, control.awbMode and
1952 * control.afMode controls; the camera device will ignore
1953 * those settings while USE_SCENE_MODE is active (except for
Zhijun Heee2ebde2015-06-16 19:58:11 -07001954 * FACE_PRIORITY scene mode). Other control entries are still active.
1955 * This setting can only be used if scene mode is supported (i.e.
1956 * {@link CameraCharacteristics#CONTROL_AVAILABLE_SCENE_MODES android.control.availableSceneModes}
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001957 * contain some modes other than DISABLED).</p>
Zhijun Hea4866242014-03-27 23:51:34 -07001958 *
1959 * @see CameraCharacteristics#CONTROL_AVAILABLE_SCENE_MODES
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001960 * @see CaptureRequest#CONTROL_MODE
1961 */
1962 public static final int CONTROL_MODE_USE_SCENE_MODE = 2;
1963
Zhijun He2d5e8972014-02-07 16:13:46 -08001964 /**
1965 * <p>Same as OFF mode, except that this capture will not be
1966 * used by camera device background auto-exposure, auto-white balance and
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001967 * auto-focus algorithms (3A) to update their statistics.</p>
1968 * <p>Specifically, the 3A routines are locked to the last
1969 * values set from a request with AUTO, OFF, or
1970 * USE_SCENE_MODE, and any statistics or state updates
1971 * collected from manual captures with OFF_KEEP_STATE will be
1972 * discarded by the camera device.</p>
Zhijun He2d5e8972014-02-07 16:13:46 -08001973 * @see CaptureRequest#CONTROL_MODE
1974 */
1975 public static final int CONTROL_MODE_OFF_KEEP_STATE = 3;
1976
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001977 //
1978 // Enumeration values for CaptureRequest#CONTROL_SCENE_MODE
1979 //
1980
1981 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001982 * <p>Indicates that no scene modes are set for a given capture request.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001983 * @see CaptureRequest#CONTROL_SCENE_MODE
1984 */
Ruben Brunke6679362014-01-17 17:05:54 -08001985 public static final int CONTROL_SCENE_MODE_DISABLED = 0;
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001986
1987 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001988 * <p>If face detection support exists, use face
1989 * detection data for auto-focus, auto-white balance, and
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001990 * auto-exposure routines.</p>
1991 * <p>If face detection statistics are disabled
1992 * (i.e. {@link CaptureRequest#STATISTICS_FACE_DETECT_MODE android.statistics.faceDetectMode} is set to OFF),
Ruben Brunke6679362014-01-17 17:05:54 -08001993 * this should still operate correctly (but will not return
1994 * face detection statistics to the framework).</p>
1995 * <p>Unlike the other scene modes, {@link CaptureRequest#CONTROL_AE_MODE android.control.aeMode},
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08001996 * {@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode}, and {@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}
Ruben Brunke6679362014-01-17 17:05:54 -08001997 * remain active when FACE_PRIORITY is set.</p>
1998 *
1999 * @see CaptureRequest#CONTROL_AE_MODE
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08002000 * @see CaptureRequest#CONTROL_AF_MODE
Ruben Brunke6679362014-01-17 17:05:54 -08002001 * @see CaptureRequest#CONTROL_AWB_MODE
2002 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002003 * @see CaptureRequest#CONTROL_SCENE_MODE
2004 */
2005 public static final int CONTROL_SCENE_MODE_FACE_PRIORITY = 1;
2006
2007 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002008 * <p>Optimized for photos of quickly moving objects.</p>
2009 * <p>Similar to SPORTS.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002010 * @see CaptureRequest#CONTROL_SCENE_MODE
2011 */
2012 public static final int CONTROL_SCENE_MODE_ACTION = 2;
2013
2014 /**
Ruben Brunke6679362014-01-17 17:05:54 -08002015 * <p>Optimized for still photos of people.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002016 * @see CaptureRequest#CONTROL_SCENE_MODE
2017 */
2018 public static final int CONTROL_SCENE_MODE_PORTRAIT = 3;
2019
2020 /**
Ruben Brunke6679362014-01-17 17:05:54 -08002021 * <p>Optimized for photos of distant macroscopic objects.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002022 * @see CaptureRequest#CONTROL_SCENE_MODE
2023 */
2024 public static final int CONTROL_SCENE_MODE_LANDSCAPE = 4;
2025
2026 /**
Ruben Brunke6679362014-01-17 17:05:54 -08002027 * <p>Optimized for low-light settings.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002028 * @see CaptureRequest#CONTROL_SCENE_MODE
2029 */
2030 public static final int CONTROL_SCENE_MODE_NIGHT = 5;
2031
2032 /**
Ruben Brunke6679362014-01-17 17:05:54 -08002033 * <p>Optimized for still photos of people in low-light
2034 * settings.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002035 * @see CaptureRequest#CONTROL_SCENE_MODE
2036 */
2037 public static final int CONTROL_SCENE_MODE_NIGHT_PORTRAIT = 6;
2038
2039 /**
Ruben Brunke6679362014-01-17 17:05:54 -08002040 * <p>Optimized for dim, indoor settings where flash must
2041 * remain off.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002042 * @see CaptureRequest#CONTROL_SCENE_MODE
2043 */
2044 public static final int CONTROL_SCENE_MODE_THEATRE = 7;
2045
2046 /**
Ruben Brunke6679362014-01-17 17:05:54 -08002047 * <p>Optimized for bright, outdoor beach settings.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002048 * @see CaptureRequest#CONTROL_SCENE_MODE
2049 */
2050 public static final int CONTROL_SCENE_MODE_BEACH = 8;
2051
2052 /**
Ruben Brunke6679362014-01-17 17:05:54 -08002053 * <p>Optimized for bright, outdoor settings containing snow.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002054 * @see CaptureRequest#CONTROL_SCENE_MODE
2055 */
2056 public static final int CONTROL_SCENE_MODE_SNOW = 9;
2057
2058 /**
Ruben Brunke6679362014-01-17 17:05:54 -08002059 * <p>Optimized for scenes of the setting sun.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002060 * @see CaptureRequest#CONTROL_SCENE_MODE
2061 */
2062 public static final int CONTROL_SCENE_MODE_SUNSET = 10;
2063
2064 /**
Ruben Brunke6679362014-01-17 17:05:54 -08002065 * <p>Optimized to avoid blurry photos due to small amounts of
2066 * device motion (for example: due to hand shake).</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002067 * @see CaptureRequest#CONTROL_SCENE_MODE
2068 */
2069 public static final int CONTROL_SCENE_MODE_STEADYPHOTO = 11;
2070
2071 /**
Ruben Brunke6679362014-01-17 17:05:54 -08002072 * <p>Optimized for nighttime photos of fireworks.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002073 * @see CaptureRequest#CONTROL_SCENE_MODE
2074 */
2075 public static final int CONTROL_SCENE_MODE_FIREWORKS = 12;
2076
2077 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002078 * <p>Optimized for photos of quickly moving people.</p>
2079 * <p>Similar to ACTION.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002080 * @see CaptureRequest#CONTROL_SCENE_MODE
2081 */
2082 public static final int CONTROL_SCENE_MODE_SPORTS = 13;
2083
2084 /**
Ruben Brunke6679362014-01-17 17:05:54 -08002085 * <p>Optimized for dim, indoor settings with multiple moving
2086 * people.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002087 * @see CaptureRequest#CONTROL_SCENE_MODE
2088 */
2089 public static final int CONTROL_SCENE_MODE_PARTY = 14;
2090
2091 /**
Ruben Brunke6679362014-01-17 17:05:54 -08002092 * <p>Optimized for dim settings where the main light source
2093 * is a flame.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002094 * @see CaptureRequest#CONTROL_SCENE_MODE
2095 */
2096 public static final int CONTROL_SCENE_MODE_CANDLELIGHT = 15;
2097
2098 /**
Ruben Brunke6679362014-01-17 17:05:54 -08002099 * <p>Optimized for accurately capturing a photo of barcode
2100 * for use by camera applications that wish to read the
2101 * barcode value.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002102 * @see CaptureRequest#CONTROL_SCENE_MODE
2103 */
2104 public static final int CONTROL_SCENE_MODE_BARCODE = 16;
2105
Zhijun Hee0404182014-06-26 13:17:09 -07002106 /**
Eino-Ville Talvala639fffe2015-06-30 10:34:48 -07002107 * <p>This is deprecated, please use {@link android.hardware.camera2.CameraDevice#createConstrainedHighSpeedCaptureSession }
2108 * and {@link android.hardware.camera2.CameraConstrainedHighSpeedCaptureSession#createHighSpeedRequestList }
Zhijun Hefab663e2015-05-26 19:46:31 -07002109 * for high speed video recording.</p>
Zhijun Hee0404182014-06-26 13:17:09 -07002110 * <p>Optimized for high speed video recording (frame rate &gt;=60fps) use case.</p>
2111 * <p>The supported high speed video sizes and fps ranges are specified in
2112 * android.control.availableHighSpeedVideoConfigurations. To get desired
2113 * output frame rates, the application is only allowed to select video size
2114 * and fps range combinations listed in this static metadata. The fps range
2115 * can be control via {@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange}.</p>
2116 * <p>In this mode, the camera device will override aeMode, awbMode, and afMode to
2117 * ON, ON, and CONTINUOUS_VIDEO, respectively. All post-processing block mode
2118 * controls will be overridden to be FAST. Therefore, no manual control of capture
2119 * and post-processing parameters is possible. All other controls operate the
2120 * same as when {@link CaptureRequest#CONTROL_MODE android.control.mode} == AUTO. This means that all other
2121 * android.control.* fields continue to work, such as</p>
2122 * <ul>
2123 * <li>{@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange}</li>
2124 * <li>{@link CaptureRequest#CONTROL_AE_EXPOSURE_COMPENSATION android.control.aeExposureCompensation}</li>
2125 * <li>{@link CaptureRequest#CONTROL_AE_LOCK android.control.aeLock}</li>
2126 * <li>{@link CaptureRequest#CONTROL_AWB_LOCK android.control.awbLock}</li>
2127 * <li>{@link CaptureRequest#CONTROL_EFFECT_MODE android.control.effectMode}</li>
2128 * <li>{@link CaptureRequest#CONTROL_AE_REGIONS android.control.aeRegions}</li>
2129 * <li>{@link CaptureRequest#CONTROL_AF_REGIONS android.control.afRegions}</li>
2130 * <li>{@link CaptureRequest#CONTROL_AWB_REGIONS android.control.awbRegions}</li>
2131 * <li>{@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}</li>
2132 * <li>{@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}</li>
2133 * </ul>
2134 * <p>Outside of android.control.*, the following controls will work:</p>
2135 * <ul>
2136 * <li>{@link CaptureRequest#FLASH_MODE android.flash.mode} (automatic flash for still capture will not work since aeMode is ON)</li>
2137 * <li>{@link CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE android.lens.opticalStabilizationMode} (if it is supported)</li>
2138 * <li>{@link CaptureRequest#SCALER_CROP_REGION android.scaler.cropRegion}</li>
2139 * <li>{@link CaptureRequest#STATISTICS_FACE_DETECT_MODE android.statistics.faceDetectMode}</li>
2140 * </ul>
2141 * <p>For high speed recording use case, the actual maximum supported frame rate may
2142 * be lower than what camera can output, depending on the destination Surfaces for
2143 * the image data. For example, if the destination surface is from video encoder,
2144 * the application need check if the video encoder is capable of supporting the
2145 * high frame rate for a given video size, or it will end up with lower recording
2146 * frame rate. If the destination surface is from preview window, the preview frame
2147 * rate will be bounded by the screen refresh rate.</p>
2148 * <p>The camera device will only support up to 2 output high speed streams
2149 * (processed non-stalling format defined in android.request.maxNumOutputStreams)
2150 * in this mode. This control will be effective only if all of below conditions are true:</p>
2151 * <ul>
2152 * <li>The application created no more than maxNumHighSpeedStreams processed non-stalling
2153 * format output streams, where maxNumHighSpeedStreams is calculated as
2154 * min(2, android.request.maxNumOutputStreams[Processed (but not-stalling)]).</li>
2155 * <li>The stream sizes are selected from the sizes reported by
2156 * android.control.availableHighSpeedVideoConfigurations.</li>
2157 * <li>No processed non-stalling or raw streams are configured.</li>
2158 * </ul>
2159 * <p>When above conditions are NOT satistied, the controls of this mode and
2160 * {@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange} will be ignored by the camera device,
2161 * the camera device will fall back to {@link CaptureRequest#CONTROL_MODE android.control.mode} <code>==</code> AUTO,
2162 * and the returned capture result metadata will give the fps range choosen
2163 * by the camera device.</p>
2164 * <p>Switching into or out of this mode may trigger some camera ISP/sensor
2165 * reconfigurations, which may introduce extra latency. It is recommended that
2166 * the application avoids unnecessary scene mode switch as much as possible.</p>
2167 *
2168 * @see CaptureRequest#CONTROL_AE_EXPOSURE_COMPENSATION
2169 * @see CaptureRequest#CONTROL_AE_LOCK
2170 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
2171 * @see CaptureRequest#CONTROL_AE_REGIONS
2172 * @see CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE
2173 * @see CaptureRequest#CONTROL_AF_REGIONS
2174 * @see CaptureRequest#CONTROL_AF_TRIGGER
2175 * @see CaptureRequest#CONTROL_AWB_LOCK
2176 * @see CaptureRequest#CONTROL_AWB_REGIONS
2177 * @see CaptureRequest#CONTROL_EFFECT_MODE
2178 * @see CaptureRequest#CONTROL_MODE
2179 * @see CaptureRequest#FLASH_MODE
2180 * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE
2181 * @see CaptureRequest#SCALER_CROP_REGION
2182 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE
2183 * @see CaptureRequest#CONTROL_SCENE_MODE
Zhijun Hefab663e2015-05-26 19:46:31 -07002184 * @deprecated Please refer to this API documentation to find the alternatives
Zhijun Hee0404182014-06-26 13:17:09 -07002185 */
Aurimas Liutikas514c5ef2016-05-24 15:22:55 -07002186 @Deprecated
Zhijun Hee0404182014-06-26 13:17:09 -07002187 public static final int CONTROL_SCENE_MODE_HIGH_SPEED_VIDEO = 17;
2188
Ruben Brunkff99a0a2014-08-28 18:42:35 -07002189 /**
Eino-Ville Talvalaf4eac122014-12-05 11:10:15 -08002190 * <p>Turn on a device-specific high dynamic range (HDR) mode.</p>
2191 * <p>In this scene mode, the camera device captures images
2192 * that keep a larger range of scene illumination levels
2193 * visible in the final image. For example, when taking a
2194 * picture of a object in front of a bright window, both
2195 * the object and the scene through the window may be
2196 * visible when using HDR mode, while in normal AUTO mode,
2197 * one or the other may be poorly exposed. As a tradeoff,
2198 * HDR mode generally takes much longer to capture a single
2199 * image, has no user control, and may have other artifacts
2200 * depending on the HDR method used.</p>
2201 * <p>Therefore, HDR captures operate at a much slower rate
2202 * than regular captures.</p>
2203 * <p>In this mode, on LIMITED or FULL devices, when a request
2204 * is made with a {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} of
2205 * STILL_CAPTURE, the camera device will capture an image
2206 * using a high dynamic range capture technique. On LEGACY
2207 * devices, captures that target a JPEG-format output will
2208 * be captured with HDR, and the capture intent is not
2209 * relevant.</p>
2210 * <p>The HDR capture may involve the device capturing a burst
2211 * of images internally and combining them into one, or it
2212 * may involve the device using specialized high dynamic
2213 * range capture hardware. In all cases, a single image is
2214 * produced in response to a capture request submitted
2215 * while in HDR mode.</p>
2216 * <p>Since substantial post-processing is generally needed to
Eino-Ville Talvalac7c569d2016-04-04 10:48:38 -07002217 * produce an HDR image, only YUV, PRIVATE, and JPEG
2218 * outputs are supported for LIMITED/FULL device HDR
2219 * captures, and only JPEG outputs are supported for LEGACY
2220 * HDR captures. Using a RAW output for HDR capture is not
Eino-Ville Talvalaf4eac122014-12-05 11:10:15 -08002221 * supported.</p>
Eino-Ville Talvalac7c569d2016-04-04 10:48:38 -07002222 * <p>Some devices may also support always-on HDR, which
2223 * applies HDR processing at full frame rate. For these
2224 * devices, intents other than STILL_CAPTURE will also
2225 * produce an HDR output with no frame rate impact compared
2226 * to normal operation, though the quality may be lower
2227 * than for STILL_CAPTURE intents.</p>
2228 * <p>If SCENE_MODE_HDR is used with unsupported output types
2229 * or capture intents, the images captured will be as if
2230 * the SCENE_MODE was not enabled at all.</p>
Eino-Ville Talvalaf4eac122014-12-05 11:10:15 -08002231 *
2232 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
Ruben Brunkff99a0a2014-08-28 18:42:35 -07002233 * @see CaptureRequest#CONTROL_SCENE_MODE
Ruben Brunkff99a0a2014-08-28 18:42:35 -07002234 */
2235 public static final int CONTROL_SCENE_MODE_HDR = 18;
2236
Zhijun Heee2ebde2015-06-16 19:58:11 -07002237 /**
2238 * <p>Same as FACE_PRIORITY scene mode, except that the camera
Zhijun He4fb81252015-07-11 20:02:30 -07002239 * device will choose higher sensitivity values ({@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity})
Zhijun Heee2ebde2015-06-16 19:58:11 -07002240 * under low light conditions.</p>
2241 * <p>The camera device may be tuned to expose the images in a reduced
2242 * sensitivity range to produce the best quality images. For example,
2243 * if the {@link CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE android.sensor.info.sensitivityRange} gives range of [100, 1600],
2244 * the camera device auto-exposure routine tuning process may limit the actual
Zhijun He4fb81252015-07-11 20:02:30 -07002245 * exposure sensitivity range to [100, 1200] to ensure that the noise level isn't
2246 * exessive in order to preserve the image quality. Under this situation, the image under
Zhijun Heee2ebde2015-06-16 19:58:11 -07002247 * low light may be under-exposed when the sensor max exposure time (bounded by the
2248 * {@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange} when {@link CaptureRequest#CONTROL_AE_MODE android.control.aeMode} is one of the
Zhijun He4fb81252015-07-11 20:02:30 -07002249 * ON_* modes) and effective max sensitivity are reached. This scene mode allows the
Zhijun Heee2ebde2015-06-16 19:58:11 -07002250 * camera device auto-exposure routine to increase the sensitivity up to the max
2251 * sensitivity specified by {@link CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE android.sensor.info.sensitivityRange} when the scene is too
2252 * dark and the max exposure time is reached. The captured images may be noisier
Zhijun He4fb81252015-07-11 20:02:30 -07002253 * compared with the images captured in normal FACE_PRIORITY mode; therefore, it is
Zhijun Heee2ebde2015-06-16 19:58:11 -07002254 * recommended that the application only use this scene mode when it is capable of
2255 * reducing the noise level of the captured images.</p>
2256 * <p>Unlike the other scene modes, {@link CaptureRequest#CONTROL_AE_MODE android.control.aeMode},
2257 * {@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode}, and {@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}
2258 * remain active when FACE_PRIORITY_LOW_LIGHT is set.</p>
2259 *
2260 * @see CaptureRequest#CONTROL_AE_MODE
2261 * @see CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE
2262 * @see CaptureRequest#CONTROL_AF_MODE
2263 * @see CaptureRequest#CONTROL_AWB_MODE
2264 * @see CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE
2265 * @see CaptureRequest#SENSOR_SENSITIVITY
2266 * @see CaptureRequest#CONTROL_SCENE_MODE
2267 * @hide
2268 */
2269 public static final int CONTROL_SCENE_MODE_FACE_PRIORITY_LOW_LIGHT = 19;
2270
Yin-Chia Yeh37348202016-03-09 14:44:49 -08002271 /**
2272 * <p>Scene mode values within the range of
2273 * <code>[DEVICE_CUSTOM_START, DEVICE_CUSTOM_END]</code> are reserved for device specific
2274 * customized scene modes.</p>
2275 * @see CaptureRequest#CONTROL_SCENE_MODE
2276 * @hide
2277 */
2278 public static final int CONTROL_SCENE_MODE_DEVICE_CUSTOM_START = 100;
2279
2280 /**
2281 * <p>Scene mode values within the range of
2282 * <code>[DEVICE_CUSTOM_START, DEVICE_CUSTOM_END]</code> are reserved for device specific
2283 * customized scene modes.</p>
2284 * @see CaptureRequest#CONTROL_SCENE_MODE
2285 * @hide
2286 */
2287 public static final int CONTROL_SCENE_MODE_DEVICE_CUSTOM_END = 127;
2288
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002289 //
Zhijun He4793af52014-05-05 10:39:12 -07002290 // Enumeration values for CaptureRequest#CONTROL_VIDEO_STABILIZATION_MODE
2291 //
2292
2293 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002294 * <p>Video stabilization is disabled.</p>
Zhijun He4793af52014-05-05 10:39:12 -07002295 * @see CaptureRequest#CONTROL_VIDEO_STABILIZATION_MODE
2296 */
2297 public static final int CONTROL_VIDEO_STABILIZATION_MODE_OFF = 0;
2298
2299 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002300 * <p>Video stabilization is enabled.</p>
Zhijun He4793af52014-05-05 10:39:12 -07002301 * @see CaptureRequest#CONTROL_VIDEO_STABILIZATION_MODE
2302 */
2303 public static final int CONTROL_VIDEO_STABILIZATION_MODE_ON = 1;
2304
2305 //
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002306 // Enumeration values for CaptureRequest#EDGE_MODE
2307 //
2308
2309 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002310 * <p>No edge enhancement is applied.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002311 * @see CaptureRequest#EDGE_MODE
2312 */
2313 public static final int EDGE_MODE_OFF = 0;
2314
2315 /**
Chien-Yu Chen9c9167e2015-07-14 16:38:25 -07002316 * <p>Apply edge enhancement at a quality level that does not slow down frame rate
2317 * relative to sensor output. It may be the same as OFF if edge enhancement will
2318 * slow down frame rate relative to sensor.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002319 * @see CaptureRequest#EDGE_MODE
2320 */
2321 public static final int EDGE_MODE_FAST = 1;
2322
2323 /**
Yin-Chia Yehfba08dd2015-04-02 14:05:14 -07002324 * <p>Apply high-quality edge enhancement, at a cost of possibly reduced output frame rate.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002325 * @see CaptureRequest#EDGE_MODE
2326 */
2327 public static final int EDGE_MODE_HIGH_QUALITY = 2;
2328
Eino-Ville Talvala0dd17502015-07-07 10:43:07 -07002329 /**
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -08002330 * <p>Edge enhancement is applied at different
2331 * levels for different output streams, based on resolution. Streams at maximum recording
2332 * resolution (see {@link android.hardware.camera2.CameraDevice#createCaptureSession })
2333 * or below have edge enhancement applied, while higher-resolution streams have no edge
2334 * enhancement applied. The level of edge enhancement for low-resolution streams is tuned
2335 * so that frame rate is not impacted, and the quality is equal to or better than FAST
2336 * (since it is only applied to lower-resolution outputs, quality may improve from FAST).</p>
Eino-Ville Talvala0dd17502015-07-07 10:43:07 -07002337 * <p>This mode is intended to be used by applications operating in a zero-shutter-lag mode
2338 * with YUV or PRIVATE reprocessing, where the application continuously captures
2339 * high-resolution intermediate buffers into a circular buffer, from which a final image is
2340 * produced via reprocessing when a user takes a picture. For such a use case, the
2341 * high-resolution buffers must not have edge enhancement applied to maximize efficiency of
2342 * preview and to avoid double-applying enhancement when reprocessed, while low-resolution
2343 * buffers (used for recording or preview, generally) need edge enhancement applied for
2344 * reasonable preview quality.</p>
2345 * <p>This mode is guaranteed to be supported by devices that support either the
2346 * YUV_REPROCESSING or PRIVATE_REPROCESSING capabilities
Chien-Yu Chen72333912015-07-08 11:55:19 -07002347 * ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} lists either of those capabilities) and it will
2348 * be the default mode for CAMERA3_TEMPLATE_ZERO_SHUTTER_LAG template.</p>
Eino-Ville Talvala0dd17502015-07-07 10:43:07 -07002349 *
2350 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
2351 * @see CaptureRequest#EDGE_MODE
2352 */
2353 public static final int EDGE_MODE_ZERO_SHUTTER_LAG = 3;
2354
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002355 //
2356 // Enumeration values for CaptureRequest#FLASH_MODE
2357 //
2358
2359 /**
Zhijun He66d065a2014-01-16 18:18:50 -08002360 * <p>Do not fire the flash for this capture.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002361 * @see CaptureRequest#FLASH_MODE
2362 */
2363 public static final int FLASH_MODE_OFF = 0;
2364
2365 /**
Zhijun He66d065a2014-01-16 18:18:50 -08002366 * <p>If the flash is available and charged, fire flash
Zhijun He89492252014-05-23 13:49:59 -07002367 * for this capture.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002368 * @see CaptureRequest#FLASH_MODE
2369 */
2370 public static final int FLASH_MODE_SINGLE = 1;
2371
2372 /**
Zhijun He66d065a2014-01-16 18:18:50 -08002373 * <p>Transition flash to continuously on.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002374 * @see CaptureRequest#FLASH_MODE
2375 */
2376 public static final int FLASH_MODE_TORCH = 2;
2377
2378 //
Ruben Brunkeba1b3a2014-02-07 18:23:50 -08002379 // Enumeration values for CaptureRequest#HOT_PIXEL_MODE
2380 //
2381
2382 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002383 * <p>No hot pixel correction is applied.</p>
Ruben Brunkeba1b3a2014-02-07 18:23:50 -08002384 * <p>The frame rate must not be reduced relative to sensor raw output
2385 * for this option.</p>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002386 * <p>The hotpixel map may be returned in {@link CaptureResult#STATISTICS_HOT_PIXEL_MAP android.statistics.hotPixelMap}.</p>
Ruben Brunk9d454fd2014-03-04 14:11:52 -08002387 *
2388 * @see CaptureResult#STATISTICS_HOT_PIXEL_MAP
Ruben Brunkeba1b3a2014-02-07 18:23:50 -08002389 * @see CaptureRequest#HOT_PIXEL_MODE
2390 */
2391 public static final int HOT_PIXEL_MODE_OFF = 0;
2392
2393 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002394 * <p>Hot pixel correction is applied, without reducing frame
2395 * rate relative to sensor raw output.</p>
2396 * <p>The hotpixel map may be returned in {@link CaptureResult#STATISTICS_HOT_PIXEL_MAP android.statistics.hotPixelMap}.</p>
Ruben Brunk9d454fd2014-03-04 14:11:52 -08002397 *
2398 * @see CaptureResult#STATISTICS_HOT_PIXEL_MAP
Ruben Brunkeba1b3a2014-02-07 18:23:50 -08002399 * @see CaptureRequest#HOT_PIXEL_MODE
2400 */
2401 public static final int HOT_PIXEL_MODE_FAST = 1;
2402
2403 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002404 * <p>High-quality hot pixel correction is applied, at a cost
Yin-Chia Yehfba08dd2015-04-02 14:05:14 -07002405 * of possibly reduced frame rate relative to sensor raw output.</p>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002406 * <p>The hotpixel map may be returned in {@link CaptureResult#STATISTICS_HOT_PIXEL_MAP android.statistics.hotPixelMap}.</p>
Ruben Brunk9d454fd2014-03-04 14:11:52 -08002407 *
2408 * @see CaptureResult#STATISTICS_HOT_PIXEL_MAP
Ruben Brunkeba1b3a2014-02-07 18:23:50 -08002409 * @see CaptureRequest#HOT_PIXEL_MODE
2410 */
2411 public static final int HOT_PIXEL_MODE_HIGH_QUALITY = 2;
2412
2413 //
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002414 // Enumeration values for CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE
2415 //
2416
2417 /**
Ruben Brunk00849b32014-01-17 18:30:23 -08002418 * <p>Optical stabilization is unavailable.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002419 * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE
2420 */
2421 public static final int LENS_OPTICAL_STABILIZATION_MODE_OFF = 0;
2422
2423 /**
Ruben Brunk00849b32014-01-17 18:30:23 -08002424 * <p>Optical stabilization is enabled.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002425 * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE
2426 */
2427 public static final int LENS_OPTICAL_STABILIZATION_MODE_ON = 1;
2428
2429 //
2430 // Enumeration values for CaptureRequest#NOISE_REDUCTION_MODE
2431 //
2432
2433 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002434 * <p>No noise reduction is applied.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002435 * @see CaptureRequest#NOISE_REDUCTION_MODE
2436 */
2437 public static final int NOISE_REDUCTION_MODE_OFF = 0;
2438
2439 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002440 * <p>Noise reduction is applied without reducing frame rate relative to sensor
Chien-Yu Chen9c9167e2015-07-14 16:38:25 -07002441 * output. It may be the same as OFF if noise reduction will reduce frame rate
2442 * relative to sensor.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002443 * @see CaptureRequest#NOISE_REDUCTION_MODE
2444 */
2445 public static final int NOISE_REDUCTION_MODE_FAST = 1;
2446
2447 /**
Yin-Chia Yehfba08dd2015-04-02 14:05:14 -07002448 * <p>High-quality noise reduction is applied, at the cost of possibly reduced frame
2449 * rate relative to sensor output.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002450 * @see CaptureRequest#NOISE_REDUCTION_MODE
2451 */
2452 public static final int NOISE_REDUCTION_MODE_HIGH_QUALITY = 2;
2453
Zhijun He0e99c222015-01-29 15:26:05 -08002454 /**
2455 * <p>MINIMAL noise reduction is applied without reducing frame rate relative to
2456 * sensor output. </p>
2457 * @see CaptureRequest#NOISE_REDUCTION_MODE
2458 */
2459 public static final int NOISE_REDUCTION_MODE_MINIMAL = 3;
2460
Eino-Ville Talvala0dd17502015-07-07 10:43:07 -07002461 /**
2462 * <p>Noise reduction is applied at different levels for different output streams,
Eino-Ville Talvala9dc7ec12017-11-10 15:23:00 -08002463 * based on resolution. Streams at maximum recording resolution (see {@link android.hardware.camera2.CameraDevice#createCaptureSession })
2464 * or below have noise reduction applied, while higher-resolution streams have MINIMAL (if
2465 * supported) or no noise reduction applied (if MINIMAL is not supported.) The degree of
2466 * noise reduction for low-resolution streams is tuned so that frame rate is not impacted,
2467 * and the quality is equal to or better than FAST (since it is only applied to
2468 * lower-resolution outputs, quality may improve from FAST).</p>
Eino-Ville Talvala0dd17502015-07-07 10:43:07 -07002469 * <p>This mode is intended to be used by applications operating in a zero-shutter-lag mode
2470 * with YUV or PRIVATE reprocessing, where the application continuously captures
2471 * high-resolution intermediate buffers into a circular buffer, from which a final image is
2472 * produced via reprocessing when a user takes a picture. For such a use case, the
2473 * high-resolution buffers must not have noise reduction applied to maximize efficiency of
2474 * preview and to avoid over-applying noise filtering when reprocessing, while
2475 * low-resolution buffers (used for recording or preview, generally) need noise reduction
2476 * applied for reasonable preview quality.</p>
2477 * <p>This mode is guaranteed to be supported by devices that support either the
2478 * YUV_REPROCESSING or PRIVATE_REPROCESSING capabilities
Chien-Yu Chen72333912015-07-08 11:55:19 -07002479 * ({@link CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES android.request.availableCapabilities} lists either of those capabilities) and it will
2480 * be the default mode for CAMERA3_TEMPLATE_ZERO_SHUTTER_LAG template.</p>
Eino-Ville Talvala0dd17502015-07-07 10:43:07 -07002481 *
2482 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
2483 * @see CaptureRequest#NOISE_REDUCTION_MODE
2484 */
2485 public static final int NOISE_REDUCTION_MODE_ZERO_SHUTTER_LAG = 4;
2486
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002487 //
Igor Murashkinc127f052014-01-17 18:06:02 -08002488 // Enumeration values for CaptureRequest#SENSOR_TEST_PATTERN_MODE
2489 //
2490
2491 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002492 * <p>No test pattern mode is used, and the camera
Igor Murashkinc127f052014-01-17 18:06:02 -08002493 * device returns captures from the image sensor.</p>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002494 * <p>This is the default if the key is not set.</p>
Igor Murashkinc127f052014-01-17 18:06:02 -08002495 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE
2496 */
2497 public static final int SENSOR_TEST_PATTERN_MODE_OFF = 0;
2498
2499 /**
2500 * <p>Each pixel in <code>[R, G_even, G_odd, B]</code> is replaced by its
2501 * respective color channel provided in
2502 * {@link CaptureRequest#SENSOR_TEST_PATTERN_DATA android.sensor.testPatternData}.</p>
2503 * <p>For example:</p>
2504 * <pre><code>android.testPatternData = [0, 0xFFFFFFFF, 0xFFFFFFFF, 0]
2505 * </code></pre>
2506 * <p>All green pixels are 100% green. All red/blue pixels are black.</p>
2507 * <pre><code>android.testPatternData = [0xFFFFFFFF, 0, 0xFFFFFFFF, 0]
2508 * </code></pre>
2509 * <p>All red pixels are 100% red. Only the odd green pixels
2510 * are 100% green. All blue pixels are 100% black.</p>
2511 *
2512 * @see CaptureRequest#SENSOR_TEST_PATTERN_DATA
2513 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE
2514 */
2515 public static final int SENSOR_TEST_PATTERN_MODE_SOLID_COLOR = 1;
2516
2517 /**
2518 * <p>All pixel data is replaced with an 8-bar color pattern.</p>
2519 * <p>The vertical bars (left-to-right) are as follows:</p>
2520 * <ul>
2521 * <li>100% white</li>
2522 * <li>yellow</li>
2523 * <li>cyan</li>
2524 * <li>green</li>
2525 * <li>magenta</li>
2526 * <li>red</li>
2527 * <li>blue</li>
2528 * <li>black</li>
2529 * </ul>
2530 * <p>In general the image would look like the following:</p>
2531 * <pre><code>W Y C G M R B K
2532 * W Y C G M R B K
2533 * W Y C G M R B K
2534 * W Y C G M R B K
2535 * W Y C G M R B K
2536 * . . . . . . . .
2537 * . . . . . . . .
2538 * . . . . . . . .
2539 *
2540 * (B = Blue, K = Black)
2541 * </code></pre>
2542 * <p>Each bar should take up 1/8 of the sensor pixel array width.
2543 * When this is not possible, the bar size should be rounded
2544 * down to the nearest integer and the pattern can repeat
2545 * on the right side.</p>
2546 * <p>Each bar's height must always take up the full sensor
2547 * pixel array height.</p>
2548 * <p>Each pixel in this test pattern must be set to either
2549 * 0% intensity or 100% intensity.</p>
2550 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE
2551 */
2552 public static final int SENSOR_TEST_PATTERN_MODE_COLOR_BARS = 2;
2553
2554 /**
2555 * <p>The test pattern is similar to COLOR_BARS, except that
2556 * each bar should start at its specified color at the top,
2557 * and fade to gray at the bottom.</p>
2558 * <p>Furthermore each bar is further subdivided into a left and
2559 * right half. The left half should have a smooth gradient,
2560 * and the right half should have a quantized gradient.</p>
2561 * <p>In particular, the right half's should consist of blocks of the
2562 * same color for 1/16th active sensor pixel array width.</p>
2563 * <p>The least significant bits in the quantized gradient should
2564 * be copied from the most significant bits of the smooth gradient.</p>
2565 * <p>The height of each bar should always be a multiple of 128.
2566 * When this is not the case, the pattern should repeat at the bottom
2567 * of the image.</p>
2568 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE
2569 */
2570 public static final int SENSOR_TEST_PATTERN_MODE_COLOR_BARS_FADE_TO_GRAY = 3;
2571
2572 /**
2573 * <p>All pixel data is replaced by a pseudo-random sequence
2574 * generated from a PN9 512-bit sequence (typically implemented
2575 * in hardware with a linear feedback shift register).</p>
2576 * <p>The generator should be reset at the beginning of each frame,
2577 * and thus each subsequent raw frame with this test pattern should
2578 * be exactly the same as the last.</p>
2579 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE
2580 */
2581 public static final int SENSOR_TEST_PATTERN_MODE_PN9 = 4;
2582
2583 /**
2584 * <p>The first custom test pattern. All custom patterns that are
2585 * available only on this camera device are at least this numeric
2586 * value.</p>
2587 * <p>All of the custom test patterns will be static
2588 * (that is the raw image must not vary from frame to frame).</p>
2589 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE
2590 */
2591 public static final int SENSOR_TEST_PATTERN_MODE_CUSTOM1 = 256;
2592
2593 //
Zhijun Heba93fe62014-01-17 16:43:05 -08002594 // Enumeration values for CaptureRequest#SHADING_MODE
2595 //
2596
2597 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002598 * <p>No lens shading correction is applied.</p>
Zhijun Heba93fe62014-01-17 16:43:05 -08002599 * @see CaptureRequest#SHADING_MODE
Zhijun Heba93fe62014-01-17 16:43:05 -08002600 */
2601 public static final int SHADING_MODE_OFF = 0;
2602
2603 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002604 * <p>Apply lens shading corrections, without slowing
2605 * frame rate relative to sensor raw output</p>
Zhijun Heba93fe62014-01-17 16:43:05 -08002606 * @see CaptureRequest#SHADING_MODE
Zhijun Heba93fe62014-01-17 16:43:05 -08002607 */
2608 public static final int SHADING_MODE_FAST = 1;
2609
2610 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002611 * <p>Apply high-quality lens shading correction, at the
Yin-Chia Yehfba08dd2015-04-02 14:05:14 -07002612 * cost of possibly reduced frame rate.</p>
Zhijun Heba93fe62014-01-17 16:43:05 -08002613 * @see CaptureRequest#SHADING_MODE
Zhijun Heba93fe62014-01-17 16:43:05 -08002614 */
2615 public static final int SHADING_MODE_HIGH_QUALITY = 2;
2616
2617 //
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002618 // Enumeration values for CaptureRequest#STATISTICS_FACE_DETECT_MODE
2619 //
2620
2621 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002622 * <p>Do not include face detection statistics in capture
2623 * results.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002624 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE
2625 */
2626 public static final int STATISTICS_FACE_DETECT_MODE_OFF = 0;
2627
2628 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002629 * <p>Return face rectangle and confidence values only.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002630 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE
2631 */
2632 public static final int STATISTICS_FACE_DETECT_MODE_SIMPLE = 1;
2633
2634 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002635 * <p>Return all face
2636 * metadata.</p>
Eino-Ville Talvalafd3e2892014-10-06 10:23:55 -07002637 * <p>In this mode, face rectangles, scores, landmarks, and face IDs are all valid.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002638 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE
2639 */
2640 public static final int STATISTICS_FACE_DETECT_MODE_FULL = 2;
2641
2642 //
Eino-Ville Talvalad96748b2013-09-12 11:11:27 -07002643 // Enumeration values for CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE
2644 //
2645
2646 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002647 * <p>Do not include a lens shading map in the capture result.</p>
Eino-Ville Talvalad96748b2013-09-12 11:11:27 -07002648 * @see CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE
2649 */
2650 public static final int STATISTICS_LENS_SHADING_MAP_MODE_OFF = 0;
2651
2652 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002653 * <p>Include a lens shading map in the capture result.</p>
Eino-Ville Talvalad96748b2013-09-12 11:11:27 -07002654 * @see CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE
2655 */
2656 public static final int STATISTICS_LENS_SHADING_MAP_MODE_ON = 1;
2657
2658 //
Chien-Yu Chenc9cf5b92018-01-18 12:24:40 -08002659 // Enumeration values for CaptureRequest#STATISTICS_OIS_DATA_MODE
2660 //
2661
2662 /**
2663 * <p>Do not include OIS data in the capture result.</p>
2664 * @see CaptureRequest#STATISTICS_OIS_DATA_MODE
2665 */
2666 public static final int STATISTICS_OIS_DATA_MODE_OFF = 0;
2667
2668 /**
2669 * <p>Include OIS data in the capture result.</p>
Chien-Yu Chenc804d1c2018-02-15 12:44:19 -08002670 * <p>{@link CaptureResult#STATISTICS_OIS_SAMPLES android.statistics.oisSamples} provides OIS sample data in the
2671 * output result metadata.</p>
2672 *
2673 * @see CaptureResult#STATISTICS_OIS_SAMPLES
Chien-Yu Chenc9cf5b92018-01-18 12:24:40 -08002674 * @see CaptureRequest#STATISTICS_OIS_DATA_MODE
2675 */
2676 public static final int STATISTICS_OIS_DATA_MODE_ON = 1;
2677
2678 //
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002679 // Enumeration values for CaptureRequest#TONEMAP_MODE
2680 //
2681
2682 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08002683 * <p>Use the tone mapping curve specified in
Yin-Chia Yeh8490ace2014-05-27 10:04:54 -07002684 * the {@link CaptureRequest#TONEMAP_CURVE android.tonemap.curve}* entries.</p>
Igor Murashkine0060932014-01-17 17:24:11 -08002685 * <p>All color enhancement and tonemapping must be disabled, except
2686 * for applying the tonemapping curve specified by
Yin-Chia Yeh8490ace2014-05-27 10:04:54 -07002687 * {@link CaptureRequest#TONEMAP_CURVE android.tonemap.curve}.</p>
Igor Murashkine0060932014-01-17 17:24:11 -08002688 * <p>Must not slow down frame rate relative to raw
2689 * sensor output.</p>
2690 *
Yin-Chia Yeh8490ace2014-05-27 10:04:54 -07002691 * @see CaptureRequest#TONEMAP_CURVE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002692 * @see CaptureRequest#TONEMAP_MODE
2693 */
2694 public static final int TONEMAP_MODE_CONTRAST_CURVE = 0;
2695
2696 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002697 * <p>Advanced gamma mapping and color enhancement may be applied, without
2698 * reducing frame rate compared to raw sensor output.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002699 * @see CaptureRequest#TONEMAP_MODE
2700 */
2701 public static final int TONEMAP_MODE_FAST = 1;
2702
2703 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002704 * <p>High-quality gamma mapping and color enhancement will be applied, at
Yin-Chia Yehfba08dd2015-04-02 14:05:14 -07002705 * the cost of possibly reduced frame rate compared to raw sensor output.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002706 * @see CaptureRequest#TONEMAP_MODE
2707 */
2708 public static final int TONEMAP_MODE_HIGH_QUALITY = 2;
2709
Yin-Chia Yeh956c52b2015-02-06 11:23:25 -08002710 /**
Yin-Chia Yeh03d50da2015-05-06 00:10:11 -07002711 * <p>Use the gamma value specified in {@link CaptureRequest#TONEMAP_GAMMA android.tonemap.gamma} to peform
Yin-Chia Yeh956c52b2015-02-06 11:23:25 -08002712 * tonemapping.</p>
2713 * <p>All color enhancement and tonemapping must be disabled, except
Yin-Chia Yeh03d50da2015-05-06 00:10:11 -07002714 * for applying the tonemapping curve specified by {@link CaptureRequest#TONEMAP_GAMMA android.tonemap.gamma}.</p>
Yin-Chia Yeh956c52b2015-02-06 11:23:25 -08002715 * <p>Must not slow down frame rate relative to raw sensor output.</p>
Yin-Chia Yeh03d50da2015-05-06 00:10:11 -07002716 *
2717 * @see CaptureRequest#TONEMAP_GAMMA
Yin-Chia Yeh956c52b2015-02-06 11:23:25 -08002718 * @see CaptureRequest#TONEMAP_MODE
2719 */
2720 public static final int TONEMAP_MODE_GAMMA_VALUE = 3;
2721
2722 /**
2723 * <p>Use the preset tonemapping curve specified in
Yin-Chia Yeh03d50da2015-05-06 00:10:11 -07002724 * {@link CaptureRequest#TONEMAP_PRESET_CURVE android.tonemap.presetCurve} to peform tonemapping.</p>
Yin-Chia Yeh956c52b2015-02-06 11:23:25 -08002725 * <p>All color enhancement and tonemapping must be disabled, except
2726 * for applying the tonemapping curve specified by
Yin-Chia Yeh03d50da2015-05-06 00:10:11 -07002727 * {@link CaptureRequest#TONEMAP_PRESET_CURVE android.tonemap.presetCurve}.</p>
Yin-Chia Yeh956c52b2015-02-06 11:23:25 -08002728 * <p>Must not slow down frame rate relative to raw sensor output.</p>
Yin-Chia Yeh03d50da2015-05-06 00:10:11 -07002729 *
2730 * @see CaptureRequest#TONEMAP_PRESET_CURVE
Yin-Chia Yeh956c52b2015-02-06 11:23:25 -08002731 * @see CaptureRequest#TONEMAP_MODE
2732 */
2733 public static final int TONEMAP_MODE_PRESET_CURVE = 4;
2734
2735 //
2736 // Enumeration values for CaptureRequest#TONEMAP_PRESET_CURVE
2737 //
2738
2739 /**
2740 * <p>Tonemapping curve is defined by sRGB</p>
2741 * @see CaptureRequest#TONEMAP_PRESET_CURVE
2742 */
2743 public static final int TONEMAP_PRESET_CURVE_SRGB = 0;
2744
2745 /**
2746 * <p>Tonemapping curve is defined by ITU-R BT.709</p>
2747 * @see CaptureRequest#TONEMAP_PRESET_CURVE
2748 */
2749 public static final int TONEMAP_PRESET_CURVE_REC709 = 1;
2750
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002751 //
Eino-Ville Talvala41670722018-03-13 19:43:07 -07002752 // Enumeration values for CaptureRequest#DISTORTION_CORRECTION_MODE
2753 //
2754
2755 /**
2756 * <p>No distortion correction is applied.</p>
2757 * @see CaptureRequest#DISTORTION_CORRECTION_MODE
2758 */
2759 public static final int DISTORTION_CORRECTION_MODE_OFF = 0;
2760
2761 /**
2762 * <p>Lens distortion correction is applied without reducing frame rate
2763 * relative to sensor output. It may be the same as OFF if distortion correction would
2764 * reduce frame rate relative to sensor.</p>
2765 * @see CaptureRequest#DISTORTION_CORRECTION_MODE
2766 */
2767 public static final int DISTORTION_CORRECTION_MODE_FAST = 1;
2768
2769 /**
2770 * <p>High-quality distortion correction is applied, at the cost of
2771 * possibly reduced frame rate relative to sensor output.</p>
2772 * @see CaptureRequest#DISTORTION_CORRECTION_MODE
2773 */
2774 public static final int DISTORTION_CORRECTION_MODE_HIGH_QUALITY = 2;
2775
2776 //
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002777 // Enumeration values for CaptureResult#CONTROL_AE_STATE
2778 //
2779
2780 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002781 * <p>AE is off or recently reset.</p>
2782 * <p>When a camera device is opened, it starts in
Zhijun He60b19dc2014-02-24 10:19:20 -08002783 * this state. This is a transient state, the camera device may skip reporting
2784 * this state in capture result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002785 * @see CaptureResult#CONTROL_AE_STATE
2786 */
2787 public static final int CONTROL_AE_STATE_INACTIVE = 0;
2788
2789 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08002790 * <p>AE doesn't yet have a good set of control values
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002791 * for the current scene.</p>
2792 * <p>This is a transient state, the camera device may skip
Zhijun He60b19dc2014-02-24 10:19:20 -08002793 * reporting this state in capture result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002794 * @see CaptureResult#CONTROL_AE_STATE
2795 */
2796 public static final int CONTROL_AE_STATE_SEARCHING = 1;
2797
2798 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08002799 * <p>AE has a good set of control values for the
Zhijun He228f4f92014-01-16 17:22:05 -08002800 * current scene.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002801 * @see CaptureResult#CONTROL_AE_STATE
2802 */
2803 public static final int CONTROL_AE_STATE_CONVERGED = 2;
2804
2805 /**
Zhijun He228f4f92014-01-16 17:22:05 -08002806 * <p>AE has been locked.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002807 * @see CaptureResult#CONTROL_AE_STATE
2808 */
2809 public static final int CONTROL_AE_STATE_LOCKED = 3;
2810
2811 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08002812 * <p>AE has a good set of control values, but flash
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002813 * needs to be fired for good quality still
Zhijun He228f4f92014-01-16 17:22:05 -08002814 * capture.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002815 * @see CaptureResult#CONTROL_AE_STATE
2816 */
2817 public static final int CONTROL_AE_STATE_FLASH_REQUIRED = 4;
2818
2819 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08002820 * <p>AE has been asked to do a precapture sequence
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002821 * and is currently executing it.</p>
2822 * <p>Precapture can be triggered through setting
Zhijun Hefa95b042015-02-09 10:40:49 -08002823 * {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger} to START. Currently
2824 * active and completed (if it causes camera device internal AE lock) precapture
2825 * metering sequence can be canceled through setting
2826 * {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger} to CANCEL.</p>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002827 * <p>Once PRECAPTURE completes, AE will transition to CONVERGED
2828 * or FLASH_REQUIRED as appropriate. This is a transient
2829 * state, the camera device may skip reporting this state in
2830 * capture result.</p>
Zhijun He228f4f92014-01-16 17:22:05 -08002831 *
2832 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002833 * @see CaptureResult#CONTROL_AE_STATE
2834 */
2835 public static final int CONTROL_AE_STATE_PRECAPTURE = 5;
2836
2837 //
2838 // Enumeration values for CaptureResult#CONTROL_AF_STATE
2839 //
2840
2841 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002842 * <p>AF is off or has not yet tried to scan/been asked
2843 * to scan.</p>
2844 * <p>When a camera device is opened, it starts in this
2845 * state. This is a transient state, the camera device may
2846 * skip reporting this state in capture
2847 * result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002848 * @see CaptureResult#CONTROL_AF_STATE
2849 */
2850 public static final int CONTROL_AF_STATE_INACTIVE = 0;
2851
2852 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002853 * <p>AF is currently performing an AF scan initiated the
2854 * camera device in a continuous autofocus mode.</p>
2855 * <p>Only used by CONTINUOUS_* AF modes. This is a transient
2856 * state, the camera device may skip reporting this state in
2857 * capture result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002858 * @see CaptureResult#CONTROL_AF_STATE
2859 */
2860 public static final int CONTROL_AF_STATE_PASSIVE_SCAN = 1;
2861
2862 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002863 * <p>AF currently believes it is in focus, but may
2864 * restart scanning at any time.</p>
2865 * <p>Only used by CONTINUOUS_* AF modes. This is a transient
2866 * state, the camera device may skip reporting this state in
2867 * capture result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002868 * @see CaptureResult#CONTROL_AF_STATE
2869 */
2870 public static final int CONTROL_AF_STATE_PASSIVE_FOCUSED = 2;
2871
2872 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002873 * <p>AF is performing an AF scan because it was
2874 * triggered by AF trigger.</p>
2875 * <p>Only used by AUTO or MACRO AF modes. This is a transient
2876 * state, the camera device may skip reporting this state in
2877 * capture result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002878 * @see CaptureResult#CONTROL_AF_STATE
2879 */
2880 public static final int CONTROL_AF_STATE_ACTIVE_SCAN = 3;
2881
2882 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002883 * <p>AF believes it is focused correctly and has locked
2884 * focus.</p>
2885 * <p>This state is reached only after an explicit START AF trigger has been
2886 * sent ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}), when good focus has been obtained.</p>
2887 * <p>The lens will remain stationary until the AF mode ({@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}) is changed or
2888 * a new AF trigger is sent to the camera device ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}).</p>
2889 *
2890 * @see CaptureRequest#CONTROL_AF_MODE
2891 * @see CaptureRequest#CONTROL_AF_TRIGGER
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002892 * @see CaptureResult#CONTROL_AF_STATE
2893 */
2894 public static final int CONTROL_AF_STATE_FOCUSED_LOCKED = 4;
2895
2896 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002897 * <p>AF has failed to focus successfully and has locked
2898 * focus.</p>
2899 * <p>This state is reached only after an explicit START AF trigger has been
2900 * sent ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}), when good focus cannot be obtained.</p>
2901 * <p>The lens will remain stationary until the AF mode ({@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}) is changed or
2902 * a new AF trigger is sent to the camera device ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}).</p>
2903 *
2904 * @see CaptureRequest#CONTROL_AF_MODE
2905 * @see CaptureRequest#CONTROL_AF_TRIGGER
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002906 * @see CaptureResult#CONTROL_AF_STATE
2907 */
2908 public static final int CONTROL_AF_STATE_NOT_FOCUSED_LOCKED = 5;
2909
Eino-Ville Talvala9f880f72013-09-20 17:50:41 -07002910 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002911 * <p>AF finished a passive scan without finding focus,
2912 * and may restart scanning at any time.</p>
2913 * <p>Only used by CONTINUOUS_* AF modes. This is a transient state, the camera
Zhijun He60b19dc2014-02-24 10:19:20 -08002914 * device may skip reporting this state in capture result.</p>
Igor Murashkin4b8cd6b2014-10-02 16:00:52 -07002915 * <p>LEGACY camera devices do not support this state. When a passive
2916 * scan has finished, it will always go to PASSIVE_FOCUSED.</p>
Eino-Ville Talvala9f880f72013-09-20 17:50:41 -07002917 * @see CaptureResult#CONTROL_AF_STATE
2918 */
2919 public static final int CONTROL_AF_STATE_PASSIVE_UNFOCUSED = 6;
2920
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002921 //
2922 // Enumeration values for CaptureResult#CONTROL_AWB_STATE
2923 //
2924
2925 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002926 * <p>AWB is not in auto mode, or has not yet started metering.</p>
2927 * <p>When a camera device is opened, it starts in this
2928 * state. This is a transient state, the camera device may
2929 * skip reporting this state in capture
2930 * result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002931 * @see CaptureResult#CONTROL_AWB_STATE
2932 */
2933 public static final int CONTROL_AWB_STATE_INACTIVE = 0;
2934
2935 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08002936 * <p>AWB doesn't yet have a good set of control
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002937 * values for the current scene.</p>
2938 * <p>This is a transient state, the camera device
Zhijun He60b19dc2014-02-24 10:19:20 -08002939 * may skip reporting this state in capture result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002940 * @see CaptureResult#CONTROL_AWB_STATE
2941 */
2942 public static final int CONTROL_AWB_STATE_SEARCHING = 1;
2943
2944 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08002945 * <p>AWB has a good set of control values for the
Zhijun He228f4f92014-01-16 17:22:05 -08002946 * current scene.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002947 * @see CaptureResult#CONTROL_AWB_STATE
2948 */
2949 public static final int CONTROL_AWB_STATE_CONVERGED = 2;
2950
2951 /**
Zhijun He228f4f92014-01-16 17:22:05 -08002952 * <p>AWB has been locked.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002953 * @see CaptureResult#CONTROL_AWB_STATE
2954 */
2955 public static final int CONTROL_AWB_STATE_LOCKED = 3;
2956
2957 //
Chien-Yu Chene8d86eb2017-11-27 15:42:44 -08002958 // Enumeration values for CaptureResult#CONTROL_AF_SCENE_CHANGE
2959 //
2960
2961 /**
Chien-Yu Chen2adc8ec2017-12-07 14:45:50 -08002962 * <p>Scene change is not detected within the AF region(s).</p>
Chien-Yu Chene8d86eb2017-11-27 15:42:44 -08002963 * @see CaptureResult#CONTROL_AF_SCENE_CHANGE
2964 */
2965 public static final int CONTROL_AF_SCENE_CHANGE_NOT_DETECTED = 0;
2966
2967 /**
Chien-Yu Chen2adc8ec2017-12-07 14:45:50 -08002968 * <p>Scene change is detected within the AF region(s).</p>
Chien-Yu Chene8d86eb2017-11-27 15:42:44 -08002969 * @see CaptureResult#CONTROL_AF_SCENE_CHANGE
2970 */
2971 public static final int CONTROL_AF_SCENE_CHANGE_DETECTED = 1;
2972
2973 //
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002974 // Enumeration values for CaptureResult#FLASH_STATE
2975 //
2976
2977 /**
Zhijun He8dda7272014-03-25 13:49:30 -07002978 * <p>No flash on camera.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002979 * @see CaptureResult#FLASH_STATE
2980 */
2981 public static final int FLASH_STATE_UNAVAILABLE = 0;
2982
2983 /**
Zhijun He8dda7272014-03-25 13:49:30 -07002984 * <p>Flash is charging and cannot be fired.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002985 * @see CaptureResult#FLASH_STATE
2986 */
2987 public static final int FLASH_STATE_CHARGING = 1;
2988
2989 /**
Zhijun He8dda7272014-03-25 13:49:30 -07002990 * <p>Flash is ready to fire.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002991 * @see CaptureResult#FLASH_STATE
2992 */
2993 public static final int FLASH_STATE_READY = 2;
2994
2995 /**
Zhijun He8dda7272014-03-25 13:49:30 -07002996 * <p>Flash fired for this capture.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002997 * @see CaptureResult#FLASH_STATE
2998 */
2999 public static final int FLASH_STATE_FIRED = 3;
3000
Zhijun He8dda7272014-03-25 13:49:30 -07003001 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07003002 * <p>Flash partially illuminated this frame.</p>
3003 * <p>This is usually due to the next or previous frame having
3004 * the flash fire, and the flash spilling into this capture
Zhijun He8dda7272014-03-25 13:49:30 -07003005 * due to hardware limitations.</p>
3006 * @see CaptureResult#FLASH_STATE
3007 */
3008 public static final int FLASH_STATE_PARTIAL = 4;
3009
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07003010 //
3011 // Enumeration values for CaptureResult#LENS_STATE
3012 //
3013
3014 /**
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08003015 * <p>The lens parameters ({@link CaptureRequest#LENS_FOCAL_LENGTH android.lens.focalLength}, {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance},
3016 * {@link CaptureRequest#LENS_FILTER_DENSITY android.lens.filterDensity} and {@link CaptureRequest#LENS_APERTURE android.lens.aperture}) are not changing.</p>
Zhijun Heca1b73a2014-02-03 12:39:53 -08003017 *
3018 * @see CaptureRequest#LENS_APERTURE
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08003019 * @see CaptureRequest#LENS_FILTER_DENSITY
Zhijun Heca1b73a2014-02-03 12:39:53 -08003020 * @see CaptureRequest#LENS_FOCAL_LENGTH
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08003021 * @see CaptureRequest#LENS_FOCUS_DISTANCE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07003022 * @see CaptureResult#LENS_STATE
3023 */
3024 public static final int LENS_STATE_STATIONARY = 0;
3025
Igor Murashkin9ea4ae62013-09-11 21:40:11 -07003026 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07003027 * <p>One or several of the lens parameters
3028 * ({@link CaptureRequest#LENS_FOCAL_LENGTH android.lens.focalLength}, {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance},
3029 * {@link CaptureRequest#LENS_FILTER_DENSITY android.lens.filterDensity} or {@link CaptureRequest#LENS_APERTURE android.lens.aperture}) is
3030 * currently changing.</p>
Zhijun Heca1b73a2014-02-03 12:39:53 -08003031 *
3032 * @see CaptureRequest#LENS_APERTURE
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08003033 * @see CaptureRequest#LENS_FILTER_DENSITY
Zhijun Heca1b73a2014-02-03 12:39:53 -08003034 * @see CaptureRequest#LENS_FOCAL_LENGTH
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08003035 * @see CaptureRequest#LENS_FOCUS_DISTANCE
Igor Murashkin9ea4ae62013-09-11 21:40:11 -07003036 * @see CaptureResult#LENS_STATE
3037 */
3038 public static final int LENS_STATE_MOVING = 1;
3039
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07003040 //
3041 // Enumeration values for CaptureResult#STATISTICS_SCENE_FLICKER
3042 //
3043
3044 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07003045 * <p>The camera device does not detect any flickering illumination
3046 * in the current scene.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07003047 * @see CaptureResult#STATISTICS_SCENE_FLICKER
3048 */
3049 public static final int STATISTICS_SCENE_FLICKER_NONE = 0;
3050
3051 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07003052 * <p>The camera device detects illumination flickering at 50Hz
3053 * in the current scene.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07003054 * @see CaptureResult#STATISTICS_SCENE_FLICKER
3055 */
3056 public static final int STATISTICS_SCENE_FLICKER_50HZ = 1;
3057
3058 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07003059 * <p>The camera device detects illumination flickering at 60Hz
3060 * in the current scene.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07003061 * @see CaptureResult#STATISTICS_SCENE_FLICKER
3062 */
3063 public static final int STATISTICS_SCENE_FLICKER_60HZ = 2;
3064
Igor Murashkin3865a842014-01-17 18:18:39 -08003065 //
3066 // Enumeration values for CaptureResult#SYNC_FRAME_NUMBER
3067 //
3068
3069 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07003070 * <p>The current result is not yet fully synchronized to any request.</p>
3071 * <p>Synchronization is in progress, and reading metadata from this
Igor Murashkin3865a842014-01-17 18:18:39 -08003072 * result may include a mix of data that have taken effect since the
3073 * last synchronization time.</p>
3074 * <p>In some future result, within {@link CameraCharacteristics#SYNC_MAX_LATENCY android.sync.maxLatency} frames,
3075 * this value will update to the actual frame number frame number
3076 * the result is guaranteed to be synchronized to (as long as the
3077 * request settings remain constant).</p>
3078 *
3079 * @see CameraCharacteristics#SYNC_MAX_LATENCY
3080 * @see CaptureResult#SYNC_FRAME_NUMBER
3081 * @hide
3082 */
3083 public static final int SYNC_FRAME_NUMBER_CONVERGING = -1;
3084
3085 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07003086 * <p>The current result's synchronization status is unknown.</p>
3087 * <p>The result may have already converged, or it may be in
3088 * progress. Reading from this result may include some mix
3089 * of settings from past requests.</p>
Igor Murashkin3865a842014-01-17 18:18:39 -08003090 * <p>After a settings change, the new settings will eventually all
3091 * take effect for the output buffers and results. However, this
3092 * value will not change when that happens. Altering settings
3093 * rapidly may provide outcomes using mixes of settings from recent
3094 * requests.</p>
3095 * <p>This value is intended primarily for backwards compatibility with
3096 * the older camera implementations (for android.hardware.Camera).</p>
3097 * @see CaptureResult#SYNC_FRAME_NUMBER
3098 * @hide
3099 */
3100 public static final int SYNC_FRAME_NUMBER_UNKNOWN = -2;
3101
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07003102 /*~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~
3103 * End generated code
3104 *~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~O@*/
3105
Igor Murashkinb519cc52013-07-02 11:23:44 -07003106}