Chia-I Wu | aab99f5 | 2016-10-05 12:59:58 +0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright 2016 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 | |
Ady Abraham | 9fc2805 | 2021-10-14 17:21:38 -0700 | [diff] [blame] | 17 | #pragma once |
Chia-I Wu | aab99f5 | 2016-10-05 12:59:58 +0800 | [diff] [blame] | 18 | |
Chia-I Wu | cd8d7f0 | 2016-11-16 11:02:31 +0800 | [diff] [blame] | 19 | #include <memory> |
Chia-I Wu | aab99f5 | 2016-10-05 12:59:58 +0800 | [diff] [blame] | 20 | |
Ady Abraham | 8a82ba6 | 2020-01-17 12:43:17 -0800 | [diff] [blame] | 21 | // TODO(b/129481165): remove the #pragma below and fix conversion issues |
| 22 | #pragma clang diagnostic push |
| 23 | #pragma clang diagnostic ignored "-Wconversion" |
Marin Shalamanov | bed7fd3 | 2020-12-21 20:02:20 +0100 | [diff] [blame] | 24 | #pragma clang diagnostic ignored "-Wextra" |
Ady Abraham | 8a82ba6 | 2020-01-17 12:43:17 -0800 | [diff] [blame] | 25 | |
Peiyong Lin | afa0f57 | 2020-01-13 16:35:02 -0800 | [diff] [blame] | 26 | #include <composer-command-buffer/2.4/ComposerCommandBuffer.h> |
Alec Mouri | e7cc1c2 | 2021-04-27 15:23:26 -0700 | [diff] [blame] | 27 | #include <gui/BufferQueue.h> |
Courtney Goeltzenleuchter | f9c98e5 | 2018-02-12 07:23:17 -0700 | [diff] [blame] | 28 | #include <gui/HdrMetadata.h> |
Peiyong Lin | 0e7a791 | 2018-04-05 14:36:36 -0700 | [diff] [blame] | 29 | #include <math/mat4.h> |
Kevin DuBois | 1d4249a | 2018-08-29 10:45:14 -0700 | [diff] [blame] | 30 | #include <ui/DisplayedFrameStats.h> |
Lloyd Pique | d0094aa | 2017-12-20 16:43:28 -0800 | [diff] [blame] | 31 | #include <ui/GraphicBuffer.h> |
Chia-I Wu | aab99f5 | 2016-10-05 12:59:58 +0800 | [diff] [blame] | 32 | #include <utils/StrongPointer.h> |
| 33 | |
Ady Abraham | 6e60b14 | 2022-01-06 18:10:35 -0800 | [diff] [blame] | 34 | #include <aidl/android/hardware/graphics/composer3/Color.h> |
Leon Scroggins III | 2e1aa18 | 2021-12-01 17:33:12 -0500 | [diff] [blame] | 35 | #include <aidl/android/hardware/graphics/composer3/Composition.h> |
Leon Scroggins III | 5967aec | 2021-12-29 11:14:22 -0500 | [diff] [blame] | 36 | #include <aidl/android/hardware/graphics/composer3/DisplayCapability.h> |
Leon Scroggins III | 2e1aa18 | 2021-12-01 17:33:12 -0500 | [diff] [blame] | 37 | |
Ady Abraham | 8a82ba6 | 2020-01-17 12:43:17 -0800 | [diff] [blame] | 38 | // TODO(b/129481165): remove the #pragma below and fix conversion issues |
Marin Shalamanov | bed7fd3 | 2020-12-21 20:02:20 +0100 | [diff] [blame] | 39 | #pragma clang diagnostic pop // ignored "-Wconversion -Wextra" |
Ady Abraham | 8a82ba6 | 2020-01-17 12:43:17 -0800 | [diff] [blame] | 40 | |
Ady Abraham | 9fc2805 | 2021-10-14 17:21:38 -0700 | [diff] [blame] | 41 | namespace android::Hwc2 { |
Chia-I Wu | aab99f5 | 2016-10-05 12:59:58 +0800 | [diff] [blame] | 42 | |
Dominik Laskowski | 6231aaf | 2018-04-02 17:10:23 -0700 | [diff] [blame] | 43 | namespace types = hardware::graphics::common; |
Chia-I Wu | aab99f5 | 2016-10-05 12:59:58 +0800 | [diff] [blame] | 44 | |
Dominik Laskowski | 6231aaf | 2018-04-02 17:10:23 -0700 | [diff] [blame] | 45 | namespace V2_1 = hardware::graphics::composer::V2_1; |
| 46 | namespace V2_2 = hardware::graphics::composer::V2_2; |
Dominik Laskowski | e9ef7c4 | 2018-03-12 19:34:30 -0700 | [diff] [blame] | 47 | namespace V2_3 = hardware::graphics::composer::V2_3; |
Dominik Laskowski | 25a4e7d | 2019-09-20 14:50:10 -0700 | [diff] [blame] | 48 | namespace V2_4 = hardware::graphics::composer::V2_4; |
Chia-I Wu | aab99f5 | 2016-10-05 12:59:58 +0800 | [diff] [blame] | 49 | |
Dominik Laskowski | 6231aaf | 2018-04-02 17:10:23 -0700 | [diff] [blame] | 50 | using types::V1_0::ColorTransform; |
Dominik Laskowski | 6231aaf | 2018-04-02 17:10:23 -0700 | [diff] [blame] | 51 | using types::V1_0::Transform; |
Dominik Laskowski | 6231aaf | 2018-04-02 17:10:23 -0700 | [diff] [blame] | 52 | using types::V1_1::RenderIntent; |
Valerie Hau | 9758ae0 | 2018-10-09 16:05:09 -0700 | [diff] [blame] | 53 | using types::V1_2::ColorMode; |
| 54 | using types::V1_2::Dataspace; |
Valerie Hau | e9e843a | 2018-12-18 13:39:23 -0800 | [diff] [blame] | 55 | using types::V1_2::Hdr; |
Kevin DuBois | 73d0f48 | 2019-01-25 11:18:03 -0800 | [diff] [blame] | 56 | using types::V1_2::PixelFormat; |
Valerie Hau | e9e843a | 2018-12-18 13:39:23 -0800 | [diff] [blame] | 57 | |
Dominik Laskowski | 6231aaf | 2018-04-02 17:10:23 -0700 | [diff] [blame] | 58 | using V2_1::Config; |
| 59 | using V2_1::Display; |
| 60 | using V2_1::Error; |
Dominik Laskowski | 6231aaf | 2018-04-02 17:10:23 -0700 | [diff] [blame] | 61 | using V2_1::Layer; |
Peiyong Lin | afa0f57 | 2020-01-13 16:35:02 -0800 | [diff] [blame] | 62 | using V2_4::CommandReaderBase; |
| 63 | using V2_4::CommandWriterBase; |
Dominik Laskowski | 25a4e7d | 2019-09-20 14:50:10 -0700 | [diff] [blame] | 64 | using V2_4::IComposer; |
Ady Abraham | 7159f57 | 2019-10-11 11:10:18 -0700 | [diff] [blame] | 65 | using V2_4::IComposerCallback; |
Dominik Laskowski | 25a4e7d | 2019-09-20 14:50:10 -0700 | [diff] [blame] | 66 | using V2_4::IComposerClient; |
Ady Abraham | 7159f57 | 2019-10-11 11:10:18 -0700 | [diff] [blame] | 67 | using V2_4::VsyncPeriodChangeTimeline; |
| 68 | using V2_4::VsyncPeriodNanos; |
Peiyong Lin | 0ac5f4e | 2018-04-19 22:06:34 -0700 | [diff] [blame] | 69 | using PerFrameMetadata = IComposerClient::PerFrameMetadata; |
| 70 | using PerFrameMetadataKey = IComposerClient::PerFrameMetadataKey; |
Valerie Hau | e9e843a | 2018-12-18 13:39:23 -0800 | [diff] [blame] | 71 | using PerFrameMetadataBlob = IComposerClient::PerFrameMetadataBlob; |
Peiyong Lin | 0ac5f4e | 2018-04-19 22:06:34 -0700 | [diff] [blame] | 72 | |
Lloyd Pique | a822d52 | 2017-12-20 16:42:57 -0800 | [diff] [blame] | 73 | class Composer { |
| 74 | public: |
Ady Abraham | 9fc2805 | 2021-10-14 17:21:38 -0700 | [diff] [blame] | 75 | static std::unique_ptr<Composer> create(const std::string& serviceName); |
| 76 | |
Lloyd Pique | a822d52 | 2017-12-20 16:42:57 -0800 | [diff] [blame] | 77 | virtual ~Composer() = 0; |
| 78 | |
Ady Abraham | 4d211cf | 2021-12-14 16:19:03 -0800 | [diff] [blame] | 79 | enum class OptionalFeature { |
| 80 | RefreshRateSwitching, |
Ady Abraham | 43065bd | 2021-12-10 17:22:15 -0800 | [diff] [blame] | 81 | ExpectedPresentTime, |
Alec Mouri | cdf1679 | 2021-12-10 13:16:06 -0800 | [diff] [blame] | 82 | // Whether setDisplayBrightness is able to be applied as part of a display command. |
| 83 | DisplayBrightnessCommand, |
Kriti Dang | 7defaf3 | 2021-11-15 11:55:43 +0100 | [diff] [blame^] | 84 | BootDisplayConfig, |
Ady Abraham | 4d211cf | 2021-12-14 16:19:03 -0800 | [diff] [blame] | 85 | }; |
| 86 | |
| 87 | virtual bool isSupported(OptionalFeature) const = 0; |
| 88 | |
Lloyd Pique | a822d52 | 2017-12-20 16:42:57 -0800 | [diff] [blame] | 89 | virtual std::vector<IComposer::Capability> getCapabilities() = 0; |
| 90 | virtual std::string dumpDebugInfo() = 0; |
| 91 | |
| 92 | virtual void registerCallback(const sp<IComposerCallback>& callback) = 0; |
| 93 | |
Lloyd Pique | a822d52 | 2017-12-20 16:42:57 -0800 | [diff] [blame] | 94 | // Reset all pending commands in the command buffer. Useful if you want to |
| 95 | // skip a frame but have already queued some commands. |
| 96 | virtual void resetCommands() = 0; |
| 97 | |
| 98 | // Explicitly flush all pending commands in the command buffer. |
| 99 | virtual Error executeCommands() = 0; |
| 100 | |
| 101 | virtual uint32_t getMaxVirtualDisplayCount() = 0; |
Dominik Laskowski | 1394860 | 2021-03-08 20:48:28 -0800 | [diff] [blame] | 102 | virtual Error createVirtualDisplay(uint32_t width, uint32_t height, PixelFormat*, |
Dominik Laskowski | 263eec4 | 2021-07-21 23:13:24 -0700 | [diff] [blame] | 103 | Display* outDisplay) = 0; |
Lloyd Pique | a822d52 | 2017-12-20 16:42:57 -0800 | [diff] [blame] | 104 | virtual Error destroyVirtualDisplay(Display display) = 0; |
| 105 | |
| 106 | virtual Error acceptDisplayChanges(Display display) = 0; |
| 107 | |
| 108 | virtual Error createLayer(Display display, Layer* outLayer) = 0; |
| 109 | virtual Error destroyLayer(Display display, Layer layer) = 0; |
| 110 | |
| 111 | virtual Error getActiveConfig(Display display, Config* outConfig) = 0; |
| 112 | virtual Error getChangedCompositionTypes( |
| 113 | Display display, std::vector<Layer>* outLayers, |
Leon Scroggins III | 2e1aa18 | 2021-12-01 17:33:12 -0500 | [diff] [blame] | 114 | std::vector<aidl::android::hardware::graphics::composer3::Composition>* outTypes) = 0; |
Lloyd Pique | a822d52 | 2017-12-20 16:42:57 -0800 | [diff] [blame] | 115 | virtual Error getColorModes(Display display, std::vector<ColorMode>* outModes) = 0; |
| 116 | virtual Error getDisplayAttribute(Display display, Config config, |
| 117 | IComposerClient::Attribute attribute, int32_t* outValue) = 0; |
| 118 | virtual Error getDisplayConfigs(Display display, std::vector<Config>* outConfigs) = 0; |
| 119 | virtual Error getDisplayName(Display display, std::string* outName) = 0; |
| 120 | |
| 121 | virtual Error getDisplayRequests(Display display, uint32_t* outDisplayRequestMask, |
| 122 | std::vector<Layer>* outLayers, |
| 123 | std::vector<uint32_t>* outLayerRequestMasks) = 0; |
| 124 | |
Lloyd Pique | a822d52 | 2017-12-20 16:42:57 -0800 | [diff] [blame] | 125 | virtual Error getDozeSupport(Display display, bool* outSupport) = 0; |
| 126 | virtual Error getHdrCapabilities(Display display, std::vector<Hdr>* outTypes, |
| 127 | float* outMaxLuminance, float* outMaxAverageLuminance, |
| 128 | float* outMinLuminance) = 0; |
| 129 | |
| 130 | virtual Error getReleaseFences(Display display, std::vector<Layer>* outLayers, |
| 131 | std::vector<int>* outReleaseFences) = 0; |
| 132 | |
| 133 | virtual Error presentDisplay(Display display, int* outPresentFence) = 0; |
| 134 | |
| 135 | virtual Error setActiveConfig(Display display, Config config) = 0; |
| 136 | |
| 137 | /* |
| 138 | * The composer caches client targets internally. When target is nullptr, |
| 139 | * the composer uses slot to look up the client target from its cache. |
| 140 | * When target is not nullptr, the cache is updated with the new target. |
| 141 | */ |
| 142 | virtual Error setClientTarget(Display display, uint32_t slot, const sp<GraphicBuffer>& target, |
| 143 | int acquireFence, Dataspace dataspace, |
| 144 | const std::vector<IComposerClient::Rect>& damage) = 0; |
Peiyong Lin | 0e7a791 | 2018-04-05 14:36:36 -0700 | [diff] [blame] | 145 | virtual Error setColorMode(Display display, ColorMode mode, RenderIntent renderIntent) = 0; |
Ady Abraham | dc011a9 | 2021-12-21 14:06:44 -0800 | [diff] [blame] | 146 | virtual Error setColorTransform(Display display, const float* matrix) = 0; |
Lloyd Pique | a822d52 | 2017-12-20 16:42:57 -0800 | [diff] [blame] | 147 | virtual Error setOutputBuffer(Display display, const native_handle_t* buffer, |
| 148 | int releaseFence) = 0; |
| 149 | virtual Error setPowerMode(Display display, IComposerClient::PowerMode mode) = 0; |
| 150 | virtual Error setVsyncEnabled(Display display, IComposerClient::Vsync enabled) = 0; |
| 151 | |
| 152 | virtual Error setClientTargetSlotCount(Display display) = 0; |
| 153 | |
Ady Abraham | 43065bd | 2021-12-10 17:22:15 -0800 | [diff] [blame] | 154 | virtual Error validateDisplay(Display display, nsecs_t expectedPresentTime, |
| 155 | uint32_t* outNumTypes, uint32_t* outNumRequests) = 0; |
Lloyd Pique | a822d52 | 2017-12-20 16:42:57 -0800 | [diff] [blame] | 156 | |
Ady Abraham | 43065bd | 2021-12-10 17:22:15 -0800 | [diff] [blame] | 157 | virtual Error presentOrValidateDisplay(Display display, nsecs_t expectedPresentTime, |
| 158 | uint32_t* outNumTypes, uint32_t* outNumRequests, |
| 159 | int* outPresentFence, uint32_t* state) = 0; |
Lloyd Pique | a822d52 | 2017-12-20 16:42:57 -0800 | [diff] [blame] | 160 | |
| 161 | virtual Error setCursorPosition(Display display, Layer layer, int32_t x, int32_t y) = 0; |
| 162 | /* see setClientTarget for the purpose of slot */ |
| 163 | virtual Error setLayerBuffer(Display display, Layer layer, uint32_t slot, |
| 164 | const sp<GraphicBuffer>& buffer, int acquireFence) = 0; |
| 165 | virtual Error setLayerSurfaceDamage(Display display, Layer layer, |
| 166 | const std::vector<IComposerClient::Rect>& damage) = 0; |
| 167 | virtual Error setLayerBlendMode(Display display, Layer layer, |
| 168 | IComposerClient::BlendMode mode) = 0; |
Ady Abraham | 6e60b14 | 2022-01-06 18:10:35 -0800 | [diff] [blame] | 169 | virtual Error setLayerColor( |
| 170 | Display display, Layer layer, |
| 171 | const aidl::android::hardware::graphics::composer3::Color& color) = 0; |
Leon Scroggins III | 2e1aa18 | 2021-12-01 17:33:12 -0500 | [diff] [blame] | 172 | virtual Error setLayerCompositionType( |
| 173 | Display display, Layer layer, |
| 174 | aidl::android::hardware::graphics::composer3::Composition type) = 0; |
Lloyd Pique | a822d52 | 2017-12-20 16:42:57 -0800 | [diff] [blame] | 175 | virtual Error setLayerDataspace(Display display, Layer layer, Dataspace dataspace) = 0; |
| 176 | virtual Error setLayerDisplayFrame(Display display, Layer layer, |
| 177 | const IComposerClient::Rect& frame) = 0; |
| 178 | virtual Error setLayerPlaneAlpha(Display display, Layer layer, float alpha) = 0; |
| 179 | virtual Error setLayerSidebandStream(Display display, Layer layer, |
| 180 | const native_handle_t* stream) = 0; |
| 181 | virtual Error setLayerSourceCrop(Display display, Layer layer, |
| 182 | const IComposerClient::FRect& crop) = 0; |
| 183 | virtual Error setLayerTransform(Display display, Layer layer, Transform transform) = 0; |
| 184 | virtual Error setLayerVisibleRegion(Display display, Layer layer, |
| 185 | const std::vector<IComposerClient::Rect>& visible) = 0; |
| 186 | virtual Error setLayerZOrder(Display display, Layer layer, uint32_t z) = 0; |
Peiyong Lin | 0e7a791 | 2018-04-05 14:36:36 -0700 | [diff] [blame] | 187 | |
| 188 | // Composer HAL 2.2 |
Peiyong Lin | 0ac5f4e | 2018-04-19 22:06:34 -0700 | [diff] [blame] | 189 | virtual Error setLayerPerFrameMetadata( |
| 190 | Display display, Layer layer, |
| 191 | const std::vector<IComposerClient::PerFrameMetadata>& perFrameMetadatas) = 0; |
Chia-I Wu | d7e01d7 | 2018-06-21 13:39:09 +0800 | [diff] [blame] | 192 | virtual std::vector<IComposerClient::PerFrameMetadataKey> getPerFrameMetadataKeys( |
| 193 | Display display) = 0; |
Peiyong Lin | 0e7a791 | 2018-04-05 14:36:36 -0700 | [diff] [blame] | 194 | virtual Error getRenderIntents(Display display, ColorMode colorMode, |
| 195 | std::vector<RenderIntent>* outRenderIntents) = 0; |
| 196 | virtual Error getDataspaceSaturationMatrix(Dataspace dataspace, mat4* outMatrix) = 0; |
Dominik Laskowski | e9ef7c4 | 2018-03-12 19:34:30 -0700 | [diff] [blame] | 197 | |
| 198 | // Composer HAL 2.3 |
| 199 | virtual Error getDisplayIdentificationData(Display display, uint8_t* outPort, |
| 200 | std::vector<uint8_t>* outData) = 0; |
Peiyong Lin | 698147a | 2018-09-14 13:27:18 -0700 | [diff] [blame] | 201 | virtual Error setLayerColorTransform(Display display, Layer layer, |
| 202 | const float* matrix) = 0; |
Kevin DuBois | 9c0a176 | 2018-10-16 13:32:31 -0700 | [diff] [blame] | 203 | virtual Error getDisplayedContentSamplingAttributes(Display display, PixelFormat* outFormat, |
| 204 | Dataspace* outDataspace, |
| 205 | uint8_t* outComponentMask) = 0; |
Kevin DuBois | 74e5377 | 2018-11-19 10:52:38 -0800 | [diff] [blame] | 206 | virtual Error setDisplayContentSamplingEnabled(Display display, bool enabled, |
| 207 | uint8_t componentMask, uint64_t maxFrames) = 0; |
Kevin DuBois | 1d4249a | 2018-08-29 10:45:14 -0700 | [diff] [blame] | 208 | virtual Error getDisplayedContentSample(Display display, uint64_t maxFrames, uint64_t timestamp, |
| 209 | DisplayedFrameStats* outStats) = 0; |
Valerie Hau | e9e843a | 2018-12-18 13:39:23 -0800 | [diff] [blame] | 210 | virtual Error setLayerPerFrameMetadataBlobs( |
| 211 | Display display, Layer layer, const std::vector<PerFrameMetadataBlob>& metadata) = 0; |
Alec Mouri | cdf1679 | 2021-12-10 13:16:06 -0800 | [diff] [blame] | 212 | // Options for setting the display brightness |
| 213 | struct DisplayBrightnessOptions { |
| 214 | // If true, then immediately submits a brightness change request to composer. Otherwise, |
| 215 | // submission of the brightness change may be deferred until presenting the next frame. |
| 216 | // applyImmediately should only be false if OptionalFeature::DisplayBrightnessCommand is |
| 217 | // supported. |
| 218 | bool applyImmediately = true; |
Alec Mouri | cdf1679 | 2021-12-10 13:16:06 -0800 | [diff] [blame] | 219 | |
| 220 | bool operator==(const DisplayBrightnessOptions& other) const { |
Alec Mouri | 90a1927 | 2021-12-30 14:11:38 -0800 | [diff] [blame] | 221 | return applyImmediately == other.applyImmediately; |
Alec Mouri | cdf1679 | 2021-12-10 13:16:06 -0800 | [diff] [blame] | 222 | } |
| 223 | }; |
| 224 | virtual Error setDisplayBrightness(Display display, float brightness, |
| 225 | const DisplayBrightnessOptions& options) = 0; |
Dominik Laskowski | 25a4e7d | 2019-09-20 14:50:10 -0700 | [diff] [blame] | 226 | |
| 227 | // Composer HAL 2.4 |
Leon Scroggins III | 5967aec | 2021-12-29 11:14:22 -0500 | [diff] [blame] | 228 | virtual Error getDisplayCapabilities( |
| 229 | Display display, |
| 230 | std::vector<aidl::android::hardware::graphics::composer3::DisplayCapability>* |
| 231 | outCapabilities) = 0; |
Ady Abraham | 7159f57 | 2019-10-11 11:10:18 -0700 | [diff] [blame] | 232 | virtual V2_4::Error getDisplayConnectionType( |
| 233 | Display display, IComposerClient::DisplayConnectionType* outType) = 0; |
| 234 | virtual V2_4::Error getDisplayVsyncPeriod(Display display, |
| 235 | VsyncPeriodNanos* outVsyncPeriod) = 0; |
| 236 | virtual V2_4::Error setActiveConfigWithConstraints( |
| 237 | Display display, Config config, |
| 238 | const IComposerClient::VsyncPeriodChangeConstraints& vsyncPeriodChangeConstraints, |
| 239 | VsyncPeriodChangeTimeline* outTimeline) = 0; |
Galia Peycheva | 5492cb5 | 2019-10-30 14:13:16 +0100 | [diff] [blame] | 240 | |
| 241 | virtual V2_4::Error setAutoLowLatencyMode(Display displayId, bool on) = 0; |
| 242 | virtual V2_4::Error getSupportedContentTypes( |
| 243 | Display displayId, |
| 244 | std::vector<IComposerClient::ContentType>* outSupportedContentTypes) = 0; |
| 245 | virtual V2_4::Error setContentType(Display displayId, |
| 246 | IComposerClient::ContentType contentType) = 0; |
Dan Stoza | 18d48cb | 2019-10-21 15:39:24 -0700 | [diff] [blame] | 247 | virtual V2_4::Error setLayerGenericMetadata(Display display, Layer layer, |
| 248 | const std::string& key, bool mandatory, |
| 249 | const std::vector<uint8_t>& value) = 0; |
| 250 | virtual V2_4::Error getLayerGenericMetadataKeys( |
| 251 | std::vector<IComposerClient::LayerGenericMetadataKey>* outKeys) = 0; |
Kriti Dang | 7defaf3 | 2021-11-15 11:55:43 +0100 | [diff] [blame^] | 252 | |
Peiyong Lin | dfc3f7c | 2020-05-07 20:15:50 -0700 | [diff] [blame] | 253 | virtual Error getClientTargetProperty( |
Alec Mouri | cdf6cbc | 2021-11-01 17:21:15 -0700 | [diff] [blame] | 254 | Display display, IComposerClient::ClientTargetProperty* outClientTargetProperty, |
| 255 | float* outWhitePointNits) = 0; |
| 256 | |
| 257 | // AIDL Composer |
| 258 | virtual Error setLayerWhitePointNits(Display display, Layer layer, float whitePointNits) = 0; |
Leon Scroggins III | d77d316 | 2022-01-05 10:42:28 -0500 | [diff] [blame] | 259 | virtual Error setLayerBlockingRegion(Display display, Layer layer, |
| 260 | const std::vector<IComposerClient::Rect>& blocking) = 0; |
Kriti Dang | 7defaf3 | 2021-11-15 11:55:43 +0100 | [diff] [blame^] | 261 | virtual Error setBootDisplayConfig(Display displayId, Config) = 0; |
| 262 | virtual Error clearBootDisplayConfig(Display displayId) = 0; |
| 263 | virtual Error getPreferredBootDisplayConfig(Display displayId, Config*) = 0; |
Lloyd Pique | a822d52 | 2017-12-20 16:42:57 -0800 | [diff] [blame] | 264 | }; |
| 265 | |
Ady Abraham | 9fc2805 | 2021-10-14 17:21:38 -0700 | [diff] [blame] | 266 | } // namespace android::Hwc2 |