Avichal Rakesh | 6e57a2b | 2023-05-01 17:53:37 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2023 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 | |
| 17 | package android.hardware; |
| 18 | |
| 19 | /** |
| 20 | * Metrics specific to Extension Sessions (see CameraExtensionSession) for logging. |
| 21 | * |
| 22 | * Each Extension Session is mapped to one camera session internally, and will be sent to |
| 23 | * CameraServiceProxy with IDLE/CLOSE calls. |
| 24 | * @hide |
| 25 | */ |
| 26 | parcelable CameraExtensionSessionStats { |
| 27 | /** |
| 28 | * Value should match {@code CameraExtensionCharacteristics#EXTENSION_*} |
| 29 | */ |
| 30 | @Backing(type="int") |
| 31 | enum Type { |
| 32 | EXTENSION_NONE = -1, |
| 33 | EXTENSION_AUTOMATIC = 0, |
| 34 | EXTENSION_FACE_RETOUCH = 1, |
| 35 | EXTENSION_BOKEH = 2, |
| 36 | EXTENSION_HDR = 3, |
| 37 | EXTENSION_NIGHT = 4 |
| 38 | } |
| 39 | |
| 40 | /** |
| 41 | * Key to uniquely identify the session this stat is associated with. The first call to |
| 42 | * 'ICameraService.reportExtensionSessionStats' should set this to an empty string. |
| 43 | * 'ICameraService.reportExtensionSessionStats' will return the key which should be used with |
| 44 | * the next calls. |
| 45 | */ |
| 46 | String key; |
| 47 | |
| 48 | /** |
| 49 | * Camera ID for which the stats is being reported. |
| 50 | */ |
| 51 | String cameraId; |
| 52 | |
| 53 | /** |
| 54 | * Package name of the client using the camera |
| 55 | */ |
| 56 | String clientName; |
| 57 | |
| 58 | |
| 59 | /** |
| 60 | * Type of extension session requested by the app. Note that EXTENSION_AUTOMATIC is reported |
| 61 | * as such. |
| 62 | */ |
| 63 | Type type = Type.EXTENSION_NONE; |
| 64 | |
| 65 | /** |
| 66 | * true if advanced extensions are being used, false otherwise |
| 67 | */ |
| 68 | boolean isAdvanced = false; |
Ravneet Dhanjal | 2ed4f4c | 2024-05-07 23:17:13 +0000 | [diff] [blame] | 69 | |
| 70 | /** |
| 71 | * Format of image capture request |
| 72 | */ |
| 73 | int captureFormat; |
Avichal Rakesh | 6e57a2b | 2023-05-01 17:53:37 -0700 | [diff] [blame] | 74 | } |