CameraMetadata.ScalerRotateAndCropAuto Field

Definition

Caution

This constant will be removed in the future version. Use Android.Hardware.Camera2.ScalerRotateAndCropType enum directly instead of this field.

The camera API automatically selects the best concrete value for rotate-and-crop based on the application's support for resizability and the current multi-window mode.

[Android.Runtime.Register("SCALER_ROTATE_AND_CROP_AUTO", ApiSince=31)]
[System.Obsolete("This constant will be removed in the future version. Use Android.Hardware.Camera2.ScalerRotateAndCropType enum directly instead of this field.", true)]
public const Android.Hardware.Camera2.ScalerRotateAndCropType ScalerRotateAndCropAuto = 4;
[<Android.Runtime.Register("SCALER_ROTATE_AND_CROP_AUTO", ApiSince=31)>]
[<System.Obsolete("This constant will be removed in the future version. Use Android.Hardware.Camera2.ScalerRotateAndCropType enum directly instead of this field.", true)>]
val mutable ScalerRotateAndCropAuto : Android.Hardware.Camera2.ScalerRotateAndCropType

Field Value

Value = 4
Attributes

Remarks

The camera API automatically selects the best concrete value for rotate-and-crop based on the application's support for resizability and the current multi-window mode.

If the application does not support resizing but the display mode for its main Activity is not in a typical orientation, the camera API will set ROTATE_AND_CROP_90 or some other supported rotation value, depending on device configuration, to ensure preview and captured images are correctly shown to the user. Otherwise, ROTATE_AND_CROP_NONE will be selected.

When a value other than NONE is selected, several metadata fields will also be parsed differently to ensure that coordinates are correctly handled for features like drawing face detection boxes or passing in tap-to-focus coordinates. The camera API will convert positions in the active array coordinate system to/from the cropped-and-rotated coordinate system to make the operation transparent for applications.

No coordinate mapping will be done when the application selects a non-AUTO mode.

Java documentation for android.hardware.camera2.CameraMetadata.SCALER_ROTATE_AND_CROP_AUTO.

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