-
-
Notifications
You must be signed in to change notification settings - Fork 11.5k
automatic resolution change after turning stopped working #5908
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I just upgraded my Pixel 8 after reading this issue, and I can reproduce. At least, the timing is perfect, I should have some free time this evening. I know what I'm going to do 😅 |
Thanks a bunch in advance. |
Given the work already done for this same problem for Android 14, the fix is in fact trivial: diff --git server/src/main/java/com/genymobile/scrcpy/video/DisplaySizeMonitor.java server/src/main/java/com/genymobile/scrcpy/video/DisplaySizeMonitor.java
index ff863aa86..b6d77181f 100644
--- server/src/main/java/com/genymobile/scrcpy/video/DisplaySizeMonitor.java
+++ server/src/main/java/com/genymobile/scrcpy/video/DisplaySizeMonitor.java
@@ -23,7 +23,7 @@ public class DisplaySizeMonitor {
// On Android 14, DisplayListener may be broken (it never sends events). This is fixed in recent Android 14 upgrades, but we can't really
// detect it directly, so register a DisplayWindowListener (introduced in Android 11) to listen to configuration changes instead.
- private static final boolean USE_DEFAULT_METHOD = Build.VERSION.SDK_INT != AndroidVersions.API_34_ANDROID_14;
+ private static final boolean USE_DEFAULT_METHOD = Build.VERSION.SDK_INT < AndroidVersions.API_34_ANDROID_14;
private DisplayManager.DisplayListenerHandle displayListenerHandle;
private HandlerThread handlerThread; Please replace this server in your 3.1 release (or set
|
Replaced, tested and it works. |
The provided patch also work for Pixel 7 Pro under Android 15 after Mars update. |
Pixel 6 fully updated. Running Linux fedora 41 fully up to date . Updated scrcpy about an hour ago. Test just now and I'm having the same problem. Earlier today before I updated scrcpy it was working fine. wonder if any one here can teach a man to fish? I usually wait for the fix to be done by the coders of scrcpy. I've been trying to add the patch in this thread with no luck. The problem is that that my phones battery is over heating and it has swelled to the point that it has popped the screen out lol. ordered a new battery from ifixit wont be here till Saturday the latest. so I try to keep the screen off phone calls and the hot spot for the cpu only. the battery stays cool. i figure if I can install the patch and keep the screen off I can you the phone as normal on the pc screen. Soon on the 20th I get a new amount of hot spot data so I can use the cpu when Im on the road but I would still like to learn this for future use Thanks anyone. |
A recent Android 15 upgrade broke the display listener (again). Use the alternative method for Android >= 14. Fixes Genymobile#5908 <Genymobile#5908>
Environment
Describe the bug
My Google Pixel 8a got a system update this week to build number BP1A.250305.019 of Android 15. In the previous build of Android 15, turning the phone changed the screen resolution of scrcpy from landscape to portrait automatically. In this build, this stopped working.
Before the update, turning the phone printed
INFO: Texture: 2400x1080
and changed the resolution.Now it looks like this, without resolution change:
The text was updated successfully, but these errors were encountered: