scrcpy icon indicating copy to clipboard operation
scrcpy copied to clipboard

Blank screen when connected to Android ATD virtual device

Open technoir42 opened this issue 1 year ago • 2 comments

  • [x] I have read the FAQ.
  • [x] I have searched in existing issues.

Environment

  • OS: macOS
  • scrcpy version: 2.3.1
  • installation method: brew
  • device model: Pixel 5 virtual device
  • Android version: Android 13 ATD with Google APIs

Describe the bug scrcpy shows a blank black screen when connected to ATD virtual device. When running a test, the screen flashes for fraction of a second, but the app doesn't seem to get rendered properly. Apps launched via adb shell manually aren't displayed either.

To reproduce, configure Gradle-managed device as follows:

android {
  testOptions {
    managedDevices {
      localDevices {
        pixel5 {
          device = "Pixel 5"
          apiLevel = 33
          systemImageSource = "google-atd"
        }
      }
    }
  }
}

Run instrumented tests on the Gradle-managed device as follows:

./gradlew pixel5DebugAndroidTest

Terminal output:

$ scrcpy -n -s emulator-5554 --no-audio --render-driver=software
scrcpy 2.3.1 <https://github.com/Genymobile/scrcpy>
INFO: ADB device found:
INFO:     --> (tcpip)  emulator-5554                   device  Android_ATD_built_for_arm64
/opt/homebrew/Cellar/scrcpy/2.3.1/share/scrcpy/scrcpy-server: 1 file pushed, 0 skipped. 109.1 MB/s (66007 bytes in 0.001s)
[server] INFO: Device: [Google] google Android ATD built for arm64 (Android 13)
INFO: Renderer: software
INFO: Texture: 1080x2336

If I change to regular, non-ATD device, display output gets forwarded properly.

technoir42 avatar Jan 23 '24 12:01 technoir42

On those ATD devices, can you capture using adb shell screenrecord /sdcard/file.mp4?

rom1v avatar Jan 23 '24 12:01 rom1v

Black screen issue for Murena 2 phone running e/OS; Please see

https://github.com/Genymobile/scrcpy/issues/3940

I included a description of problem in comments.

Jaz-z avatar Feb 03 '24 02:02 Jaz-z