Open source

Scrcpy v4.0 adds flex displays and aspect‑ratio lock for smoother Android mirroring

At a glance:

  • scrcpy 4.0 switches from SDL2 to SDL3, locking aspect ratio during window resize
  • New “flex” display lets individual Android apps run in resizable desktop‑style windows
  • Added –keep‑active flag, live camera controls and clearer disconnection alerts

What’s new in scrcpy 4.0

Scrcpy, the open‑source screen‑copy utility that lets you control an Android device from a PC, has reached a major milestone with version 4.0. The most visible change is the migration from SDL2 to SDL3, a low‑level multimedia framework that now gives the program native control over the device’s aspect ratio. When you drag the edges of the scrcpy window, the Android UI scales without the familiar black bars that previously appeared. Users who prefer the old letterboxing can still obtain it with the --no-window-aspect-ratio-lock flag.

Beyond the visual polish, the update introduces a “flex” display mode. Rather than merely mirroring the phone’s physical screen, flex creates a virtual Android display that can be resized independently of the client window. This means you can launch a single Android app—say, a messaging client or a media player—in its own resizable window that behaves much like a native desktop application. The feature is especially handy for developers testing UI responsiveness or power users who want a more integrated workflow.

Quality‑of‑life commands and UI tweaks

The 4.0 release bundles several smaller but impactful enhancements. The historic --stay-awake flag, which altered the device’s global screen‑timeout setting, is superseded by a cleaner --keep-active command. This new flag simply sends periodic user‑activity events, keeping the screen on without touching system‑level preferences.

If you use your phone as a webcam or stream its camera feed, scrcpy now exposes live hardware controls. You can adjust flash, optical zoom, digital zoom, and other camera parameters on the fly, directly from the PC interface. This eliminates the need to switch back to the phone for quick tweaks during a live broadcast.

Connection stability has also been improved. Previously, an ADB drop would cause the scrcpy window to disappear instantly, leaving users unsure whether the program had crashed. The new version shows a clear “disconnected” icon for two seconds before gracefully closing the window, giving a more predictable user experience.

How to get scrcpy 4.0

The full changelog and binaries are hosted on GitHub. To upgrade, download the appropriate package for Windows, macOS, or Linux, or build from source using the instructions provided in the repository’s README. Existing users can simply replace the old executable; the command‑line interface remains backward compatible, with the new flags added as optional arguments.

Developers and power users are encouraged to test the flex display by launching an app with the --display=flex option (syntax may vary; see the changelog for exact usage). Community feedback has been instrumental in shaping these features, and the project maintainers continue to solicit bug reports and suggestions via the issue tracker.

What this means for the Android mirroring ecosystem

Scrcpy has long been the go‑to free tool for developers, streamers, and anyone who needs precise control over an Android device from a desktop. By embracing SDL3 and adding desktop‑style window management, the project narrows the gap between mobile and PC experiences. Competing commercial solutions that charge for similar functionality now face a more capable open‑source alternative, which could shift market expectations around latency, UI fidelity, and feature depth.

The addition of live camera controls also positions scrcpy as a viable option for remote production workflows, where quick adjustments to a phone‑based camera are essential. As more creators adopt phone cameras for cost‑effective streaming, the tool’s new capabilities may accelerate that trend.

Overall, scrcpy 4.0 demonstrates how incremental, community‑driven development can deliver user‑centric innovations that rival proprietary software, reinforcing the importance of open‑source projects in the broader tech landscape.

Editorial SiliconFeed is an automated feed: facts are checked against sources; copy is normalized and lightly edited for readers.

FAQ

How does the new aspect‑ratio lock work in scrcpy 4.0?
The upgrade to SDL3 gives scrcpy access to APIs that enforce the device’s native aspect ratio when the desktop window is resized. This prevents the black bars that appeared with SDL2. Users who still want letterboxing can disable the lock with the `--no-window-aspect-ratio-lock` flag.
What is the “flex” display feature and how can I use it?
Flex creates a virtual Android display that can be resized independently of the main scrcpy window. To launch an app in a flex window, start scrcpy with the appropriate flag (e.g., `scrcpy --display=flex`). The app then appears in its own resizable desktop‑style window, allowing you to treat it like native software.
Do I need to change any settings on my phone to keep the screen awake with the new flag?
No. The new `--keep-active` flag replaces the older `--stay-awake` option. It sends periodic activity signals to Android, keeping the screen on without modifying the system’s global screen‑timeout settings, so your phone’s power‑saving configuration remains untouched.

More in the feed

Prepared by the editorial stack from public data and external sources.

Original article