Language

CaptureRequest.ControlSettingsOverride Property

Definition

The desired CaptureRequest settings override with which certain keys are applied earlier so that they can take effect sooner.

[Android.Runtime.Register("CONTROL_SETTINGS_OVERRIDE", ApiSince=34)]
public static Android.Hardware.Camera2.CaptureRequest.Key ControlSettingsOverride { get; }
[<Android.Runtime.Register("CONTROL_SETTINGS_OVERRIDE", ApiSince=34)>]
static member ControlSettingsOverride : Android.Hardware.Camera2.CaptureRequest.Key

Property Value

The desired CaptureRequest settings override with which certain keys are applied earlier so that they can take effect sooner.

Attributes

Remarks

The desired CaptureRequest settings override with which certain keys are applied earlier so that they can take effect sooner.

There are some CaptureRequest keys which can be applied earlier than others when controls within a CaptureRequest aren't required to take effect at the same time. One such example is zoom. Zoom can be applied at a later stage of the camera pipeline. As soon as the camera device receives the CaptureRequest, it can apply the requested zoom value onto an earlier request that's already in the pipeline, thus improves zoom latency.

This key's value in the capture result reflects whether the controls for this capture are overridden "by" a newer request. This means that if a capture request turns on settings override, the capture result of an earlier request will contain the key value of ZOOM. On the other hand, if a capture request has settings override turned on, but all newer requests have it turned off, the key's value in the capture result will be OFF because this capture isn't overridden by a newer capture. In the two examples below, the capture results columns illustrate the settingsOverride values in different scenarios.

Camera session created
Request 1 (zoom=1.0x, override=ZOOM) ->
Request 2 (zoom=1.2x, override=ZOOM) ->
Request 3 (zoom=1.4x, override=ZOOM) ->  Result 1 (zoom=1.2x, override=ZOOM)
Request 4 (zoom=1.6x, override=ZOOM) ->  Result 2 (zoom=1.4x, override=ZOOM)
Request 5 (zoom=1.8x, override=ZOOM) ->  Result 3 (zoom=1.6x, override=ZOOM)
                                     ->  Result 4 (zoom=1.8x, override=ZOOM)
                                     ->  Result 5 (zoom=1.8x, override=OFF)

The application can turn on settings override and use zoom as normal. The example shows that the later zoom values (1.2x, 1.4x, 1.6x, and 1.8x) overwrite the zoom values (1.0x, 1.2x, 1.4x, and 1.8x) of earlier requests (#1, #2, #3, and #4).

The application must make sure the settings override doesn't interfere with user journeys requiring simultaneous application of all controls in CaptureRequest on the requested output targets. For example, if the application takes a still capture using CameraCaptureSession#capture, and the repeating request immediately sets a different zoom value using override, the inflight still capture could have its zoom value overwritten unexpectedly.

So the application is strongly recommended to turn off settingsOverride when taking still/burst captures, and turn it back on when there is only repeating viewfinder request and no inflight still/burst captures.

Request 1 (zoom=1.0x, override=OFF)
Request 2 (zoom=1.2x, override=OFF)
Request 3 (zoom=1.4x, override=ZOOM)  -> Result 1 (zoom=1.0x, override=OFF)
Request 4 (zoom=1.6x, override=ZOOM)  -> Result 2 (zoom=1.4x, override=ZOOM)
Request 5 (zoom=1.8x, override=OFF)   -> Result 3 (zoom=1.6x, override=ZOOM)
                                      -> Result 4 (zoom=1.6x, override=OFF)
                                      -> Result 5 (zoom=1.8x, override=OFF)

This example shows that: The application "ramps in" settings override by setting the control to ZOOM. In the example, request #3 enables zoom settings override. Because the camera device can speed up applying zoom by 1 frame, the outputs of request #2 has 1.4x zoom, the value specified in request #3; The application "ramps out" of settings override by setting the control to OFF. In the example, request #5 changes the override to OFF. Because request #4's zoom takes effect in result #3, result #4's zoom remains the same until new value takes effect in result #5

Possible values: OFF; ZOOM

Available values for this device: android.control.availableSettingsOverrides

Optional - The value for this key may be null on some devices.

Android reference for android.hardware.camera2.CaptureRequest.CONTROL_SETTINGS_OVERRIDE.

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to