blob: e464f2a3fad24fccd9978c0c5877edcb459b5956 [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
Igor Murashkind6d65152014-05-19 16:31:02 -070019import android.util.Log;
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080020
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070021import java.lang.reflect.Field;
Igor Murashkin03fdb142013-09-30 12:14:58 -070022import java.lang.reflect.Modifier;
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070023import java.util.ArrayList;
24import java.util.Collections;
25import java.util.List;
26
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080027/**
28 * The base class for camera controls and information.
29 *
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070030 * <p>
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080031 * This class defines the basic key/value map used for querying for camera
32 * characteristics or capture results, and for setting camera request
33 * parameters.
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070034 * </p>
35 *
36 * <p>
37 * All instances of CameraMetadata are immutable. The list of keys with {@link #getKeys()}
Igor Murashkind6d65152014-05-19 16:31:02 -070038 * never changes, nor do the values returned by any key with {@code #get} throughout
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070039 * the lifetime of the object.
40 * </p>
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080041 *
42 * @see CameraDevice
43 * @see CameraManager
Igor Murashkin68f40062013-09-10 12:15:54 -070044 * @see CameraCharacteristics
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080045 **/
Igor Murashkind6d65152014-05-19 16:31:02 -070046public abstract class CameraMetadata<TKey> {
47
48 private static final String TAG = "CameraMetadataAb";
49 private static final boolean VERBOSE = false;
Igor Murashkin70725502013-06-25 20:27:06 +000050
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080051 /**
Igor Murashkin68f40062013-09-10 12:15:54 -070052 * Set a camera metadata field to a value. The field definitions can be
53 * found in {@link CameraCharacteristics}, {@link CaptureResult}, and
54 * {@link CaptureRequest}.
55 *
56 * @param key The metadata field to write.
57 * @param value The value to set the field to, which must be of a matching
58 * type to the key.
59 *
Eino-Ville Talvala70c22072013-08-27 12:09:04 -070060 * @hide
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080061 */
Eino-Ville Talvala70c22072013-08-27 12:09:04 -070062 protected CameraMetadata() {
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080063 }
64
65 /**
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070066 * Get a camera metadata field value.
67 *
68 * <p>The field definitions can be
Igor Murashkin68f40062013-09-10 12:15:54 -070069 * found in {@link CameraCharacteristics}, {@link CaptureResult}, and
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070070 * {@link CaptureRequest}.</p>
71 *
72 * <p>Querying the value for the same key more than once will return a value
73 * which is equal to the previous queried value.</p>
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080074 *
Igor Murashkinb519cc52013-07-02 11:23:44 -070075 * @throws IllegalArgumentException if the key was not valid
76 *
Benjamin Hendricks24eb8a32013-08-15 12:46:22 -070077 * @param key The metadata field to read.
78 * @return The value of that key, or {@code null} if the field is not set.
Igor Murashkind6d65152014-05-19 16:31:02 -070079 *
80 * @hide
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080081 */
Igor Murashkind6d65152014-05-19 16:31:02 -070082 protected abstract <T> T getProtected(TKey key);
83
84 /**
85 * @hide
86 */
87 protected abstract Class<TKey> getKeyClass();
Eino-Ville Talvalab2675542012-12-12 13:29:45 -080088
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070089 /**
90 * Returns a list of the keys contained in this map.
91 *
92 * <p>The list returned is not modifiable, so any attempts to modify it will throw
93 * a {@code UnsupportedOperationException}.</p>
94 *
Igor Murashkind6d65152014-05-19 16:31:02 -070095 * <p>All values retrieved by a key from this list with {@code #get} are guaranteed to be
Igor Murashkin7a36a0f2013-09-10 18:13:09 -070096 * non-{@code null}. Each key is only listed once in the list. The order of the keys
97 * is undefined.</p>
98 *
99 * @return List of the keys contained in this map.
100 */
Igor Murashkind6d65152014-05-19 16:31:02 -0700101 @SuppressWarnings("unchecked")
102 public List<TKey> getKeys() {
103 Class<CameraMetadata<TKey>> thisClass = (Class<CameraMetadata<TKey>>) getClass();
104 return Collections.unmodifiableList(getKeysStatic(thisClass, getKeyClass(), this));
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700105 }
106
107 /**
108 * Return a list of all the Key<?> that are declared as a field inside of the class
109 * {@code type}.
110 *
111 * <p>
112 * Optionally, if {@code instance} is not null, then filter out any keys with null values.
113 * </p>
114 */
Igor Murashkind6d65152014-05-19 16:31:02 -0700115 /*package*/ @SuppressWarnings("unchecked")
116 static <TKey> ArrayList<TKey> getKeysStatic(
117 Class<?> type, Class<TKey> keyClass,
118 CameraMetadata<TKey> instance) {
119
120 if (VERBOSE) Log.v(TAG, "getKeysStatic for " + type);
121
122 ArrayList<TKey> keyList = new ArrayList<TKey>();
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700123
124 Field[] fields = type.getDeclaredFields();
125 for (Field field : fields) {
Igor Murashkin03fdb142013-09-30 12:14:58 -0700126 // Filter for Keys that are public
Igor Murashkind6d65152014-05-19 16:31:02 -0700127 if (field.getType().isAssignableFrom(keyClass) &&
Igor Murashkin03fdb142013-09-30 12:14:58 -0700128 (field.getModifiers() & Modifier.PUBLIC) != 0) {
Igor Murashkind6d65152014-05-19 16:31:02 -0700129
130 TKey key;
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700131 try {
Igor Murashkind6d65152014-05-19 16:31:02 -0700132 key = (TKey) field.get(instance);
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700133 } catch (IllegalAccessException e) {
134 throw new AssertionError("Can't get IllegalAccessException", e);
135 } catch (IllegalArgumentException e) {
136 throw new AssertionError("Can't get IllegalArgumentException", e);
137 }
Igor Murashkind6d65152014-05-19 16:31:02 -0700138
139 if (instance == null || instance.getProtected(key) != null) {
Igor Murashkin7a36a0f2013-09-10 18:13:09 -0700140 keyList.add(key);
141 }
142 }
143 }
144
145 return keyList;
146 }
147
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700148 /*@O~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~
149 * The enum values below this point are generated from metadata
150 * definitions in /system/media/camera/docs. Do not modify by hand or
151 * modify the comment blocks at the start or end.
152 *~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~*/
153
154 //
Zhijun Heff413932014-02-07 15:44:30 -0800155 // Enumeration values for CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION
156 //
157
158 /**
159 * <p>The lens focus distance is not accurate, and the units used for
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700160 * {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance} do not correspond to any physical units.</p>
161 * <p>Setting the lens to the same focus distance on separate occasions may
Zhijun Heff413932014-02-07 15:44:30 -0800162 * result in a different real focus distance, depending on factors such
163 * as the orientation of the device, the age of the focusing mechanism,
164 * and the device temperature. The focus distance value will still be
165 * in the range of <code>[0, {@link CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE android.lens.info.minimumFocusDistance}]</code>, where 0
166 * represents the farthest focus.</p>
167 *
168 * @see CaptureRequest#LENS_FOCUS_DISTANCE
169 * @see CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE
170 * @see CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION
171 */
172 public static final int LENS_INFO_FOCUS_DISTANCE_CALIBRATION_UNCALIBRATED = 0;
173
174 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700175 * <p>The lens focus distance is measured in diopters.</p>
176 * <p>However, setting the lens to the same focus distance
177 * on separate occasions may result in a different real
178 * focus distance, depending on factors such as the
179 * orientation of the device, the age of the focusing
180 * mechanism, and the device temperature.</p>
Zhijun Heff413932014-02-07 15:44:30 -0800181 * @see CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION
182 */
183 public static final int LENS_INFO_FOCUS_DISTANCE_CALIBRATION_APPROXIMATE = 1;
184
185 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700186 * <p>The lens focus distance is measured in diopters, and
187 * is calibrated.</p>
188 * <p>The lens mechanism is calibrated so that setting the
189 * same focus distance is repeatable on multiple
190 * occasions with good accuracy, and the focus distance
191 * corresponds to the real physical distance to the plane
192 * of best focus.</p>
Zhijun Heff413932014-02-07 15:44:30 -0800193 * @see CameraCharacteristics#LENS_INFO_FOCUS_DISTANCE_CALIBRATION
194 */
195 public static final int LENS_INFO_FOCUS_DISTANCE_CALIBRATION_CALIBRATED = 2;
196
197 //
Igor Murashkin68f40062013-09-10 12:15:54 -0700198 // Enumeration values for CameraCharacteristics#LENS_FACING
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700199 //
200
201 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700202 * <p>The camera device faces the same direction as the device's screen.</p>
Igor Murashkin68f40062013-09-10 12:15:54 -0700203 * @see CameraCharacteristics#LENS_FACING
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700204 */
205 public static final int LENS_FACING_FRONT = 0;
206
207 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700208 * <p>The camera device faces the opposite direction as the device's screen.</p>
Igor Murashkin68f40062013-09-10 12:15:54 -0700209 * @see CameraCharacteristics#LENS_FACING
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700210 */
211 public static final int LENS_FACING_BACK = 1;
212
213 //
Igor Murashkine46c0da2014-02-07 18:34:37 -0800214 // Enumeration values for CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
215 //
216
217 /**
218 * <p>The minimal set of capabilities that every camera
219 * device (regardless of {@link CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL android.info.supportedHardwareLevel})
220 * will support.</p>
221 * <p>The full set of features supported by this capability makes
222 * the camera2 api backwards compatible with the camera1
223 * (android.hardware.Camera) API.</p>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800224 *
225 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
226 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700227 * @hide
Igor Murashkine46c0da2014-02-07 18:34:37 -0800228 */
229 public static final int REQUEST_AVAILABLE_CAPABILITIES_BACKWARD_COMPATIBLE = 0;
230
231 /**
232 * <p>This is a catch-all capability to include all other
233 * tags or functionality not encapsulated by one of the other
234 * capabilities.</p>
235 * <p>A typical example is all tags marked 'optional'.</p>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800236 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700237 * @hide
Igor Murashkine46c0da2014-02-07 18:34:37 -0800238 */
239 public static final int REQUEST_AVAILABLE_CAPABILITIES_OPTIONAL = 1;
240
241 /**
242 * <p>The camera device can be manually controlled (3A algorithms such
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700243 * as auto-exposure, and auto-focus can be bypassed).
Zhijun He50f72432014-05-28 13:52:04 -0700244 * The camera device supports basic manual control of the sensor image
245 * acquisition related stages. This means the following controls are
246 * guaranteed to be supported:</p>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800247 * <ul>
Zhijun He50f72432014-05-28 13:52:04 -0700248 * <li>Manual frame duration control<ul>
249 * <li>{@link CaptureRequest#SENSOR_FRAME_DURATION android.sensor.frameDuration}</li>
250 * <li>{@link CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION android.sensor.info.maxFrameDuration}</li>
Zhijun He50f72432014-05-28 13:52:04 -0700251 * </ul>
252 * </li>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800253 * <li>Manual exposure control<ul>
254 * <li>{@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}</li>
255 * <li>{@link CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE android.sensor.info.exposureTimeRange}</li>
256 * </ul>
257 * </li>
258 * <li>Manual sensitivity control<ul>
259 * <li>{@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}</li>
260 * <li>{@link CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE android.sensor.info.sensitivityRange}</li>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800261 * </ul>
262 * </li>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700263 * <li>Manual lens control (if the lens is adjustable)<ul>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800264 * <li>android.lens.*</li>
265 * </ul>
266 * </li>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700267 * <li>Manual flash control (if a flash unit is present)<ul>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800268 * <li>android.flash.*</li>
269 * </ul>
270 * </li>
271 * <li>Manual black level locking<ul>
272 * <li>{@link CaptureRequest#BLACK_LEVEL_LOCK android.blackLevel.lock}</li>
273 * </ul>
274 * </li>
275 * </ul>
276 * <p>If any of the above 3A algorithms are enabled, then the camera
277 * device will accurately report the values applied by 3A in the
278 * result.</p>
Zhijun He50f72432014-05-28 13:52:04 -0700279 * <p>A given camera device may also support additional manual sensor controls,
280 * but this capability only covers the above list of controls.</p>
Ruben Brunk3e4fed22014-06-18 17:08:42 -0700281 * <p>If this is supported, {@link CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP android.scaler.streamConfigurationMap} will
282 * additionally return a min frame duration that is greater than
283 * zero for each supported size-format combination.</p>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800284 *
285 * @see CaptureRequest#BLACK_LEVEL_LOCK
Zhijun He50f72432014-05-28 13:52:04 -0700286 * @see CameraCharacteristics#SCALER_STREAM_CONFIGURATION_MAP
Igor Murashkine46c0da2014-02-07 18:34:37 -0800287 * @see CaptureRequest#SENSOR_EXPOSURE_TIME
Zhijun He50f72432014-05-28 13:52:04 -0700288 * @see CaptureRequest#SENSOR_FRAME_DURATION
Igor Murashkine46c0da2014-02-07 18:34:37 -0800289 * @see CameraCharacteristics#SENSOR_INFO_EXPOSURE_TIME_RANGE
Zhijun He50f72432014-05-28 13:52:04 -0700290 * @see CameraCharacteristics#SENSOR_INFO_MAX_FRAME_DURATION
Igor Murashkine46c0da2014-02-07 18:34:37 -0800291 * @see CameraCharacteristics#SENSOR_INFO_SENSITIVITY_RANGE
292 * @see CaptureRequest#SENSOR_SENSITIVITY
293 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
294 */
295 public static final int REQUEST_AVAILABLE_CAPABILITIES_MANUAL_SENSOR = 2;
296
297 /**
Zhijun He50f72432014-05-28 13:52:04 -0700298 * <p>The camera device post-processing stages can be manually controlled.
299 * The camera device supports basic manual control of the image post-processing
300 * stages. This means the following controls are guaranteed to be supported:</p>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800301 * <ul>
302 * <li>Manual tonemap control<ul>
Yin-Chia Yeh8490ace2014-05-27 10:04:54 -0700303 * <li>{@link CaptureRequest#TONEMAP_CURVE android.tonemap.curve}</li>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800304 * <li>{@link CaptureRequest#TONEMAP_MODE android.tonemap.mode}</li>
305 * <li>{@link CameraCharacteristics#TONEMAP_MAX_CURVE_POINTS android.tonemap.maxCurvePoints}</li>
306 * </ul>
307 * </li>
308 * <li>Manual white balance control<ul>
309 * <li>{@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}</li>
310 * <li>{@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains}</li>
311 * </ul>
312 * </li>
Zhijun He28288ca2014-06-25 15:49:13 -0700313 * <li>Manual lens shading map control<ul>
314 * <li>{@link CaptureRequest#SHADING_MODE android.shading.mode}</li>
315 * <li>{@link CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE android.statistics.lensShadingMapMode}</li>
Ruben Brunk57493682014-05-27 18:58:08 -0700316 * <li>android.statistics.lensShadingMap</li>
317 * <li>android.lens.info.shadingMapSize</li>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800318 * </ul>
319 * </li>
320 * </ul>
321 * <p>If auto white balance is enabled, then the camera device
322 * will accurately report the values applied by AWB in the result.</p>
Zhijun He50f72432014-05-28 13:52:04 -0700323 * <p>A given camera device may also support additional post-processing
324 * controls, but this capability only covers the above list of controls.</p>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800325 *
326 * @see CaptureRequest#COLOR_CORRECTION_GAINS
327 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Zhijun He28288ca2014-06-25 15:49:13 -0700328 * @see CaptureRequest#SHADING_MODE
329 * @see CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE
Yin-Chia Yeh8490ace2014-05-27 10:04:54 -0700330 * @see CaptureRequest#TONEMAP_CURVE
Igor Murashkine46c0da2014-02-07 18:34:37 -0800331 * @see CameraCharacteristics#TONEMAP_MAX_CURVE_POINTS
332 * @see CaptureRequest#TONEMAP_MODE
333 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
334 */
Zhijun He50f72432014-05-28 13:52:04 -0700335 public static final int REQUEST_AVAILABLE_CAPABILITIES_MANUAL_POST_PROCESSING = 3;
Igor Murashkine46c0da2014-02-07 18:34:37 -0800336
337 /**
338 * <p>The camera device supports the Zero Shutter Lag use case.</p>
339 * <ul>
340 * <li>At least one input stream can be used.</li>
341 * <li>RAW_OPAQUE is supported as an output/input format</li>
342 * <li>Using RAW_OPAQUE does not cause a frame rate drop
343 * relative to the sensor's maximum capture rate (at that
344 * resolution).</li>
345 * <li>RAW_OPAQUE will be reprocessable into both YUV_420_888
346 * and JPEG formats.</li>
347 * <li>The maximum available resolution for RAW_OPAQUE streams
348 * (both input/output) will match the maximum available
349 * resolution of JPEG streams.</li>
350 * </ul>
351 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700352 * @hide
Igor Murashkine46c0da2014-02-07 18:34:37 -0800353 */
354 public static final int REQUEST_AVAILABLE_CAPABILITIES_ZSL = 4;
355
356 /**
357 * <p>The camera device supports outputting RAW buffers that can be
358 * saved offline into a DNG format. It can reprocess DNG
359 * files (produced from the same camera device) back into YUV.</p>
360 * <ul>
361 * <li>At least one input stream can be used.</li>
362 * <li>RAW16 is supported as output/input format.</li>
363 * <li>RAW16 is reprocessable into both YUV_420_888 and JPEG
364 * formats.</li>
365 * <li>The maximum available resolution for RAW16 streams (both
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700366 * input/output) will match either the value in
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -0700367 * {@link CameraCharacteristics#SENSOR_INFO_PIXEL_ARRAY_SIZE android.sensor.info.pixelArraySize} or
368 * {@link CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE android.sensor.info.activeArraySize}.</li>
Igor Murashkine46c0da2014-02-07 18:34:37 -0800369 * <li>All DNG-related optional metadata entries are provided
370 * by the camera device.</li>
371 * </ul>
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -0800372 *
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -0700373 * @see CameraCharacteristics#SENSOR_INFO_ACTIVE_ARRAY_SIZE
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -0800374 * @see CameraCharacteristics#SENSOR_INFO_PIXEL_ARRAY_SIZE
Igor Murashkine46c0da2014-02-07 18:34:37 -0800375 * @see CameraCharacteristics#REQUEST_AVAILABLE_CAPABILITIES
376 */
377 public static final int REQUEST_AVAILABLE_CAPABILITIES_DNG = 5;
378
379 //
Zhijun He14986152014-05-22 21:17:37 -0700380 // Enumeration values for CameraCharacteristics#SCALER_CROPPING_TYPE
381 //
382
383 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700384 * <p>The camera device only supports centered crop regions.</p>
Zhijun He14986152014-05-22 21:17:37 -0700385 * @see CameraCharacteristics#SCALER_CROPPING_TYPE
386 */
387 public static final int SCALER_CROPPING_TYPE_CENTER_ONLY = 0;
388
389 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700390 * <p>The camera device supports arbitrarily chosen crop regions.</p>
Zhijun He14986152014-05-22 21:17:37 -0700391 * @see CameraCharacteristics#SCALER_CROPPING_TYPE
392 */
393 public static final int SCALER_CROPPING_TYPE_FREEFORM = 1;
394
395 //
Zhijun Hed1784962014-04-08 17:41:46 -0700396 // Enumeration values for CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT
397 //
398
399 /**
400 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT
401 */
402 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_RGGB = 0;
403
404 /**
405 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT
406 */
407 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GRBG = 1;
408
409 /**
410 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT
411 */
412 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_GBRG = 2;
413
414 /**
415 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT
416 */
417 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_BGGR = 3;
418
419 /**
420 * <p>Sensor is not Bayer; output has 3 16-bit
421 * values for each pixel, instead of just 1 16-bit value
422 * per pixel.</p>
423 * @see CameraCharacteristics#SENSOR_INFO_COLOR_FILTER_ARRANGEMENT
424 */
425 public static final int SENSOR_INFO_COLOR_FILTER_ARRANGEMENT_RGB = 4;
426
427 //
Zhijun He45fa43a12014-06-13 18:29:37 -0700428 // Enumeration values for CameraCharacteristics#SENSOR_INFO_TIMESTAMP_CALIBRATION
429 //
430
431 /**
432 * <p>Timestamps from {@link CaptureResult#SENSOR_TIMESTAMP android.sensor.timestamp} are in nanoseconds and monotonic,
433 * but can not be compared to timestamps from other subsystems
434 * (e.g. accelerometer, gyro etc.), or other instances of the same or different
435 * camera devices in the same system. Timestamps between streams and results for
436 * a single camera instance are comparable, and the timestamps for all buffers
437 * and the result metadata generated by a single capture are identical.</p>
438 *
439 * @see CaptureResult#SENSOR_TIMESTAMP
440 * @see CameraCharacteristics#SENSOR_INFO_TIMESTAMP_CALIBRATION
441 */
442 public static final int SENSOR_INFO_TIMESTAMP_CALIBRATION_UNCALIBRATED = 0;
443
444 /**
445 * <p>Timestamps from {@link CaptureResult#SENSOR_TIMESTAMP android.sensor.timestamp} are in the same timebase as
446 * android.os.SystemClock#elapsedRealtimeNanos(),
447 * and they can be compared to other timestamps using that base.</p>
448 *
449 * @see CaptureResult#SENSOR_TIMESTAMP
450 * @see CameraCharacteristics#SENSOR_INFO_TIMESTAMP_CALIBRATION
451 */
452 public static final int SENSOR_INFO_TIMESTAMP_CALIBRATION_CALIBRATED = 1;
453
454 //
Ruben Brunk7c062362014-04-15 23:53:53 -0700455 // Enumeration values for CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
456 //
457
458 /**
459 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
460 */
461 public static final int SENSOR_REFERENCE_ILLUMINANT1_DAYLIGHT = 1;
462
463 /**
464 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
465 */
466 public static final int SENSOR_REFERENCE_ILLUMINANT1_FLUORESCENT = 2;
467
468 /**
469 * <p>Incandescent light</p>
470 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
471 */
472 public static final int SENSOR_REFERENCE_ILLUMINANT1_TUNGSTEN = 3;
473
474 /**
475 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
476 */
477 public static final int SENSOR_REFERENCE_ILLUMINANT1_FLASH = 4;
478
479 /**
480 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
481 */
482 public static final int SENSOR_REFERENCE_ILLUMINANT1_FINE_WEATHER = 9;
483
484 /**
485 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
486 */
487 public static final int SENSOR_REFERENCE_ILLUMINANT1_CLOUDY_WEATHER = 10;
488
489 /**
490 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
491 */
492 public static final int SENSOR_REFERENCE_ILLUMINANT1_SHADE = 11;
493
494 /**
495 * <p>D 5700 - 7100K</p>
496 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
497 */
498 public static final int SENSOR_REFERENCE_ILLUMINANT1_DAYLIGHT_FLUORESCENT = 12;
499
500 /**
501 * <p>N 4600 - 5400K</p>
502 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
503 */
504 public static final int SENSOR_REFERENCE_ILLUMINANT1_DAY_WHITE_FLUORESCENT = 13;
505
506 /**
507 * <p>W 3900 - 4500K</p>
508 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
509 */
510 public static final int SENSOR_REFERENCE_ILLUMINANT1_COOL_WHITE_FLUORESCENT = 14;
511
512 /**
513 * <p>WW 3200 - 3700K</p>
514 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
515 */
516 public static final int SENSOR_REFERENCE_ILLUMINANT1_WHITE_FLUORESCENT = 15;
517
518 /**
519 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
520 */
521 public static final int SENSOR_REFERENCE_ILLUMINANT1_STANDARD_A = 17;
522
523 /**
524 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
525 */
526 public static final int SENSOR_REFERENCE_ILLUMINANT1_STANDARD_B = 18;
527
528 /**
529 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
530 */
531 public static final int SENSOR_REFERENCE_ILLUMINANT1_STANDARD_C = 19;
532
533 /**
534 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
535 */
536 public static final int SENSOR_REFERENCE_ILLUMINANT1_D55 = 20;
537
538 /**
539 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
540 */
541 public static final int SENSOR_REFERENCE_ILLUMINANT1_D65 = 21;
542
543 /**
544 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
545 */
546 public static final int SENSOR_REFERENCE_ILLUMINANT1_D75 = 22;
547
548 /**
549 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
550 */
551 public static final int SENSOR_REFERENCE_ILLUMINANT1_D50 = 23;
552
553 /**
554 * @see CameraCharacteristics#SENSOR_REFERENCE_ILLUMINANT1
555 */
556 public static final int SENSOR_REFERENCE_ILLUMINANT1_ISO_STUDIO_TUNGSTEN = 24;
557
558 //
Igor Murashkin68f40062013-09-10 12:15:54 -0700559 // Enumeration values for CameraCharacteristics#LED_AVAILABLE_LEDS
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700560 //
561
562 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700563 * <p>android.led.transmit control is used.</p>
Igor Murashkin68f40062013-09-10 12:15:54 -0700564 * @see CameraCharacteristics#LED_AVAILABLE_LEDS
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700565 * @hide
566 */
567 public static final int LED_AVAILABLE_LEDS_TRANSMIT = 0;
568
569 //
Igor Murashkin68f40062013-09-10 12:15:54 -0700570 // Enumeration values for CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700571 //
572
573 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700574 * <p>This camera device has only limited capabilities.</p>
Igor Murashkin68f40062013-09-10 12:15:54 -0700575 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700576 */
577 public static final int INFO_SUPPORTED_HARDWARE_LEVEL_LIMITED = 0;
578
579 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700580 * <p>This camera device is capable of supporting advanced imaging
581 * applications.</p>
Igor Murashkin68f40062013-09-10 12:15:54 -0700582 * @see CameraCharacteristics#INFO_SUPPORTED_HARDWARE_LEVEL
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700583 */
584 public static final int INFO_SUPPORTED_HARDWARE_LEVEL_FULL = 1;
585
586 //
Igor Murashkin3865a842014-01-17 18:18:39 -0800587 // Enumeration values for CameraCharacteristics#SYNC_MAX_LATENCY
588 //
589
590 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700591 * <p>Every frame has the requests immediately applied.</p>
592 * <p>Furthermore for all results,
593 * <code>android.sync.frameNumber == android.request.frameCount</code></p>
Igor Murashkin3865a842014-01-17 18:18:39 -0800594 * <p>Changing controls over multiple requests one after another will
595 * produce results that have those controls applied atomically
596 * each frame.</p>
597 * <p>All FULL capability devices will have this as their maxLatency.</p>
598 * @see CameraCharacteristics#SYNC_MAX_LATENCY
599 */
600 public static final int SYNC_MAX_LATENCY_PER_FRAME_CONTROL = 0;
601
602 /**
603 * <p>Each new frame has some subset (potentially the entire set)
604 * of the past requests applied to the camera settings.</p>
605 * <p>By submitting a series of identical requests, the camera device
606 * will eventually have the camera settings applied, but it is
607 * unknown when that exact point will be.</p>
608 * @see CameraCharacteristics#SYNC_MAX_LATENCY
609 */
610 public static final int SYNC_MAX_LATENCY_UNKNOWN = -1;
611
612 //
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700613 // Enumeration values for CaptureRequest#COLOR_CORRECTION_MODE
614 //
615
616 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800617 * <p>Use the {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform} matrix
Igor Murashkin7d2a5c52014-01-17 15:07:52 -0800618 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} to do color conversion.</p>
619 * <p>All advanced white balance adjustments (not specified
620 * by our white balance pipeline) must be disabled.</p>
621 * <p>If AWB is enabled with <code>{@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode} != OFF</code>, then
622 * TRANSFORM_MATRIX is ignored. The camera device will override
623 * this value to either FAST or HIGH_QUALITY.</p>
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800624 *
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800625 * @see CaptureRequest#COLOR_CORRECTION_GAINS
Eino-Ville Talvala265b34c2014-01-16 16:18:52 -0800626 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Igor Murashkin7d2a5c52014-01-17 15:07:52 -0800627 * @see CaptureRequest#CONTROL_AWB_MODE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700628 * @see CaptureRequest#COLOR_CORRECTION_MODE
629 */
630 public static final int COLOR_CORRECTION_MODE_TRANSFORM_MATRIX = 0;
631
632 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700633 * <p>Color correction processing must not slow down
634 * capture rate relative to sensor raw output.</p>
Igor Murashkin7d2a5c52014-01-17 15:07:52 -0800635 * <p>Advanced white balance adjustments above and beyond
636 * the specified white balance pipeline may be applied.</p>
637 * <p>If AWB is enabled with <code>{@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode} != OFF</code>, then
638 * the camera device uses the last frame's AWB values
639 * (or defaults if AWB has never been run).</p>
640 *
641 * @see CaptureRequest#CONTROL_AWB_MODE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700642 * @see CaptureRequest#COLOR_CORRECTION_MODE
643 */
644 public static final int COLOR_CORRECTION_MODE_FAST = 1;
645
646 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700647 * <p>Color correction processing operates at improved
648 * quality but reduced capture rate (relative to sensor raw
649 * output).</p>
Igor Murashkin7d2a5c52014-01-17 15:07:52 -0800650 * <p>Advanced white balance adjustments above and beyond
651 * the specified white balance pipeline may be applied.</p>
652 * <p>If AWB is enabled with <code>{@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode} != OFF</code>, then
653 * the camera device uses the last frame's AWB values
654 * (or defaults if AWB has never been run).</p>
655 *
656 * @see CaptureRequest#CONTROL_AWB_MODE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700657 * @see CaptureRequest#COLOR_CORRECTION_MODE
658 */
659 public static final int COLOR_CORRECTION_MODE_HIGH_QUALITY = 2;
660
661 //
662 // Enumeration values for CaptureRequest#CONTROL_AE_ANTIBANDING_MODE
663 //
664
665 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800666 * <p>The camera device will not adjust exposure duration to
667 * avoid banding problems.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700668 * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE
669 */
670 public static final int CONTROL_AE_ANTIBANDING_MODE_OFF = 0;
671
672 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800673 * <p>The camera device will adjust exposure duration to
674 * avoid banding problems with 50Hz illumination sources.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700675 * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE
676 */
677 public static final int CONTROL_AE_ANTIBANDING_MODE_50HZ = 1;
678
679 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800680 * <p>The camera device will adjust exposure duration to
681 * avoid banding problems with 60Hz illumination
682 * sources.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700683 * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE
684 */
685 public static final int CONTROL_AE_ANTIBANDING_MODE_60HZ = 2;
686
687 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800688 * <p>The camera device will automatically adapt its
689 * antibanding routine to the current illumination
690 * conditions. This is the default.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700691 * @see CaptureRequest#CONTROL_AE_ANTIBANDING_MODE
692 */
693 public static final int CONTROL_AE_ANTIBANDING_MODE_AUTO = 3;
694
695 //
696 // Enumeration values for CaptureRequest#CONTROL_AE_MODE
697 //
698
699 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700700 * <p>The camera device's autoexposure routine is disabled.</p>
701 * <p>The application-selected {@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime},
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800702 * {@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity} and
703 * {@link CaptureRequest#SENSOR_FRAME_DURATION android.sensor.frameDuration} are used by the camera
704 * device, along with android.flash.* fields, if there's
705 * a flash unit for this camera device.</p>
706 *
Zhijun He5f2a47f2014-01-16 15:44:41 -0800707 * @see CaptureRequest#SENSOR_EXPOSURE_TIME
Eino-Ville Talvala265b34c2014-01-16 16:18:52 -0800708 * @see CaptureRequest#SENSOR_FRAME_DURATION
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800709 * @see CaptureRequest#SENSOR_SENSITIVITY
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700710 * @see CaptureRequest#CONTROL_AE_MODE
711 */
712 public static final int CONTROL_AE_MODE_OFF = 0;
713
714 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800715 * <p>The camera device's autoexposure routine is active,
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700716 * with no flash control.</p>
717 * <p>The application's values for
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800718 * {@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime},
719 * {@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}, and
720 * {@link CaptureRequest#SENSOR_FRAME_DURATION android.sensor.frameDuration} are ignored. The
721 * application has control over the various
722 * android.flash.* fields.</p>
723 *
Zhijun He5f2a47f2014-01-16 15:44:41 -0800724 * @see CaptureRequest#SENSOR_EXPOSURE_TIME
Eino-Ville Talvala265b34c2014-01-16 16:18:52 -0800725 * @see CaptureRequest#SENSOR_FRAME_DURATION
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800726 * @see CaptureRequest#SENSOR_SENSITIVITY
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700727 * @see CaptureRequest#CONTROL_AE_MODE
728 */
729 public static final int CONTROL_AE_MODE_ON = 1;
730
731 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800732 * <p>Like ON, except that the camera device also controls
733 * the camera's flash unit, firing it in low-light
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700734 * conditions.</p>
735 * <p>The flash may be fired during a precapture sequence
736 * (triggered by {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}) and
737 * may be fired for captures for which the
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800738 * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} field is set to
739 * STILL_CAPTURE</p>
740 *
Igor Murashkin3242f4f2014-01-15 12:27:41 -0800741 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
Zhijun He5f2a47f2014-01-16 15:44:41 -0800742 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700743 * @see CaptureRequest#CONTROL_AE_MODE
744 */
745 public static final int CONTROL_AE_MODE_ON_AUTO_FLASH = 2;
746
747 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800748 * <p>Like ON, except that the camera device also controls
749 * the camera's flash unit, always firing it for still
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700750 * captures.</p>
751 * <p>The flash may be fired during a precapture sequence
752 * (triggered by {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}) and
753 * will always be fired for captures for which the
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800754 * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} field is set to
755 * STILL_CAPTURE</p>
756 *
Igor Murashkin3242f4f2014-01-15 12:27:41 -0800757 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
Zhijun He5f2a47f2014-01-16 15:44:41 -0800758 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700759 * @see CaptureRequest#CONTROL_AE_MODE
760 */
761 public static final int CONTROL_AE_MODE_ON_ALWAYS_FLASH = 3;
762
763 /**
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800764 * <p>Like ON_AUTO_FLASH, but with automatic red eye
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700765 * reduction.</p>
766 * <p>If deemed necessary by the camera device, a red eye
767 * reduction flash will fire during the precapture
768 * sequence.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700769 * @see CaptureRequest#CONTROL_AE_MODE
770 */
771 public static final int CONTROL_AE_MODE_ON_AUTO_FLASH_REDEYE = 4;
772
773 //
774 // Enumeration values for CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
775 //
776
777 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -0800778 * <p>The trigger is idle.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700779 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
780 */
781 public static final int CONTROL_AE_PRECAPTURE_TRIGGER_IDLE = 0;
782
783 /**
Zhijun He228f4f92014-01-16 17:22:05 -0800784 * <p>The precapture metering sequence will be started
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700785 * by the camera device.</p>
786 * <p>The exact effect of the precapture trigger depends on
787 * the current AE mode and state.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700788 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
789 */
790 public static final int CONTROL_AE_PRECAPTURE_TRIGGER_START = 1;
791
792 //
793 // Enumeration values for CaptureRequest#CONTROL_AF_MODE
794 //
795
796 /**
Zhijun Hef3537422013-12-16 16:56:35 -0800797 * <p>The auto-focus routine does not control the lens;
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800798 * {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance} is controlled by the
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700799 * application.</p>
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800800 *
801 * @see CaptureRequest#LENS_FOCUS_DISTANCE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700802 * @see CaptureRequest#CONTROL_AF_MODE
803 */
804 public static final int CONTROL_AF_MODE_OFF = 0;
805
806 /**
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -0700807 * <p>Basic automatic focus mode.</p>
808 * <p>In this mode, the lens does not move unless
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700809 * the autofocus trigger action is called. When that trigger
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -0700810 * is activated, AF will transition to ACTIVE_SCAN, then to
Zhijun Hef3537422013-12-16 16:56:35 -0800811 * the outcome of the scan (FOCUSED or NOT_FOCUSED).</p>
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -0700812 * <p>Always supported if lens is not fixed focus.</p>
813 * <p>Use {@link CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE android.lens.info.minimumFocusDistance} to determine if lens
814 * is fixed-focus.</p>
Zhijun Hef3537422013-12-16 16:56:35 -0800815 * <p>Triggering AF_CANCEL resets the lens position to default,
Igor Murashkinace5bf02013-12-10 17:36:40 -0800816 * and sets the AF state to INACTIVE.</p>
Eino-Ville Talvala0da8bf52014-01-08 16:18:35 -0800817 *
818 * @see CameraCharacteristics#LENS_INFO_MINIMUM_FOCUS_DISTANCE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700819 * @see CaptureRequest#CONTROL_AF_MODE
820 */
821 public static final int CONTROL_AF_MODE_AUTO = 1;
822
823 /**
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -0700824 * <p>Close-up focusing mode.</p>
Igor Murashkinace5bf02013-12-10 17:36:40 -0800825 * <p>In this mode, the lens does not move unless the
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -0700826 * autofocus trigger action is called. When that trigger is
827 * activated, AF will transition to ACTIVE_SCAN, then to
828 * the outcome of the scan (FOCUSED or NOT_FOCUSED). This
829 * mode is optimized for focusing on objects very close to
830 * the camera.</p>
831 * <p>When that trigger is activated, AF will transition to
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700832 * ACTIVE_SCAN, then to the outcome of the scan (FOCUSED or
Eino-Ville Talvalab67a3b32014-06-06 13:07:20 -0700833 * NOT_FOCUSED). Triggering cancel AF resets the lens
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700834 * position to default, and sets the AF state to
Igor Murashkinace5bf02013-12-10 17:36:40 -0800835 * INACTIVE.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700836 * @see CaptureRequest#CONTROL_AF_MODE
837 */
838 public static final int CONTROL_AF_MODE_MACRO = 2;
839
840 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -0800841 * <p>In this mode, the AF algorithm modifies the lens
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700842 * position continually to attempt to provide a
Igor Murashkinace5bf02013-12-10 17:36:40 -0800843 * constantly-in-focus image stream.</p>
844 * <p>The focusing behavior should be suitable for good quality
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700845 * video recording; typically this means slower focus
846 * movement and no overshoots. When the AF trigger is not
847 * involved, the AF algorithm should start in INACTIVE state,
848 * and then transition into PASSIVE_SCAN and PASSIVE_FOCUSED
849 * states as appropriate. When the AF trigger is activated,
850 * the algorithm should immediately transition into
851 * AF_FOCUSED or AF_NOT_FOCUSED as appropriate, and lock the
Igor Murashkinace5bf02013-12-10 17:36:40 -0800852 * lens position until a cancel AF trigger is received.</p>
853 * <p>Once cancel is received, the algorithm should transition
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700854 * back to INACTIVE and resume passive scan. Note that this
855 * behavior is not identical to CONTINUOUS_PICTURE, since an
856 * ongoing PASSIVE_SCAN must immediately be
Igor Murashkinace5bf02013-12-10 17:36:40 -0800857 * canceled.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700858 * @see CaptureRequest#CONTROL_AF_MODE
859 */
860 public static final int CONTROL_AF_MODE_CONTINUOUS_VIDEO = 3;
861
862 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -0800863 * <p>In this mode, the AF algorithm modifies the lens
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700864 * position continually to attempt to provide a
Igor Murashkinace5bf02013-12-10 17:36:40 -0800865 * constantly-in-focus image stream.</p>
866 * <p>The focusing behavior should be suitable for still image
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700867 * capture; typically this means focusing as fast as
868 * possible. When the AF trigger is not involved, the AF
869 * algorithm should start in INACTIVE state, and then
870 * transition into PASSIVE_SCAN and PASSIVE_FOCUSED states as
871 * appropriate as it attempts to maintain focus. When the AF
872 * trigger is activated, the algorithm should finish its
873 * PASSIVE_SCAN if active, and then transition into
874 * AF_FOCUSED or AF_NOT_FOCUSED as appropriate, and lock the
Igor Murashkinace5bf02013-12-10 17:36:40 -0800875 * lens position until a cancel AF trigger is received.</p>
876 * <p>When the AF cancel trigger is activated, the algorithm
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700877 * should transition back to INACTIVE and then act as if it
Igor Murashkinace5bf02013-12-10 17:36:40 -0800878 * has just been started.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700879 * @see CaptureRequest#CONTROL_AF_MODE
880 */
881 public static final int CONTROL_AF_MODE_CONTINUOUS_PICTURE = 4;
882
883 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700884 * <p>Extended depth of field (digital focus) mode.</p>
885 * <p>The camera device will produce images with an extended
886 * depth of field automatically; no special focusing
887 * operations need to be done before taking a picture.</p>
888 * <p>AF triggers are ignored, and the AF state will always be
Igor Murashkinace5bf02013-12-10 17:36:40 -0800889 * INACTIVE.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700890 * @see CaptureRequest#CONTROL_AF_MODE
891 */
892 public static final int CONTROL_AF_MODE_EDOF = 5;
893
894 //
895 // Enumeration values for CaptureRequest#CONTROL_AF_TRIGGER
896 //
897
898 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -0800899 * <p>The trigger is idle.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700900 * @see CaptureRequest#CONTROL_AF_TRIGGER
901 */
902 public static final int CONTROL_AF_TRIGGER_IDLE = 0;
903
904 /**
Zhijun He228f4f92014-01-16 17:22:05 -0800905 * <p>Autofocus will trigger now.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700906 * @see CaptureRequest#CONTROL_AF_TRIGGER
907 */
908 public static final int CONTROL_AF_TRIGGER_START = 1;
909
910 /**
Zhijun He228f4f92014-01-16 17:22:05 -0800911 * <p>Autofocus will return to its initial
912 * state, and cancel any currently active trigger.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700913 * @see CaptureRequest#CONTROL_AF_TRIGGER
914 */
915 public static final int CONTROL_AF_TRIGGER_CANCEL = 2;
916
917 //
918 // Enumeration values for CaptureRequest#CONTROL_AWB_MODE
919 //
920
921 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700922 * <p>The camera device's auto-white balance routine is disabled.</p>
923 * <p>The application-selected color transform matrix
Zhijun He399f05d2014-01-15 11:31:30 -0800924 * ({@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}) and gains
925 * ({@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains}) are used by the camera
926 * device for manual white balance control.</p>
927 *
Zhijun He399f05d2014-01-15 11:31:30 -0800928 * @see CaptureRequest#COLOR_CORRECTION_GAINS
Eino-Ville Talvala265b34c2014-01-16 16:18:52 -0800929 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700930 * @see CaptureRequest#CONTROL_AWB_MODE
931 */
932 public static final int CONTROL_AWB_MODE_OFF = 0;
933
934 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700935 * <p>The camera device's auto-white balance routine is active.</p>
936 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
937 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
938 * For devices that support the MANUAL_POST_PROCESSING capability, the
939 * values used by the camera device for the transform and gains
940 * will be available in the capture result for this request.</p>
Zhijun He399f05d2014-01-15 11:31:30 -0800941 *
942 * @see CaptureRequest#COLOR_CORRECTION_GAINS
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -0800943 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700944 * @see CaptureRequest#CONTROL_AWB_MODE
945 */
946 public static final int CONTROL_AWB_MODE_AUTO = 1;
947
948 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700949 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -0800950 * the camera device uses incandescent light as the assumed scene
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700951 * illumination for white balance.</p>
952 * <p>While the exact white balance transforms are up to the
953 * camera device, they will approximately match the CIE
954 * standard illuminant A.</p>
955 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
956 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
957 * For devices that support the MANUAL_POST_PROCESSING capability, the
958 * values used by the camera device for the transform and gains
959 * will be available in the capture result for this request.</p>
960 *
961 * @see CaptureRequest#COLOR_CORRECTION_GAINS
962 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700963 * @see CaptureRequest#CONTROL_AWB_MODE
964 */
965 public static final int CONTROL_AWB_MODE_INCANDESCENT = 2;
966
967 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700968 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -0800969 * the camera device uses fluorescent light as the assumed scene
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700970 * illumination for white balance.</p>
971 * <p>While the exact white balance transforms are up to the
972 * camera device, they will approximately match the CIE
973 * standard illuminant F2.</p>
974 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
975 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
976 * For devices that support the MANUAL_POST_PROCESSING capability, the
977 * values used by the camera device for the transform and gains
978 * will be available in the capture result for this request.</p>
979 *
980 * @see CaptureRequest#COLOR_CORRECTION_GAINS
981 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -0700982 * @see CaptureRequest#CONTROL_AWB_MODE
983 */
984 public static final int CONTROL_AWB_MODE_FLUORESCENT = 3;
985
986 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700987 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -0800988 * the camera device uses warm fluorescent light as the assumed scene
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -0700989 * illumination for white balance.</p>
990 * <p>While the exact white balance transforms are up to the
991 * camera device, they will approximately match the CIE
992 * standard illuminant F4.</p>
993 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
994 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
995 * For devices that support the MANUAL_POST_PROCESSING capability, the
996 * values used by the camera device for the transform and gains
997 * will be available in the capture result for this request.</p>
998 *
999 * @see CaptureRequest#COLOR_CORRECTION_GAINS
1000 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001001 * @see CaptureRequest#CONTROL_AWB_MODE
1002 */
1003 public static final int CONTROL_AWB_MODE_WARM_FLUORESCENT = 4;
1004
1005 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001006 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -08001007 * the camera device uses daylight light as the assumed scene
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001008 * illumination for white balance.</p>
1009 * <p>While the exact white balance transforms are up to the
1010 * camera device, they will approximately match the CIE
1011 * standard illuminant D65.</p>
1012 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
1013 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
1014 * For devices that support the MANUAL_POST_PROCESSING capability, the
1015 * values used by the camera device for the transform and gains
1016 * will be available in the capture result for this request.</p>
1017 *
1018 * @see CaptureRequest#COLOR_CORRECTION_GAINS
1019 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001020 * @see CaptureRequest#CONTROL_AWB_MODE
1021 */
1022 public static final int CONTROL_AWB_MODE_DAYLIGHT = 5;
1023
1024 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001025 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -08001026 * the camera device uses cloudy daylight light as the assumed scene
1027 * illumination for white balance.</p>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001028 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
1029 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
1030 * For devices that support the MANUAL_POST_PROCESSING capability, the
1031 * values used by the camera device for the transform and gains
1032 * will be available in the capture result for this request.</p>
1033 *
1034 * @see CaptureRequest#COLOR_CORRECTION_GAINS
1035 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001036 * @see CaptureRequest#CONTROL_AWB_MODE
1037 */
1038 public static final int CONTROL_AWB_MODE_CLOUDY_DAYLIGHT = 6;
1039
1040 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001041 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -08001042 * the camera device uses twilight light as the assumed scene
1043 * illumination for white balance.</p>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001044 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
1045 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
1046 * For devices that support the MANUAL_POST_PROCESSING capability, the
1047 * values used by the camera device for the transform and gains
1048 * will be available in the capture result for this request.</p>
1049 *
1050 * @see CaptureRequest#COLOR_CORRECTION_GAINS
1051 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001052 * @see CaptureRequest#CONTROL_AWB_MODE
1053 */
1054 public static final int CONTROL_AWB_MODE_TWILIGHT = 7;
1055
1056 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001057 * <p>The camera device's auto-white balance routine is disabled;
Zhijun He399f05d2014-01-15 11:31:30 -08001058 * the camera device uses shade light as the assumed scene
1059 * illumination for white balance.</p>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001060 * <p>The application's values for {@link CaptureRequest#COLOR_CORRECTION_TRANSFORM android.colorCorrection.transform}
1061 * and {@link CaptureRequest#COLOR_CORRECTION_GAINS android.colorCorrection.gains} are ignored.
1062 * For devices that support the MANUAL_POST_PROCESSING capability, the
1063 * values used by the camera device for the transform and gains
1064 * will be available in the capture result for this request.</p>
1065 *
1066 * @see CaptureRequest#COLOR_CORRECTION_GAINS
1067 * @see CaptureRequest#COLOR_CORRECTION_TRANSFORM
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001068 * @see CaptureRequest#CONTROL_AWB_MODE
1069 */
1070 public static final int CONTROL_AWB_MODE_SHADE = 8;
1071
1072 //
1073 // Enumeration values for CaptureRequest#CONTROL_CAPTURE_INTENT
1074 //
1075
1076 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001077 * <p>The goal of this request doesn't fall into the other
1078 * categories. The camera device will default to preview-like
Igor Murashkinace5bf02013-12-10 17:36:40 -08001079 * behavior.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001080 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1081 */
1082 public static final int CONTROL_CAPTURE_INTENT_CUSTOM = 0;
1083
1084 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001085 * <p>This request is for a preview-like use case.</p>
1086 * <p>The precapture trigger may be used to start off a metering
1087 * w/flash sequence.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001088 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1089 */
1090 public static final int CONTROL_CAPTURE_INTENT_PREVIEW = 1;
1091
1092 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001093 * <p>This request is for a still capture-type
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001094 * use case.</p>
1095 * <p>If the flash unit is under automatic control, it may fire as needed.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001096 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1097 */
1098 public static final int CONTROL_CAPTURE_INTENT_STILL_CAPTURE = 2;
1099
1100 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001101 * <p>This request is for a video recording
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001102 * use case.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001103 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1104 */
1105 public static final int CONTROL_CAPTURE_INTENT_VIDEO_RECORD = 3;
1106
1107 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001108 * <p>This request is for a video snapshot (still
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001109 * image while recording video) use case.</p>
1110 * <p>The camera device should take the highest-quality image
1111 * possible (given the other settings) without disrupting the
1112 * frame rate of video recording.<br />
1113 * </p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001114 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1115 */
1116 public static final int CONTROL_CAPTURE_INTENT_VIDEO_SNAPSHOT = 4;
1117
1118 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001119 * <p>This request is for a ZSL usecase; the
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001120 * application will stream full-resolution images and
1121 * reprocess one or several later for a final
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001122 * capture.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001123 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1124 */
1125 public static final int CONTROL_CAPTURE_INTENT_ZERO_SHUTTER_LAG = 5;
1126
Zhijun Hee30adb72014-04-09 19:04:31 -07001127 /**
1128 * <p>This request is for manual capture use case where
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001129 * the applications want to directly control the capture parameters.</p>
1130 * <p>For example, the application may wish to manually control
1131 * {@link CaptureRequest#SENSOR_EXPOSURE_TIME android.sensor.exposureTime}, {@link CaptureRequest#SENSOR_SENSITIVITY android.sensor.sensitivity}, etc.</p>
Zhijun Hee30adb72014-04-09 19:04:31 -07001132 *
1133 * @see CaptureRequest#SENSOR_EXPOSURE_TIME
1134 * @see CaptureRequest#SENSOR_SENSITIVITY
1135 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
1136 */
1137 public static final int CONTROL_CAPTURE_INTENT_MANUAL = 6;
1138
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001139 //
1140 // Enumeration values for CaptureRequest#CONTROL_EFFECT_MODE
1141 //
1142
1143 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001144 * <p>No color effect will be applied.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001145 * @see CaptureRequest#CONTROL_EFFECT_MODE
1146 */
1147 public static final int CONTROL_EFFECT_MODE_OFF = 0;
1148
1149 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001150 * <p>A "monocolor" effect where the image is mapped into
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001151 * a single color.</p>
1152 * <p>This will typically be grayscale.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001153 * @see CaptureRequest#CONTROL_EFFECT_MODE
1154 */
1155 public static final int CONTROL_EFFECT_MODE_MONO = 1;
1156
1157 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001158 * <p>A "photo-negative" effect where the image's colors
1159 * are inverted.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001160 * @see CaptureRequest#CONTROL_EFFECT_MODE
1161 */
1162 public static final int CONTROL_EFFECT_MODE_NEGATIVE = 2;
1163
1164 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001165 * <p>A "solarisation" effect (Sabattier effect) where the
1166 * image is wholly or partially reversed in
1167 * tone.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001168 * @see CaptureRequest#CONTROL_EFFECT_MODE
1169 */
1170 public static final int CONTROL_EFFECT_MODE_SOLARIZE = 3;
1171
1172 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001173 * <p>A "sepia" effect where the image is mapped into warm
1174 * gray, red, and brown tones.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001175 * @see CaptureRequest#CONTROL_EFFECT_MODE
1176 */
1177 public static final int CONTROL_EFFECT_MODE_SEPIA = 4;
1178
1179 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001180 * <p>A "posterization" effect where the image uses
1181 * discrete regions of tone rather than a continuous
1182 * gradient of tones.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001183 * @see CaptureRequest#CONTROL_EFFECT_MODE
1184 */
1185 public static final int CONTROL_EFFECT_MODE_POSTERIZE = 5;
1186
1187 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001188 * <p>A "whiteboard" effect where the image is typically displayed
1189 * as regions of white, with black or grey details.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001190 * @see CaptureRequest#CONTROL_EFFECT_MODE
1191 */
1192 public static final int CONTROL_EFFECT_MODE_WHITEBOARD = 6;
1193
1194 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001195 * <p>A "blackboard" effect where the image is typically displayed
1196 * as regions of black, with white or grey details.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001197 * @see CaptureRequest#CONTROL_EFFECT_MODE
1198 */
1199 public static final int CONTROL_EFFECT_MODE_BLACKBOARD = 7;
1200
1201 /**
Ruben Brunk5f1dcfe2014-01-17 16:42:51 -08001202 * <p>An "aqua" effect where a blue hue is added to the image.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001203 * @see CaptureRequest#CONTROL_EFFECT_MODE
1204 */
1205 public static final int CONTROL_EFFECT_MODE_AQUA = 8;
1206
1207 //
1208 // Enumeration values for CaptureRequest#CONTROL_MODE
1209 //
1210
1211 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001212 * <p>Full application control of pipeline.</p>
1213 * <p>All control by the device's metering and focusing (3A)
1214 * routines is disabled, and no other settings in
1215 * android.control.* have any effect, except that
1216 * {@link CaptureRequest#CONTROL_CAPTURE_INTENT android.control.captureIntent} may be used by the camera
1217 * device to select post-processing values for processing
1218 * blocks that do not allow for manual control, or are not
1219 * exposed by the camera API.</p>
1220 * <p>However, the camera device's 3A routines may continue to
1221 * collect statistics and update their internal state so that
1222 * when control is switched to AUTO mode, good control values
1223 * can be immediately applied.</p>
1224 *
1225 * @see CaptureRequest#CONTROL_CAPTURE_INTENT
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001226 * @see CaptureRequest#CONTROL_MODE
1227 */
1228 public static final int CONTROL_MODE_OFF = 0;
1229
1230 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001231 * <p>Use settings for each individual 3A routine.</p>
1232 * <p>Manual control of capture parameters is disabled. All
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001233 * controls in android.control.* besides sceneMode take
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001234 * effect.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001235 * @see CaptureRequest#CONTROL_MODE
1236 */
1237 public static final int CONTROL_MODE_AUTO = 1;
1238
1239 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001240 * <p>Use a specific scene mode.</p>
1241 * <p>Enabling this disables control.aeMode, control.awbMode and
1242 * control.afMode controls; the camera device will ignore
1243 * those settings while USE_SCENE_MODE is active (except for
1244 * FACE_PRIORITY scene mode). Other control entries are still
1245 * active. This setting can only be used if scene mode is
1246 * supported (i.e. {@link CameraCharacteristics#CONTROL_AVAILABLE_SCENE_MODES android.control.availableSceneModes}
1247 * contain some modes other than DISABLED).</p>
Zhijun Hea4866242014-03-27 23:51:34 -07001248 *
1249 * @see CameraCharacteristics#CONTROL_AVAILABLE_SCENE_MODES
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001250 * @see CaptureRequest#CONTROL_MODE
1251 */
1252 public static final int CONTROL_MODE_USE_SCENE_MODE = 2;
1253
Zhijun He2d5e8972014-02-07 16:13:46 -08001254 /**
1255 * <p>Same as OFF mode, except that this capture will not be
1256 * used by camera device background auto-exposure, auto-white balance and
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001257 * auto-focus algorithms (3A) to update their statistics.</p>
1258 * <p>Specifically, the 3A routines are locked to the last
1259 * values set from a request with AUTO, OFF, or
1260 * USE_SCENE_MODE, and any statistics or state updates
1261 * collected from manual captures with OFF_KEEP_STATE will be
1262 * discarded by the camera device.</p>
Zhijun He2d5e8972014-02-07 16:13:46 -08001263 * @see CaptureRequest#CONTROL_MODE
1264 */
1265 public static final int CONTROL_MODE_OFF_KEEP_STATE = 3;
1266
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001267 //
1268 // Enumeration values for CaptureRequest#CONTROL_SCENE_MODE
1269 //
1270
1271 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001272 * <p>Indicates that no scene modes are set for a given capture request.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001273 * @see CaptureRequest#CONTROL_SCENE_MODE
1274 */
Ruben Brunke6679362014-01-17 17:05:54 -08001275 public static final int CONTROL_SCENE_MODE_DISABLED = 0;
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001276
1277 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001278 * <p>If face detection support exists, use face
1279 * detection data for auto-focus, auto-white balance, and
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001280 * auto-exposure routines.</p>
1281 * <p>If face detection statistics are disabled
1282 * (i.e. {@link CaptureRequest#STATISTICS_FACE_DETECT_MODE android.statistics.faceDetectMode} is set to OFF),
Ruben Brunke6679362014-01-17 17:05:54 -08001283 * this should still operate correctly (but will not return
1284 * face detection statistics to the framework).</p>
1285 * <p>Unlike the other scene modes, {@link CaptureRequest#CONTROL_AE_MODE android.control.aeMode},
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08001286 * {@link CaptureRequest#CONTROL_AWB_MODE android.control.awbMode}, and {@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}
Ruben Brunke6679362014-01-17 17:05:54 -08001287 * remain active when FACE_PRIORITY is set.</p>
1288 *
1289 * @see CaptureRequest#CONTROL_AE_MODE
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08001290 * @see CaptureRequest#CONTROL_AF_MODE
Ruben Brunke6679362014-01-17 17:05:54 -08001291 * @see CaptureRequest#CONTROL_AWB_MODE
1292 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001293 * @see CaptureRequest#CONTROL_SCENE_MODE
1294 */
1295 public static final int CONTROL_SCENE_MODE_FACE_PRIORITY = 1;
1296
1297 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001298 * <p>Optimized for photos of quickly moving objects.</p>
1299 * <p>Similar to SPORTS.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001300 * @see CaptureRequest#CONTROL_SCENE_MODE
1301 */
1302 public static final int CONTROL_SCENE_MODE_ACTION = 2;
1303
1304 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001305 * <p>Optimized for still photos of people.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001306 * @see CaptureRequest#CONTROL_SCENE_MODE
1307 */
1308 public static final int CONTROL_SCENE_MODE_PORTRAIT = 3;
1309
1310 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001311 * <p>Optimized for photos of distant macroscopic objects.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001312 * @see CaptureRequest#CONTROL_SCENE_MODE
1313 */
1314 public static final int CONTROL_SCENE_MODE_LANDSCAPE = 4;
1315
1316 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001317 * <p>Optimized for low-light settings.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001318 * @see CaptureRequest#CONTROL_SCENE_MODE
1319 */
1320 public static final int CONTROL_SCENE_MODE_NIGHT = 5;
1321
1322 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001323 * <p>Optimized for still photos of people in low-light
1324 * settings.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001325 * @see CaptureRequest#CONTROL_SCENE_MODE
1326 */
1327 public static final int CONTROL_SCENE_MODE_NIGHT_PORTRAIT = 6;
1328
1329 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001330 * <p>Optimized for dim, indoor settings where flash must
1331 * remain off.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001332 * @see CaptureRequest#CONTROL_SCENE_MODE
1333 */
1334 public static final int CONTROL_SCENE_MODE_THEATRE = 7;
1335
1336 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001337 * <p>Optimized for bright, outdoor beach settings.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001338 * @see CaptureRequest#CONTROL_SCENE_MODE
1339 */
1340 public static final int CONTROL_SCENE_MODE_BEACH = 8;
1341
1342 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001343 * <p>Optimized for bright, outdoor settings containing snow.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001344 * @see CaptureRequest#CONTROL_SCENE_MODE
1345 */
1346 public static final int CONTROL_SCENE_MODE_SNOW = 9;
1347
1348 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001349 * <p>Optimized for scenes of the setting sun.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001350 * @see CaptureRequest#CONTROL_SCENE_MODE
1351 */
1352 public static final int CONTROL_SCENE_MODE_SUNSET = 10;
1353
1354 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001355 * <p>Optimized to avoid blurry photos due to small amounts of
1356 * device motion (for example: due to hand shake).</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001357 * @see CaptureRequest#CONTROL_SCENE_MODE
1358 */
1359 public static final int CONTROL_SCENE_MODE_STEADYPHOTO = 11;
1360
1361 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001362 * <p>Optimized for nighttime photos of fireworks.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001363 * @see CaptureRequest#CONTROL_SCENE_MODE
1364 */
1365 public static final int CONTROL_SCENE_MODE_FIREWORKS = 12;
1366
1367 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001368 * <p>Optimized for photos of quickly moving people.</p>
1369 * <p>Similar to ACTION.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001370 * @see CaptureRequest#CONTROL_SCENE_MODE
1371 */
1372 public static final int CONTROL_SCENE_MODE_SPORTS = 13;
1373
1374 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001375 * <p>Optimized for dim, indoor settings with multiple moving
1376 * people.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001377 * @see CaptureRequest#CONTROL_SCENE_MODE
1378 */
1379 public static final int CONTROL_SCENE_MODE_PARTY = 14;
1380
1381 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001382 * <p>Optimized for dim settings where the main light source
1383 * is a flame.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001384 * @see CaptureRequest#CONTROL_SCENE_MODE
1385 */
1386 public static final int CONTROL_SCENE_MODE_CANDLELIGHT = 15;
1387
1388 /**
Ruben Brunke6679362014-01-17 17:05:54 -08001389 * <p>Optimized for accurately capturing a photo of barcode
1390 * for use by camera applications that wish to read the
1391 * barcode value.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001392 * @see CaptureRequest#CONTROL_SCENE_MODE
1393 */
1394 public static final int CONTROL_SCENE_MODE_BARCODE = 16;
1395
Zhijun Hee0404182014-06-26 13:17:09 -07001396 /**
1397 * <p>Optimized for high speed video recording (frame rate &gt;=60fps) use case.</p>
1398 * <p>The supported high speed video sizes and fps ranges are specified in
1399 * android.control.availableHighSpeedVideoConfigurations. To get desired
1400 * output frame rates, the application is only allowed to select video size
1401 * and fps range combinations listed in this static metadata. The fps range
1402 * can be control via {@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange}.</p>
1403 * <p>In this mode, the camera device will override aeMode, awbMode, and afMode to
1404 * ON, ON, and CONTINUOUS_VIDEO, respectively. All post-processing block mode
1405 * controls will be overridden to be FAST. Therefore, no manual control of capture
1406 * and post-processing parameters is possible. All other controls operate the
1407 * same as when {@link CaptureRequest#CONTROL_MODE android.control.mode} == AUTO. This means that all other
1408 * android.control.* fields continue to work, such as</p>
1409 * <ul>
1410 * <li>{@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange}</li>
1411 * <li>{@link CaptureRequest#CONTROL_AE_EXPOSURE_COMPENSATION android.control.aeExposureCompensation}</li>
1412 * <li>{@link CaptureRequest#CONTROL_AE_LOCK android.control.aeLock}</li>
1413 * <li>{@link CaptureRequest#CONTROL_AWB_LOCK android.control.awbLock}</li>
1414 * <li>{@link CaptureRequest#CONTROL_EFFECT_MODE android.control.effectMode}</li>
1415 * <li>{@link CaptureRequest#CONTROL_AE_REGIONS android.control.aeRegions}</li>
1416 * <li>{@link CaptureRequest#CONTROL_AF_REGIONS android.control.afRegions}</li>
1417 * <li>{@link CaptureRequest#CONTROL_AWB_REGIONS android.control.awbRegions}</li>
1418 * <li>{@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}</li>
1419 * <li>{@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger}</li>
1420 * </ul>
1421 * <p>Outside of android.control.*, the following controls will work:</p>
1422 * <ul>
1423 * <li>{@link CaptureRequest#FLASH_MODE android.flash.mode} (automatic flash for still capture will not work since aeMode is ON)</li>
1424 * <li>{@link CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE android.lens.opticalStabilizationMode} (if it is supported)</li>
1425 * <li>{@link CaptureRequest#SCALER_CROP_REGION android.scaler.cropRegion}</li>
1426 * <li>{@link CaptureRequest#STATISTICS_FACE_DETECT_MODE android.statistics.faceDetectMode}</li>
1427 * </ul>
1428 * <p>For high speed recording use case, the actual maximum supported frame rate may
1429 * be lower than what camera can output, depending on the destination Surfaces for
1430 * the image data. For example, if the destination surface is from video encoder,
1431 * the application need check if the video encoder is capable of supporting the
1432 * high frame rate for a given video size, or it will end up with lower recording
1433 * frame rate. If the destination surface is from preview window, the preview frame
1434 * rate will be bounded by the screen refresh rate.</p>
1435 * <p>The camera device will only support up to 2 output high speed streams
1436 * (processed non-stalling format defined in android.request.maxNumOutputStreams)
1437 * in this mode. This control will be effective only if all of below conditions are true:</p>
1438 * <ul>
1439 * <li>The application created no more than maxNumHighSpeedStreams processed non-stalling
1440 * format output streams, where maxNumHighSpeedStreams is calculated as
1441 * min(2, android.request.maxNumOutputStreams[Processed (but not-stalling)]).</li>
1442 * <li>The stream sizes are selected from the sizes reported by
1443 * android.control.availableHighSpeedVideoConfigurations.</li>
1444 * <li>No processed non-stalling or raw streams are configured.</li>
1445 * </ul>
1446 * <p>When above conditions are NOT satistied, the controls of this mode and
1447 * {@link CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE android.control.aeTargetFpsRange} will be ignored by the camera device,
1448 * the camera device will fall back to {@link CaptureRequest#CONTROL_MODE android.control.mode} <code>==</code> AUTO,
1449 * and the returned capture result metadata will give the fps range choosen
1450 * by the camera device.</p>
1451 * <p>Switching into or out of this mode may trigger some camera ISP/sensor
1452 * reconfigurations, which may introduce extra latency. It is recommended that
1453 * the application avoids unnecessary scene mode switch as much as possible.</p>
1454 *
1455 * @see CaptureRequest#CONTROL_AE_EXPOSURE_COMPENSATION
1456 * @see CaptureRequest#CONTROL_AE_LOCK
1457 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
1458 * @see CaptureRequest#CONTROL_AE_REGIONS
1459 * @see CaptureRequest#CONTROL_AE_TARGET_FPS_RANGE
1460 * @see CaptureRequest#CONTROL_AF_REGIONS
1461 * @see CaptureRequest#CONTROL_AF_TRIGGER
1462 * @see CaptureRequest#CONTROL_AWB_LOCK
1463 * @see CaptureRequest#CONTROL_AWB_REGIONS
1464 * @see CaptureRequest#CONTROL_EFFECT_MODE
1465 * @see CaptureRequest#CONTROL_MODE
1466 * @see CaptureRequest#FLASH_MODE
1467 * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE
1468 * @see CaptureRequest#SCALER_CROP_REGION
1469 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE
1470 * @see CaptureRequest#CONTROL_SCENE_MODE
1471 */
1472 public static final int CONTROL_SCENE_MODE_HIGH_SPEED_VIDEO = 17;
1473
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001474 //
Zhijun He4793af52014-05-05 10:39:12 -07001475 // Enumeration values for CaptureRequest#CONTROL_VIDEO_STABILIZATION_MODE
1476 //
1477
1478 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001479 * <p>Video stabilization is disabled.</p>
Zhijun He4793af52014-05-05 10:39:12 -07001480 * @see CaptureRequest#CONTROL_VIDEO_STABILIZATION_MODE
1481 */
1482 public static final int CONTROL_VIDEO_STABILIZATION_MODE_OFF = 0;
1483
1484 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001485 * <p>Video stabilization is enabled.</p>
Zhijun He4793af52014-05-05 10:39:12 -07001486 * @see CaptureRequest#CONTROL_VIDEO_STABILIZATION_MODE
1487 */
1488 public static final int CONTROL_VIDEO_STABILIZATION_MODE_ON = 1;
1489
1490 //
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001491 // Enumeration values for CaptureRequest#EDGE_MODE
1492 //
1493
1494 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001495 * <p>No edge enhancement is applied.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001496 * @see CaptureRequest#EDGE_MODE
1497 */
1498 public static final int EDGE_MODE_OFF = 0;
1499
1500 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001501 * <p>Apply edge enhancement at a quality level that does not slow down frame rate relative to sensor
Zhijun He28079362013-12-17 10:35:40 -08001502 * output</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001503 * @see CaptureRequest#EDGE_MODE
1504 */
1505 public static final int EDGE_MODE_FAST = 1;
1506
1507 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001508 * <p>Apply high-quality edge enhancement, at a cost of reducing output frame rate.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001509 * @see CaptureRequest#EDGE_MODE
1510 */
1511 public static final int EDGE_MODE_HIGH_QUALITY = 2;
1512
1513 //
1514 // Enumeration values for CaptureRequest#FLASH_MODE
1515 //
1516
1517 /**
Zhijun He66d065a2014-01-16 18:18:50 -08001518 * <p>Do not fire the flash for this capture.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001519 * @see CaptureRequest#FLASH_MODE
1520 */
1521 public static final int FLASH_MODE_OFF = 0;
1522
1523 /**
Zhijun He66d065a2014-01-16 18:18:50 -08001524 * <p>If the flash is available and charged, fire flash
Zhijun He89492252014-05-23 13:49:59 -07001525 * for this capture.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001526 * @see CaptureRequest#FLASH_MODE
1527 */
1528 public static final int FLASH_MODE_SINGLE = 1;
1529
1530 /**
Zhijun He66d065a2014-01-16 18:18:50 -08001531 * <p>Transition flash to continuously on.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001532 * @see CaptureRequest#FLASH_MODE
1533 */
1534 public static final int FLASH_MODE_TORCH = 2;
1535
1536 //
Ruben Brunkeba1b3a2014-02-07 18:23:50 -08001537 // Enumeration values for CaptureRequest#HOT_PIXEL_MODE
1538 //
1539
1540 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001541 * <p>No hot pixel correction is applied.</p>
Ruben Brunkeba1b3a2014-02-07 18:23:50 -08001542 * <p>The frame rate must not be reduced relative to sensor raw output
1543 * for this option.</p>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001544 * <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 -08001545 *
1546 * @see CaptureResult#STATISTICS_HOT_PIXEL_MAP
Ruben Brunkeba1b3a2014-02-07 18:23:50 -08001547 * @see CaptureRequest#HOT_PIXEL_MODE
1548 */
1549 public static final int HOT_PIXEL_MODE_OFF = 0;
1550
1551 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001552 * <p>Hot pixel correction is applied, without reducing frame
1553 * rate relative to sensor raw output.</p>
1554 * <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 -08001555 *
1556 * @see CaptureResult#STATISTICS_HOT_PIXEL_MAP
Ruben Brunkeba1b3a2014-02-07 18:23:50 -08001557 * @see CaptureRequest#HOT_PIXEL_MODE
1558 */
1559 public static final int HOT_PIXEL_MODE_FAST = 1;
1560
1561 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001562 * <p>High-quality hot pixel correction is applied, at a cost
1563 * of reducing frame rate relative to sensor raw output.</p>
1564 * <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 -08001565 *
1566 * @see CaptureResult#STATISTICS_HOT_PIXEL_MAP
Ruben Brunkeba1b3a2014-02-07 18:23:50 -08001567 * @see CaptureRequest#HOT_PIXEL_MODE
1568 */
1569 public static final int HOT_PIXEL_MODE_HIGH_QUALITY = 2;
1570
1571 //
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001572 // Enumeration values for CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE
1573 //
1574
1575 /**
Ruben Brunk00849b32014-01-17 18:30:23 -08001576 * <p>Optical stabilization is unavailable.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001577 * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE
1578 */
1579 public static final int LENS_OPTICAL_STABILIZATION_MODE_OFF = 0;
1580
1581 /**
Ruben Brunk00849b32014-01-17 18:30:23 -08001582 * <p>Optical stabilization is enabled.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001583 * @see CaptureRequest#LENS_OPTICAL_STABILIZATION_MODE
1584 */
1585 public static final int LENS_OPTICAL_STABILIZATION_MODE_ON = 1;
1586
1587 //
1588 // Enumeration values for CaptureRequest#NOISE_REDUCTION_MODE
1589 //
1590
1591 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001592 * <p>No noise reduction is applied.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001593 * @see CaptureRequest#NOISE_REDUCTION_MODE
1594 */
1595 public static final int NOISE_REDUCTION_MODE_OFF = 0;
1596
1597 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001598 * <p>Noise reduction is applied without reducing frame rate relative to sensor
1599 * output.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001600 * @see CaptureRequest#NOISE_REDUCTION_MODE
1601 */
1602 public static final int NOISE_REDUCTION_MODE_FAST = 1;
1603
1604 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001605 * <p>High-quality noise reduction is applied, at the cost of reducing frame rate
1606 * relative to sensor output.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001607 * @see CaptureRequest#NOISE_REDUCTION_MODE
1608 */
1609 public static final int NOISE_REDUCTION_MODE_HIGH_QUALITY = 2;
1610
1611 //
Igor Murashkinc127f052014-01-17 18:06:02 -08001612 // Enumeration values for CaptureRequest#SENSOR_TEST_PATTERN_MODE
1613 //
1614
1615 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001616 * <p>No test pattern mode is used, and the camera
Igor Murashkinc127f052014-01-17 18:06:02 -08001617 * device returns captures from the image sensor.</p>
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001618 * <p>This is the default if the key is not set.</p>
Igor Murashkinc127f052014-01-17 18:06:02 -08001619 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE
1620 */
1621 public static final int SENSOR_TEST_PATTERN_MODE_OFF = 0;
1622
1623 /**
1624 * <p>Each pixel in <code>[R, G_even, G_odd, B]</code> is replaced by its
1625 * respective color channel provided in
1626 * {@link CaptureRequest#SENSOR_TEST_PATTERN_DATA android.sensor.testPatternData}.</p>
1627 * <p>For example:</p>
1628 * <pre><code>android.testPatternData = [0, 0xFFFFFFFF, 0xFFFFFFFF, 0]
1629 * </code></pre>
1630 * <p>All green pixels are 100% green. All red/blue pixels are black.</p>
1631 * <pre><code>android.testPatternData = [0xFFFFFFFF, 0, 0xFFFFFFFF, 0]
1632 * </code></pre>
1633 * <p>All red pixels are 100% red. Only the odd green pixels
1634 * are 100% green. All blue pixels are 100% black.</p>
1635 *
1636 * @see CaptureRequest#SENSOR_TEST_PATTERN_DATA
1637 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE
1638 */
1639 public static final int SENSOR_TEST_PATTERN_MODE_SOLID_COLOR = 1;
1640
1641 /**
1642 * <p>All pixel data is replaced with an 8-bar color pattern.</p>
1643 * <p>The vertical bars (left-to-right) are as follows:</p>
1644 * <ul>
1645 * <li>100% white</li>
1646 * <li>yellow</li>
1647 * <li>cyan</li>
1648 * <li>green</li>
1649 * <li>magenta</li>
1650 * <li>red</li>
1651 * <li>blue</li>
1652 * <li>black</li>
1653 * </ul>
1654 * <p>In general the image would look like the following:</p>
1655 * <pre><code>W Y C G M R B K
1656 * W Y C G M R B K
1657 * W Y C G M R B K
1658 * W Y C G M R B K
1659 * W Y C G M R B K
1660 * . . . . . . . .
1661 * . . . . . . . .
1662 * . . . . . . . .
1663 *
1664 * (B = Blue, K = Black)
1665 * </code></pre>
1666 * <p>Each bar should take up 1/8 of the sensor pixel array width.
1667 * When this is not possible, the bar size should be rounded
1668 * down to the nearest integer and the pattern can repeat
1669 * on the right side.</p>
1670 * <p>Each bar's height must always take up the full sensor
1671 * pixel array height.</p>
1672 * <p>Each pixel in this test pattern must be set to either
1673 * 0% intensity or 100% intensity.</p>
1674 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE
1675 */
1676 public static final int SENSOR_TEST_PATTERN_MODE_COLOR_BARS = 2;
1677
1678 /**
1679 * <p>The test pattern is similar to COLOR_BARS, except that
1680 * each bar should start at its specified color at the top,
1681 * and fade to gray at the bottom.</p>
1682 * <p>Furthermore each bar is further subdivided into a left and
1683 * right half. The left half should have a smooth gradient,
1684 * and the right half should have a quantized gradient.</p>
1685 * <p>In particular, the right half's should consist of blocks of the
1686 * same color for 1/16th active sensor pixel array width.</p>
1687 * <p>The least significant bits in the quantized gradient should
1688 * be copied from the most significant bits of the smooth gradient.</p>
1689 * <p>The height of each bar should always be a multiple of 128.
1690 * When this is not the case, the pattern should repeat at the bottom
1691 * of the image.</p>
1692 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE
1693 */
1694 public static final int SENSOR_TEST_PATTERN_MODE_COLOR_BARS_FADE_TO_GRAY = 3;
1695
1696 /**
1697 * <p>All pixel data is replaced by a pseudo-random sequence
1698 * generated from a PN9 512-bit sequence (typically implemented
1699 * in hardware with a linear feedback shift register).</p>
1700 * <p>The generator should be reset at the beginning of each frame,
1701 * and thus each subsequent raw frame with this test pattern should
1702 * be exactly the same as the last.</p>
1703 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE
1704 */
1705 public static final int SENSOR_TEST_PATTERN_MODE_PN9 = 4;
1706
1707 /**
1708 * <p>The first custom test pattern. All custom patterns that are
1709 * available only on this camera device are at least this numeric
1710 * value.</p>
1711 * <p>All of the custom test patterns will be static
1712 * (that is the raw image must not vary from frame to frame).</p>
1713 * @see CaptureRequest#SENSOR_TEST_PATTERN_MODE
1714 */
1715 public static final int SENSOR_TEST_PATTERN_MODE_CUSTOM1 = 256;
1716
1717 //
Zhijun Heba93fe62014-01-17 16:43:05 -08001718 // Enumeration values for CaptureRequest#SHADING_MODE
1719 //
1720
1721 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001722 * <p>No lens shading correction is applied.</p>
Zhijun Heba93fe62014-01-17 16:43:05 -08001723 * @see CaptureRequest#SHADING_MODE
Zhijun Heba93fe62014-01-17 16:43:05 -08001724 */
1725 public static final int SHADING_MODE_OFF = 0;
1726
1727 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001728 * <p>Apply lens shading corrections, without slowing
1729 * frame rate relative to sensor raw output</p>
Zhijun Heba93fe62014-01-17 16:43:05 -08001730 * @see CaptureRequest#SHADING_MODE
Zhijun Heba93fe62014-01-17 16:43:05 -08001731 */
1732 public static final int SHADING_MODE_FAST = 1;
1733
1734 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001735 * <p>Apply high-quality lens shading correction, at the
1736 * cost of reduced frame rate.</p>
Zhijun Heba93fe62014-01-17 16:43:05 -08001737 * @see CaptureRequest#SHADING_MODE
Zhijun Heba93fe62014-01-17 16:43:05 -08001738 */
1739 public static final int SHADING_MODE_HIGH_QUALITY = 2;
1740
1741 //
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001742 // Enumeration values for CaptureRequest#STATISTICS_FACE_DETECT_MODE
1743 //
1744
1745 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001746 * <p>Do not include face detection statistics in capture
1747 * results.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001748 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE
1749 */
1750 public static final int STATISTICS_FACE_DETECT_MODE_OFF = 0;
1751
1752 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001753 * <p>Return face rectangle and confidence values only.</p>
1754 * <p>In this mode, only android.statistics.faceRectangles and
1755 * android.statistics.faceScores outputs are valid.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001756 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE
1757 */
1758 public static final int STATISTICS_FACE_DETECT_MODE_SIMPLE = 1;
1759
1760 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001761 * <p>Return all face
1762 * metadata.</p>
1763 * <p>In this mode,
1764 * android.statistics.faceRectangles,
1765 * android.statistics.faceScores,
1766 * android.statistics.faceIds, and
1767 * android.statistics.faceLandmarks outputs are valid.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001768 * @see CaptureRequest#STATISTICS_FACE_DETECT_MODE
1769 */
1770 public static final int STATISTICS_FACE_DETECT_MODE_FULL = 2;
1771
1772 //
Eino-Ville Talvalad96748b2013-09-12 11:11:27 -07001773 // Enumeration values for CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE
1774 //
1775
1776 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001777 * <p>Do not include a lens shading map in the capture result.</p>
Eino-Ville Talvalad96748b2013-09-12 11:11:27 -07001778 * @see CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE
1779 */
1780 public static final int STATISTICS_LENS_SHADING_MAP_MODE_OFF = 0;
1781
1782 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001783 * <p>Include a lens shading map in the capture result.</p>
Eino-Ville Talvalad96748b2013-09-12 11:11:27 -07001784 * @see CaptureRequest#STATISTICS_LENS_SHADING_MAP_MODE
1785 */
1786 public static final int STATISTICS_LENS_SHADING_MAP_MODE_ON = 1;
1787
1788 //
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001789 // Enumeration values for CaptureRequest#TONEMAP_MODE
1790 //
1791
1792 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001793 * <p>Use the tone mapping curve specified in
Yin-Chia Yeh8490ace2014-05-27 10:04:54 -07001794 * the {@link CaptureRequest#TONEMAP_CURVE android.tonemap.curve}* entries.</p>
Igor Murashkine0060932014-01-17 17:24:11 -08001795 * <p>All color enhancement and tonemapping must be disabled, except
1796 * for applying the tonemapping curve specified by
Yin-Chia Yeh8490ace2014-05-27 10:04:54 -07001797 * {@link CaptureRequest#TONEMAP_CURVE android.tonemap.curve}.</p>
Igor Murashkine0060932014-01-17 17:24:11 -08001798 * <p>Must not slow down frame rate relative to raw
1799 * sensor output.</p>
1800 *
Yin-Chia Yeh8490ace2014-05-27 10:04:54 -07001801 * @see CaptureRequest#TONEMAP_CURVE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001802 * @see CaptureRequest#TONEMAP_MODE
1803 */
1804 public static final int TONEMAP_MODE_CONTRAST_CURVE = 0;
1805
1806 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001807 * <p>Advanced gamma mapping and color enhancement may be applied, without
1808 * reducing frame rate compared to raw sensor output.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001809 * @see CaptureRequest#TONEMAP_MODE
1810 */
1811 public static final int TONEMAP_MODE_FAST = 1;
1812
1813 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001814 * <p>High-quality gamma mapping and color enhancement will be applied, at
1815 * the cost of reduced frame rate compared to raw sensor output.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001816 * @see CaptureRequest#TONEMAP_MODE
1817 */
1818 public static final int TONEMAP_MODE_HIGH_QUALITY = 2;
1819
1820 //
1821 // Enumeration values for CaptureResult#CONTROL_AE_STATE
1822 //
1823
1824 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001825 * <p>AE is off or recently reset.</p>
1826 * <p>When a camera device is opened, it starts in
Zhijun He60b19dc2014-02-24 10:19:20 -08001827 * this state. This is a transient state, the camera device may skip reporting
1828 * this state in capture result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001829 * @see CaptureResult#CONTROL_AE_STATE
1830 */
1831 public static final int CONTROL_AE_STATE_INACTIVE = 0;
1832
1833 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001834 * <p>AE doesn't yet have a good set of control values
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001835 * for the current scene.</p>
1836 * <p>This is a transient state, the camera device may skip
Zhijun He60b19dc2014-02-24 10:19:20 -08001837 * reporting this state in capture result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001838 * @see CaptureResult#CONTROL_AE_STATE
1839 */
1840 public static final int CONTROL_AE_STATE_SEARCHING = 1;
1841
1842 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001843 * <p>AE has a good set of control values for the
Zhijun He228f4f92014-01-16 17:22:05 -08001844 * current scene.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001845 * @see CaptureResult#CONTROL_AE_STATE
1846 */
1847 public static final int CONTROL_AE_STATE_CONVERGED = 2;
1848
1849 /**
Zhijun He228f4f92014-01-16 17:22:05 -08001850 * <p>AE has been locked.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001851 * @see CaptureResult#CONTROL_AE_STATE
1852 */
1853 public static final int CONTROL_AE_STATE_LOCKED = 3;
1854
1855 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001856 * <p>AE has a good set of control values, but flash
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001857 * needs to be fired for good quality still
Zhijun He228f4f92014-01-16 17:22:05 -08001858 * capture.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001859 * @see CaptureResult#CONTROL_AE_STATE
1860 */
1861 public static final int CONTROL_AE_STATE_FLASH_REQUIRED = 4;
1862
1863 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001864 * <p>AE has been asked to do a precapture sequence
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001865 * and is currently executing it.</p>
1866 * <p>Precapture can be triggered through setting
1867 * {@link CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER android.control.aePrecaptureTrigger} to START.</p>
1868 * <p>Once PRECAPTURE completes, AE will transition to CONVERGED
1869 * or FLASH_REQUIRED as appropriate. This is a transient
1870 * state, the camera device may skip reporting this state in
1871 * capture result.</p>
Zhijun He228f4f92014-01-16 17:22:05 -08001872 *
1873 * @see CaptureRequest#CONTROL_AE_PRECAPTURE_TRIGGER
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001874 * @see CaptureResult#CONTROL_AE_STATE
1875 */
1876 public static final int CONTROL_AE_STATE_PRECAPTURE = 5;
1877
1878 //
1879 // Enumeration values for CaptureResult#CONTROL_AF_STATE
1880 //
1881
1882 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001883 * <p>AF is off or has not yet tried to scan/been asked
1884 * to scan.</p>
1885 * <p>When a camera device is opened, it starts in this
1886 * state. This is a transient state, the camera device may
1887 * skip reporting this state in capture
1888 * result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001889 * @see CaptureResult#CONTROL_AF_STATE
1890 */
1891 public static final int CONTROL_AF_STATE_INACTIVE = 0;
1892
1893 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001894 * <p>AF is currently performing an AF scan initiated the
1895 * camera device in a continuous autofocus mode.</p>
1896 * <p>Only used by CONTINUOUS_* AF modes. This is a transient
1897 * state, the camera device may skip reporting this state in
1898 * capture result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001899 * @see CaptureResult#CONTROL_AF_STATE
1900 */
1901 public static final int CONTROL_AF_STATE_PASSIVE_SCAN = 1;
1902
1903 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001904 * <p>AF currently believes it is in focus, but may
1905 * restart scanning at any time.</p>
1906 * <p>Only used by CONTINUOUS_* AF modes. This is a transient
1907 * state, the camera device may skip reporting this state in
1908 * capture result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001909 * @see CaptureResult#CONTROL_AF_STATE
1910 */
1911 public static final int CONTROL_AF_STATE_PASSIVE_FOCUSED = 2;
1912
1913 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001914 * <p>AF is performing an AF scan because it was
1915 * triggered by AF trigger.</p>
1916 * <p>Only used by AUTO or MACRO AF modes. This is a transient
1917 * state, the camera device may skip reporting this state in
1918 * capture result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001919 * @see CaptureResult#CONTROL_AF_STATE
1920 */
1921 public static final int CONTROL_AF_STATE_ACTIVE_SCAN = 3;
1922
1923 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001924 * <p>AF believes it is focused correctly and has locked
1925 * focus.</p>
1926 * <p>This state is reached only after an explicit START AF trigger has been
1927 * sent ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}), when good focus has been obtained.</p>
1928 * <p>The lens will remain stationary until the AF mode ({@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}) is changed or
1929 * a new AF trigger is sent to the camera device ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}).</p>
1930 *
1931 * @see CaptureRequest#CONTROL_AF_MODE
1932 * @see CaptureRequest#CONTROL_AF_TRIGGER
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001933 * @see CaptureResult#CONTROL_AF_STATE
1934 */
1935 public static final int CONTROL_AF_STATE_FOCUSED_LOCKED = 4;
1936
1937 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001938 * <p>AF has failed to focus successfully and has locked
1939 * focus.</p>
1940 * <p>This state is reached only after an explicit START AF trigger has been
1941 * sent ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}), when good focus cannot be obtained.</p>
1942 * <p>The lens will remain stationary until the AF mode ({@link CaptureRequest#CONTROL_AF_MODE android.control.afMode}) is changed or
1943 * a new AF trigger is sent to the camera device ({@link CaptureRequest#CONTROL_AF_TRIGGER android.control.afTrigger}).</p>
1944 *
1945 * @see CaptureRequest#CONTROL_AF_MODE
1946 * @see CaptureRequest#CONTROL_AF_TRIGGER
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001947 * @see CaptureResult#CONTROL_AF_STATE
1948 */
1949 public static final int CONTROL_AF_STATE_NOT_FOCUSED_LOCKED = 5;
1950
Eino-Ville Talvala9f880f72013-09-20 17:50:41 -07001951 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001952 * <p>AF finished a passive scan without finding focus,
1953 * and may restart scanning at any time.</p>
1954 * <p>Only used by CONTINUOUS_* AF modes. This is a transient state, the camera
Zhijun He60b19dc2014-02-24 10:19:20 -08001955 * device may skip reporting this state in capture result.</p>
Eino-Ville Talvala9f880f72013-09-20 17:50:41 -07001956 * @see CaptureResult#CONTROL_AF_STATE
1957 */
1958 public static final int CONTROL_AF_STATE_PASSIVE_UNFOCUSED = 6;
1959
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001960 //
1961 // Enumeration values for CaptureResult#CONTROL_AWB_STATE
1962 //
1963
1964 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001965 * <p>AWB is not in auto mode, or has not yet started metering.</p>
1966 * <p>When a camera device is opened, it starts in this
1967 * state. This is a transient state, the camera device may
1968 * skip reporting this state in capture
1969 * result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001970 * @see CaptureResult#CONTROL_AWB_STATE
1971 */
1972 public static final int CONTROL_AWB_STATE_INACTIVE = 0;
1973
1974 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001975 * <p>AWB doesn't yet have a good set of control
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07001976 * values for the current scene.</p>
1977 * <p>This is a transient state, the camera device
Zhijun He60b19dc2014-02-24 10:19:20 -08001978 * may skip reporting this state in capture result.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001979 * @see CaptureResult#CONTROL_AWB_STATE
1980 */
1981 public static final int CONTROL_AWB_STATE_SEARCHING = 1;
1982
1983 /**
Igor Murashkinace5bf02013-12-10 17:36:40 -08001984 * <p>AWB has a good set of control values for the
Zhijun He228f4f92014-01-16 17:22:05 -08001985 * current scene.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001986 * @see CaptureResult#CONTROL_AWB_STATE
1987 */
1988 public static final int CONTROL_AWB_STATE_CONVERGED = 2;
1989
1990 /**
Zhijun He228f4f92014-01-16 17:22:05 -08001991 * <p>AWB has been locked.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07001992 * @see CaptureResult#CONTROL_AWB_STATE
1993 */
1994 public static final int CONTROL_AWB_STATE_LOCKED = 3;
1995
1996 //
1997 // Enumeration values for CaptureResult#FLASH_STATE
1998 //
1999
2000 /**
Zhijun He8dda7272014-03-25 13:49:30 -07002001 * <p>No flash on camera.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002002 * @see CaptureResult#FLASH_STATE
2003 */
2004 public static final int FLASH_STATE_UNAVAILABLE = 0;
2005
2006 /**
Zhijun He8dda7272014-03-25 13:49:30 -07002007 * <p>Flash is charging and cannot be fired.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002008 * @see CaptureResult#FLASH_STATE
2009 */
2010 public static final int FLASH_STATE_CHARGING = 1;
2011
2012 /**
Zhijun He8dda7272014-03-25 13:49:30 -07002013 * <p>Flash is ready to fire.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002014 * @see CaptureResult#FLASH_STATE
2015 */
2016 public static final int FLASH_STATE_READY = 2;
2017
2018 /**
Zhijun He8dda7272014-03-25 13:49:30 -07002019 * <p>Flash fired for this capture.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002020 * @see CaptureResult#FLASH_STATE
2021 */
2022 public static final int FLASH_STATE_FIRED = 3;
2023
Zhijun He8dda7272014-03-25 13:49:30 -07002024 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002025 * <p>Flash partially illuminated this frame.</p>
2026 * <p>This is usually due to the next or previous frame having
2027 * the flash fire, and the flash spilling into this capture
Zhijun He8dda7272014-03-25 13:49:30 -07002028 * due to hardware limitations.</p>
2029 * @see CaptureResult#FLASH_STATE
2030 */
2031 public static final int FLASH_STATE_PARTIAL = 4;
2032
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002033 //
2034 // Enumeration values for CaptureResult#LENS_STATE
2035 //
2036
2037 /**
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08002038 * <p>The lens parameters ({@link CaptureRequest#LENS_FOCAL_LENGTH android.lens.focalLength}, {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance},
2039 * {@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 -08002040 *
2041 * @see CaptureRequest#LENS_APERTURE
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08002042 * @see CaptureRequest#LENS_FILTER_DENSITY
Zhijun Heca1b73a2014-02-03 12:39:53 -08002043 * @see CaptureRequest#LENS_FOCAL_LENGTH
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08002044 * @see CaptureRequest#LENS_FOCUS_DISTANCE
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002045 * @see CaptureResult#LENS_STATE
2046 */
2047 public static final int LENS_STATE_STATIONARY = 0;
2048
Igor Murashkin9ea4ae62013-09-11 21:40:11 -07002049 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002050 * <p>One or several of the lens parameters
2051 * ({@link CaptureRequest#LENS_FOCAL_LENGTH android.lens.focalLength}, {@link CaptureRequest#LENS_FOCUS_DISTANCE android.lens.focusDistance},
2052 * {@link CaptureRequest#LENS_FILTER_DENSITY android.lens.filterDensity} or {@link CaptureRequest#LENS_APERTURE android.lens.aperture}) is
2053 * currently changing.</p>
Zhijun Heca1b73a2014-02-03 12:39:53 -08002054 *
2055 * @see CaptureRequest#LENS_APERTURE
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08002056 * @see CaptureRequest#LENS_FILTER_DENSITY
Zhijun Heca1b73a2014-02-03 12:39:53 -08002057 * @see CaptureRequest#LENS_FOCAL_LENGTH
Eino-Ville Talvalad8fd6792014-02-10 12:41:04 -08002058 * @see CaptureRequest#LENS_FOCUS_DISTANCE
Igor Murashkin9ea4ae62013-09-11 21:40:11 -07002059 * @see CaptureResult#LENS_STATE
2060 */
2061 public static final int LENS_STATE_MOVING = 1;
2062
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002063 //
2064 // Enumeration values for CaptureResult#STATISTICS_SCENE_FLICKER
2065 //
2066
2067 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002068 * <p>The camera device does not detect any flickering illumination
2069 * in the current scene.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002070 * @see CaptureResult#STATISTICS_SCENE_FLICKER
2071 */
2072 public static final int STATISTICS_SCENE_FLICKER_NONE = 0;
2073
2074 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002075 * <p>The camera device detects illumination flickering at 50Hz
2076 * in the current scene.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002077 * @see CaptureResult#STATISTICS_SCENE_FLICKER
2078 */
2079 public static final int STATISTICS_SCENE_FLICKER_50HZ = 1;
2080
2081 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002082 * <p>The camera device detects illumination flickering at 60Hz
2083 * in the current scene.</p>
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002084 * @see CaptureResult#STATISTICS_SCENE_FLICKER
2085 */
2086 public static final int STATISTICS_SCENE_FLICKER_60HZ = 2;
2087
Igor Murashkin3865a842014-01-17 18:18:39 -08002088 //
2089 // Enumeration values for CaptureResult#SYNC_FRAME_NUMBER
2090 //
2091
2092 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002093 * <p>The current result is not yet fully synchronized to any request.</p>
2094 * <p>Synchronization is in progress, and reading metadata from this
Igor Murashkin3865a842014-01-17 18:18:39 -08002095 * result may include a mix of data that have taken effect since the
2096 * last synchronization time.</p>
2097 * <p>In some future result, within {@link CameraCharacteristics#SYNC_MAX_LATENCY android.sync.maxLatency} frames,
2098 * this value will update to the actual frame number frame number
2099 * the result is guaranteed to be synchronized to (as long as the
2100 * request settings remain constant).</p>
2101 *
2102 * @see CameraCharacteristics#SYNC_MAX_LATENCY
2103 * @see CaptureResult#SYNC_FRAME_NUMBER
2104 * @hide
2105 */
2106 public static final int SYNC_FRAME_NUMBER_CONVERGING = -1;
2107
2108 /**
Eino-Ville Talvalae600d6a2014-06-09 14:25:50 -07002109 * <p>The current result's synchronization status is unknown.</p>
2110 * <p>The result may have already converged, or it may be in
2111 * progress. Reading from this result may include some mix
2112 * of settings from past requests.</p>
Igor Murashkin3865a842014-01-17 18:18:39 -08002113 * <p>After a settings change, the new settings will eventually all
2114 * take effect for the output buffers and results. However, this
2115 * value will not change when that happens. Altering settings
2116 * rapidly may provide outcomes using mixes of settings from recent
2117 * requests.</p>
2118 * <p>This value is intended primarily for backwards compatibility with
2119 * the older camera implementations (for android.hardware.Camera).</p>
2120 * @see CaptureResult#SYNC_FRAME_NUMBER
2121 * @hide
2122 */
2123 public static final int SYNC_FRAME_NUMBER_UNKNOWN = -2;
2124
Eino-Ville Talvala5a32b20c2013-08-08 12:38:36 -07002125 /*~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~
2126 * End generated code
2127 *~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~@~O@*/
2128
Igor Murashkinb519cc52013-07-02 11:23:44 -07002129}