Camera: Add autoframing API

The new API can be used to keep objects in the frame's fov.
Auto-generated file from changes in metadata_definitions.xml

Bug: 234004829
Test: Successful build
Change-Id: I68b1c38a67427aba3fa0ef9f21fb526199953682
This commit is contained in:
Bharatt Kukreja 2022-09-15 20:24:36 +00:00
parent a476540571
commit cbbc870ba8
8 changed files with 258 additions and 0 deletions

View file

@ -94,6 +94,9 @@ enum CameraMetadataTag {
ANDROID_CONTROL_AVAILABLE_HIGH_SPEED_VIDEO_CONFIGURATIONS_MAXIMUM_RESOLUTION = 65584,
ANDROID_CONTROL_SETTINGS_OVERRIDE = 65588,
ANDROID_CONTROL_AVAILABLE_SETTINGS_OVERRIDES = 65589,
ANDROID_CONTROL_AUTOFRAMING = 65590,
ANDROID_CONTROL_AUTOFRAMING_AVAILABLE = 65591,
ANDROID_CONTROL_AUTOFRAMING_STATE = 65592,
ANDROID_DEMOSAIC_MODE = 131072,
ANDROID_EDGE_MODE = 196608,
ANDROID_EDGE_STRENGTH = 196609,

View file

@ -0,0 +1,44 @@
/*
* Copyright (C) 2022 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*//*
* Autogenerated from camera metadata definitions in
* /system/media/camera/docs/metadata_definitions.xml
* *** DO NOT EDIT BY HAND ***
*/
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a snapshot of an AIDL file. Do not edit it manually. There are
// two cases:
// 1). this is a frozen version file - do not edit this in any case.
// 2). this is a 'current' file. If you make a backwards compatible change to
// the interface (from the latest frozen version), the build system will
// prompt you to update this file with `m <name>-update-api`.
//
// You must not make a backward incompatible change to any AIDL file built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.hardware.camera.metadata;
@Backing(type="int") @VintfStability
enum ControlAutoframing {
ANDROID_CONTROL_AUTOFRAMING_OFF = 0,
ANDROID_CONTROL_AUTOFRAMING_ON = 1,
ANDROID_CONTROL_AUTOFRAMING_AUTO = 2,
}

View file

@ -0,0 +1,43 @@
/*
* Copyright (C) 2022 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*//*
* Autogenerated from camera metadata definitions in
* /system/media/camera/docs/metadata_definitions.xml
* *** DO NOT EDIT BY HAND ***
*/
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a snapshot of an AIDL file. Do not edit it manually. There are
// two cases:
// 1). this is a frozen version file - do not edit this in any case.
// 2). this is a 'current' file. If you make a backwards compatible change to
// the interface (from the latest frozen version), the build system will
// prompt you to update this file with `m <name>-update-api`.
//
// You must not make a backward incompatible change to any AIDL file built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.hardware.camera.metadata;
@Backing(type="int") @VintfStability
enum ControlAutoframingAvailable {
ANDROID_CONTROL_AUTOFRAMING_AVAILABLE_FALSE = 0,
ANDROID_CONTROL_AUTOFRAMING_AVAILABLE_TRUE = 1,
}

View file

@ -0,0 +1,44 @@
/*
* Copyright (C) 2022 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*//*
* Autogenerated from camera metadata definitions in
* /system/media/camera/docs/metadata_definitions.xml
* *** DO NOT EDIT BY HAND ***
*/
///////////////////////////////////////////////////////////////////////////////
// THIS FILE IS IMMUTABLE. DO NOT EDIT IN ANY CASE. //
///////////////////////////////////////////////////////////////////////////////
// This file is a snapshot of an AIDL file. Do not edit it manually. There are
// two cases:
// 1). this is a frozen version file - do not edit this in any case.
// 2). this is a 'current' file. If you make a backwards compatible change to
// the interface (from the latest frozen version), the build system will
// prompt you to update this file with `m <name>-update-api`.
//
// You must not make a backward incompatible change to any AIDL file built
// with the aidl_interface module type with versions property set. The module
// type is used to build AIDL files in a way that they can be used across
// independently updatable components of the system. If a device is shipped
// with such a backward incompatible change, it has a high risk of breaking
// later when a module using the interface is updated, e.g., Mainline modules.
package android.hardware.camera.metadata;
@Backing(type="int") @VintfStability
enum ControlAutoframingState {
ANDROID_CONTROL_AUTOFRAMING_STATE_INACTIVE = 0,
ANDROID_CONTROL_AUTOFRAMING_STATE_FRAMING = 1,
ANDROID_CONTROL_AUTOFRAMING_STATE_CONVERGED = 2,
}

View file

@ -463,6 +463,26 @@ enum CameraMetadataTag {
* be used to speed up certain controls.</p>
*/
ANDROID_CONTROL_AVAILABLE_SETTINGS_OVERRIDES,
/**
* android.control.autoframing [dynamic, enum, public]
*
* <p>Automatic crop, pan and zoom to keep objects in the center of the frame.</p>
*/
ANDROID_CONTROL_AUTOFRAMING,
/**
* android.control.autoframingAvailable [static, enum, public]
*
* <p>Whether the camera device supports ANDROID_CONTROL_AUTOFRAMING.</p>
*
* @see ANDROID_CONTROL_AUTOFRAMING
*/
ANDROID_CONTROL_AUTOFRAMING_AVAILABLE,
/**
* android.control.autoframingState [dynamic, enum, public]
*
* <p>Current state of auto-framing.</p>
*/
ANDROID_CONTROL_AUTOFRAMING_STATE,
/**
* android.demosaic.mode [controls, enum, system]
*

View file

@ -0,0 +1,35 @@
/*
* Copyright (C) 2022 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
* Autogenerated from camera metadata definitions in
* /system/media/camera/docs/metadata_definitions.xml
* *** DO NOT EDIT BY HAND ***
*/
package android.hardware.camera.metadata;
/**
* android.control.autoframing enumeration values
* @see ANDROID_CONTROL_AUTOFRAMING
*/
@VintfStability
@Backing(type="int")
enum ControlAutoframing {
ANDROID_CONTROL_AUTOFRAMING_OFF,
ANDROID_CONTROL_AUTOFRAMING_ON,
ANDROID_CONTROL_AUTOFRAMING_AUTO,
}

View file

@ -0,0 +1,34 @@
/*
* Copyright (C) 2022 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
* Autogenerated from camera metadata definitions in
* /system/media/camera/docs/metadata_definitions.xml
* *** DO NOT EDIT BY HAND ***
*/
package android.hardware.camera.metadata;
/**
* android.control.autoframingAvailable enumeration values
* @see ANDROID_CONTROL_AUTOFRAMING_AVAILABLE
*/
@VintfStability
@Backing(type="int")
enum ControlAutoframingAvailable {
ANDROID_CONTROL_AUTOFRAMING_AVAILABLE_FALSE,
ANDROID_CONTROL_AUTOFRAMING_AVAILABLE_TRUE,
}

View file

@ -0,0 +1,35 @@
/*
* Copyright (C) 2022 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
* Autogenerated from camera metadata definitions in
* /system/media/camera/docs/metadata_definitions.xml
* *** DO NOT EDIT BY HAND ***
*/
package android.hardware.camera.metadata;
/**
* android.control.autoframingState enumeration values
* @see ANDROID_CONTROL_AUTOFRAMING_STATE
*/
@VintfStability
@Backing(type="int")
enum ControlAutoframingState {
ANDROID_CONTROL_AUTOFRAMING_STATE_INACTIVE,
ANDROID_CONTROL_AUTOFRAMING_STATE_FRAMING,
ANDROID_CONTROL_AUTOFRAMING_STATE_CONVERGED,
}