scrcpy: scrcpy and Force Touch Detector conflict (xposed plugin)

scrcpy 和 Force Touch Detector 冲突,会使点击操作变成大面积按压。

The conflict between scrcpy and Force Touch Detector will make the click operation become a large area pressing.

  • I have read the FAQ.
  • I have searched in existing issues.

Environment

  • OS: [e.g. Debian, Windows, macOS…]
  • scrcpy version: [e.g. 1.12.1]
  • installation method: [e.g. manual build, apt, snap, brew, Windows release…]
  • device model:
  • Android version: [e.g. 10]

Describe the bug A clear and concise description of what the bug is.

On errors, please provide the output of the console (and adb logcat if relevant).

Please paste terminal output in a code block.

Please do not post screenshots of your terminal, just post the content as text instead.

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Comments: 20

Commits related to this issue

Most upvoted comments

I might merge device_id_0 into .dev

Here are binaries for this branch (to be replaced in v1.17 release):

  • scrcpy.exe SHA256: eaf3033a76d41572d99222fb1ca0ce5337cccdafe84330b2dad13b6fb1c2737d
  • scrcpy-server SHA256: e19182a8e8b68b58865c4de7764e54aa30328c2edbdc8a9877e0d81ae5cb6198

完美,现在在我的手机上一切正常。 非常感谢你仍在为我提供支持!🤞

Perfect, everything works fine on my phone now. Thank you very much for supporting me all the time!🤞

scrcpy for some reason sends a perfect 1.0

Hmm, indeed:

https://github.com/Genymobile/scrcpy/blob/f8524a2be738e6471ed2e48265f2663d8c21c0be/server/src/main/java/com/genymobile/scrcpy/Controller.java#L48

For a touch screen or touch pad, reports the approximate size of the contact area in relation to the maximum detectable size for the device. The value is normalized to a range from 0 (smallest detectable size) to 1 (largest detectable size), although it is not a linear scale.

https://developer.android.com/reference/android/view/MotionEvent#AXIS_SIZE

Try with:

diff --git a/server/src/main/java/com/genymobile/scrcpy/Controller.java b/server/src/main/java/com/genymobile/scrcpy/Controller.java
index 84780239..d8059b43 100644
--- a/server/src/main/java/com/genymobile/scrcpy/Controller.java
+++ b/server/src/main/java/com/genymobile/scrcpy/Controller.java
@@ -45,7 +45,7 @@ public class Controller {
 
             MotionEvent.PointerCoords coords = new MotionEvent.PointerCoords();
             coords.orientation = 0;
-            coords.size = 1;
+            coords.size = 0;
 
             pointerProperties[i] = props;
             pointerCoords[i] = coords;