You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
automatic resolution change after turning stopped workingΒ #5908
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.
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 SCRCPY_SERVER_PATH=/path/to/this/scrcpy-server):
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.
Activity
rom1v commentedon Mar 7, 2025
Looks like your device does not trigger a display changed event as expected: e26bdb0 39d51ff
sprd-tmu commentedon Mar 7, 2025
Seems like a duplicate of #5881 and #5853, but with Android 15.
rom1v commentedon Mar 7, 2025
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 π
sprd-tmu commentedon Mar 7, 2025
Thanks a bunch in advance.
rom1v commentedon Mar 7, 2025
Given the work already done for this same problem for Android 14, the fix is in fact trivial:
Please replace this server in your 3.1 release (or set
SCRCPY_SERVER_PATH=/path/to/this/scrcpy-server):scrcpy-serverSHA-256: e5b4c0f10bd7985694d96a33f9be45097b2e9640971182fe1b79597fcfb2d4bsprd-tmu commentedon Mar 7, 2025
Replaced, tested and it works.
Work around broken display listener on Android 15
vintotal commentedon Mar 11, 2025
The provided patch also work for Pixel 7 Pro under Android 15 after Mars update.
Temujin0 commentedon Mar 11, 2025
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.
Work around broken display listener on Android 15