@@ -86,43 +86,141 @@ It accepts command-line arguments, listed by:
8686scrcpy --help
8787```
8888
89- For example, to decrease video bitrate to 2Mbps (default is 8Mbps):
89+ ## Features
90+
91+
92+ ### Reduce size
93+
94+ Sometimes, it is useful to mirror an Android device at a lower definition to
95+ increase performances.
96+
97+ To limit both width and height to some value (e.g. 1024):
9098
9199``` bash
92- scrcpy -b 2M
100+ scrcpy --max-size 1024
101+ scrcpy -m 1024 # short version
93102```
94103
95- To limit the video dimensions (e.g. if the device is 2540×1440, but the host
96- screen is smaller, or cannot decode such a high definition):
104+ The other dimension is computed to that the device aspect-ratio is preserved.
105+ That way, a device in 1920×1080 will be mirrored at 1024×576.
106+
107+
108+ ### Change bit-rate
109+
110+ The default bit-rate is 8Mbps. To change the video bitrate (e.g. to 2Mbps):
97111
98112``` bash
99- scrcpy -m 1024
113+ scrcpy --bit-rate 2M
114+ scrcpy -b 2M # short version
100115```
101116
102- The device screen may be cropped to mirror only part of the screen:
117+
118+ ### Crop
119+
120+ The device screen may be cropped to mirror only part of the screen.
121+
122+ This is useful for example to mirror only 1 eye of the Oculus Go:
103123
104124``` bash
105- scrcpy -c 1224:1440:0:0 # 1224x1440 at offset (0,0)
125+ scrcpy --crop 1224:1440:0:0 # 1224x1440 at offset (0,0)
126+ scrcpy -c 1224:1440:0:0 # short version
106127```
107128
108- If several devices are listed in ` adb devices ` , you must specify the _ serial_ :
129+ If ` --max-size ` is also specified, resizing is applied after cropping.
130+
131+
132+ ### Wireless
133+
134+ _ Scrcpy_ uses ` adb ` to communicate with the device, and ` adb ` can [ connect] to a
135+ device over TCP/IP:
136+
137+ 1 . Connect the device to the same Wi-Fi as your computer.
138+ 2 . Get your device IP address (in Settings → About phone → Status).
139+ 3 . Enable adb over TCP/IP on your device: ` adb tcpip 5555 ` .
140+ 4 . Unplug your device.
141+ 5 . Connect to your device: ` adb connect DEVICE_IP:5555 ` _ (replace ` DEVICE_IP ` )_ .
142+ 6 . Run ` scrcpy ` as usual.
143+
144+ It may be useful to decrease the bit-rate and the definition:
109145
110146``` bash
111- scrcpy -s 0123456789abcdef
147+ scrcpy --bit-rate 2M --max-size 800
148+ scrcpy -b2M -m800 # short version
112149```
113150
114- To show physical touches while scrcpy is running:
151+ [ connect ] : https://developer.android.com/studio/command-line/adb.html#wireless
152+
153+
154+ ### Record screen
155+
156+ It is possible to record the screen while mirroring:
115157
116158``` bash
117- scrcpy -t
159+ scrcpy --record file.mp4
160+ scrcpy -r file.mp4
161+ ```
162+
163+ "Skipped frames" are recorded, even if they are not displayed in real time (for
164+ performance reasons). Frames are _ timestamped_ on the device, so [ packet delay
165+ variation] does not impact the recorded file.
166+
167+ [ packet delay variation ] : https://en.wikipedia.org/wiki/Packet_delay_variation
168+
169+
170+ ### Multi-devices
171+
172+ If several devices are listed in ` adb devices ` , you must specify the _ serial_ :
173+
174+ ``` bash
175+ scrcpy --serial 0123456789abcdef
176+ scrcpy -s 0123456789abcdef # short version
118177```
119178
179+ You can start several instances of _ scrcpy_ for several devices.
180+
181+
182+ ### Fullscreen
183+
120184The app may be started directly in fullscreen:
121185
186+ ``` bash
187+ scrcpy --fullscreen
188+ scrcpy -f # short version
122189```
123- scrcpy -f
190+
191+ Fullscreen can then be toggled dynamically with ` Ctrl ` +` f ` .
192+
193+
194+ ### Show touches
195+
196+ For presentations, it may be useful to show physical touches (on the physical
197+ device).
198+
199+ Android provides this feature in _ Developers options_ .
200+
201+ _ Scrcpy_ provides an option to enable this feature on start and disable on exit:
202+
203+ ``` bash
204+ scrcpy --show-touches
205+ scrcpy -t
124206```
125207
208+ Note that it only shows _ physical_ touches (with the finger on the device).
209+
210+
211+ ### Forward audio
212+
213+ Audio is not forwarded by _ scrcpy_ .
214+
215+ There is a limited solution using [ AOA] , implemented in the [ ` audio ` ] branch. If
216+ you are interested, see [ issue 14] .
217+
218+
219+ [ AOA ] : https://source.android.com/devices/accessories/aoa2
220+ [ `audio` ] : https://github.com/Genymobile/scrcpy/commits/audio
221+ [ issue 14 ] : https://github.com/Genymobile/scrcpy/issues/14
222+
223+
126224## Shortcuts
127225
128226 | Action | Shortcut |
0 commit comments