blob: ed182608fbdb2598ab6e3405829640ab93d9e9d7 [file] [log] [blame]
Peiyong Lin6a043d52019-04-01 17:18:21 -07001/*
2 * Copyright 2019 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 */
Sundong Ahnd5e08f62018-12-12 20:27:28 +090016
17#ifndef SURFACEFLINGERPROPERTIES_H_
18#define SURFACEFLINGERPROPERTIES_H_
19
Inseob Kimd6e835b2019-02-14 12:33:30 +090020#include <SurfaceFlingerProperties.sysprop.h>
Sundong Ahnd5e08f62018-12-12 20:27:28 +090021#include <android/hardware/configstore/1.1/ISurfaceFlingerConfigs.h>
Sundong Ahncb20cca2019-02-22 11:57:38 +090022#include <android/hardware/graphics/common/1.2/types.h>
Sundong Ahncb20cca2019-02-22 11:57:38 +090023#include <ui/ConfigStoreTypes.h>
Sundong Ahnd5e08f62018-12-12 20:27:28 +090024
25#include <cstdint>
26#include <optional>
27#include <vector>
28
29namespace android {
30namespace sysprop {
31
32int64_t vsync_event_phase_offset_ns(int64_t defaultValue);
33
34int64_t vsync_sf_event_phase_offset_ns(int64_t defaultValue);
35
36bool use_context_priority(bool defaultValue);
37
38int64_t max_frame_buffer_acquired_buffers(int64_t defaultValue);
39
Brian Lindahla13f2d52020-03-05 11:54:17 +010040int32_t max_graphics_width(int32_t defaultValue);
41int32_t max_graphics_height(int32_t defaultValue);
42
Sundong Ahnd5e08f62018-12-12 20:27:28 +090043bool has_wide_color_display(bool defaultValue);
44
45bool running_without_sync_framework(bool defaultValue);
46
47bool has_HDR_display(bool defaultValue);
48
49int64_t present_time_offset_from_vsync_ns(int64_t defaultValue);
50
51bool force_hwc_copy_for_virtual_displays(bool defaultValue);
52
53int64_t max_virtual_display_dimension(int64_t defaultValue);
54
55bool use_vr_flinger(bool defaultValue);
56
57bool start_graphics_allocator_service(bool defaultValue);
58
59SurfaceFlingerProperties::primary_display_orientation_values primary_display_orientation(
60 SurfaceFlingerProperties::primary_display_orientation_values defaultValue);
61
Sundong Ahnd5e08f62018-12-12 20:27:28 +090062int64_t default_composition_dataspace(
63 android::hardware::graphics::common::V1_2::Dataspace defaultValue);
64
65int32_t default_composition_pixel_format(
Kevin DuBois73d0f482019-01-25 11:18:03 -080066 android::hardware::graphics::common::V1_2::PixelFormat defaultValue);
Sundong Ahnd5e08f62018-12-12 20:27:28 +090067
68int64_t wcg_composition_dataspace(
69 android::hardware::graphics::common::V1_2::Dataspace defaultValue);
70
71int32_t wcg_composition_pixel_format(
Kevin DuBois73d0f482019-01-25 11:18:03 -080072 android::hardware::graphics::common::V1_2::PixelFormat defaultValue);
Sundong Ahn85131bd2019-02-18 15:51:53 +090073
Yichi Chenda901bf2019-06-28 14:58:27 +080074int64_t color_space_agnostic_dataspace(
75 android::hardware::graphics::common::V1_2::Dataspace defaultValue);
76
Ana Krulec10e02052020-02-04 17:16:10 +000077bool refresh_rate_switching(bool defaultValue);
78
Ady Abrahambe59c0d2019-03-05 13:01:13 -080079int32_t set_idle_timer_ms(int32_t defaultValue);
80
Ady Abraham8532d012019-05-08 14:50:56 -070081int32_t set_touch_timer_ms(int32_t defaultValue);
82
Ady Abraham6fe2c172019-07-12 12:37:57 -070083int32_t set_display_power_timer_ms(int32_t defaultValue);
84
Ady Abraham48da0702020-02-04 15:59:25 -080085bool use_content_detection_for_refresh_rate(bool defaultValue);
Ana Krulece5a06e02019-03-06 17:09:03 -080086
Peiyong Lin6a043d52019-04-01 17:18:21 -070087bool enable_protected_contents(bool defaultValue);
88
Alec Mouridc28b372019-04-18 21:17:13 -070089bool support_kernel_idle_timer(bool defaultValue);
90
Ana Krulec3803b8d2020-02-03 16:35:46 -080091bool use_frame_rate_api(bool defaultValue);
92
Dan Stoza030fbc12020-02-19 15:32:01 -080093int32_t display_update_imminent_timeout_ms(int32_t defaultValue);
94
Sundong Ahncb20cca2019-02-22 11:57:38 +090095android::ui::DisplayPrimaries getDisplayNativePrimaries();
Marin Shalamanovf8c63722020-10-06 13:11:21 +020096
97bool update_device_product_info_on_hotplug_reconnect(bool defaultValue);
98
Ady Abraham4899ff82021-01-06 13:53:29 -080099bool enable_frame_rate_override(bool defaultValue);
100
Ady Abraham9c87def2021-02-18 11:25:28 -0800101bool enable_layer_caching(bool defaultValue);
102
John Reckac09e452021-04-07 16:35:37 -0400103bool enable_sdr_dimming(bool defaultValue);
104
Sundong Ahnd5e08f62018-12-12 20:27:28 +0900105} // namespace sysprop
106} // namespace android
107#endif // SURFACEFLINGERPROPERTIES_H_