1<?xml version="1.0" encoding="utf-8"?>
2<!-- Copyright (C) 2012 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<metadata xmlns="http://schemas.android.com/service/camera/metadata/"
17xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
18xsi:schemaLocation="http://schemas.android.com/service/camera/metadata/ metadata_properties.xsd">
19
20  <tags>
21    <tag id="AWB">
22        Needed for auto white balance
23    </tag>
24    <tag id="BC">
25        Needed for backwards compatibility with old Java API
26    </tag>
27    <tag id="V1">
28        New features for first camera 2 release (API1)
29    </tag>
30    <tag id="ADV">
31      <!-- TODO: fill the tag description -->
32    </tag>
33    <tag id="DNG">
34        Needed for DNG file support
35    </tag>
36    <tag id="EXIF">
37      <!-- TODO: fill the tag description -->
38    </tag>
39  </tags>
40  <namespace name="android">
41    <section name="colorCorrection">
42      <controls>
43        <entry name="mode" type="byte" enum="true">
44          <enum>
45            <value>TRANSFORM_MATRIX
46              <notes>Use the android.colorCorrection.transform matrix
47              to do color conversion</notes>
48            </value>
49            <value>FAST
50              <notes>Must not slow down frame rate relative to raw
51              bayer output</notes>
52            </value>
53            <value>HIGH_QUALITY
54              <notes>Frame rate may be reduced by high
55              quality</notes>
56            </value>
57          </enum>
58        </entry>
59        <entry name="transform" type="float"
60        type_notes="3x3 float matrix in row-major order"
61        container="array">
62          <array>
63            <size>3</size>
64            <size>3</size>
65          </array>
66          <description>A transform matrix to chromatically adapt
67          pixels in the CIE XYZ (1931) color space from the scene
68          illuminant to the sRGB-standard
69          D65-illuminant</description>
70          <range>Output values are expected to be in the range
71          (0,1)</range>
72          <notes>Values outside (0,1) should be clamped. Need to
73          provide utilities to go from CCT (+hue?), or (x,y) white
74          point, (or AWB mode) to matrix; use linear Bradford
75          algorithm.</notes>
76        </entry>
77      </controls>
78      <dynamic>
79        <clone entry="android.colorCorrection.mode"
80        kind="controls"></clone>
81      </dynamic>
82    </section>
83    <section name="control">
84      <controls>
85        <entry name="aeAntibandingMode" type="byte" enum="true">
86          <enum>
87            <value>OFF</value>
88            <value>50HZ</value>
89            <value>60HZ</value>
90            <value>AUTO</value>
91          </enum>
92          <description>Enum for controlling
93          antibanding</description>
94          <range>
95          android.control.aeAvailableAntibandingModes</range>
96        </entry>
97        <entry name="aeExposureCompensation" type="int32">
98          <description>Adjustment to AE target image
99          brightness</description>
100          <units>count of positive/negative EV steps</units>
101          <notes>For example, if EV step is 0.333, '6' will mean an
102          exposure compensation of +2 EV; -3 will mean an exposure
103          compensation of -1</notes>
104          <tag id="BC" />
105        </entry>
106        <entry name="aeLock" type="byte" enum="true">
107          <enum>
108            <value>OFF
109            <notes>Autoexposure lock is disabled; the AE algorithm
110            is free to update its parameters.</notes></value>
111            <value>ON
112            <notes>Autoexposure lock is enabled; the AE algorithm
113            must not update the exposure and sensitivity parameters
114            while the lock is active</notes></value>
115          </enum>
116          <description>Whether AE is currently locked to its latest
117          calculated values</description>
118          <notes>Note that even when AE is locked, the flash may be
119          fired if the AE mode is ON_AUTO_FLASH / ON_ALWAYS_FLASH /
120          ON_AUTO_FLASH_REDEYE.</notes>
121          <tag id="BC" />
122        </entry>
123        <entry name="aeMode" type="byte" enum="true">
124          <enum>
125            <value>OFF
126              <notes>Autoexposure is disabled; sensor.exposureTime
127              and sensor.sensitivity are used</notes>
128            </value>
129            <value>ON
130              <notes>Autoexposure is active, no flash
131              control</notes>
132            </value>
133            <value>ON_AUTO_FLASH
134            <notes>if flash exists Autoexposure is active, auto
135            flash control; flash may be fired when precapture
136            trigger is activated, and for captures for which
137            captureIntent = STILL_CAPTURE</notes></value>
138            <value>ON_ALWAYS_FLASH
139            <notes>if flash exists Autoexposure is active, auto
140            flash control for precapture trigger and always flash
141            when captureIntent = STILL_CAPTURE</notes></value>
142            <value>ON_AUTO_FLASH_REDEYE
143            <notes>optional Automatic red eye reduction with flash.
144            If deemed necessary, red eye reduction sequence should
145            fire when precapture trigger is activated, and final
146            flash should fire when captureIntent =
147            STILL_CAPTURE</notes></value>
148          </enum>
149          <description>Whether AE is currently updating the sensor
150          exposure and sensitivity fields</description>
151          <range>android.control.aeAvailableModes</range>
152          <notes>Only effective if android.control.mode =
153          AUTO</notes>
154          <tag id="BC" />
155        </entry>
156        <entry name="aeRegions" type="int32" container="array">
157          <array>
158            <size>5</size>
159            <size>area_count</size>
160          </array>
161          <description>List of areas to use for
162          metering</description>
163          <notes>Each area is a rectangle plus weight: xmin, ymin,
164          xmax, ymax, weight. The coordinate system is based on the
165          active pixel array, with (0,0) being the top-left of the
166          active pixel array, and
167          (android.sensor.info.activeArraySize.width,
168          android.sensor.info.activeArraySize.height) being the
169          bottom-right point of the active pixel array. The weight
170          should be nonnegative. If all regions have 0 weight, then
171          no specific metering area needs to be used by the HAL. If
172          the metering region is outside the current
173          android.scaler.cropRegion, the HAL should ignore the
174          sections outside the region and output the used sections
175          in the frame metadata</notes>
176          <tag id="BC" />
177        </entry>
178        <entry name="aeTargetFpsRange" type="int32"
179        container="array">
180          <array>
181            <size>2</size>
182          </array>
183          <description>Range over which fps can be adjusted to
184          maintain exposure</description>
185          <range>android.control.aeAvailableTargetFpsRanges</range>
186          <notes>Only constrains AE algorithm, not manual control
187          of android.sensor.exposureTime</notes>
188          <tag id="BC" />
189        </entry>
190        <entry name="aePrecaptureTrigger" type="byte" enum="true">
191          <enum>
192            <value>IDLE
193              <notes>The trigger is idle.</notes>
194            </value>
195            <value>START
196              <notes>The precapture metering sequence
197              must be started. The exact effect of the precapture
198              trigger depends on the current AE mode and
199              state.</notes>
200            </value>
201          </enum>
202          <description>Whether the HAL must trigger precapture
203          metering.</description>
204          <notes>This entry is normally set to IDLE, or is not
205          included at all in the request settings. When included and
206          set to START, the HAL must trigger the autoexposure
207          precapture metering sequence. The effect of AE precapture
208          trigger depends on the current AE mode and state; see the
209          camera HAL device v3 header for details.</notes>
210          <tag id="BC" />
211        </entry>
212        <entry name="afMode" type="byte" enum="true">
213          <enum>
214            <value>OFF
215            <notes>The 3A routines do not control the lens;
216            android.lens.focusPosition is controlled by the
217            application</notes></value>
218            <value>AUTO
219            <notes>if lens is not fixed focus. Use
220            android.lens.minimumFocusDistance to determine if lens
221            is fixed focus In this mode, the lens does not move
222            unless the autofocus trigger action is called. When
223            that trigger is activated, AF must transition to
224            ACTIVE_SCAN, then to the outcome of the scan (FOCUSED
225            or NOT_FOCUSED). Triggering cancel AF resets the lens
226            position to default, and sets the AF state to
227            INACTIVE.</notes></value>
228            <value>MACRO
229            <notes>In this mode, the lens does not move unless the
230            autofocus trigger action is called. When that trigger
231            is activated, AF must transition to ACTIVE_SCAN, then
232            to the outcome of the scan (FOCUSED or NOT_FOCUSED).
233            Triggering cancel AF resets the lens position to
234            default, and sets the AF state to
235            INACTIVE.</notes></value>
236            <value>CONTINUOUS_VIDEO
237            <notes>In this mode, the AF algorithm modifies the lens
238            position continually to attempt to provide a
239            constantly-in-focus image stream. The focusing behavior
240            should be suitable for good quality video recording;
241            typically this means slower focus movement and no
242            overshoots. When the AF trigger is not involved, the AF
243            algorithm should start in INACTIVE state, and then
244            transition into PASSIVE_SCAN and PASSIVE_FOCUSED states
245            as appropriate. When the AF trigger is activated, the
246            algorithm should immediately transition into AF_FOCUSED
247            or AF_NOT_FOCUSED as appropriate, and lock the lens
248            position until a cancel AF trigger is received. Once
249            cancel is received, the algorithm should transition
250            back to INACTIVE and resume passive scan. Note that
251            this behavior is not identical to CONTINUOUS_PICTURE,
252            since an ongoing PASSIVE_SCAN must immediately be
253            canceled.</notes></value>
254            <value>CONTINUOUS_PICTURE
255            <notes>In this mode, the AF algorithm modifies the lens
256            position continually to attempt to provide a
257            constantly-in-focus image stream. The focusing behavior
258            should be suitable for still image capture; typically
259            this means focusing as fast as possible. When the AF
260            trigger is not involved, the AF algorithm should start
261            in INACTIVE state, and then transition into
262            PASSIVE_SCAN and PASSIVE_FOCUSED states as appropriate
263            as it attempts to maintain focus. When the AF trigger
264            is activated, the algorithm should finish its
265            PASSIVE_SCAN if active, and then transition into
266            AF_FOCUSED or AF_NOT_FOCUSED as appropriate, and lock
267            the lens position until a cancel AF trigger is
268            received. When the AF cancel trigger is activated, the
269            algorithm should transition back to INACTIVE and then
270            act as if it has just been started.</notes></value>
271            <value>EDOF
272            <notes>Extended depth of field (digital focus). AF
273            trigger is ignored, AF state should always be
274            INACTIVE.</notes></value>
275          </enum>
276          <description>Whether AF is currently enabled, and what
277          mode it is set to</description>
278          <tag id="BC" />
279        </entry>
280        <entry name="afRegions" type="int32" container="array">
281          <array>
282            <size>5</size>
283            <size>area_count</size>
284          </array>
285          <description>List of areas to use for focus
286          estimation</description>
287          <notes>Each area is a rectangle plus weight: xmin, ymin,
288          xmax, ymax, weight. The coordinate system is based on the
289          active pixel array, with (0,0) being the top-left of the
290          active pixel array, and
291          (android.sensor.info.activeArraySize.width,
292          android.sensor.info.activeArraySize.height) being the
293          bottom-right point of the active pixel array. The weight
294          should be nonnegative. If all regions have 0 weight, then
295          no specific focus area needs to be used by the HAL. If
296          the focusing region is outside the current
297          android.scaler.cropRegion, the HAL should ignore the
298          sections outside the region and output the used sections
299          in the frame metadata</notes>
300          <tag id="BC" />
301        </entry>
302        <entry name="afTrigger" type="byte" enum="true">
303          <enum>
304            <value>IDLE
305              <notes>The trigger is idle.</notes>
306            </value>
307            <value>START
308              <notes>Autofocus must trigger now.</notes>
309            </value>
310            <value>CANCEL
311              <notes>Autofocus must return to initial
312              state, and cancel any active trigger.</notes>
313            </value>
314          </enum>
315          <description>Whether the HAL must trigger autofocus.</description>
316          <notes>This entry is normally set to IDLE, or is not
317          included at all in the request settings. When included and
318          set to START, the HAL must trigger the autofocus
319          algorithm. The effect of AF trigger depends on the current
320          AF mode and state; see the camera HAL device v3 header for
321          details. When set to CANCEL, the HAL must cancel any active
322          trigger, and return to initial AF state.</notes>
323          <tag id="BC" />
324        </entry>
325        <entry name="awbLock" type="byte" enum="true">
326          <enum>
327            <value>OFF
328            <notes>Auto-whitebalance lock is disabled; the AWB
329            algorithm is free to update its parameters if in AUTO
330            mode.</notes></value>
331            <value>ON
332            <notes>Auto-whitebalance lock is enabled; the AWB
333            algorithm must not update the exposure and sensitivity
334            parameters while the lock is active</notes></value>
335          </enum>
336          <description>Whether AWB is currently locked to its
337          latest calculated values</description>
338          <notes>Note that AWB lock is only meaningful for AUTO
339          mode; in other modes, AWB is already fixed to a specific
340          setting</notes>
341          <tag id="BC" />
342        </entry>
343        <entry name="awbMode" type="byte" enum="true">
344          <enum>
345            <value>OFF</value>
346            <value>AUTO</value>
347            <value>INCANDESCENT</value>
348            <value>FLUORESCENT</value>
349            <value>WARM_FLUORESCENT</value>
350            <value>DAYLIGHT</value>
351            <value>CLOUDY_DAYLIGHT</value>
352            <value>TWILIGHT</value>
353            <value>SHADE</value>
354          </enum>
355          <description>Whether AWB is currently setting the color
356          transform fields, and what its illumination target
357          is</description>
358          <notes>[BC - AWB lock,AWB modes]</notes>
359          <tag id="BC" />
360          <tag id="AWB" />
361        </entry>
362        <entry name="awbRegions" type="int32" container="array">
363          <array>
364            <size>5</size>
365            <size>area_count</size>
366          </array>
367          <description>List of areas to use for illuminant
368          estimation</description>
369          <notes>Only used in AUTO mode. Each area is a rectangle
370          plus weight: xmin, ymin, xmax, ymax, weight. The
371          coordinate system is based on the active pixel array,
372          with (0,0) being the top-left of the active pixel array,
373          and (android.sensor.info.activeArraySize.width,
374          android.sensor.info.activeArraySize.height) being the
375          bottom-right point of the active pixel array. The weight
376          should be nonnegative. If all regions have 0 weight, then
377          no specific metering area needs to be used by the HAL. If
378          the metering region is outside the current
379          android.scaler.cropRegion, the HAL should ignore the
380          sections outside the region and output the used sections
381          in the frame metadata</notes>
382          <tag id="BC" />
383        </entry>
384        <entry name="captureIntent" type="byte" enum="true">
385          <enum>
386            <value>CUSTOM
387            <notes>This request doesn't fall into the other
388            categories. Default to preview-like
389            behavior.</notes></value>
390            <value>PREVIEW
391            <notes>This request is for a preview-like usecase. The
392            precapture trigger may be used to start off a metering
393            w/flash sequence</notes></value>
394            <value>STILL_CAPTURE
395            <notes>This request is for a still capture-type
396            usecase.</notes></value>
397            <value>VIDEO_RECORD
398            <notes>This request is for a video recording
399            usecase.</notes></value>
400            <value>VIDEO_SNAPSHOT
401            <notes>This request is for a video snapshot (still
402            image while recording video) usecase</notes></value>
403            <value>ZERO_SHUTTER_LAG
404            <notes>This request is for a ZSL usecase; the
405            application will stream full-resolution images and
406            reprocess one or several later for a final
407            capture</notes></value>
408          </enum>
409          <description>Information to 3A routines about the purpose
410          of this capture, to help decide optimal 3A
411          strategy</description>
412          <range>all must be supported</range>
413          <notes>Only used if android.control.mode != OFF.</notes>
414          <tag id="BC" />
415        </entry>
416        <entry name="effectMode" type="byte" enum="true">
417          <enum>
418            <value>OFF</value>
419            <value optional="true">MONO</value>
420            <value optional="true">NEGATIVE</value>
421            <value optional="true">SOLARIZE</value>
422            <value optional="true">SEPIA</value>
423            <value optional="true">POSTERIZE</value>
424            <value optional="true">WHITEBOARD</value>
425            <value optional="true">BLACKBOARD</value>
426            <value optional="true">AQUA</value>
427          </enum>
428          <description>Whether any special color effect is in use.
429          Only used if android.control.mode != OFF</description>
430          <range>android.control.availableEffects</range>
431          <tag id="BC" />
432        </entry>
433        <entry name="mode" type="byte" enum="true">
434          <enum>
435            <value>OFF
436            <notes>Full application control of pipeline. All 3A
437            routines are disabled, no other settings in
438            android.control.* have any effect</notes></value>
439            <value>AUTO
440            <notes>Use settings for each individual 3A routine.
441            Manual control of capture parameters is disabled. All
442            controls in android.control.* besides sceneMode take
443            effect</notes></value>
444            <value>USE_SCENE_MODE
445            <notes>Use specific scene mode. Enabling this disables
446            control.aeMode, control.awbMode and control.afMode
447            controls; the HAL must ignore those settings while
448            USE_SCENE_MODE is active (except for FACE_PRIORITY
449            scene mode). Other control entries are still active.
450            This setting can only be used if availableSceneModes !=
451            UNSUPPORTED</notes></value>
452          </enum>
453          <description>Overall mode of 3A control
454          routines</description>
455          <range>all must be supported</range>
456          <tag id="BC" />
457        </entry>
458        <entry name="sceneMode" type="byte" enum="true">
459          <enum>
460            <value id="0">UNSUPPORTED</value>
461            <value>FACE_PRIORITY
462            <notes>if face detection support exists Use face
463            detection data to drive 3A routines. If face detection
464            statistics are disabled, should still operate correctly
465            (but not return face detection statistics to the
466            framework). Unlike the other scene modes, aeMode,
467            awbMode, and afMode remain active when FACE_PRIORITY is
468            set. This is due to compatibility concerns with the old
469            camera API</notes></value>
470            <value optional="true">ACTION</value>
471            <value optional="true">PORTRAIT</value>
472            <value optional="true">LANDSCAPE</value>
473            <value optional="true">NIGHT</value>
474            <value optional="true">NIGHT_PORTRAIT</value>
475            <value optional="true">THEATRE</value>
476            <value optional="true">BEACH</value>
477            <value optional="true">SNOW</value>
478            <value optional="true">SUNSET</value>
479            <value optional="true">STEADYPHOTO</value>
480            <value optional="true">FIREWORKS</value>
481            <value optional="true">SPORTS</value>
482            <value optional="true">PARTY</value>
483            <value optional="true">CANDLELIGHT</value>
484            <value optional="true">BARCODE</value>
485          </enum>
486          <description>Which scene mode is active when
487          android.control.mode = SCENE_MODE</description>
488          <range>android.control.availableSceneModes</range>
489          <tag id="BC" />
490        </entry>
491        <entry name="videoStabilizationMode" type="byte" enum="true">
492          <enum>
493            <value>OFF</value>
494            <value>ON</value>
495          </enum>
496          <description>Whether video stabilization is
497          active</description>
498          <notes>If enabled, video stabilization can modify the
499          android.scaler.cropRegion to keep the video stream
500          stabilized</notes>
501          <tag id="BC" />
502        </entry>
503      </controls>
504      <static>
505        <entry name="aeAvailableAntibandingModes" type="byte"
506        type_notes="list of enums" container="array">
507          <array>
508            <size>n</size>
509          </array>
510          <description>Which set of antibanding modes are
511          supported</description>
512        </entry>
513        <entry name="aeAvailableModes" type="byte"
514        type_notes="list of enums" container="array">
515          <array>
516            <size>n</size>
517          </array>
518          <description>Which subset of AE modes is
519          supported</description>
520          <range>OFF, ON must be supported.
521          ON_AUTO_FLASH/ON_ALWAYS_FLASH must be supported if flash
522          unit is available</range>
523        </entry>
524        <entry name="aeAvailableTargetFpsRanges" type="int32"
525        type_notes="list of pairs of frame rates"
526        container="array">
527          <array>
528            <size>2</size>
529            <size>n</size>
530          </array>
531          <description>List of frame rate ranges supported by the
532          AE algorithm/hardware</description>
533        </entry>
534        <entry name="aeCompensationRange" type="int32"
535        container="array">
536          <array>
537            <size>2</size>
538          </array>
539          <description>Maximum and minimum exposure compensation
540          setting, in counts of
541          android.control.aeCompensationStepSize</description>
542          <range>At least (-2,2)/(exp compensation step
543          size)</range>
544          <tag id="BC" />
545        </entry>
546        <entry name="aeCompensationStep" type="rational">
547          <description>Smallest step by which exposure compensation
548          can be changed</description>
549          <range>&lt;= 1/2</range>
550          <tag id="BC" />
551        </entry>
552        <entry name="afAvailableModes" type="byte"
553        type_notes="List of enums" container="array">
554          <array>
555            <size>n</size>
556          </array>
557          <description>List of AF modes that can be
558          selected</description>
559          <range>OFF must be included. AUTO must be supported if
560          lens allows for changing focus</range>
561          <tag id="BC" />
562        </entry>
563        <entry name="availableEffects" type="byte"
564        type_notes="list of enums" container="array">
565          <array>
566            <size>n</size>
567          </array>
568          <description>what subset of the full color effect enum
569          list is supported</description>
570          <range>OFF must be listed</range>
571          <tag id="BC" />
572        </entry>
573        <entry name="availableSceneModes" type="byte"
574        type_notes="list of enums from android.control.sceneMode, plus UNSUPPORTED to indicate no scene modes are supported"
575        container="array">
576          <array>
577            <size>n</size>
578          </array>
579          <description>what subset of the scene mode enum list is
580          supported.</description>
581          <range>SCENE_MODE_FACE_PRIORITY must be supported if face
582          detection is supported</range>
583          <tag id="BC" />
584        </entry>
585        <entry name="availableVideoStabilizationModes" type="byte"
586        type_notes="List of enums." container="array">
587          <array>
588            <size>n</size>
589          </array>
590          <description>List of video stabilization modes that can
591          be supported</description>
592          <range>OFF must be included</range>
593          <tag id="BC" />
594        </entry>
595        <entry name="awbAvailableModes" type="byte"
596        type_notes="List of enums (android.control.awbMode)"
597        container="array">
598          <array>
599            <size>n</size>
600          </array>
601          <range>OFF, AUTO must be included</range>
602          <tag id="BC" />
603        </entry>
604        <entry name="maxRegions" type="int32">
605          <description>For AE, AWB, and AF, how many individual
606          regions can be listed for metering?</description>
607          <range>&gt;= 1</range>
608          <tag id="BC" />
609        </entry>
610        <entry name="sceneModeOverrides" type="byte"
611        container="array">
612          <array>
613            <size>3</size>
614            <size>lengthavailablescenemodes</size>
615          </array>
616          <description>List of AE, AWB, and AF modes to use for
617          each available scene mode</description>
618          <range>For each listed scene mode, lists the aeMode,
619          awbMode, and afMode that the HAL wants to use for that
620          scene mode. For each entry, the order is {aeMode,
621          awbMode, afMode} in order of increasing index</range>
622          <notes>When a scene mode is enabled, the HAL is expected
623          to override aeMode, awbMode, and afMode with its
624          preferred settings for that scene mode. To simplify
625          communication with old camera API applications, the
626          service wants this override list in the static metadata.
627          The order of this list matches that of
628          availableSceneModes, with 3 entires for each scene mode.
629          The overrides listed for SCENE_MODE_FACE_PRIORITY are
630          ignored, since for that mode, the application-set aeMode,
631          awbMode, and afMode are used instead, like they are when
632          android.control.mode is AUTO. It is recommended that for
633          FACE_PRIORITY, the overrides should be set to 0. As an
634          example, if availableSceneModes is { FACE_PRIORITY,
635          ACTION, NIGHT }, then the service expects this field to
636          have 9 entries; for example { 0 , 0, 0, ON_AUTO_FLASH,
637          AUTO, CONTINUOUS_PICTURE, ON_AUTO_FLASH, INCANDESCENT,
638          AUTO }</notes>
639          <tag id="BC" />
640        </entry>
641      </static>
642      <dynamic>
643        <entry name="aePrecaptureId" type="int32">
644          <description>The ID sent with the latest
645          CAMERA2_TRIGGER_PRECAPTURE_METERING call</description>
646          <notes>Must be 0 if no
647          CAMERA2_TRIGGER_PRECAPTURE_METERING trigger received yet
648          by HAL. Always updated even if AE algorithm ignores the
649          trigger</notes>
650        </entry>
651        <clone entry="android.control.aeRegions" kind="controls">
652        </clone>
653        <entry name="aeState" type="byte" enum="true">
654          <enum>
655            <value>INACTIVE
656            <notes>AE is off.  When a camera device is opened, it starts in
657            this state.</notes></value>
658            <value>SEARCHING
659            <notes>AE doesn't yet have a good set of control values
660            for the current scene</notes></value>
661            <value>CONVERGED
662            <notes>AE has a good set of control values for the
663            current scene</notes></value>
664            <value>LOCKED
665            <notes>AE has been locked (aeMode =
666            LOCKED)</notes></value>
667            <value>FLASH_REQUIRED
668            <notes>AE has a good set of control values, but flash
669            needs to be fired for good quality still
670            capture</notes></value>
671            <value>PRECAPTURE
672            <notes>AE has been asked to do a precapture sequence
673            (through the
674            trigger_action(CAMERA2_TRIGGER_PRECAPTURE_METERING)
675            call), and is currently executing it. Once PRECAPTURE
676            completes, AE will transition to CONVERGED or
677            FLASH_REQUIRED as appropriate</notes></value>
678          </enum>
679          <description>Current state of AE algorithm</description>
680          <notes>Whenever the AE algorithm state changes, a
681          MSG_AUTOEXPOSURE notification must be send if a
682          notification callback is registered.</notes>
683        </entry>
684        <clone entry="android.control.afMode" kind="controls">
685        </clone>
686        <clone entry="android.control.afRegions" kind="controls">
687        </clone>
688        <entry name="afState" type="byte" enum="true">
689          <enum>
690            <value>INACTIVE
691            <notes>AF off or has not yet tried to scan/been asked
692            to scan.  When a camera device is opened, it starts in
693            this state.</notes></value>
694            <value>PASSIVE_SCAN
695            <notes>if CONTINUOUS_* modes are supported AF is
696            currently doing an AF scan initiated by a continuous
697            autofocus mode</notes></value>
698            <value>PASSIVE_FOCUSED
699            <notes>if CONTINUOUS_* modes are supported AF currently
700            believes it is in focus, but may restart scanning at
701            any time.</notes></value>
702            <value>ACTIVE_SCAN
703            <notes>if AUTO or MACRO modes are supported AF is doing
704            an AF scan because it was triggered by AF
705            trigger</notes></value>
706            <value>FOCUSED_LOCKED
707            <notes>if any AF mode besides OFF is supported AF
708            believes it is focused correctly and is
709            locked</notes></value>
710            <value>NOT_FOCUSED_LOCKED
711            <notes>if any AF mode besides OFF is supported AF has
712            failed to focus successfully and is
713            locked</notes></value>
714          </enum>
715          <description>Current state of AF algorithm</description>
716          <notes>Whenever the AF algorithm state changes, a
717          MSG_AUTOFOCUS notification must be send if a notification
718          callback is registered.</notes>
719        </entry>
720        <entry name="afTriggerId" type="int32">
721          <description>The ID sent with the latest
722          CAMERA2_TRIGGER_AUTOFOCUS call</description>
723          <notes>Must be 0 if no CAMERA2_TRIGGER_AUTOFOCUS trigger
724          received yet by HAL. Always updated even if AF algorithm
725          ignores the trigger</notes>
726        </entry>
727        <clone entry="android.control.awbMode" kind="controls">
728        </clone>
729        <clone entry="android.control.awbRegions" kind="controls">
730        </clone>
731        <entry name="awbState" type="byte" enum="true">
732          <enum>
733            <value>INACTIVE
734            <notes>AWB is not in auto mode.  When a camera device is opened, it
735            starts in this state.</notes></value>
736            <value>SEARCHING
737            <notes>AWB doesn't yet have a good set of control
738            values for the current scene</notes></value>
739            <value>CONVERGED
740            <notes>AWB has a good set of control values for the
741            current scene</notes></value>
742            <value>LOCKED
743            <notes>AE has been locked (aeMode =
744            LOCKED)</notes></value>
745          </enum>
746          <description>Current state of AWB algorithm</description>
747          <notes>Whenever the AWB algorithm state changes, a
748          MSG_AUTOWHITEBALANCE notification must be send if a
749          notification callback is registered.</notes>
750        </entry>
751        <clone entry="android.control.mode" kind="controls">
752        </clone>
753      </dynamic>
754    </section>
755    <section name="demosaic">
756      <controls>
757        <entry name="mode" type="byte" enum="true">
758          <enum>
759            <value>FAST
760            <notes>Minimal or no slowdown of frame rate compared to
761            Bayer RAW output</notes></value>
762            <value>HIGH_QUALITY
763            <notes>High-quality may reduce output frame
764            rate</notes></value>
765          </enum>
766          <description>Controls the quality of the demosaicing
767          processing</description>
768          <tag id="V1" />
769        </entry>
770      </controls>
771    </section>
772    <section name="edge">
773      <controls>
774        <entry name="mode" type="byte" enum="true">
775          <enum>
776            <value>OFF
777            <notes>No edge enhancement is applied</notes></value>
778            <value>FAST
779            <notes>Must not slow down frame rate relative to raw
780            bayer output</notes></value>
781            <value>HIGH_QUALITY
782            <notes>Frame rate may be reduced by high
783            quality</notes></value>
784          </enum>
785          <description>Operation mode for edge
786          enhancement</description>
787        </entry>
788        <entry name="strength" type="byte">
789          <description>Control the amount of edge enhancement
790          applied to the images</description>
791          <units>1-10; 10 is maximum sharpening</units>
792        </entry>
793      </controls>
794      <dynamic>
795        <clone entry="android.edge.mode" kind="controls"></clone>
796      </dynamic>
797    </section>
798    <section name="flash">
799      <controls>
800        <entry name="firingPower" type="byte">
801          <description>Power for flash firing/torch</description>
802          <units>10 is max power; 0 is no flash. Linear</units>
803          <range>0 - 10</range>
804          <notes>Power for snapshot may use a different scale than
805          for torch mode. Only one entry for torch mode will be
806          used</notes>
807          <tag id="V1" />
808        </entry>
809        <entry name="firingTime" type="int64">
810          <description>Firing time of flash relative to start of
811          exposure</description>
812          <units>nanoseconds</units>
813          <range>0-(exposure time-flash duration)</range>
814          <notes>Clamped to (0, exposure time - flash
815          duration).</notes>
816          <tag id="V1" />
817        </entry>
818        <entry name="mode" type="byte" enum="true">
819          <enum>
820            <value>OFF
821            <notes>Do not fire the flash for this
822            capture</notes></value>
823            <value>SINGLE
824            <notes>if android.flash.available is true Fire flash
825            for this capture based on firingPower,
826            firingTime.</notes></value>
827            <value>TORCH
828            <notes>if android.flash.available is true Flash
829            continuously on, power set by
830            firingPower</notes></value>
831          </enum>
832          <description>Select flash operation mode</description>
833          <tag id="BC" />
834        </entry>
835      </controls>
836      <static>
837        <namespace name="info">
838          <entry name="available" type="byte">
839            <description>Whether this camera has a
840            flash</description>
841            <units>boolean (0 = false, otherwise true)</units>
842            <notes>If no flash, none of the flash controls do
843            anything. All other metadata should return 0</notes>
844            <tag id="BC" />
845          </entry>
846          <entry name="chargeDuration" type="int64">
847            <description>Time taken before flash can fire
848            again</description>
849            <units>nanoseconds</units>
850            <range>0-1e9</range>
851            <notes>1 second too long/too short for recharge? Should
852            this be power-dependent?</notes>
853            <tag id="V1" />
854          </entry>
855        </namespace>
856        <entry name="colorTemperature" type="byte">
857          <description>The x,y whitepoint of the
858          flash</description>
859          <units>pair of floats</units>
860          <range>0-1 for both</range>
861          <tag id="ADV" />
862        </entry>
863        <entry name="maxEnergy" type="byte">
864          <description>Max energy output of the flash for a full
865          power single flash</description>
866          <units>lumen-seconds</units>
867          <range>&gt;= 0</range>
868          <tag id="ADV" />
869        </entry>
870      </static>
871      <dynamic>
872        <clone entry="android.flash.firingPower" kind="controls">
873        </clone>
874        <clone entry="android.flash.firingTime" kind="controls">
875        </clone>
876        <clone entry="android.flash.mode" kind="controls"></clone>
877        <entry name="state" type="byte" enum="true">
878          <enum>
879            <value>UNAVAILABLE
880            <notes>No flash on camera</notes></value>
881            <value>CHARGING
882            <notes>if android.flash.available is true Flash is
883            charging and cannot be fired</notes></value>
884            <value>READY
885            <notes>if android.flash.available is true Flash is
886            ready to fire</notes></value>
887            <value>FIRED
888            <notes>if android.flash.available is true Flash fired
889            for this capture</notes></value>
890          </enum>
891          <description>Current state of the flash
892          unit</description>
893        </entry>
894      </dynamic>
895    </section>
896    <section name="geometric">
897      <controls>
898        <entry name="mode" type="byte" enum="true">
899          <enum>
900            <value>OFF
901            <notes>No geometric correction is
902            applied</notes></value>
903            <value>FAST
904            <notes>Must not slow down frame rate relative to raw
905            bayer output</notes></value>
906            <value>HIGH_QUALITY
907            <notes>Frame rate may be reduced by high
908            quality</notes></value>
909          </enum>
910          <description>Operating mode of geometric
911          correction</description>
912        </entry>
913        <entry name="strength" type="byte">
914          <description>Control the amount of shading correction
915          applied to the images</description>
916          <units>unitless: 1-10; 10 is full shading
917          compensation</units>
918          <tag id="ADV" />
919        </entry>
920      </controls>
921    </section>
922    <section name="hotPixel">
923      <controls>
924        <entry name="mode" type="byte" enum="true">
925          <enum>
926            <value>OFF
927            <notes>No hot pixel correction can be
928            applied</notes></value>
929            <value>FAST
930            <notes>Frame rate must not be reduced compared to raw
931            Bayer output</notes></value>
932            <value>HIGH_QUALITY
933            <notes>Frame rate may be reduced by high
934            quality</notes></value>
935          </enum>
936          <description>Set operational mode for hot pixel
937          correction</description>
938          <tag id="V1" />
939        </entry>
940      </controls>
941      <static>
942        <namespace name="info">
943          <entry name="map" type="int32"
944          type_notes="list of coordinates based on android.sensor.pixelArraySize"
945          container="array">
946            <array>
947              <size>2</size>
948              <size>n</size>
949            </array>
950            <description>Location of hot/defective pixels on
951            sensor</description>
952            <tag id="ADV" />
953          </entry>
954        </namespace>
955      </static>
956      <dynamic>
957        <clone entry="android.hotPixel.mode" kind="controls">
958          <tag id="V1" />
959        </clone>
960      </dynamic>
961    </section>
962    <section name="jpeg">
963      <controls>
964        <entry name="gpsCoordinates" type="double"
965        type_notes="latitude, longitude, altitude. First two in degrees, the third in meters"
966        container="array">
967          <array>
968            <size>3</size>
969          </array>
970          <description>GPS coordinates to include in output JPEG
971          EXIF</description>
972          <range>(-180 - 180], [-90,90], [-inf, inf]</range>
973          <tag id="BC" />
974        </entry>
975        <entry name="gpsProcessingMethod" type="byte">
976          <description>32 characters describing GPS algorithm to
977          include in EXIF</description>
978          <units>UTF-8 null-terminated string</units>
979          <tag id="BC" />
980        </entry>
981        <entry name="gpsTimestamp" type="int64">
982          <description>Time GPS fix was made to include in
983          EXIF</description>
984          <units>UTC in seconds since January 1, 1970</units>
985          <tag id="BC" />
986        </entry>
987        <entry name="orientation" type="int32">
988          <description>Orientation of JPEG image to
989          write</description>
990          <units>Degrees in multiples of 90</units>
991          <range>0, 90, 180, 270</range>
992          <tag id="BC" />
993        </entry>
994        <entry name="quality" type="byte">
995          <description>Compression quality of the final JPEG
996          image</description>
997          <range>1-100; larger is higher quality</range>
998          <notes>85-95 is typical usage range</notes>
999          <tag id="BC" />
1000        </entry>
1001        <entry name="thumbnailQuality" type="byte">
1002          <description>Compression quality of JPEG
1003          thumbnail</description>
1004          <range>1-100; larger is higher quality</range>
1005          <tag id="BC" />
1006        </entry>
1007        <entry name="thumbnailSize" type="int32" container="array">
1008          <array>
1009            <size>2</size>
1010          </array>
1011          <description>Resolution of embedded JPEG
1012          thumbnail</description>
1013          <range>from android.jpeg.availableThumbnailSizes</range>
1014          <tag id="BC" />
1015        </entry>
1016      </controls>
1017      <static>
1018        <entry name="availableThumbnailSizes" type="int32"
1019        type_notes="list of resolution pairs" container="array">
1020          <array>
1021            <size>2</size>
1022            <size>n</size>
1023          </array>
1024          <description>Supported resolutions for the JPEG
1025          thumbnail</description>
1026          <range>Must include at least one valid resolution, plus
1027          (0,0) for no thumbnail generation</range>
1028          <tag id="BC" />
1029        </entry>
1030        <entry name="maxSize" type="int32">
1031          <description>Maximum size in bytes for the compressed
1032          JPEG buffer</description>
1033          <range>Must be large enough to fit any JPEG produced by
1034          the camera</range>
1035          <notes>This is used for sizing the gralloc buffers for
1036          JPEG</notes>
1037        </entry>
1038      </static>
1039      <dynamic>
1040        <clone entry="android.jpeg.gpsCoordinates" kind="controls">
1041        </clone>
1042        <clone entry="android.jpeg.gpsProcessingMethod"
1043        kind="controls"></clone>
1044        <clone entry="android.jpeg.gpsTimestamp" kind="controls">
1045        </clone>
1046        <clone entry="android.jpeg.orientation" kind="controls">
1047        </clone>
1048        <clone entry="android.jpeg.quality" kind="controls">
1049        </clone>
1050        <entry name="size" type="int32">
1051          <description>The size of the compressed JPEG image, in
1052          bytes</description>
1053          <range>&gt;= 0</range>
1054          <notes>If no JPEG output is produced for the request,
1055          this must be 0. Otherwise, this describes the real size
1056          of the compressed JPEG image placed in the output stream.
1057          More specifically, if android.jpeg.maxSize = 1000000, and
1058          a specific capture has android.jpeg.size = 500000, then
1059          the output buffer from the JPEG stream will be 1000000
1060          bytes, of which the first 500000 make up the real
1061          data.</notes>
1062        </entry>
1063        <clone entry="android.jpeg.thumbnailQuality"
1064        kind="controls"></clone>
1065        <clone entry="android.jpeg.thumbnailSize" kind="controls">
1066        </clone>
1067      </dynamic>
1068    </section>
1069    <section name="lens">
1070      <controls>
1071        <entry name="aperture" type="float">
1072          <description>Size of the lens aperture</description>
1073          <units>f-number (f/NNN)</units>
1074          <range>android.lens.info.availableApertures</range>
1075          <notes>Will not be supported on most devices. Can only
1076          pick from supported list</notes>
1077          <tag id="V1" />
1078        </entry>
1079        <entry name="filterDensity" type="float">
1080          <description>State of lens neutral density
1081          filter(s)</description>
1082          <units>number of stops of filtering</units>
1083          <range>android.lens.info.availableFilterDensities</range>
1084          <notes>Will not be supported on most devices. Can only
1085          pick from supported list</notes>
1086          <tag id="V1" />
1087        </entry>
1088        <entry name="focalLength" type="float">
1089          <description>Lens optical zoom setting</description>
1090          <units>focal length in mm</units>
1091          <range>&gt; 0</range>
1092          <notes>Will not be supported on most devices.</notes>
1093          <tag id="V1" />
1094        </entry>
1095        <entry name="focusDistance" type="float">
1096          <description>Distance to plane of sharpest focus,
1097          measured from frontmost surface of the lens</description>
1098          <units>diopters (1/m)</units>
1099          <range>&gt;= 0</range>
1100          <notes>0 = infinity focus. Used value should be clamped
1101          to (0,minimum focus distance)</notes>
1102          <tag id="BC" />
1103          <tag id="V1" />
1104        </entry>
1105        <entry name="opticalStabilizationMode" type="byte" enum="true">
1106          <enum>
1107            <value>OFF</value>
1108            <value optional="true">ON</value>
1109          </enum>
1110          <description>Whether optical image stabilization is
1111          enabled.</description>
1112          <range>android.lens.availableOpticalStabilization</range>
1113          <notes>Will not be supported on most devices.</notes>
1114          <tag id="V1" />
1115        </entry>
1116      </controls>
1117      <static>
1118        <namespace name="info">
1119          <entry name="availableApertures" type="float"
1120          container="array">
1121            <array>
1122              <size>n</size>
1123            </array>
1124            <description>List of supported aperture
1125            values</description>
1126            <range>one entry required, &gt; 0</range>
1127            <notes>If variable aperture not available, only setting
1128            should be for the fixed aperture</notes>
1129            <tag id="V1" />
1130          </entry>
1131          <entry name="availableFilterDensities" type="float"
1132          container="array">
1133            <array>
1134              <size>n</size>
1135            </array>
1136            <description>List of supported ND filter
1137            values</description>
1138            <range>one entry required, &gt;= 0</range>
1139            <notes>If not available, only setting is 0. Otherwise,
1140            lists the available exposure index values for dimming
1141            (2 would mean the filter is set to reduce incoming
1142            light by two stops)</notes>
1143            <tag id="V1" />
1144          </entry>
1145          <entry name="availableFocalLengths" type="float"
1146          type_notes="the list of available focal lengths"
1147          container="array">
1148            <array>
1149              <size>n</size>
1150            </array>
1151            <description>If fitted with optical zoom, what focal
1152            lengths are available. If not, the static focal
1153            length</description>
1154            <range>&gt; 0</range>
1155            <notes>If optical zoom not supported, only one value
1156            should be reported</notes>
1157            <tag id="BC" />
1158            <tag id="V1" />
1159          </entry>
1160          <entry name="availableOpticalStabilization" type="byte"
1161          type_notes="list of enums" container="array">
1162            <array>
1163              <size>n</size>
1164            </array>
1165            <description>List of supported optical image
1166            stabilization modes</description>
1167            <tag id="V1" />
1168          </entry>
1169          <entry name="geometricCorrectionMap" type="float"
1170          type_notes="2D array of destination coordinate pairs for uniform grid points in source image, per color channel. Size in the range of 2x3x40x30"
1171          container="array">
1172            <array>
1173              <size>2</size>
1174              <size>3</size>
1175              <size>n</size>
1176              <size>m</size>
1177            </array>
1178            <description>A low-resolution map for correction of
1179            geometric distortions and chromatic aberrations, per
1180            color channel</description>
1181            <range>N, M &gt;= 2</range>
1182            <notes>[DNG wants a function instead]. What's easiest
1183            for implementers? With an array size (M, N), entry (i,
1184            j) provides the destination for pixel (i/(M-1) * width,
1185            j/(N-1) * height). Data is row-major, with each array
1186            entry being ( (X, Y)_r, (X, Y)_g, (X, Y)_b ) )</notes>
1187            <tag id="DNG" />
1188          </entry>
1189          <entry name="geometricCorrectionMapSize" type="int32"
1190          type_notes="width and height of geometric correction map"
1191          container="array">
1192            <array>
1193              <size>2</size>
1194            </array>
1195            <description>Dimensions of geometric correction
1196            map</description>
1197            <range>Both values &gt;= 2</range>
1198            <tag id="V1" />
1199          </entry>
1200          <entry name="hyperfocalDistance" type="float">
1201            <description>Hyperfocal distance for this lens; set to
1202            0 if fixed focus</description>
1203            <units>diopters</units>
1204            <range>&gt;= 0</range>
1205            <notes>The hyperfocal distance is used for the old
1206            API's 'fixed' setting</notes>
1207            <tag id="BC" />
1208          </entry>
1209          <entry name="minimumFocusDistance" type="float">
1210            <description>Shortest distance from frontmost surface
1211            of the lens that can be focused correctly</description>
1212            <units>diopters</units>
1213            <range>&gt;= 0</range>
1214            <notes>If the lens is fixed-focus, this should be
1215            0</notes>
1216            <tag id="V1" />
1217          </entry>
1218          <entry name="shadingMap" type="float"
1219          type_notes="2D array of float gain factors per channel to correct for lens falloff. Should be on the order of 3x40x30"
1220          container="array">
1221            <array>
1222              <size>3</size>
1223              <size>n</size>
1224              <size>m</size>
1225            </array>
1226            <description>A low-resolution map of lens shading, per
1227            color channel</description>
1228            <range>Each gain factor is &gt;= 1</range>
1229            <notes>Assume bilinear interpolation of map. The least
1230            shaded section of the image should have a gain factor
1231            of 1; all other sections should have gains above
1232            1.</notes>
1233            <tag id="DNG" />
1234          </entry>
1235          <entry name="shadingMapSize" type="int32"
1236          type_notes="width and height of lens shading map"
1237          container="array">
1238            <array>
1239              <size>2</size>
1240            </array>
1241            <description>Dimensions of lens shading
1242            map</description>
1243            <range>Both values &gt;= 1</range>
1244            <tag id="V1" />
1245          </entry>
1246        </namespace>
1247        <entry name="facing" type="byte" enum="true">
1248          <enum>
1249            <value>FRONT</value>
1250            <value>BACK</value>
1251          </enum>
1252          <description>Direction the camera faces relative to
1253          device screen</description>
1254        </entry>
1255        <entry name="opticalAxisAngle" type="float"
1256        type_notes="degrees. First defines the angle of separation between the perpendicular to the screen and the camera optical axis. The second then defines the clockwise rotation of the optical axis from native device up."
1257        container="array">
1258          <array>
1259            <size>2</size>
1260          </array>
1261          <description>Relative angle of camera optical axis to the
1262          perpendicular axis from the display</description>
1263          <range>[0-90) for first angle, [0-360) for second</range>
1264          <notes>Examples: (0,0) means that the camera optical axis
1265          is perpendicular to the display surface; (45,0) means
1266          that the camera points 45 degrees up when device is held
1267          upright; (45,90) means the camera points 45 degrees to
1268          the right when the device is held upright. Use FACING
1269          field to determine perpendicular outgoing
1270          direction</notes>
1271          <tag id="ADV" />
1272        </entry>
1273        <entry name="position" type="float" container="array">
1274          <array>
1275            <size>3, location in mm, in the sensor coordinate
1276            system</size>
1277          </array>
1278          <description>Coordinates of camera optical axis on
1279          device</description>
1280          <tag id="V1" />
1281        </entry>
1282      </static>
1283      <dynamic>
1284        <clone entry="android.lens.aperture" kind="controls">
1285          <tag id="V1" />
1286        </clone>
1287        <clone entry="android.lens.filterDensity" kind="controls">
1288          <tag id="V1" />
1289        </clone>
1290        <clone entry="android.lens.focalLength" kind="controls">
1291          <tag id="BC" />
1292        </clone>
1293        <clone entry="android.lens.focusDistance" kind="controls">
1294          <notes>Should be zero for fixed-focus cameras</notes>
1295          <tag id="BC" />
1296        </clone>
1297        <entry name="focusRange" type="float">
1298          <description>The range of scene distances that are in
1299          sharp focus (depth of field)</description>
1300          <units>pair of focus distances in diopters: (near,
1301          far)</units>
1302          <range>&gt;=0</range>
1303          <notes>If variable focus not supported, can still report
1304          fixed depth of field range</notes>
1305          <tag id="BC" />
1306        </entry>
1307        <clone entry="android.lens.opticalStabilizationMode"
1308        kind="controls">
1309          <tag id="V1" />
1310        </clone>
1311        <entry name="state" type="byte" enum="true">
1312          <enum>
1313            <value>STATIONARY</value>
1314          </enum>
1315          <description>Current lens status</description>
1316          <tag id="V1" />
1317        </entry>
1318      </dynamic>
1319    </section>
1320    <section name="noiseReduction">
1321      <controls>
1322        <entry name="mode" type="byte" enum="true">
1323          <enum>
1324            <value>OFF
1325            <notes>No noise reduction is applied</notes></value>
1326            <value>FAST
1327            <notes>Must not slow down frame rate relative to raw
1328            bayer output</notes></value>
1329            <value>HIGH_QUALITY
1330            <notes>May slow down frame rate to provide highest
1331            quality</notes></value>
1332          </enum>
1333          <description>Mode of operation for the noise reduction
1334          algorithm</description>
1335          <range>android.noiseReduction.availableModes</range>
1336          <tag id="V1" />
1337        </entry>
1338        <entry name="strength" type="byte">
1339          <description>Control the amount of noise reduction
1340          applied to the images</description>
1341          <units>1-10; 10 is max noise reduction</units>
1342          <range>1 - 10</range>
1343        </entry>
1344      </controls>
1345      <dynamic>
1346        <clone entry="android.noiseReduction.mode" kind="controls">
1347        </clone>
1348      </dynamic>
1349    </section>
1350    <section name="quirks">
1351      <static>
1352        <entry name="meteringCropRegion" type="byte">
1353          <description>If set to 1, the camera service does not
1354          scale 'normalized' coordinates with respect to the crop
1355          region. This applies to metering input (a{e,f,wb}Region
1356          and output (face rectangles).</description>
1357          <notes>Normalized coordinates refer to those in the
1358          (-1000,1000) range mentioned in the
1359          android.hardware.Camera API. HAL implementations should
1360          instead always use and emit sensor array-relative
1361          coordinates for all region data. Does not need to be
1362          listed in static metadata. Support will be removed in
1363          future versions of camera service.</notes>
1364        </entry>
1365        <entry name="triggerAfWithAuto" type="byte">
1366          <description>If set to 1, then the camera service always
1367          switches to FOCUS_MODE_AUTO before issuing a AF
1368          trigger.</description>
1369          <notes>HAL implementations should implement AF trigger
1370          modes for AUTO, MACRO, CONTINUOUS_FOCUS, and
1371          CONTINUOUS_PICTURE modes instead of using this flag. Does
1372          not need to be listed in static metadata. Support will be
1373          removed in future versions of camera service</notes>
1374        </entry>
1375        <entry name="useZslFormat" type="byte">
1376          <description>If set to 1, the camera service uses
1377          CAMERA2_PIXEL_FORMAT_ZSL instead of
1378          HAL_PIXEL_FORMAT_IMPLEMENTATION_DEFINED for the zero
1379          shutter lag stream</description>
1380          <notes>HAL implementations should use gralloc usage flags
1381          to determine that a stream will be used for
1382          zero-shutter-lag, instead of relying on an explicit
1383          format setting. Does not need to be listed in static
1384          metadata. Support will be removed in future versions of
1385          camera service.</notes>
1386        </entry>
1387      </static>
1388    </section>
1389    <section name="request">
1390      <controls>
1391        <entry name="frameCount" type="int32">
1392          <description>A frame counter set by the framework. Must
1393          be maintained unchanged in output frame</description>
1394          <units>incrementing integer</units>
1395          <range>Any int</range>
1396        </entry>
1397        <entry name="id" type="int32">
1398          <description>An application-specified ID for the current
1399          request. Must be maintained unchanged in output
1400          frame</description>
1401          <units>arbitrary integer assigned by application</units>
1402          <range>Any int</range>
1403          <tag id="V1" />
1404        </entry>
1405        <entry name="inputStreams" type="byte">
1406          <description>List which camera reprocess stream is used
1407          for the source of reprocessing data.</description>
1408          <units>List of camera reprocess stream IDs</units>
1409          <range>Typically, only one entry allowed, must be a valid
1410          reprocess stream ID. If android.jpeg.needsThumbnail is
1411          set, then multiple reprocess streams may be included in a
1412          single request; they must be different scaled versions of
1413          the same image.</range>
1414          <notes>Only meaningful when android.request.type ==
1415          REPROCESS. Ignored otherwise</notes>
1416        </entry>
1417        <entry name="metadataMode" type="byte" enum="true">
1418          <enum>
1419            <value>NONE
1420            <notes>No metadata should be produced on output, except
1421            for application-bound buffer data. If no
1422            application-bound streams exist, no frame should be
1423            placed in the output frame queue. If such streams
1424            exist, a frame should be placed on the output queue
1425            with null metadata but with the necessary output buffer
1426            information. Timestamp information should still be
1427            included with any output stream buffers</notes></value>
1428            <value>FULL
1429            <notes>All metadata should be produced. Statistics will
1430            only be produced if they are separately
1431            enabled</notes></value>
1432          </enum>
1433          <description>How much metadata to produce on
1434          output</description>
1435        </entry>
1436        <entry name="outputStreams" type="byte">
1437          <description>Lists which camera output streams image data
1438          from this capture must be sent to</description>
1439          <units>List of camera stream IDs</units>
1440          <range>List must only include streams that have been
1441          created</range>
1442          <notes>If no output streams are listed, then the image
1443          data should simply be discarded. The image data must
1444          still be captured for metadata and statistics production,
1445          and the lens and flash must operate as requested.</notes>
1446        </entry>
1447        <entry name="type" type="byte" enum="true">
1448          <enum>
1449            <value>CAPTURE
1450            <notes>Capture a new image from the imaging hardware,
1451            and process it according to the
1452            settings</notes></value>
1453            <value>REPROCESS
1454            <notes>Process previously captured data; the
1455            android.request.inputStream parameter determines the
1456            source reprocessing stream. TODO: Mark dynamic metadata
1457            needed for reprocessing with [RP]</notes></value>
1458          </enum>
1459          <description>The type of the request; either CAPTURE or
1460          REPROCESS</description>
1461        </entry>
1462      </controls>
1463      <static>
1464        <entry name="maxNumOutputStreams" type="int32"
1465        container="array">
1466          <array>
1467            <size>3</size>
1468          </array>
1469          <description>How many output streams can be allocated at
1470          the same time for each type of stream</description>
1471          <units>The number of raw sensor streams; the number of
1472          processed, uncompressed streams; and the number of
1473          JPEG-compressed streams</units>
1474          <range>&gt;=1 for Raw and JPEG-compressed stream. &gt;= 3
1475          for processed, uncompressed streams</range>
1476          <notes>Video snapshot with preview callbacks requires 3
1477          processed streams (preview, record, app callbacks) and
1478          one JPEG stream (snapshot)</notes>
1479          <tag id="BC" />
1480        </entry>
1481        <entry name="maxNumReprocessStreams" type="int32"
1482        container="array">
1483          <array>
1484            <size>1</size>
1485          </array>
1486          <description>How many reprocessing streams of any type
1487          can be allocated at the same time</description>
1488          <range>&gt;= 1</range>
1489        </entry>
1490      </static>
1491      <dynamic>
1492        <entry name="frameCount" type="int32">
1493          <description>Number of frames captured since
1494          open()</description>
1495          <units>count of frames</units>
1496          <range>&gt; 0</range>
1497          <notes>Reset on release()</notes>
1498        </entry>
1499        <clone entry="android.request.id" kind="controls"></clone>
1500        <clone entry="android.request.metadataMode"
1501        kind="controls"></clone>
1502        <clone entry="android.request.outputStreams"
1503        kind="controls"></clone>
1504      </dynamic>
1505    </section>
1506    <section name="scaler">
1507      <controls>
1508        <entry name="cropRegion" type="int32" container="array">
1509          <array>
1510            <size>4</size>
1511          </array>
1512          <description>(x, y, width, height).
1513
1514          A rectangle with the top-level corner of (x,y) and size
1515          (width, height). The region of the sensor that is used for
1516          output. Each stream must use this rectangle to produce its
1517          output, cropping to a smaller region if necessary to
1518          maintain the stream's aspect ratio.
1519
1520          HAL2.x uses only (x, y, width)</description>
1521          <units>(x,y) of top-left corner, width and height of region
1522          in pixels; (0,0) is top-left corner of
1523          android.sensor.activeArraySize</units>
1524          <notes>
1525            Any additional per-stream cropping must be done to
1526            maximize the final pixel area of the stream.
1527
1528            For example, if the crop region is set to a 4:3 aspect
1529            ratio, then 4:3 streams should use the exact crop
1530            region. 16:9 streams should further crop vertically
1531            (letterbox).
1532
1533            Conversely, if the crop region is set to a 16:9, then 4:3
1534            outputs should crop horizontally (pillarbox), and 16:9
1535            streams should match exactly. These additional crops must
1536            be centered within the crop region.
1537
1538            The output streams must maintain square pixels at all
1539            times, no matter what the relative aspect ratios of the
1540            crop region and the stream are.  Negative values for
1541            corner are allowed for raw output if full pixel array is
1542            larger than active pixel array. Width and height may be
1543            rounded to nearest larger supportable width, especially
1544            for raw output, where only a few fixed scales may be
1545            possible. The width and height of the crop region cannot
1546            be set to be smaller than floor( activeArraySize.width /
1547            android.scaler.maxDigitalZoom ) and floor(
1548            activeArraySize.height / android.scaler.maxDigitalZoom),
1549            respectively.
1550          </notes>
1551          <tag id="BC" />
1552        </entry>
1553      </controls>
1554      <static>
1555        <entry name="availableFormats" type="int32" enum="true"
1556        type_notes="values from HAL_PIXEL_FORMAT_* in /system/core/include/system/graphics.h"
1557        container="array">
1558          <array>
1559            <size>n</size>
1560          </array>
1561          <enum>
1562            <value id="0x20">RAW_SENSOR
1563            </value>
1564            <value id="0x32315659">YV12
1565                <notes>YCrCb 4:2:0 Planar</notes>
1566            </value>
1567            <value id="0x11">YCrCb_420_SP
1568                <notes>NV21</notes>
1569            </value>
1570
1571            <value id="0x22">IMPLEMENTATION_DEFINED
1572                <notes>Hal Implementation Defined</notes>
1573            </value>
1574
1575            <value id="0x23">YCbCr_420_888
1576                <notes>Flexible YUV420 Format</notes>
1577            </value>
1578
1579            <value id="0x21">BLOB
1580                <notes>JPEG</notes>
1581            </value>
1582          </enum>
1583          <description>List of app-visible formats</description>
1584          <tag id="BC" />
1585        </entry>
1586        <entry name="availableJpegMinDurations" type="int64"
1587        container="array">
1588          <array>
1589            <size>n</size>
1590          </array>
1591          <description>The minimum frame duration that is supported
1592          for each resolution in availableJpegSizes. Should
1593          correspond to the frame duration when only that JPEG
1594          stream is active, with all processing set to
1595          FAST</description>
1596          <notes>When multiple streams are configured, the minimum
1597          frame duration will be &gt;= max(individual stream min
1598          durations)</notes>
1599          <tag id="BC" />
1600        </entry>
1601        <entry name="availableJpegSizes" type="int32"
1602        container="array">
1603          <array>
1604            <size>n</size>
1605            <size>2</size>
1606          </array>
1607          <description>The resolutions available for output from
1608          the JPEG block. Listed as width x height</description>
1609          <range>Must include: - sensor maximum resolution Should
1610          include: - half/quarter max resolution</range>
1611          <tag id="BC" />
1612        </entry>
1613        <entry name="availableMaxDigitalZoom" type="float">
1614          <description>The maximum ratio between active area width
1615          and crop region width, or between active area height and
1616          crop region height, if the crop region height is larger
1617          than width</description>
1618          <range>&gt;=1</range>
1619          <tag id="BC" />
1620        </entry>
1621        <entry name="availableProcessedMinDurations" type="int64"
1622        container="array">
1623          <array>
1624            <size>n</size>
1625          </array>
1626          <description>The minimum frame duration that is supported
1627          for each resolution in availableProcessedSizes. Should
1628          correspond to the frame duration when only that processed
1629          stream is active, with all processing set to
1630          FAST</description>
1631          <notes>When multiple streams are configured, the minimum
1632          frame duration will be &gt;= max(individual stream min
1633          durations)</notes>
1634          <tag id="BC" />
1635        </entry>
1636        <entry name="availableProcessedSizes" type="int32"
1637        container="array">
1638          <array>
1639            <size>n</size>
1640            <size>2</size>
1641          </array>
1642          <description>The resolutions available for use with
1643          processed output streams, such as YV12, NV12, and
1644          platform opaque YUV/RGB streams to the GPU or video
1645          encoders. Listed as width, height</description>
1646          <range>Must include: - sensor maximum resolution -
1647          standard QCIF, 240p, 480p, 720p, and 1080p
1648          resolutions</range>
1649          <tag id="BC" />
1650        </entry>
1651        <entry name="availableRawMinDurations" type="int64"
1652        container="array">
1653          <array>
1654            <size>n</size>
1655          </array>
1656          <description>The minimum frame duration that is supported
1657          for each raw resolution in availableRawSizes. Should
1658          correspond to the frame duration when only the raw stream
1659          is active.</description>
1660          <notes>When multiple streams are configured, the minimum
1661          frame duration will be &gt;= max(individual stream min
1662          durations)</notes>
1663          <tag id="BC" />
1664        </entry>
1665        <entry name="availableRawSizes" type="int32"
1666        container="array">
1667          <array>
1668            <size>n</size>
1669            <size>2</size>
1670          </array>
1671          <description>The resolutions available for use with raw
1672          sensor output streams, listed as width,
1673          height</description>
1674          <range>Must include: - sensor maximum resolution</range>
1675        </entry>
1676      </static>
1677      <dynamic>
1678        <clone entry="android.scaler.cropRegion" kind="controls">
1679        </clone>
1680      </dynamic>
1681    </section>
1682    <section name="sensor">
1683      <controls>
1684        <entry name="exposureTime" type="int64">
1685          <description>Duration each pixel is exposed to
1686          light</description>
1687          <units>nanoseconds</units>
1688          <range>android.sensor.info.exposureTimeRange</range>
1689          <notes>1/10000 - 30 sec range. No bulb mode</notes>
1690          <tag id="V1" />
1691        </entry>
1692        <entry name="frameDuration" type="int64">
1693          <description>Duration from start of frame exposure to
1694          start of next frame exposure</description>
1695          <units>nanoseconds</units>
1696          <range>see android.sensor.info.maxFrameDuration,
1697          android.scaler.info.availableMinFrameDurations</range>
1698          <notes>Exposure time has priority, so duration is set to
1699          max(duration, exposure time + overhead)</notes>
1700          <tag id="V1" />
1701          <tag id="BC" />
1702        </entry>
1703        <entry name="sensitivity" type="int32">
1704          <description>Gain applied to image data. Must be
1705          implemented through analog gain only if set to values
1706          below 'maximum analog sensitivity'.</description>
1707          <units>ISO arithmetic units</units>
1708          <range>android.sensor.info.sensitivityRange</range>
1709          <notes>ISO 12232:2006 REI method</notes>
1710          <tag id="V1" />
1711        </entry>
1712      </controls>
1713      <static>
1714        <namespace name="info">
1715          <entry name="activeArraySize" type="int32"
1716          type_notes="Four ints defining the active pixel rectangle"
1717          container="array">
1718            <array>
1719              <size>4</size>
1720            </array>
1721            <description>Area of raw data which corresponds to only
1722            active pixels; smaller or equal to
1723            pixelArraySize.</description>
1724            <units>xmin, ymin, width, height. Top left of full
1725            pixel array is (0,0)</units>
1726            <tag id="DNG" />
1727          </entry>
1728          <entry name="availableSensitivities" type="int32"
1729          type_notes="List of supported sensitivity values"
1730          container="array">
1731            <array>
1732              <size>n</size>
1733            </array>
1734            <description>Range of valid sensitivities</description>
1735            <range>Must at least include 100, 200, 400, 800,
1736            1600</range>
1737            <tag id="BC" />
1738            <tag id="V1" />
1739          </entry>
1740          <entry name="colorFilterArrangement" type="byte" enum="true">
1741            <enum>
1742              <value>RGGB</value>
1743              <value>GRBG</value>
1744              <value>GBRG</value>
1745              <value>BGGR</value>
1746              <value>RGB
1747              <notes>Sensor is not Bayer; output has 3 16-bit
1748              values for each pixel, instead of just 1 16-bit value
1749              per pixel.</notes></value>
1750            </enum>
1751            <description>Arrangement of color filters on sensor;
1752            represents the colors in the top-left 2x2 section of
1753            the sensor, in reading order</description>
1754            <tag id="DNG" />
1755          </entry>
1756          <entry name="exposureTimeRange" type="int64"
1757          type_notes="nanoseconds" container="array">
1758            <array>
1759              <size>2</size>
1760            </array>
1761            <description>Range of valid exposure
1762            times</description>
1763            <range>Min &lt;= 100e3 (100 us), Max &gt;= 30e9 (30
1764            sec)</range>
1765            <tag id="V1" />
1766          </entry>
1767          <entry name="maxFrameDuration" type="int64">
1768            <description>Maximum frame duration (minimum frame
1769            rate)</description>
1770            <units>nanoseconds</units>
1771            <range>&gt;= 30e9</range>
1772            <notes>Minimum duration is a function of resolution,
1773            processing settings. See
1774            android.scaler.info.availableMinFrameDurations</notes>
1775            <tag id="BC" />
1776            <tag id="V1" />
1777          </entry>
1778          <entry name="physicalSize" type="float"
1779          type_notes="width x height in millimeters"
1780          container="array">
1781            <array>
1782              <size>2</size>
1783            </array>
1784            <description>The physical dimensions of the full pixel
1785            array</description>
1786            <notes>Needed for FOV calculation for old API</notes>
1787            <tag id="V1" />
1788            <tag id="BC" />
1789          </entry>
1790          <entry name="pixelArraySize" type="int32"
1791          container="array">
1792            <array>
1793              <size>2</size>
1794            </array>
1795            <description>Dimensions of full pixel array, possibly
1796            including black calibration pixels</description>
1797            <notes>Maximum output resolution for raw format must
1798            match this in
1799            android.scaler.info.availableSizesPerFormat</notes>
1800            <tag id="DNG" />
1801            <tag id="BC" />
1802          </entry>
1803          <entry name="whiteLevel" type="int32">
1804            <description>Maximum raw value output by
1805            sensor</description>
1806            <range>&gt; 1024 (10-bit output)</range>
1807            <notes>Defines sensor bit depth (10-14 bits is
1808            expected)</notes>
1809            <tag id="DNG" />
1810          </entry>
1811        </namespace>
1812        <entry name="baseGainFactor" type="rational">
1813          <description>Gain factor from electrons to raw units when
1814          ISO=100</description>
1815          <tag id="V1" />
1816        </entry>
1817        <entry name="blackLevelPattern" type="int32"
1818        type_notes="2x2 raw count block" container="array">
1819          <array>
1820            <size>4</size>
1821          </array>
1822          <description>A fixed black level offset for each of the
1823          Bayer mosaic channels</description>
1824          <range>&gt;= 0 each</range>
1825          <notes>As per DNG BlackLevelRepeatDim / BlackLevel
1826          tags</notes>
1827          <tag id="DNG" />
1828        </entry>
1829        <entry name="calibrationTransform1" type="rational"
1830        type_notes="3x3 matrix in row-major-order"
1831        container="array">
1832          <array>
1833            <size>9</size>
1834          </array>
1835          <description>Per-device calibration on top of color space
1836          transform 1</description>
1837          <tag id="DNG" />
1838        </entry>
1839        <entry name="calibrationTransform2" type="rational"
1840        type_notes="3x3 matrix in row-major-order"
1841        container="array">
1842          <array>
1843            <size>9</size>
1844          </array>
1845          <description>Per-device calibration on top of color space
1846          transform 2</description>
1847          <tag id="DNG" />
1848        </entry>
1849        <entry name="colorTransform1" type="rational"
1850        type_notes="3x3 matrix in row-major-order"
1851        container="array">
1852          <array>
1853            <size>9</size>
1854          </array>
1855          <description>Linear mapping from XYZ (D50) color space to
1856          reference linear sensor color, for first reference
1857          illuminant</description>
1858          <notes>Use as follows XYZ = inv(transform) * clip( (raw -
1859          black level(raw) ) / ( white level - max black level) ).
1860          At least in the simple case</notes>
1861          <tag id="DNG" />
1862        </entry>
1863        <entry name="colorTransform2" type="rational"
1864        type_notes="3x3 matrix in row-major-order"
1865        container="array">
1866          <array>
1867            <size>9</size>
1868          </array>
1869          <description>Linear mapping from XYZ (D50) color space to
1870          reference linear sensor color, for second reference
1871          illuminant</description>
1872          <tag id="DNG" />
1873        </entry>
1874        <entry name="forwardMatrix1" type="rational"
1875        type_notes="3x3 matrix in row-major-order"
1876        container="array">
1877          <array>
1878            <size>9</size>
1879          </array>
1880          <description>Used by DNG for better WB
1881          adaptation</description>
1882          <tag id="DNG" />
1883        </entry>
1884        <entry name="forwardMatrix2" type="rational"
1885        type_notes="3x3 matrix in row-major-order"
1886        container="array">
1887          <array>
1888            <size>9</size>
1889          </array>
1890          <description>Used by DNG for better WB
1891          adaptation</description>
1892          <tag id="DNG" />
1893        </entry>
1894        <entry name="maxAnalogSensitivity" type="int32">
1895          <description>Maximum sensitivity that is implemented
1896          purely through analog gain</description>
1897          <notes>For android.sensor.sensitivity values less than or
1898          equal to this, all applied gain must be analog. For
1899          values above this, it can be a mix of analog and
1900          digital</notes>
1901          <tag id="V1" />
1902        </entry>
1903        <entry name="noiseModelCoefficients" type="float"
1904        type_notes="float constants A, B for the noise variance model"
1905        container="array">
1906          <array>
1907            <size>2</size>
1908          </array>
1909          <description>Estimation of sensor noise
1910          characteristics</description>
1911          <units>var(raw pixel value) = electrons * (baseGainFactor
1912          * iso/100)^2 + A * (baseGainFactor * iso/100)^2 +
1913          B</units>
1914          <notes>A represents sensor read noise before analog
1915          amplification; B represents noise from A/D conversion and
1916          other circuits after amplification. Both noise sources
1917          are assumed to be gaussian, independent, and not to vary
1918          across the sensor</notes>
1919          <tag id="V1" />
1920        </entry>
1921        <entry name="orientation" type="int32">
1922          <description>Clockwise angle through which the output
1923          image needs to be rotated to be upright on the device
1924          screen in its native orientation. Also defines the
1925          direction of rolling shutter readout, which is from top
1926          to bottom in the sensor's coordinate system</description>
1927          <units>degrees clockwise rotation, only multiples of
1928          90</units>
1929          <range>0,90,180,270</range>
1930          <tag id="BC" />
1931        </entry>
1932        <entry name="referenceIlluminant1" type="byte" enum="true">
1933          <enum>
1934            <value id="1">DAYLIGHT</value>
1935            <value id="2">FLUORESCENT</value>
1936            <value id="3">TUNGSTEN
1937            <notes>Incandescent light</notes></value>
1938            <value id="4">FLASH</value>
1939            <value id="9">FINE_WEATHER</value>
1940            <value id="10">CLOUDY_WEATHER</value>
1941            <value id="11">SHADE</value>
1942            <value id="12">DAYLIGHT_FLUORESCENT
1943            <notes>D 5700 - 7100K</notes></value>
1944            <value id="13">DAY_WHITE_FLUORESCENT
1945            <notes>N 4600 - 5400K</notes></value>
1946            <value id="14">COOL_WHITE_FLUORESCENT
1947            <notes>W 3900 - 4500K</notes></value>
1948            <value id="15">WHITE_FLUORESCENT
1949            <notes>WW 3200 - 3700K</notes></value>
1950            <value id="17">STANDARD_A</value>
1951            <value id="18">STANDARD_B</value>
1952            <value id="19">STANDARD_C</value>
1953            <value id="20">D55</value>
1954            <value id="21">D65</value>
1955            <value id="22">D75</value>
1956            <value id="23">D50</value>
1957            <value id="24">ISO_STUDIO_TUNGSTEN</value>
1958          </enum>
1959          <description>Light source used to define transform
1960          1</description>
1961          <notes>[EXIF LightSource tag] Must all these be
1962          supported? Need CCT for each!</notes>
1963          <tag id="DNG" />
1964          <tag id="EXIF" />
1965        </entry>
1966        <entry name="referenceIlluminant2" type="byte">
1967          <description>Light source used to define transform
1968          2</description>
1969          <units>Same as illuminant 1</units>
1970        </entry>
1971      </static>
1972      <dynamic>
1973        <clone entry="android.sensor.exposureTime" kind="controls">
1974        </clone>
1975        <clone entry="android.sensor.frameDuration"
1976        kind="controls"></clone>
1977        <clone entry="android.sensor.sensitivity" kind="controls">
1978        </clone>
1979        <entry name="timestamp" type="int64">
1980          <description>Time at start of exposure of first
1981          row</description>
1982          <units>nanoseconds</units>
1983          <range>&gt; 0</range>
1984          <notes>Monotonic, should be synced to other timestamps in
1985          system</notes>
1986          <tag id="BC" />
1987        </entry>
1988      </dynamic>
1989    </section>
1990    <section name="shading">
1991      <controls>
1992        <entry name="mode" type="byte" enum="true">
1993          <enum>
1994            <value>OFF
1995            <notes>No shading correction is applied</notes></value>
1996            <value>FAST
1997            <notes>Must not slow down frame rate relative to raw
1998            bayer output</notes></value>
1999            <value>HIGH_QUALITY
2000            <notes>Frame rate may be reduced by high
2001            quality</notes></value>
2002          </enum>
2003          <description>Quality of lens shading correction applied
2004          to the image data</description>
2005        </entry>
2006        <entry name="strength" type="byte">
2007          <description>Control the amount of shading correction
2008          applied to the images</description>
2009          <units>unitless: 1-10; 10 is full shading
2010          compensation</units>
2011          <tag id="ADV" />
2012        </entry>
2013      </controls>
2014      <dynamic>
2015        <clone entry="android.shading.mode" kind="controls">
2016        </clone>
2017      </dynamic>
2018    </section>
2019    <section name="statistics">
2020      <controls>
2021        <entry name="faceDetectMode" type="byte" enum="true">
2022          <enum>
2023            <value>OFF</value>
2024            <value>SIMPLE
2025            <notes>Optional Return rectangle and confidence
2026            only</notes></value>
2027            <value>FULL
2028            <notes>Optional Return all face
2029            metadata</notes></value>
2030          </enum>
2031          <description>State of the face detector
2032          unit</description>
2033          <range>
2034          android.statistics.availableFaceDetectModes</range>
2035          <tag id="BC" />
2036        </entry>
2037        <entry name="histogramMode" type="byte" enum="true">
2038          <enum>
2039            <value>OFF</value>
2040            <value>ON</value>
2041          </enum>
2042          <description>Operating mode for histogram
2043          generation</description>
2044          <tag id="V1" />
2045        </entry>
2046        <entry name="sharpnessMapMode" type="byte" enum="true">
2047          <enum>
2048            <value>OFF</value>
2049            <value>ON</value>
2050          </enum>
2051          <description>Operating mode for sharpness map
2052          generation</description>
2053          <tag id="V1" />
2054        </entry>
2055      </controls>
2056      <static>
2057        <namespace name="info">
2058          <entry name="availableFaceDetectModes" type="byte"
2059          type_notes="List of enums" container="array">
2060            <array>
2061              <size>n</size>
2062            </array>
2063            <description>Which face detection modes are available,
2064            if any</description>
2065            <range>OFF</range>
2066          </entry>
2067          <entry name="histogramBucketCount" type="int32">
2068            <description>Number of histogram buckets
2069            supported</description>
2070            <range>&gt;= 64</range>
2071          </entry>
2072          <entry name="maxFaceCount" type="int32">
2073            <description>If face detection is supported, how many
2074            faces can be detected at once</description>
2075            <range>&gt;= 4 if availableFaceDetectionModes lists
2076            modes besides OFF, otherwise 0</range>
2077          </entry>
2078          <entry name="maxHistogramCount" type="int32">
2079            <description>Maximum value possible for a histogram
2080            bucket</description>
2081          </entry>
2082          <entry name="maxSharpnessMapValue" type="int32">
2083            <description>Maximum value possible for a sharpness map
2084            region.</description>
2085          </entry>
2086          <entry name="sharpnessMapSize" type="int32"
2087          type_notes="width x height" container="array">
2088            <array>
2089              <size>2</size>
2090            </array>
2091            <description>Dimensions of the sharpness
2092            map</description>
2093            <range>Must be at least 32 x 32</range>
2094          </entry>
2095        </namespace>
2096      </static>
2097      <dynamic>
2098        <clone entry="android.statistics.faceDetectMode"
2099        kind="controls"></clone>
2100        <entry name="faceIds" type="int32" container="array">
2101          <array>
2102            <size>n</size>
2103          </array>
2104          <description>List of unique IDs for detected
2105          faces</description>
2106          <notes>Only available if faceDetectMode == FULL</notes>
2107          <tag id="BC" />
2108        </entry>
2109        <entry name="faceLandmarks" type="int32"
2110        type_notes="(leftEyeX, leftEyeY, rightEyeX, rightEyeY, mouthX, mouthY)"
2111        container="array">
2112          <array>
2113            <size>n</size>
2114            <size>6</size>
2115          </array>
2116          <description>List of landmarks for detected
2117          faces</description>
2118          <notes>Only available if faceDetectMode == FULL</notes>
2119          <tag id="BC" />
2120        </entry>
2121        <entry name="faceRectangles" type="int32"
2122        type_notes="(xmin, ymin, xmax, ymax). (0,0) is top-left of active pixel area"
2123        container="array">
2124          <array>
2125            <size>n</size>
2126            <size>4</size>
2127          </array>
2128          <description>List of the bounding rectangles for detected
2129          faces</description>
2130          <notes>Only available if faceDetectMode != OFF</notes>
2131          <tag id="BC" />
2132        </entry>
2133        <entry name="faceScores" type="byte" container="array">
2134          <array>
2135            <size>n</size>
2136          </array>
2137          <description>List of the face confidence scores for
2138          detected faces</description>
2139          <range>0-100</range>
2140          <notes>Only available if faceDetectMode != OFF</notes>
2141          <tag id="BC" />
2142        </entry>
2143        <entry name="histogram" type="int32"
2144        type_notes="count of pixels for each color channel that fall into each histogram bucket, scaled to be between 0 and maxHistogramCount"
2145        container="array">
2146          <array>
2147            <size>n</size>
2148            <size>3</size>
2149          </array>
2150          <description>A 3-channel histogram based on the raw
2151          sensor data</description>
2152          <notes>The k'th bucket (0-based) covers the input range
2153          (with w = android.sensor.info.whiteLevel) of [ k * w/N,
2154          (k + 1) * w / N ). If only a monochrome sharpness map is
2155          supported, all channels should have the same data</notes>
2156          <tag id="V1" />
2157        </entry>
2158        <clone entry="android.statistics.histogramMode"
2159        kind="controls"></clone>
2160        <entry name="sharpnessMap" type="int32"
2161        type_notes="estimated sharpness for each region of the input image. Normalized to be between 0 and maxSharpnessMapValue. Higher values mean sharper (better focused)"
2162        container="array">
2163          <array>
2164            <size>n</size>
2165            <size>m</size>
2166            <size>3</size>
2167          </array>
2168          <description>A 3-channel sharpness map, based on the raw
2169          sensor data</description>
2170          <notes>If only a monochrome sharpness map is supported,
2171          all channels should have the same data</notes>
2172          <tag id="V1" />
2173        </entry>
2174        <clone entry="android.statistics.sharpnessMapMode"
2175        kind="controls"></clone>
2176      </dynamic>
2177    </section>
2178    <section name="tonemap">
2179      <controls>
2180        <entry name="curveBlue" type="float">
2181          <description>Table mapping blue input values to output
2182          values</description>
2183          <units>same as android.tonemap.curveRed</units>
2184          <range>same as android.tonemap.curveRed</range>
2185        </entry>
2186        <entry name="curveGreen" type="float">
2187          <description>Table mapping green input values to output
2188          values</description>
2189          <units>same as android.tonemap.curveRed</units>
2190          <range>same as android.tonemap.curveRed</range>
2191        </entry>
2192        <entry name="curveRed" type="float"
2193        type_notes="A 1D array of pairs of floats. mapping a 0-1 input range to a 0-1 output range."
2194        container="array">
2195          <array>
2196            <size>n</size>
2197            <size>2</size>
2198          </array>
2199          <description>Table mapping red input values to output
2200          values</description>
2201          <range>0-1 on input and output coordinates. Max entry
2202          count speciied by android.tonemap.maxCurvePoints</range>
2203          <notes>.The input range must be monotonically increasing
2204          with N, and values between entries should be linearly
2205          interpolated. For example, if the array is: [0.0, 0.0,
2206          0.3, 0.5, 1.0, 1.0], then the input-&gt;output mapping
2207          for a few sample points would be: 0 -&gt; 0, 0.15 -&gt;
2208          0.25, 0.3 -&gt; 0.5, 0.5 -&gt; 0.64</notes>
2209          <tag id="DNG" />
2210        </entry>
2211        <entry name="mode" type="byte" enum="true">
2212          <enum>
2213            <value>CONTRAST_CURVE
2214            <notes>Use the tone mapping curve specified in
2215            android.tonemap.curve</notes></value>
2216            <value>FAST
2217            <notes>Must not slow down frame rate relative to raw
2218            bayer output</notes></value>
2219            <value>HIGH_QUALITY
2220            <notes>Frame rate may be reduced by high
2221            quality</notes></value>
2222          </enum>
2223        </entry>
2224      </controls>
2225      <static>
2226        <entry name="maxCurvePoints" type="int32">
2227          <description>Maximum number of supported points in the
2228          tonemap curve</description>
2229          <range>&gt;= 128</range>
2230        </entry>
2231      </static>
2232      <dynamic>
2233        <clone entry="android.tonemap.curveBlue" kind="controls">
2234        </clone>
2235        <clone entry="android.tonemap.curveGreen" kind="controls">
2236        </clone>
2237        <clone entry="android.tonemap.curveRed" kind="controls">
2238        </clone>
2239        <clone entry="android.tonemap.mode" kind="controls">
2240        </clone>
2241      </dynamic>
2242    </section>
2243    <section name="led">
2244      <controls>
2245        <entry name="transmit" type="byte" enum="true">
2246          <enum>
2247            <value>OFF</value>
2248            <value>ON</value>
2249          </enum>
2250          <description>This LED is nominally used to indicate to the user
2251          that the camera is powered on and may be streaming images back to the
2252          Application Processor. In certain rare circumstances, the OS may
2253          disable this when video is processed locally and not transmitted to
2254          any untrusted applications.
2255
2256          In particular, the LED *must* always be on when the data could be
2257          transmitted off the device. The LED *should* always be on whenever
2258          data is stored locally on the device.
2259
2260          The LED *may* be off if a trusted application is using the data that
2261          doesn't violate the above rules.
2262          </description>
2263        </entry>
2264      </controls>
2265      <dynamic>
2266        <clone entry="android.led.transmit" kind="controls"></clone>
2267      </dynamic>
2268      <static>
2269        <entry name="availableLeds" type="byte" enum="true" container="array">
2270          <array>
2271            <size>n</size>
2272          </array>
2273          <enum>
2274            <value>TRANSMIT
2275              <notes>android.led.transmit control is used</notes>
2276            </value>
2277          </enum>
2278          <description>A list of camera LEDs that are available on this system.
2279          </description>
2280        </entry>
2281      </static>
2282    </section>
2283    <section name="info">
2284      <static>
2285        <entry name="supportedHardwareLevel" type="byte" enum="true">
2286          <enum>
2287            <value>LIMITED</value>
2288            <value>FULL</value>
2289          </enum>
2290          <description>
2291          The camera 3 HAL device can implement one of two possible operational modes;
2292          limited and full. Full support is expected from new higher-end
2293          devices. Limited mode has hardware requirements roughly in line with those
2294          for a camera HAL device v1 implementation, and is expected from older or
2295          inexpensive devices. Full is a strict superset of limited, and they share the
2296          same essential operational flow.
2297
2298          For full details refer to "S3. Operational Modes" in camera3.h
2299          </description>
2300          <range>Optional. Default value is LIMITED.</range>
2301        </entry>
2302      </static>
2303    </section>
2304  </namespace>
2305</metadata>
2306