blob: 039d316a95c47e06ad2ba4db545ad837fecb3c72 [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
62bool use_color_management(bool defaultValue);
63
64int64_t default_composition_dataspace(
65 android::hardware::graphics::common::V1_2::Dataspace defaultValue);
66
67int32_t default_composition_pixel_format(
Kevin DuBois73d0f482019-01-25 11:18:03 -080068 android::hardware::graphics::common::V1_2::PixelFormat defaultValue);
Sundong Ahnd5e08f62018-12-12 20:27:28 +090069
70int64_t wcg_composition_dataspace(
71 android::hardware::graphics::common::V1_2::Dataspace defaultValue);
72
73int32_t wcg_composition_pixel_format(
Kevin DuBois73d0f482019-01-25 11:18:03 -080074 android::hardware::graphics::common::V1_2::PixelFormat defaultValue);
Sundong Ahn85131bd2019-02-18 15:51:53 +090075
Yichi Chenda901bf2019-06-28 14:58:27 +080076int64_t color_space_agnostic_dataspace(
77 android::hardware::graphics::common::V1_2::Dataspace defaultValue);
78
Ana Krulec10e02052020-02-04 17:16:10 +000079bool refresh_rate_switching(bool defaultValue);
80
Ady Abrahambe59c0d2019-03-05 13:01:13 -080081int32_t set_idle_timer_ms(int32_t defaultValue);
82
Ady Abraham8532d012019-05-08 14:50:56 -070083int32_t set_touch_timer_ms(int32_t defaultValue);
84
Ady Abraham6fe2c172019-07-12 12:37:57 -070085int32_t set_display_power_timer_ms(int32_t defaultValue);
86
Ady Abraham48da0702020-02-04 15:59:25 -080087bool use_content_detection_for_refresh_rate(bool defaultValue);
Ana Krulece5a06e02019-03-06 17:09:03 -080088
Peiyong Lin6a043d52019-04-01 17:18:21 -070089bool enable_protected_contents(bool defaultValue);
90
Alec Mouridc28b372019-04-18 21:17:13 -070091bool support_kernel_idle_timer(bool defaultValue);
92
Ana Krulec3803b8d2020-02-03 16:35:46 -080093bool use_frame_rate_api(bool defaultValue);
94
Dan Stoza030fbc12020-02-19 15:32:01 -080095int32_t display_update_imminent_timeout_ms(int32_t defaultValue);
96
Sundong Ahncb20cca2019-02-22 11:57:38 +090097android::ui::DisplayPrimaries getDisplayNativePrimaries();
Marin Shalamanovf8c63722020-10-06 13:11:21 +020098
99bool update_device_product_info_on_hotplug_reconnect(bool defaultValue);
100
Ady Abraham4899ff82021-01-06 13:53:29 -0800101bool enable_frame_rate_override(bool defaultValue);
102
Ady Abraham9c87def2021-02-18 11:25:28 -0800103bool enable_layer_caching(bool defaultValue);
104
John Reckac09e452021-04-07 16:35:37 -0400105bool enable_sdr_dimming(bool defaultValue);
106
Sundong Ahnd5e08f62018-12-12 20:27:28 +0900107} // namespace sysprop
108} // namespace android
109#endif // SURFACEFLINGERPROPERTIES_H_