scrcpy
scrcpy copied to clipboard
Software renderer on macOS only displays top left quadrant
Environment
- OS: macOS 11.6
- scrcpy version:
scrcpy 1.19
dependencies:
- SDL 2.0.14
- libavcodec 58.134.100
- libavformat 58.76.100
- libavutil 56.70.100
- installation method: NixOS/nixpkgs@ee084c02040e864eeeb4cf4f8538d92f7c675671
- device model: SM-A505FN
- Android version: 11
Describe the bug A clear and concise description of what the bug is.
scrcpy only renders the top left quadrant in software renderer mode. This does not happen with opengl or metal.
It'd probably be best to use one of those by default instead of software rendering.
Refs https://github.com/Genymobile/scrcpy/issues/1673#issuecomment-673519500
I had the same issue: only the top-left corner was visible. My solution was:
scrcpy --render-driver metal
I've tried all drivers and 2 of them worked: metal and opengl.
Environment
- MacBookAir M1 - MacOS 13.0 (Ventura)
$ scrcpy --version
scrcpy 1.24
Dependencies (compiled / linked):
- SDL: 2.0.22 / 2.0.22
- libavcodec: 58.134.100 / 58.134.100
- libavformat: 58.76.100 / 58.76.100
- libavutil: 56.70.100 / 56.70.100
- libusb: - / 1.0.26
Installation:
nix-shell -p scrcpy -I nixpkgs=https://github.com/NixOS/nixpkgs/archive/ee01de29d2f58d56b1be4ae24c24bd91c5380cea.tar.gz
Why doesn't scrcpy default to metal or OGL?
Why doesn't scrcpy default to metal or OGL?
Scrcpy leave SDL choose the render driver.
If you explicitly set --render-driver=, then it just sets an hint (SDL_HINT_RENDER_DRIVER for SDL:
https://github.com/Genymobile/scrcpy/blob/b4caa483dd6682279170b5ec61963e6239f15072/app/src/scrcpy.c#L95-L97
So maybe a SDL issue?
SDL says:
By default the first one in the list that is available on the current platform is chosen.
Oh, maybe it's related to nix? (both of you use nix)
Could certainly be a packaging bug on our side. How is this list determined?