commit | 76825bcc2bc95509933c4d186d6c24d544bb8278 | [log] [tgz] |
---|---|---|
author | Oleg Blinnikov <olb@google.com> | Tue Apr 16 11:09:30 2024 +0000 |
committer | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | Wed Apr 17 18:31:17 2024 +0000 |
tree | e3678b9e00f3dd08b942fdd89475c3b8569fc3a3 | |
parent | a14ff5208775c7812ff2428abf8fd6f37bdccf81 [diff] |
Anisotropy correction for external displays only Previously anisotropy correciton could be applied to virtual and internal displays. This is because the source display may have anisotropy itself. This CL fixes this by checking that the sink is an external display. Bug: 327717050 Test: adb shell screenrecord ; check recording has no letterboxing (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:bccda389bd7c810a3ceee7eba3fd658a9add4945) (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:8c9a9e07692e92f643da4cd0d49e1bf5bf2adfb7) Merged-In: Ic97ea30fba2d5c30b8abaee90c49bcd833b5353e Change-Id: Ic97ea30fba2d5c30b8abaee90c49bcd833b5353e
diff --git a/services/core/java/com/android/server/wm/ContentRecorder.java b/services/core/java/com/android/server/wm/ContentRecorder.java index a914c07..dd86c40 100644 --- a/services/core/java/com/android/server/wm/ContentRecorder.java +++ b/services/core/java/com/android/server/wm/ContentRecorder.java
@@ -107,7 +107,10 @@ ContentRecorder(@NonNull DisplayContent displayContent) { this(displayContent, new RemoteMediaProjectionManagerWrapper(displayContent.mDisplayId), - new DisplayManagerFlags().isConnectedDisplayManagementEnabled()); + new DisplayManagerFlags().isConnectedDisplayManagementEnabled() + && !new DisplayManagerFlags() + .isPixelAnisotropyCorrectionInLogicalDisplayEnabled() + && displayContent.getDisplayInfo().type == Display.TYPE_EXTERNAL); } @VisibleForTesting