mojira.dev
MC-80282

On Linux in fullscreen, character sometimes cannot fully turn around

As described at the end of this bug report:
MC-33903
and on this reddit thread:
http://www.reddit.com/r/linux_gaming/comments/35nheg
sometimes in fullscreen the character cannot turn all the way around, but only as far as the invisible cursor can go to the edge of the screen. This doesn't happen all the time, and this behavior goes away when you view the Esc menu, or leave fullscreen and return to it.

15w49b video: https://www.youtube.com/watch?v=qQRadVJmb7o

Related issues

Comments

kumasasa

This may be a LWJGL issue, please report it at their bug tracker: https://github.com/LWJGL/lwjgl/issues/

migrated
migrated

LWJGL contributor here.

I looked into this briefly, but there is no way (for me) to find out if this is a problem in LWJGL or Minecraft.
For this, one would need to look into the Minecraft source code, especially the part where ESC is handled.
If someone with access to minecraft source code looks into this and can tell me what exactly is called when the pause menu is entered and left and in which order, I will look into this again, but until then I am afraid I have to bounce this back to Mojang. (I am interested in all calls to org.lwjgl.opengl.Display, org.lwjgl.input.Mouse and org.lwjgl.input.Keyboard.)

Sorry, but figuring out what Minecraft does without the source takes way too much time. I did this once with the last minecraft-lwjgl linux issue I worked on, it took many hours, was painful and turned out to be a bug in minecraft, not in LWJGL 🙂

kumasasa

Is this still an issue in the current Minecraft Snapshot 15w49b or later? If so, please update the affected versions in order to best aid Mojang ensuring bugs are still valid in the latest releases/pre-releases.

migrated

Yep. Just downloaded that snapshot and tested it, still happens. You can see my capture here: https://www.youtube.com/watch?v=qQRadVJmb7o

wobst.michael

Is this still an issue in the most recent versions (i.e. 1.10.2, or 16w42a) of Minecraft?

migrated

This doesn't seem to happen anymore. However, I have a new issue related to fullscreen:
https://bugs.mojang.com/browse/MC-110156

thilo77

Something very much like this still happens under linux in 1.11. If I leave fullscreen and cause the minecraft window to lose focus (e.g., by looking something up in the browser), refocus the minecraft window and return it to fullscreen, then sometimes (but not always) the character cannot be fully turned around. Pressing Esc to enter the menu still solves this.

The one change I noticed since 1.10.2 is that the character is now restricted to turning 90 degrees to the left and 90 degrees to the right of the initial viewing direction, whereas before it was as described in the original report.

I think this bug should be reopened, as the problem basically remains the same. Please let me know if it would be better to open a new report due to the slightly changed behavior.

(I'm currently running mc 1.11 on archlinux
4.4.24-1-lts #1 SMP Fri Oct 7 20:44:49 CEST 2016 x86_64 GNU/Linux, java is
OpenJDK Runtime Environment (build 1.8.0_102-b14))

thilo77

Thanks for reopening. After playing 1.11 for a while, I must correct the statement in my previous comment: the behavior did not change at all, the bug is as described in the original bug description. I guess me being able to turn 90 degrees in each direction was a coincidence of the mouse position. Since then, I've experienced the bug as was reported initially.

Can anyone confirm with certainty that this is a Linux-only problem?

migrated

This bug is in 1.11.2 now. Was reported to the legacy LWJGL project on github, however was never resolved. see https://github.com/LWJGL/lwjgl/issues/115

1.11.2 is using lwjgl-2.9.4-nightly-20150209. There may be a newer build with the issue resolved, but it is not in this build.

migrated

Also in the latest snapshot

migrated

Just confirmed also on Windows 10 with 1.11.2! So this is no longer just a Linux issue. The only difference on windows is that the player can actually rotate, but the rotation is not smooth. The player can rotate a few degrees, then the rotation stops then the whole view rotates, almost like a lag, but at a steady 60 fps. This repeats throughout the rotation. Exiting fullscreen returns the rotation back to normal, but in doing so, the window size can no longer be changed. This is where Linux usually falls flat on its face, and I'm surprised to see this in Windows. Maybe it's time to say goodbye to LWGL legacy builds and switch to the 3.x branch.

Erik Broes

If switching to LWJGL3 was a day of work without any issues it would have been done already 🙂

migrated

It appears it's been done before with some level of success.
http://forum.lwjgl.org/index.php?topic=5610.msg29727#msg29727

There was a 2-3 compatibility shim somewhere floating around but I don't know the state of it and it seems to have disappeared.

migrated

@Grum, off course looking at the name on that forum thread on the LWJGL forums, it appears you at least knew about that tried at some point to get it working. There is a slightly more updated version here: https://github.com/Zekrom64/lwjglx but I don't know if it will get you past those original issues. Still though, I can't imagine LWJGL-legacy support will last for ever, especially on a hardware level. On top of that, it appears nothing gets marked as depreciated ( https://github.com/LWJGL/lwjgl/issues/126 ) so no heads up before something suddenly does not work.

migrated

I know it will take some debugging to figure out, but mouseInside in both WindowsDisplay.java, and LinuxDisplay.java (mac too?) and the places where it is used look like a good starting point. Even though it's supposed to keep the mouse inside the window, the rotation is stalling where the mouse would be outside that window when the game is paused. I just did a simple test to confirm using the range of movement of the mouse (physical mouse on my mousepad) in the game between each point where the rotation stops and compared it to the same range where the cursor would move in the window when paused. The range is a perfect match. I also managed to replicate this behavior by accident in my dev environment (1.10.2), except the issue was still present when falling back to windowed mode. The cursor was not completely captured by the window and locked within it's boundaries, and rotation would stop as the cursor would appear outside the window.

Edit: this comment was initially put on the wrong issue, so I deleted it and moved it here and added the updated info.

wobst.michael

Can someone please check if this is still an issue in the latest snapshot 17w43b?

migrated

Just tried on Kubuntu 17.10 with snapshot 17w43b, as far as I can tell, it appears to be fixed. Tried switching back and forth several times, no issue. Wait, LWJGL=3.1.2? I guess that explains why this is the first version of Minecraft I've ever played where my framerate doesn't drop from 60fps (vsync enabled by default in drivers) to 2 every time it rains.

pokechu22

Yep, snapshot 17w43a updated to LWJGL 3 from LWJGL 2.

migrated

(Unassigned)

Community Consensus

lwjgl

Minecraft 1.8.4, Minecraft 1.8.8, Minecraft 15w49b, Minecraft 1.11, Minecraft 1.11.2, Minecraft 17w13b

Minecraft 17w43a

Retrieved