Results 1 to 3 of 3

Thread: Handling mouse movement with Xinput

  1. #1
    Join Date
    Sep 2024
    Beans
    5

    Handling mouse movement with Xinput

    Hi everyone. I'm making a custom game engine and recently I changed keyboard and mouse handling from X to Xinput in order to be able to get raw input and mouse offsets instead of coordinates. But the problem is that XI_RawMotion is sent only when the pointer is inside the window. Which is quite logical and works well in fullscreen mode but is not acceptable in windowed mode. Using XIGrabDevice didn't change the situation, or maybe I used it in a wrong way. Are there any ideas about how to turn on an exclusive mode or something?

  2. #2
    Join Date
    Mar 2010
    Location
    Been there, meh.
    Beans
    Hidden!
    Distro
    Ubuntu

    Re: Handling mouse movement with Xinput

    First thing to ask is whether Xinput works with Wayland. Coding for Xorg (aka X11) is a short-term idea at this point.

  3. #3
    Join Date
    Sep 2024
    Beans
    5

    Re: Handling mouse movement with Xinput

    Well, typing "echo $XDG_SESSION_TYPE" in Terminal gave the result "wayland". So in general it works. But yes, I'll also try to research input handling on Wayland, just in case

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •