mirror of
https://github.com/Genymobile/scrcpy.git
synced 2025-09-11 03:55:47 +00:00
Document virtual display and "start app" features
PR #5370 <https://github.com/Genymobile/scrcpy/pull/5370>
This commit is contained in:
parent
566b5be0f6
commit
381fe95867
3 changed files with 79 additions and 0 deletions
|
@ -78,3 +78,48 @@ By default, on start, the device is powered on. To prevent this behavior:
|
|||
```bash
|
||||
scrcpy --no-power-on
|
||||
```
|
||||
|
||||
|
||||
## Start Android app
|
||||
|
||||
To list the Android apps installed on the device:
|
||||
|
||||
```bash
|
||||
scrcpy --list-apps
|
||||
```
|
||||
|
||||
An app, selected by its package name, can be launched on start:
|
||||
|
||||
```
|
||||
scrcpy --start-app=org.mozilla.firefox
|
||||
```
|
||||
|
||||
This feature can be used to run an app in a [virtual
|
||||
display](virtual_display.md):
|
||||
|
||||
```
|
||||
scrcpy --new-display=1920x1080 --start-app=org.videolan.vlc
|
||||
```
|
||||
|
||||
The app can be optionally forced-stop before being started, by adding a `+`
|
||||
prefix:
|
||||
|
||||
```
|
||||
scrcpy --start-app=+org.mozilla.firefox
|
||||
```
|
||||
|
||||
For convenience, it is also possible to select an app by its name, by adding a
|
||||
`?` prefix:
|
||||
|
||||
```
|
||||
scrcpy --start-app=?firefox
|
||||
```
|
||||
|
||||
But retrieving app names may take some time (sometimes several seconds), so
|
||||
passing the package name is recommended.
|
||||
|
||||
The `+` and `?` prefixes can be combined (in that order):
|
||||
|
||||
```
|
||||
scrcpy --start-app=+?firefox
|
||||
```
|
||||
|
|
26
doc/virtual_display.md
Normal file
26
doc/virtual_display.md
Normal file
|
@ -0,0 +1,26 @@
|
|||
# Virtual display
|
||||
|
||||
## New display
|
||||
|
||||
To mirror a new virtual display instead of the device screen:
|
||||
|
||||
```bash
|
||||
scrcpy --new-display=1920x1080
|
||||
scrcpy --new-display=1920x1080/420 # force 420 dpi
|
||||
scrcpy --new-display # use the main display size and density
|
||||
scrcpy --new-display -m1920 # ... scaled to fit a max size of 1920
|
||||
scrcpy --new-display=/240 # use the main display size and 240 dpi
|
||||
```
|
||||
|
||||
## Start app
|
||||
|
||||
On some devices, a launcher is available in the virtual display.
|
||||
|
||||
When no launcher is available, the virtual display is empty. In that case, you
|
||||
must [start an Android app](device.md#start-android-app).
|
||||
|
||||
For example:
|
||||
|
||||
```bash
|
||||
scrcpy --new-display=1920x1080 --start-app=org.videolan.vlc
|
||||
```
|
Loading…
Add table
Add a link
Reference in a new issue