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

Non-Exclusive X11 Linux Mouse Is Offset #93

Open
VENTDEV opened this issue Jan 28, 2024 · 0 comments
Open

Non-Exclusive X11 Linux Mouse Is Offset #93

VENTDEV opened this issue Jan 28, 2024 · 0 comments

Comments

@VENTDEV
Copy link

VENTDEV commented Jan 28, 2024

Describe the bug
This is a bug that I fixed in my own custom implementation of OIS back in 2013 or so. Giving the latest master a try, it remains.

On X11 Linux non-exclusive mouse (native/hardware mouse), the OS and ingame mouse positions are offset.

Software Mouse works perfectly fine.

Incorrect
The tip of the yellow arrow is where the game thinks the mouse is. The mouse cursor is the location of the hardware mouse.

To Reproduce
Compile the latest master for Linux. Create an Ogre3d SDL window. Use OIS in non-exclusive/hidden mouse mode. You'll find that the mouse positions don't match.

Expected behavior
The tip of the hardware mouse and the mouse position in the renderer window should match.

Correct
After my code fix, the two are aligned properly.

Platform (please complete the following information):

  • OS: Linux
  • Backend: X11
  • Version: 1.3 to Master.

Additional context
I already implemented a fix for this. I am not sure if the code quality is up to standard. It probably can be handled better/prettier. But I will put what I am using in a pull request anyway.

VENTDEV added a commit to gearcity/OIS that referenced this issue Jan 28, 2024
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

Successfully merging a pull request may close this issue.

1 participant