ws-scrcpy icon indicating copy to clipboard operation
ws-scrcpy copied to clipboard

rotation

Open zephyr-peak opened this issue 2 years ago • 3 comments

Hi, may I ask if there is currently support for setting the rotation of mobile phones in four directions (0, 90,270,360), or if there are any suggestions for implementation

zephyr-peak avatar Apr 28 '23 07:04 zephyr-peak

Hi. It is not supported. It will require to modify both ws-scrcpy client and scrcpy-server. Here are parts of the code that might interest you:

https://github.com/Genymobile/scrcpy/blob/cb20bcb16f4ca191e237c8744a7c2e6d29701d60/server/src/main/java/com/genymobile/scrcpy/Controller.java#L172-L174 https://github.com/Genymobile/scrcpy/blob/cb20bcb16f4ca191e237c8744a7c2e6d29701d60/server/src/main/java/com/genymobile/scrcpy/Device.java#L318-L334

https://github.com/NetrisTV/ws-scrcpy/blob/ee87ba65258057e76af7c1e67e7e6633361a62cb/src/app/controlMessage/CommandControlMessage.ts#L30 https://github.com/NetrisTV/ws-scrcpy/blob/ee87ba65258057e76af7c1e67e7e6633361a62cb/src/app/googDevice/toolbox/GoogMoreBox.ts#L174

drauggres avatar Apr 30 '23 10:04 drauggres

Also https://android.googlesource.com/platform/frameworks/base/+/master/core/java/android/view/IWindowManager.aidl#288

drauggres avatar Apr 30 '23 10:04 drauggres

Okay, thank you very much for your patient answer

zephyr-peak avatar May 04 '23 03:05 zephyr-peak