Skip to content

Commit db4df63

Browse files
author
android-build-team Robot
committed
Merge cherrypicks of [13350919, 13351137, 13351103, 13350944, 13351985, 13351986, 13351113, 13351104] into rvc-qpr2-release
Change-Id: Ia2ac25ec8b825b233db12470b7905592c1ec94ac
2 parents 2e21c28 + 62a3a83 commit db4df63

14 files changed

Lines changed: 182 additions & 1040 deletions

File tree

core/java/android/hardware/display/DisplayManager.java

Lines changed: 8 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -875,76 +875,37 @@ public interface DisplayListener {
875875
public interface DeviceConfig {
876876

877877
/**
878-
* Key for refresh rate in the low zone defined by thresholds.
878+
* Key for refresh rate in the zone defined by thresholds.
879879
*
880-
* Note that the name and value don't match because they were added before we had a high
881-
* zone to consider.
882880
* @see android.provider.DeviceConfig#NAMESPACE_DISPLAY_MANAGER
883881
* @see android.R.integer#config_defaultZoneBehavior
884882
*/
885-
String KEY_REFRESH_RATE_IN_LOW_ZONE = "refresh_rate_in_zone";
883+
String KEY_REFRESH_RATE_IN_ZONE = "refresh_rate_in_zone";
886884

887885
/**
888-
* Key for accessing the low display brightness thresholds for the configured refresh
889-
* rate zone.
886+
* Key for accessing the display brightness thresholds for the configured refresh rate zone.
890887
* The value will be a pair of comma separated integers representing the minimum and maximum
891888
* thresholds of the zone, respectively, in display backlight units (i.e. [0, 255]).
892889
*
893-
* Note that the name and value don't match because they were added before we had a high
894-
* zone to consider.
895-
*
896890
* @see android.provider.DeviceConfig#NAMESPACE_DISPLAY_MANAGER
897891
* @see android.R.array#config_brightnessThresholdsOfPeakRefreshRate
898892
* @hide
899893
*/
900-
String KEY_FIXED_REFRESH_RATE_LOW_DISPLAY_BRIGHTNESS_THRESHOLDS =
894+
String KEY_PEAK_REFRESH_RATE_DISPLAY_BRIGHTNESS_THRESHOLDS =
901895
"peak_refresh_rate_brightness_thresholds";
902896

903-
/**
904-
* Key for accessing the low ambient brightness thresholds for the configured refresh
905-
* rate zone. The value will be a pair of comma separated integers representing the minimum
906-
* and maximum thresholds of the zone, respectively, in lux.
907-
*
908-
* Note that the name and value don't match because they were added before we had a high
909-
* zone to consider.
910-
*
911-
* @see android.provider.DeviceConfig#NAMESPACE_DISPLAY_MANAGER
912-
* @see android.R.array#config_ambientThresholdsOfPeakRefreshRate
913-
* @hide
914-
*/
915-
String KEY_FIXED_REFRESH_RATE_LOW_AMBIENT_BRIGHTNESS_THRESHOLDS =
916-
"peak_refresh_rate_ambient_thresholds";
917-
/**
918-
* Key for refresh rate in the high zone defined by thresholds.
919-
*
920-
* @see android.provider.DeviceConfig#NAMESPACE_DISPLAY_MANAGER
921-
* @see android.R.integer#config_fixedRefreshRateInHighZone
922-
*/
923-
String KEY_REFRESH_RATE_IN_HIGH_ZONE = "refresh_rate_in_high_zone";
924-
925-
/**
926-
* Key for accessing the display brightness thresholds for the configured refresh rate zone.
927-
* The value will be a pair of comma separated integers representing the minimum and maximum
928-
* thresholds of the zone, respectively, in display backlight units (i.e. [0, 255]).
929-
*
930-
* @see android.provider.DeviceConfig#NAMESPACE_DISPLAY_MANAGER
931-
* @see android.R.array#config_brightnessHighThresholdsOfFixedRefreshRate
932-
* @hide
933-
*/
934-
String KEY_FIXED_REFRESH_RATE_HIGH_DISPLAY_BRIGHTNESS_THRESHOLDS =
935-
"fixed_refresh_rate_high_display_brightness_thresholds";
936-
937897
/**
938898
* Key for accessing the ambient brightness thresholds for the configured refresh rate zone.
939899
* The value will be a pair of comma separated integers representing the minimum and maximum
940900
* thresholds of the zone, respectively, in lux.
941901
*
942902
* @see android.provider.DeviceConfig#NAMESPACE_DISPLAY_MANAGER
943-
* @see android.R.array#config_ambientHighThresholdsOfFixedRefreshRate
903+
* @see android.R.array#config_ambientThresholdsOfPeakRefreshRate
944904
* @hide
945905
*/
946-
String KEY_FIXED_REFRESH_RATE_HIGH_AMBIENT_BRIGHTNESS_THRESHOLDS =
947-
"fixed_refresh_rate_high_ambient_brightness_thresholds";
906+
String KEY_PEAK_REFRESH_RATE_AMBIENT_BRIGHTNESS_THRESHOLDS =
907+
"peak_refresh_rate_ambient_thresholds";
908+
948909
/**
949910
* Key for default peak refresh rate
950911
*

core/res/res/values/config.xml

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -4138,35 +4138,6 @@
41384138
If non-positive, then the refresh rate is unchanged even if thresholds are configured. -->
41394139
<integer name="config_defaultRefreshRateInZone">0</integer>
41404140

4141-
<!-- The display uses different gamma curves for different refresh rates. It's hard for panel
4142-
vendor to tune the curves to have exact same brightness for different refresh rate. So
4143-
flicker could be observed at switch time. The issue can be observed on the screen with
4144-
even full white content at the high brightness. To prevent flickering, we support fixed
4145-
refresh rates if the display and ambient brightness are equal to or above the provided
4146-
thresholds. You can define multiple threshold levels as higher brightness environments
4147-
may have lower display brightness requirements for the flickering is visible. And the
4148-
high brightness environment could have higher threshold.
4149-
For example, fixed refresh rate if
4150-
display brightness >= disp0 && ambient brightness >= amb0
4151-
|| display brightness >= disp1 && ambient brightness >= amb1 -->
4152-
<integer-array translatable="false" name="config_highDisplayBrightnessThresholdsOfFixedRefreshRate">
4153-
<!--
4154-
<item>disp0</item>
4155-
<item>disp1</item>
4156-
-->
4157-
</integer-array>
4158-
4159-
<integer-array translatable="false" name="config_highAmbientBrightnessThresholdsOfFixedRefreshRate">
4160-
<!--
4161-
<item>amb0</item>
4162-
<item>amb1</item>
4163-
-->
4164-
</integer-array>
4165-
4166-
<!-- Default refresh rate in the high zone defined by brightness and ambient thresholds.
4167-
If non-positive, then the refresh rate is unchanged even if thresholds are configured. -->
4168-
<integer name="config_fixedRefreshRateInHighZone">0</integer>
4169-
41704141
<!-- The type of the light sensor to be used by the display framework for things like
41714142
auto-brightness. If unset, then it just gets the default sensor of type TYPE_LIGHT. -->
41724143
<string name="config_displayLightSensorType" translatable="false" />

core/res/res/values/symbols.xml

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3783,11 +3783,6 @@
37833783
<java-symbol type="array" name="config_brightnessThresholdsOfPeakRefreshRate" />
37843784
<java-symbol type="array" name="config_ambientThresholdsOfPeakRefreshRate" />
37853785

3786-
<!-- For fixed refresh rate displays in high brightness-->
3787-
<java-symbol type="integer" name="config_fixedRefreshRateInHighZone" />
3788-
<java-symbol type="array" name="config_highDisplayBrightnessThresholdsOfFixedRefreshRate" />
3789-
<java-symbol type="array" name="config_highAmbientBrightnessThresholdsOfFixedRefreshRate" />
3790-
37913786
<!-- For Auto-Brightness -->
37923787
<java-symbol type="string" name="config_displayLightSensorType" />
37933788

services/core/Android.bp

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,3 @@
1-
filegroup {
2-
name: "services.core-sources-deviceconfig-interface",
3-
srcs: [
4-
"java/com/android/server/utils/DeviceConfigInterface.java"
5-
],
6-
}
7-
81
filegroup {
92
name: "services.core-sources",
103
srcs: ["java/**/*.java"],

0 commit comments

Comments
 (0)