1*0a9764feSAndroid Build Coastguard Worker /* 2*0a9764feSAndroid Build Coastguard Worker * Copyright (C) 2022 The Android Open Source Project 3*0a9764feSAndroid Build Coastguard Worker * 4*0a9764feSAndroid Build Coastguard Worker * Licensed under the Apache License, Version 2.0 (the "License"); 5*0a9764feSAndroid Build Coastguard Worker * you may not use this file except in compliance with the License. 6*0a9764feSAndroid Build Coastguard Worker * You may obtain a copy of the License at 7*0a9764feSAndroid Build Coastguard Worker * 8*0a9764feSAndroid Build Coastguard Worker * http://www.apache.org/licenses/LICENSE-2.0 9*0a9764feSAndroid Build Coastguard Worker * 10*0a9764feSAndroid Build Coastguard Worker * Unless required by applicable law or agreed to in writing, software 11*0a9764feSAndroid Build Coastguard Worker * distributed under the License is distributed on an "AS IS" BASIS, 12*0a9764feSAndroid Build Coastguard Worker * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13*0a9764feSAndroid Build Coastguard Worker * See the License for the specific language governing permissions and 14*0a9764feSAndroid Build Coastguard Worker * limitations under the License. 15*0a9764feSAndroid Build Coastguard Worker */ 16*0a9764feSAndroid Build Coastguard Worker 17*0a9764feSAndroid Build Coastguard Worker #pragma once 18*0a9764feSAndroid Build Coastguard Worker 19*0a9764feSAndroid Build Coastguard Worker #include <hardware/hwcomposer2.h> 20*0a9764feSAndroid Build Coastguard Worker 21*0a9764feSAndroid Build Coastguard Worker #include <atomic> 22*0a9764feSAndroid Build Coastguard Worker #include <optional> 23*0a9764feSAndroid Build Coastguard Worker #include <sstream> 24*0a9764feSAndroid Build Coastguard Worker 25*0a9764feSAndroid Build Coastguard Worker #include "HwcDisplayConfigs.h" 26*0a9764feSAndroid Build Coastguard Worker #include "compositor/DisplayInfo.h" 27*0a9764feSAndroid Build Coastguard Worker #include "compositor/FlatteningController.h" 28*0a9764feSAndroid Build Coastguard Worker #include "compositor/LayerData.h" 29*0a9764feSAndroid Build Coastguard Worker #include "drm/DrmAtomicStateManager.h" 30*0a9764feSAndroid Build Coastguard Worker #include "drm/ResourceManager.h" 31*0a9764feSAndroid Build Coastguard Worker #include "drm/VSyncWorker.h" 32*0a9764feSAndroid Build Coastguard Worker #include "hwc2_device/HwcLayer.h" 33*0a9764feSAndroid Build Coastguard Worker 34*0a9764feSAndroid Build Coastguard Worker namespace android { 35*0a9764feSAndroid Build Coastguard Worker 36*0a9764feSAndroid Build Coastguard Worker class Backend; 37*0a9764feSAndroid Build Coastguard Worker class DrmHwc; 38*0a9764feSAndroid Build Coastguard Worker 39*0a9764feSAndroid Build Coastguard Worker inline constexpr uint32_t kPrimaryDisplay = 0; 40*0a9764feSAndroid Build Coastguard Worker 41*0a9764feSAndroid Build Coastguard Worker // NOLINTNEXTLINE 42*0a9764feSAndroid Build Coastguard Worker class HwcDisplay { 43*0a9764feSAndroid Build Coastguard Worker public: 44*0a9764feSAndroid Build Coastguard Worker enum ConfigError { 45*0a9764feSAndroid Build Coastguard Worker kNone, 46*0a9764feSAndroid Build Coastguard Worker kBadConfig, 47*0a9764feSAndroid Build Coastguard Worker kSeamlessNotAllowed, 48*0a9764feSAndroid Build Coastguard Worker kSeamlessNotPossible 49*0a9764feSAndroid Build Coastguard Worker }; 50*0a9764feSAndroid Build Coastguard Worker 51*0a9764feSAndroid Build Coastguard Worker HwcDisplay(hwc2_display_t handle, HWC2::DisplayType type, DrmHwc *hwc); 52*0a9764feSAndroid Build Coastguard Worker HwcDisplay(const HwcDisplay &) = delete; 53*0a9764feSAndroid Build Coastguard Worker ~HwcDisplay(); 54*0a9764feSAndroid Build Coastguard Worker 55*0a9764feSAndroid Build Coastguard Worker /* SetPipeline should be carefully used only by DrmHwcTwo hotplug handlers */ 56*0a9764feSAndroid Build Coastguard Worker void SetPipeline(std::shared_ptr<DrmDisplayPipeline> pipeline); 57*0a9764feSAndroid Build Coastguard Worker 58*0a9764feSAndroid Build Coastguard Worker HWC2::Error CreateComposition(AtomicCommitArgs &a_args); 59*0a9764feSAndroid Build Coastguard Worker std::vector<HwcLayer *> GetOrderLayersByZPos(); 60*0a9764feSAndroid Build Coastguard Worker 61*0a9764feSAndroid Build Coastguard Worker void ClearDisplay(); 62*0a9764feSAndroid Build Coastguard Worker 63*0a9764feSAndroid Build Coastguard Worker std::string Dump(); 64*0a9764feSAndroid Build Coastguard Worker GetDisplayConfigs()65*0a9764feSAndroid Build Coastguard Worker const HwcDisplayConfigs &GetDisplayConfigs() const { 66*0a9764feSAndroid Build Coastguard Worker return configs_; 67*0a9764feSAndroid Build Coastguard Worker } 68*0a9764feSAndroid Build Coastguard Worker 69*0a9764feSAndroid Build Coastguard Worker // Get the config representing the mode that has been committed to KMS. 70*0a9764feSAndroid Build Coastguard Worker auto GetCurrentConfig() const -> const HwcDisplayConfig *; 71*0a9764feSAndroid Build Coastguard Worker 72*0a9764feSAndroid Build Coastguard Worker // Get the config that was last requested through SetActiveConfig and similar 73*0a9764feSAndroid Build Coastguard Worker // functions. This may differ from the GetCurrentConfig if the config change 74*0a9764feSAndroid Build Coastguard Worker // is queued up to take effect in the future. 75*0a9764feSAndroid Build Coastguard Worker auto GetLastRequestedConfig() const -> const HwcDisplayConfig *; 76*0a9764feSAndroid Build Coastguard Worker 77*0a9764feSAndroid Build Coastguard Worker // Set a config synchronously. If the requested config fails to be committed, 78*0a9764feSAndroid Build Coastguard Worker // this will return with an error. Otherwise, the config will have been 79*0a9764feSAndroid Build Coastguard Worker // committed to the kernel on successful return. 80*0a9764feSAndroid Build Coastguard Worker ConfigError SetConfig(hwc2_config_t config); 81*0a9764feSAndroid Build Coastguard Worker 82*0a9764feSAndroid Build Coastguard Worker // Queue a configuration change to take effect in the future. 83*0a9764feSAndroid Build Coastguard Worker auto QueueConfig(hwc2_config_t config, int64_t desired_time, bool seamless, 84*0a9764feSAndroid Build Coastguard Worker QueuedConfigTiming *out_timing) -> ConfigError; 85*0a9764feSAndroid Build Coastguard Worker 86*0a9764feSAndroid Build Coastguard Worker // Get the HwcDisplayConfig, or nullptor if none. 87*0a9764feSAndroid Build Coastguard Worker auto GetConfig(hwc2_config_t config_id) const -> const HwcDisplayConfig *; 88*0a9764feSAndroid Build Coastguard Worker 89*0a9764feSAndroid Build Coastguard Worker // HWC2 Hooks - these should not be used outside of the hwc2 device. 90*0a9764feSAndroid Build Coastguard Worker HWC2::Error AcceptDisplayChanges(); 91*0a9764feSAndroid Build Coastguard Worker HWC2::Error CreateLayer(hwc2_layer_t *layer); 92*0a9764feSAndroid Build Coastguard Worker HWC2::Error DestroyLayer(hwc2_layer_t layer); 93*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetActiveConfig(hwc2_config_t *config) const; 94*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetChangedCompositionTypes(uint32_t *num_elements, 95*0a9764feSAndroid Build Coastguard Worker hwc2_layer_t *layers, int32_t *types); 96*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetClientTargetSupport(uint32_t width, uint32_t height, 97*0a9764feSAndroid Build Coastguard Worker int32_t format, int32_t dataspace); 98*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetColorModes(uint32_t *num_modes, int32_t *modes); 99*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetDisplayAttribute(hwc2_config_t config, int32_t attribute, 100*0a9764feSAndroid Build Coastguard Worker int32_t *value); 101*0a9764feSAndroid Build Coastguard Worker HWC2::Error LegacyGetDisplayConfigs(uint32_t *num_configs, 102*0a9764feSAndroid Build Coastguard Worker hwc2_config_t *configs); 103*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetDisplayName(uint32_t *size, char *name); 104*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetDisplayRequests(int32_t *display_requests, 105*0a9764feSAndroid Build Coastguard Worker uint32_t *num_elements, hwc2_layer_t *layers, 106*0a9764feSAndroid Build Coastguard Worker int32_t *layer_requests); 107*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetDisplayType(int32_t *type); 108*0a9764feSAndroid Build Coastguard Worker #if __ANDROID_API__ > 27 109*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetRenderIntents(int32_t mode, uint32_t *outNumIntents, 110*0a9764feSAndroid Build Coastguard Worker int32_t *outIntents); 111*0a9764feSAndroid Build Coastguard Worker HWC2::Error SetColorModeWithIntent(int32_t mode, int32_t intent); 112*0a9764feSAndroid Build Coastguard Worker #endif 113*0a9764feSAndroid Build Coastguard Worker #if __ANDROID_API__ > 28 114*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetDisplayIdentificationData(uint8_t *outPort, 115*0a9764feSAndroid Build Coastguard Worker uint32_t *outDataSize, 116*0a9764feSAndroid Build Coastguard Worker uint8_t *outData); 117*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetDisplayCapabilities(uint32_t *outNumCapabilities, 118*0a9764feSAndroid Build Coastguard Worker uint32_t *outCapabilities); 119*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetDisplayBrightnessSupport(bool *supported); 120*0a9764feSAndroid Build Coastguard Worker HWC2::Error SetDisplayBrightness(float); 121*0a9764feSAndroid Build Coastguard Worker #endif 122*0a9764feSAndroid Build Coastguard Worker #if __ANDROID_API__ > 29 123*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetDisplayConnectionType(uint32_t *outType); 124*0a9764feSAndroid Build Coastguard Worker 125*0a9764feSAndroid Build Coastguard Worker HWC2::Error SetActiveConfigWithConstraints( 126*0a9764feSAndroid Build Coastguard Worker hwc2_config_t config, 127*0a9764feSAndroid Build Coastguard Worker hwc_vsync_period_change_constraints_t *vsyncPeriodChangeConstraints, 128*0a9764feSAndroid Build Coastguard Worker hwc_vsync_period_change_timeline_t *outTimeline); 129*0a9764feSAndroid Build Coastguard Worker HWC2::Error SetAutoLowLatencyMode(bool on); 130*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetSupportedContentTypes( 131*0a9764feSAndroid Build Coastguard Worker uint32_t *outNumSupportedContentTypes, 132*0a9764feSAndroid Build Coastguard Worker const uint32_t *outSupportedContentTypes); 133*0a9764feSAndroid Build Coastguard Worker 134*0a9764feSAndroid Build Coastguard Worker HWC2::Error SetContentType(int32_t contentType); 135*0a9764feSAndroid Build Coastguard Worker #endif 136*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetDisplayVsyncPeriod(uint32_t *outVsyncPeriod); 137*0a9764feSAndroid Build Coastguard Worker 138*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetDozeSupport(int32_t *support); 139*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetHdrCapabilities(uint32_t *num_types, int32_t *types, 140*0a9764feSAndroid Build Coastguard Worker float *max_luminance, 141*0a9764feSAndroid Build Coastguard Worker float *max_average_luminance, 142*0a9764feSAndroid Build Coastguard Worker float *min_luminance); 143*0a9764feSAndroid Build Coastguard Worker HWC2::Error GetReleaseFences(uint32_t *num_elements, hwc2_layer_t *layers, 144*0a9764feSAndroid Build Coastguard Worker int32_t *fences); 145*0a9764feSAndroid Build Coastguard Worker HWC2::Error PresentDisplay(int32_t *out_present_fence); 146*0a9764feSAndroid Build Coastguard Worker HWC2::Error SetActiveConfig(hwc2_config_t config); 147*0a9764feSAndroid Build Coastguard Worker HWC2::Error ChosePreferredConfig(); 148*0a9764feSAndroid Build Coastguard Worker HWC2::Error SetClientTarget(buffer_handle_t target, int32_t acquire_fence, 149*0a9764feSAndroid Build Coastguard Worker int32_t dataspace, hwc_region_t damage); 150*0a9764feSAndroid Build Coastguard Worker HWC2::Error SetColorMode(int32_t mode); 151*0a9764feSAndroid Build Coastguard Worker HWC2::Error SetColorTransform(const float *matrix, int32_t hint); 152*0a9764feSAndroid Build Coastguard Worker HWC2::Error SetOutputBuffer(buffer_handle_t buffer, int32_t release_fence); 153*0a9764feSAndroid Build Coastguard Worker HWC2::Error SetPowerMode(int32_t mode); 154*0a9764feSAndroid Build Coastguard Worker HWC2::Error SetVsyncEnabled(int32_t enabled); 155*0a9764feSAndroid Build Coastguard Worker HWC2::Error ValidateDisplay(uint32_t *num_types, uint32_t *num_requests); get_layer(hwc2_layer_t layer)156*0a9764feSAndroid Build Coastguard Worker HwcLayer *get_layer(hwc2_layer_t layer) { 157*0a9764feSAndroid Build Coastguard Worker auto it = layers_.find(layer); 158*0a9764feSAndroid Build Coastguard Worker if (it == layers_.end()) 159*0a9764feSAndroid Build Coastguard Worker return nullptr; 160*0a9764feSAndroid Build Coastguard Worker return &it->second; 161*0a9764feSAndroid Build Coastguard Worker } 162*0a9764feSAndroid Build Coastguard Worker 163*0a9764feSAndroid Build Coastguard Worker /* Statistics */ 164*0a9764feSAndroid Build Coastguard Worker struct Stats { minusStats165*0a9764feSAndroid Build Coastguard Worker Stats minus(Stats b) const { 166*0a9764feSAndroid Build Coastguard Worker return {total_frames_ - b.total_frames_, 167*0a9764feSAndroid Build Coastguard Worker total_pixops_ - b.total_pixops_, 168*0a9764feSAndroid Build Coastguard Worker gpu_pixops_ - b.gpu_pixops_, 169*0a9764feSAndroid Build Coastguard Worker failed_kms_validate_ - b.failed_kms_validate_, 170*0a9764feSAndroid Build Coastguard Worker failed_kms_present_ - b.failed_kms_present_, 171*0a9764feSAndroid Build Coastguard Worker frames_flattened_ - b.frames_flattened_}; 172*0a9764feSAndroid Build Coastguard Worker } 173*0a9764feSAndroid Build Coastguard Worker 174*0a9764feSAndroid Build Coastguard Worker uint32_t total_frames_ = 0; 175*0a9764feSAndroid Build Coastguard Worker uint64_t total_pixops_ = 0; 176*0a9764feSAndroid Build Coastguard Worker uint64_t gpu_pixops_ = 0; 177*0a9764feSAndroid Build Coastguard Worker uint32_t failed_kms_validate_ = 0; 178*0a9764feSAndroid Build Coastguard Worker uint32_t failed_kms_present_ = 0; 179*0a9764feSAndroid Build Coastguard Worker uint32_t frames_flattened_ = 0; 180*0a9764feSAndroid Build Coastguard Worker }; 181*0a9764feSAndroid Build Coastguard Worker 182*0a9764feSAndroid Build Coastguard Worker const Backend *backend() const; 183*0a9764feSAndroid Build Coastguard Worker void set_backend(std::unique_ptr<Backend> backend); 184*0a9764feSAndroid Build Coastguard Worker GetHwc()185*0a9764feSAndroid Build Coastguard Worker auto GetHwc() { 186*0a9764feSAndroid Build Coastguard Worker return hwc_; 187*0a9764feSAndroid Build Coastguard Worker } 188*0a9764feSAndroid Build Coastguard Worker layers()189*0a9764feSAndroid Build Coastguard Worker std::map<hwc2_layer_t, HwcLayer> &layers() { 190*0a9764feSAndroid Build Coastguard Worker return layers_; 191*0a9764feSAndroid Build Coastguard Worker } 192*0a9764feSAndroid Build Coastguard Worker GetPipe()193*0a9764feSAndroid Build Coastguard Worker auto &GetPipe() { 194*0a9764feSAndroid Build Coastguard Worker return *pipeline_; 195*0a9764feSAndroid Build Coastguard Worker } 196*0a9764feSAndroid Build Coastguard Worker 197*0a9764feSAndroid Build Coastguard Worker bool CtmByGpu(); 198*0a9764feSAndroid Build Coastguard Worker total_stats()199*0a9764feSAndroid Build Coastguard Worker Stats &total_stats() { 200*0a9764feSAndroid Build Coastguard Worker return total_stats_; 201*0a9764feSAndroid Build Coastguard Worker } 202*0a9764feSAndroid Build Coastguard Worker 203*0a9764feSAndroid Build Coastguard Worker /* Headless mode required to keep SurfaceFlinger alive when all display are 204*0a9764feSAndroid Build Coastguard Worker * disconnected, Without headless mode Android will continuously crash. 205*0a9764feSAndroid Build Coastguard Worker * Only single internal (primary) display is required to be in HEADLESS mode 206*0a9764feSAndroid Build Coastguard Worker * to prevent the crash. See: 207*0a9764feSAndroid Build Coastguard Worker * https://source.android.com/devices/graphics/hotplug#handling-common-scenarios 208*0a9764feSAndroid Build Coastguard Worker */ IsInHeadlessMode()209*0a9764feSAndroid Build Coastguard Worker bool IsInHeadlessMode() { 210*0a9764feSAndroid Build Coastguard Worker return !pipeline_; 211*0a9764feSAndroid Build Coastguard Worker } 212*0a9764feSAndroid Build Coastguard Worker 213*0a9764feSAndroid Build Coastguard Worker void Deinit(); 214*0a9764feSAndroid Build Coastguard Worker GetFlatCon()215*0a9764feSAndroid Build Coastguard Worker auto GetFlatCon() { 216*0a9764feSAndroid Build Coastguard Worker return flatcon_; 217*0a9764feSAndroid Build Coastguard Worker } 218*0a9764feSAndroid Build Coastguard Worker GetWritebackLayer()219*0a9764feSAndroid Build Coastguard Worker auto &GetWritebackLayer() { 220*0a9764feSAndroid Build Coastguard Worker return writeback_layer_; 221*0a9764feSAndroid Build Coastguard Worker } 222*0a9764feSAndroid Build Coastguard Worker SetVirtualDisplayResolution(uint16_t width,uint16_t height)223*0a9764feSAndroid Build Coastguard Worker void SetVirtualDisplayResolution(uint16_t width, uint16_t height) { 224*0a9764feSAndroid Build Coastguard Worker virtual_disp_width_ = width; 225*0a9764feSAndroid Build Coastguard Worker virtual_disp_height_ = height; 226*0a9764feSAndroid Build Coastguard Worker } 227*0a9764feSAndroid Build Coastguard Worker 228*0a9764feSAndroid Build Coastguard Worker auto getDisplayPhysicalOrientation() -> std::optional<PanelOrientation>; 229*0a9764feSAndroid Build Coastguard Worker 230*0a9764feSAndroid Build Coastguard Worker private: 231*0a9764feSAndroid Build Coastguard Worker AtomicCommitArgs CreateModesetCommit( 232*0a9764feSAndroid Build Coastguard Worker const HwcDisplayConfig *config, 233*0a9764feSAndroid Build Coastguard Worker const std::optional<LayerData> &modeset_layer); 234*0a9764feSAndroid Build Coastguard Worker 235*0a9764feSAndroid Build Coastguard Worker HwcDisplayConfigs configs_; 236*0a9764feSAndroid Build Coastguard Worker 237*0a9764feSAndroid Build Coastguard Worker DrmHwc *const hwc_; 238*0a9764feSAndroid Build Coastguard Worker 239*0a9764feSAndroid Build Coastguard Worker SharedFd present_fence_; 240*0a9764feSAndroid Build Coastguard Worker 241*0a9764feSAndroid Build Coastguard Worker int64_t staged_mode_change_time_{}; 242*0a9764feSAndroid Build Coastguard Worker std::optional<uint32_t> staged_mode_config_id_{}; 243*0a9764feSAndroid Build Coastguard Worker 244*0a9764feSAndroid Build Coastguard Worker std::shared_ptr<DrmDisplayPipeline> pipeline_; 245*0a9764feSAndroid Build Coastguard Worker 246*0a9764feSAndroid Build Coastguard Worker std::unique_ptr<Backend> backend_; 247*0a9764feSAndroid Build Coastguard Worker std::shared_ptr<FlatteningController> flatcon_; 248*0a9764feSAndroid Build Coastguard Worker 249*0a9764feSAndroid Build Coastguard Worker std::shared_ptr<VSyncWorker> vsync_worker_; 250*0a9764feSAndroid Build Coastguard Worker bool vsync_event_en_{}; 251*0a9764feSAndroid Build Coastguard Worker bool vsync_tracking_en_{}; 252*0a9764feSAndroid Build Coastguard Worker int64_t last_vsync_ts_{}; 253*0a9764feSAndroid Build Coastguard Worker 254*0a9764feSAndroid Build Coastguard Worker const hwc2_display_t handle_; 255*0a9764feSAndroid Build Coastguard Worker HWC2::DisplayType type_; 256*0a9764feSAndroid Build Coastguard Worker 257*0a9764feSAndroid Build Coastguard Worker uint32_t layer_idx_{}; 258*0a9764feSAndroid Build Coastguard Worker 259*0a9764feSAndroid Build Coastguard Worker std::map<hwc2_layer_t, HwcLayer> layers_; 260*0a9764feSAndroid Build Coastguard Worker HwcLayer client_layer_; 261*0a9764feSAndroid Build Coastguard Worker std::unique_ptr<HwcLayer> writeback_layer_; 262*0a9764feSAndroid Build Coastguard Worker uint16_t virtual_disp_width_{}; 263*0a9764feSAndroid Build Coastguard Worker uint16_t virtual_disp_height_{}; 264*0a9764feSAndroid Build Coastguard Worker int32_t color_mode_{}; 265*0a9764feSAndroid Build Coastguard Worker static constexpr int kCtmRows = 3; 266*0a9764feSAndroid Build Coastguard Worker static constexpr int kCtmCols = 3; 267*0a9764feSAndroid Build Coastguard Worker std::shared_ptr<drm_color_ctm> color_matrix_; 268*0a9764feSAndroid Build Coastguard Worker android_color_transform_t color_transform_hint_{}; 269*0a9764feSAndroid Build Coastguard Worker int32_t content_type_{}; 270*0a9764feSAndroid Build Coastguard Worker Colorspace colorspace_{}; 271*0a9764feSAndroid Build Coastguard Worker 272*0a9764feSAndroid Build Coastguard Worker std::shared_ptr<DrmKmsPlan> current_plan_; 273*0a9764feSAndroid Build Coastguard Worker 274*0a9764feSAndroid Build Coastguard Worker uint32_t frame_no_ = 0; 275*0a9764feSAndroid Build Coastguard Worker Stats total_stats_; 276*0a9764feSAndroid Build Coastguard Worker Stats prev_stats_; 277*0a9764feSAndroid Build Coastguard Worker std::string DumpDelta(HwcDisplay::Stats delta); 278*0a9764feSAndroid Build Coastguard Worker 279*0a9764feSAndroid Build Coastguard Worker void SetColorMatrixToIdentity(); 280*0a9764feSAndroid Build Coastguard Worker 281*0a9764feSAndroid Build Coastguard Worker HWC2::Error Init(); 282*0a9764feSAndroid Build Coastguard Worker 283*0a9764feSAndroid Build Coastguard Worker HWC2::Error SetActiveConfigInternal(uint32_t config, int64_t change_time); 284*0a9764feSAndroid Build Coastguard Worker }; 285*0a9764feSAndroid Build Coastguard Worker 286*0a9764feSAndroid Build Coastguard Worker } // namespace android 287