Romain Vimont
a2c8910006
Rename --no-mirror to --no-playback
...
This option impacts video and audio _playback_. For example, if we use
V4L2, the device is still "mirrored" (via V4L2), even if playback is
disabled. Therefore, "playback" is more approriate than "mirror".
The initial option --no-display option was renamed to --no-mirror by
commit 6928acdeac
, but this has never been
released, so it is ok to rename it one more time.
Refs #3978 <https://github.com/Genymobile/scrcpy/pull/3978#issuecomment-1549420103 >
PR #4033 <https://github.com/Genymobile/scrcpy/pull/4033 >
2023-05-27 09:55:38 +02:00
Romain Vimont
b11b363e8e
Add recording to aac file
...
It is just an alias for mp4.
PR #3978 <https://github.com/Genymobile/scrcpy/pull/3978 >
2023-05-08 17:11:34 +02:00
Romain Vimont
7321db6f28
Add recording to opus file
...
Use the FFmpeg opus muxer to record an opus file.
PR #3978 <https://github.com/Genymobile/scrcpy/pull/3978 >
2023-05-08 17:11:34 +02:00
Romain Vimont
d6bcde565f
Accept .m4a and .mka
...
These are just aliases for mp4 and mkv when there is no video stream.
PR #3978 <https://github.com/Genymobile/scrcpy/pull/3978 >
2023-05-08 17:11:34 +02:00
Romain Vimont
98f4f4e68a
Refactor command line checks
...
Several checks are performed when opts->record_filename is not NULL.
Group them in a single block.
PR #3978 <https://github.com/Genymobile/scrcpy/pull/3978 >
2023-05-08 17:11:34 +02:00
Romain Vimont
be86e14e05
Factorize record format parsing
...
Convert either the filename extension or the explicit record format
to a sc_record_format using the same function.
PR #3978 <https://github.com/Genymobile/scrcpy/pull/3978 >
2023-05-08 17:11:34 +02:00
Romain Vimont
8c650e53cd
Add --no-video
...
Similar to --no-audio, add --no-video to play audio only.
Fixes #3842 <https://github.com/Genymobile/scrcpy/issues/3842 >
PR #3978 <https://github.com/Genymobile/scrcpy/pull/3978 >
2023-05-08 17:11:34 +02:00
Romain Vimont
92483fe11b
Disable controls on --no-mirror
...
If mirroring is disabled, control must also be disabled.
PR #3978 <https://github.com/Genymobile/scrcpy/pull/3978 >
2023-05-08 16:41:01 +02:00
Romain Vimont
6928acdeac
Rename --no-display to --no-mirror
...
The option impacts both video and audio playback, so "no display" is not
an appropriate name.
PR #3978 <https://github.com/Genymobile/scrcpy/pull/3978 >
2023-05-08 16:40:58 +02:00
Romain Vimont
39544f34b4
Add --audio-output-buffer
...
On some systems, the SDL audio callback is not called frequently enough
(for example it requests 5ms of samples every 10ms), because the output
buffer is too small.
By default, we want to use a small value (5ms) to minimize latency and
buffer underrun, but if it does not work well, users need a way to
increase it.
Refs #3793 <https://github.com/Genymobile/scrcpy/issues/3793 >
2023-03-14 23:54:07 +01:00
Romain Vimont
c22c87eded
Fail on deprecated options
...
Suggest the video and audio specific options instead.
2023-03-12 02:04:58 +01:00
Romain Vimont
426dfbf21d
Remove dead code about the deprecated -F option
...
The -F option was already removed.
2023-03-12 02:04:58 +01:00
Romain Vimont
5512777404
Remove deprecated option --render-expired-frames
...
This option did nothing since it was deprecated. Totally remove it.
2023-03-12 02:04:58 +01:00
Romain Vimont
7da45c246e
Warn on ignored audio options
...
For raw audio codec, some audio options are ignored.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
d2952c7e93
Add --audio-codec=raw option
...
Add support for raw (PCM S16 LE) audio codec (a raw decoder is included
in FFmpeg).
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
df55bc2683
Add --audio-buffer
...
Expose an option to add a buffering delay (in milliseconds) before
playing audio.
This is similar to the options --display-buffer and --v4l2-buffer for
video frames.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
c1528cdca9
Add --require-audio
...
By default, scrcpy mirrors only the video when audio capture fails on
the device. Add an option to force scrcpy to fail if audio is enabled
but does not work.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
b65301f672
Add --list-displays
...
Add an option to list the device displays properly.
2023-03-10 22:22:15 +01:00
Romain Vimont
9196dc1563
Add --list-encoders
...
Add an option to list the device encoders properly.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
f9960e959f
Add --audio-encoder
...
Similar to --video-encoder, but for audio.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
b03c864c70
Add --audio-codec-options
...
Similar to --video-codec-options, but for audio.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
4601735e51
Add support for AAC audio codec
...
Add option --audio-codec=aac.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
839b842aa7
Add --audio-codec
...
Introduce the selection mechanism. Alternative codecs will be added
later.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
0870b8c8be
Add --audio-bit-rate
...
Add an option to configure the audio bit-rate.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
e694619d53
Rename --encoder to --video-encoder
...
This prepares the introduction of --audio-encoder.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
31555fa530
Rename --codec-options to --video-codec-options
...
This prepares the introduction of --audio-codec-options.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
9087e85c3f
Rename --bit-rate to --video-bit-rate
...
This prepares the introduction of --audio-bit-rate.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
cee40ca047
Rename --codec to --video-codec
...
This prepares the introduction of --audio-codec.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
a1802dab76
Remove default bit-rate on client side
...
If no bit-rate is passed, let the server use the default value (8Mbps).
This avoids to define a default value on both sides, and to pass the
default bit-rate as an argument when starting the server.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Romain Vimont
f60b5767f4
Force --no-audio if no display and no recording
...
The client does not use the audio stream if there is no display and no
recording (i.e. only V4L2), so disable audio so that the device does not
attempt to capture it.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
2023-03-10 22:22:15 +01:00
Simon Chan
3cf03e4a4b
Add --no-audio option
...
Audio will be enabled by default (when supported). Add an option to
disable it.
PR #3757 <https://github.com/Genymobile/scrcpy/pull/3757 >
Co-authored-by: Romain Vimont <rom@rom1v.com>
Signed-off-by: Romain Vimont <rom@rom1v.com>
2023-03-10 22:22:15 +01:00
Romain Vimont
fa99763668
Fix --encoder documentation
...
Mention that it depends on the codec provided by --codec (which is not
necessarily H264 anymore).
2023-03-10 22:22:15 +01:00
Romain Vimont
5d6bcc5966
Use enum for long options constants
...
This avoids to manually assign values.
2023-02-21 19:47:27 +01:00
Romain Vimont
0a151b96fe
Accept muxing AV1 into MP4 container
...
MP4 supports AV1.
Refs d2dce51038
2023-02-20 20:49:56 +01:00
Romain Vimont
25e2eb7d7c
Document default video codec
...
Mention the default option value, like for other commands.
2023-02-18 19:10:25 +01:00
Romain Vimont
280a9afda8
Fix command-line help typo
2023-02-18 18:11:34 +01:00
Romain Vimont
d2dce51038
Add support for AV1
...
Add option --codec=av1.
PR #3713 <https://github.com/Genymobile/scrcpy/pull/3713 >
2023-02-06 11:00:49 +01:00
Romain Vimont
4342c5637d
Add support for H265
...
Add option --codec=h265.
PR #3713 <https://github.com/Genymobile/scrcpy/pull/3713 >
Fixes #3092 <https://github.com/Genymobile/scrcpy/issues/3092 >
2023-02-06 11:00:49 +01:00
Romain Vimont
3e517cd40e
Add option to select video codec
...
Introduce the selection mechanism. Alternative codecs will be added in
further commits.
PR #3713 <https://github.com/Genymobile/scrcpy/pull/3713 >
2023-02-06 10:58:45 +01:00
Romain Vimont
0fca2ad830
Add option to not power on on start
...
By default, on start, the device is powered on. To prevent this
behavior, add a new option --no-power-on.
Fixes #3148 <https://github.com/Genymobile/scrcpy/issues/3148 >
PR #3210 <https://github.com/Genymobile/scrcpy/pull/3210 >
2022-04-28 19:12:52 +02:00
Romain Vimont
326897a0d4
Add missing mouse shortcuts in --help
...
Document 4th-click and 5th-click shortcuts.
Fixes #3122 <https://github.com/Genymobile/scrcpy/issues/3122 >
2022-04-25 18:35:06 +02:00
Romain Vimont
4ce7af42c6
Use $ANDROID_SERIAL if no selector is specified
...
Like adb, read the ANDROID_SERIAL environment variable to select a
device by serial if no explicit selection (-s, -d, -e or --tcpip=<addr>)
is provided via the command line.
Fixes #3111 <https://github.com/Genymobile/scrcpy/issues/3111 >
PR #3113 <https://github.com/Genymobile/scrcpy/pull/3113 >
2022-03-15 08:32:34 +01:00
Romain Vimont
b1dbc30072
Document exit status in --help
...
Refs #3085 <https://github.com/Genymobile/scrcpy/pull/3085 >
2022-03-10 09:13:21 +01:00
Romain Vimont
79ed83ab68
Reorder --tcpip option in cli
...
To keep options in alphabetic order.
2022-02-22 18:10:30 +01:00
Romain Vimont
73a5311ac6
Forbid HID input without OTG on Windows
...
On Windows, if the adb daemon is running, opening the USB device will
necessarily fail, so HID input is not possible.
Refs #2773 <https://github.com/Genymobile/scrcpy/issues/2773 >
PR #3011 <https://github.com/Genymobile/scrcpy/pull/3011 >
2022-02-20 17:39:42 +01:00
Romain Vimont
6ee75c0cff
Remove obsolete text in error message
...
The HID/OTG features are now available on all platforms.
PR #3011 <https://github.com/Genymobile/scrcpy/pull/3011 >
2022-02-20 17:39:30 +01:00
Romain Vimont
82a99f69ec
Remove "linux-only" mentions for HID/OTG features
...
HID/OTG features are not limited to Linux anymore.
PR #3031 <https://github.com/Genymobile/scrcpy/pull/3031 >
2022-02-20 17:27:43 +01:00
Romain Vimont
b4fd882ece
Fix typo
2022-02-20 17:21:25 +01:00
Romain Vimont
4b018be789
Add --print-fps to enable FPS counter on start
...
The FPS counter could be enabled/disabled via MOD+i.
Add a command line option to enable it on start. This is consistent with
other features like --turn-screen-off or --fullscreen.
Fixes #468 <https://github.com/Genymobile/scrcpy/issues/468 >
PR #3030 <https://github.com/Genymobile/scrcpy/pull/3030 >
2022-02-18 18:16:50 +01:00
Romain Vimont
ccbe370cc5
Add --no-cleanup option
...
It might be useful not to cleanup on exit, for example to leave the
screen turned off, or keep the server binary on the device (via the
server option "cleanup=false").
Fixes #1764 <https://github.com/Genymobile/scrcpy/issues/1764 >
PR #3020 <https://github.com/Genymobile/scrcpy/pull/3020 >
2022-02-15 19:25:57 +01:00