Romain Vimont
7bb91638ad
Improve FAQ
2020-03-19 19:22:58 +01:00
Yogev Boaron Ben-Har
bc7508427b
Add scoop instructions for Windows
...
PR #1202 <https://github.com/Genymobile/scrcpy/pull/1202 >
Signed-off-by: Romain Vimont <rom@rom1v.com>
2020-03-14 17:11:49 +01:00
Romain Vimont
24ade6ad77
Simplify Chocolatey documentation
2020-03-14 17:07:20 +01:00
Romain Vimont
c396758b4e
Remove link to Windows 32 bits release
...
Binaries created with MinGW (even a simple Hello World) are detected as
malware by some anti-virus. For some reason, only the 32 bits version of
scrcpy is impacted.
Since users should use the 64 bits version by default anyway, remove the
link to the 32 bits version from the main page.
The 32 bits release is still available in the "releases" tab.
See <https://github.com/Genymobile/scrcpy/issues/1102 >
2020-03-03 21:39:27 +01:00
George Stamoulis
f903cd376d
Documentation rectifications
...
PR #1151 <https://github.com/Genymobile/scrcpy/pull/1151 >
Signed-off-by: Romain Vimont <rom@rom1v.com>
2020-02-16 16:04:17 +01:00
Camilo Martinez
e8127375ae
Add Chocolatey for Windows install
...
PR #1144 <https://github.com/Genymobile/scrcpy/pull/1144 >
Signed-off-by: Romain Vimont <rom@rom1v.com>
2020-02-15 22:26:30 +01:00
Romain Vimont
1144f64214
Indicate that -s can also be used for TCP/IP
2020-02-06 18:42:08 +01:00
Romain Vimont
39356602ed
Mention scrcpy Debian package in README
2020-01-19 16:19:51 +01:00
Romain Vimont
0fb22c3e98
Happy new year 2020!
2020-01-19 16:04:20 +01:00
Romain Vimont
31bd95022b
Update links to v1.12.1 in README and BUILD
2019-12-10 17:59:44 +01:00
Romain Vimont
4687a0ebac
Bump version to 1.12.1
2019-12-10 10:07:48 +01:00
Romain Vimont
6965d051ae
Limit bitrate range to 31 bits integer
...
A proper solution could be to use "long long" instead (guaranteed to be
at least 64 bits), but it adds its own problems (e.g. "%lld" is not
supported as a printf format on all platforms).
In practice, we don't need such high values, so keep it simple.
Fixes #995 <https://github.com/Genymobile/scrcpy/issues/995 >
2019-12-10 09:28:27 +01:00
Romain Vimont
71df3175bd
Update links to v1.12 in README and BUILD
2019-12-09 23:52:26 +01:00
Romain Vimont
a0f8e7fd9f
Bump version to 1.12
2019-12-09 23:24:43 +01:00
Romain Vimont
e4cebc8d4c
Do not build tests in release mode
...
Assertions would not be executed.
And as a side effect, it causes "unused variable" warnings.
2019-12-09 23:24:39 +01:00
Romain Vimont
ba1b36758e
Define SDL_MAIN_HANDLED in all tests
...
Each test defines its own main() function. If this flag is not set, then
SDL redefines it to SDL_main(), causing compilation failures.
2019-12-09 23:24:39 +01:00
Romain Vimont
ad92a192b5
Fix meson.build codestyle
2019-12-09 23:00:55 +01:00
Romain Vimont
81a8e503e5
Describe screen rotation shortcut in README
2019-12-09 22:51:27 +01:00
Romain Vimont
242e57d69b
Merge branch 'master' into dev
2019-12-09 22:37:20 +01:00
Romain Vimont
024c2f7e6b
Configure log priority early
...
The log priority must be configured before parsing command-line
arguments, in order to get logs as expected.
2019-12-09 22:31:14 +01:00
Romain Vimont
1eae139b6e
Add missing consts
...
String parsing functions should not be able to modify their input.
2019-12-09 22:30:48 +01:00
Romain Vimont
419c869c9c
Use ARRAY_LEN() macro in tests
2019-12-09 20:59:11 +01:00
Romain Vimont
929bf48c7e
Add tests for command-line parsing
2019-12-08 23:19:01 +01:00
Romain Vimont
d950383b72
Move command-line parsing to a separate file
2019-12-08 23:18:57 +01:00
Romain Vimont
61274a7cdb
Factorize integer argument parsing
...
Add util functions for integer parsing (with tests), and factorize
integer argument parsing to avoid code duplication.
2019-12-08 21:19:53 +01:00
Romain Vimont
64bcac9157
Refuse to push a non-regular file server
...
If SCRCPY_SERVER_PATH points to a directory, then a directory will be
pushed to /data/local/tmp/scrcpy-server.jar.
When executing it, app_process will just abort and leave the directory
on the device, causing scrcpy to always fail.
To avoid the problem, check that the server is a regular file before
pushing it.
Closes #956 <https://github.com/Genymobile/scrcpy/issues/956 >
2019-12-05 21:07:11 +01:00
Romain Vimont
3259c60b22
Fix test compilation on mingw
...
Including SDL2/SDL.h redefines main to SDL_main by default.
2019-12-05 21:06:49 +01:00
Romain Vimont
e0b117de13
Fix checkstyle warning
2019-12-05 21:05:45 +01:00
Romain Vimont
eb0f339271
Add shortcut to rotate screen
...
On Ctrl+r, disable auto-rotation (if enabled), set the screen rotation
and re-enable auto-rotation (if it was enabled).
Closes #11 <https://github.com/Genymobile/scrcpy/issues/11 >
2019-12-04 22:03:25 +01:00
Romain Vimont
bdd05b4a16
Refactor wrappers for Android SDK classes
...
Internally, a failure to invoke a method via reflection was partially
managed using exceptions, partially using a null return value.
Handle all errors at the same place, by not catching
NoSuchMethodException too early.
2019-12-04 19:34:20 +01:00
Romain Vimont
525d6d4a75
Try new methods before legacy ones
...
Use the legacy methods when the new ones do not exist.
2019-12-04 19:32:38 +01:00
Romain Vimont
4041043d1c
Merge pull request #967 into dev
...
Add some tests
<https://github.com/Genymobile/scrcpy/pull/967 >
2019-12-04 19:25:58 +01:00
Yu-Chen Lin
fbc86a616c
Correct coding style
...
Signed-off-by: Yu-Chen Lin <npes87184@gmail.com>
2019-12-04 19:24:59 +01:00
Yu-Chen Lin
b2bf25c52c
Add test_buffer_util
...
Signed-off-by: Yu-Chen Lin <npes87184@gmail.com>
2019-12-04 19:24:59 +01:00
Yu-Chen Lin
5eeaed09ae
Add test_strquote
...
Signed-off-by: Yu-Chen Lin <npes87184@gmail.com>
2019-12-04 19:24:59 +01:00
Romain Vimont
3100533e56
Fix "natural scrolling"
...
> Movements down (scroll backward) generate negative y values and up
> (scroll forward) generate positive y values.
> If direction is SDL_MOUSEWHEEL_FLIPPED the values in x and y will be
> opposite. Multiply by -1 to change them back.
<https://wiki.libsdl.org/SDL_MouseWheelEvent#Remarks >
The x and y values already take the scrolling configuration into
account. Reversing the values when the direction is flipped cancels the
scrolling configuration.
Therefore, just ignore the direction field.
Fixes <https://github.com/Genymobile/scrcpy/issues/966 >
2019-12-03 21:10:43 +01:00
Seb Leo
684e0abb74
Update BUILD.md to install adb package
...
PR <https://github.com/Genymobile/scrcpy/pull/965 >
Signed-off-by: Romain Vimont <rom@rom1v.com>
2019-12-03 16:05:23 +01:00
Romain Vimont
86fcd89d80
Fix max size default value
...
Suggested-by: jurkov
Closes <https://github.com/Genymobile/scrcpy/issues/978 >
2019-12-03 12:07:36 +01:00
Romain Vimont
8a694a9785
Suggest workaround for error 0xfffffc0e
...
When the hardware encoder is not able to encode at the given definition,
it fails with an error 0xfffffc0e.
It is documented in the FAQ:
<https://github.com/Genymobile/scrcpy/blob/master/FAQ.md#i-get-an-error-could-not-open-video-stream >
But it is better to directly suggest the workaround in the console.
2019-11-30 10:46:22 +01:00
Romain Vimont
26529d377f
Use virtual device id to avoid NPE
...
Inject mouse events using id -1 (virtual device) instead of 0 which
does not exist (and causes the InputDevice to be null).
Fixes <https://github.com/Genymobile/scrcpy/issues/962 >
2019-11-29 14:31:19 +01:00
Romain Vimont
15a206b7fc
Assert return value of mutex functions
...
Mutex functions may only fail due to a programming error.
Use assertions in debug builds, and ignore the value in release builds.
2019-11-27 21:40:58 +01:00
Romain Vimont
d0f5a7fd9f
Remove unused includes
...
No mutex is used in decoder.c and stream.c.
2019-11-27 21:40:54 +01:00
Romain Vimont
510caff0cd
Replace SDL_assert() by assert()
...
SDL_assert() open a dialog on assertion failure.
There is no reason not to use assert() directly.
2019-11-27 21:19:46 +01:00
Romain Vimont
b5ebb234dd
Replace BUILD_DEBUG by NDEBUG
...
Use the "standard" NDEBUG definition, which is used by assert().
2019-11-27 21:11:52 +01:00
Romain Vimont
73e8ec1b35
Remove path argument from cmd_execute()
...
It is always equal to argv[0] (or not used on Windows).
2019-11-27 21:11:52 +01:00
Romain Vimont
8dc11a0286
Fix warnings on Windows
...
fix warnings reported with -Dwarning_level=2 on Windows.
2019-11-27 21:11:52 +01:00
Romain Vimont
06104a701b
Fix windows build
...
Utilities have been moved to util/, but includes had not been updated
in Windows-specific files.
Ref: dfd0707a29
2019-11-27 13:25:56 +01:00
yangfl
8bc056b9c6
Fix manpage format
2019-11-27 10:58:17 +01:00
Romain Vimont
7637a113e3
Compile with warning_level=2 by default
2019-11-26 09:22:20 +01:00
Romain Vimont
31d9d56117
Fix warnings
...
Fix warnings reported with -Dwarning_level=2.
2019-11-26 09:10:41 +01:00