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

[3.0] CursorGrabbed doesn't work when using the SDL backend. #1617

Open
NogginBops opened this issue Jul 17, 2023 · 0 comments
Open

[3.0] CursorGrabbed doesn't work when using the SDL backend. #1617

NogginBops opened this issue Jul 17, 2023 · 0 comments

Comments

@NogginBops
Copy link
Member

Description

Setting CursorGrabbed = true and using Mouse.GetState() will return mouse coordinates that are locked within the window instead of working as expected (virtual coordinates).

Repro steps

Please provide the steps required to reproduce the problem

  1. Set CursorGrabbed = true.
  2. Read mouse position from Mouse.GetState() while moving the mouse towards the edge of the window.
  3. See that the mouse coordinates get stuck when the edge of the window is reached.

Expected behavior

For the coordinates to keep increasing past the edge.

Actual behavior

The coordinates get stuck.

Related information

  • Operating system: Windows
  • SDL or Native backend (if using OpenTK 3.x): SDL
  • What version of OpenTK (Installer, NuGet, Source Code): 3.3.3
  • What runtime (.NET Framework, CoreCLR, Mono): .net framework 4.8
  • Workarounds (if any): Don't use SDL backend
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant