Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mouse input is stuttering on Windows #37

Open
TermoZour opened this issue Oct 28, 2020 · 10 comments
Open

mouse input is stuttering on Windows #37

TermoZour opened this issue Oct 28, 2020 · 10 comments

Comments

@TermoZour
Copy link

TermoZour commented Oct 28, 2020

The lib is working perfectly fine on Linux (to be exact, Pop!OS 20.10)
On Windows, the mouse stutters (like it doesn't have enough resolution). You can see it jump from Point A to Point B when swiping fast. video here

The smooth one is moving the mouse directly, the laggy one is using the reMarkable.

@Evidlo
Copy link
Owner

Evidlo commented Oct 29, 2020 via email

@TermoZour
Copy link
Author

TermoZour commented Oct 29, 2020 via email

@Evidlo
Copy link
Owner

Evidlo commented Oct 29, 2020

You could try this snippet and see how it performs. This will move your mouse around in a circle.

import math
from pynput.mouse import Controller
import time

start = time.time()

mouse = Controller()

mouse.move(100, 100)

N = 100
for n in range(2 * N):
    rad = 2 * math.pi * n / N

    mouse.position = (
        200 * math.cos(rad) + 500,
        200 * math.sin(rad) + 500
    )

    time.sleep(.01)


print('total:', time.time() - start)

@TermoZour
Copy link
Author

It works smoothly. video here

@petergroves81
Copy link

I'm using remarkable_mouse on Windows 10. The cursor seems to move OK but when I try to write or draw something (in Windows Journal or Paint 3D) nothing appears on screen until I lift the pen from the ReMarkable, whereupon a straight line appears on my screen joining the starting point and the finishing point.

@Evidlo
Copy link
Owner

Evidlo commented Jan 7, 2021

Here is a stripped down version of the code which should help figure out what's causing the latency.

@TermoZour
Copy link
Author

I've just tested it and I still get the same weird latency.

@Evidlo
Copy link
Owner

Evidlo commented Jan 8, 2021

Right, the purpose of that code is just to make it easier for others to poke around and figure out the cause.

@Evidlo
Copy link
Owner

Evidlo commented Jan 15, 2021

I've narrowed the problem down a bit on Windows: paramiko/paramiko#1801

@DDorch
Copy link

DDorch commented Jan 24, 2021

@petergroves81, I had the same issue on Paint3D but it works fine on Gimp. (I used the rm2 branch with a Remarkable2).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants