Results 1 to 2 of 2
Hi everybody, i am write a module (fakemouse) which is base swinput to fake mouse event. My module can fake mouse click ( left, right and middle button) well, but ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 04-26-2008 #1
- Join Date
- Apr 2008
Ask about mouse motion event
Hi everybody, i am write a module (fakemouse) which is base swinput to fake mouse event. My module can fake mouse click ( left, right and middle button) well, but it had some problem with mouse 's moving.
I use function input_report_rel( ) to change position of mouse from current position (assume (x,y)) to
position (x + dx, y+dy)
input_report_rel(fkmouse.idev, REL_X, dx); input_report_rel(fkmouse.idev, REL_Y, dy); input_sync(fkmouse.idev);
Last edited by 5primes; 04-26-2008 at 08:18 PM. Reason: attach file
- 04-28-2008 #2
I don't completely understand what your problem is, but if you are expecting the mouse to move "slowly" so you can see it travel from (x,y) to (x+dx, y+dy) then your got to do some intermediate stepping. i.e.: you have to provide a programming loop of some type to "visually see" this movement.
As the fake pointer does move from its source point (x,y) to destination point (x+dx, y+dy) is that not exactly as you would expect it to do?
This is certainly not a Kernel issue, more likely the driver implementation.