lwjgl icon indicating copy to clipboard operation
lwjgl copied to clipboard

Wayland not supported

Open srakitnican opened this issue 10 years ago • 9 comments

Minecraft is not starting up under Wayland because of lwygl error "No modes available". As stated by Olivier Fourdan issue seems to be that lwygl doesn't understand output of command "xrandr -q" under Wayland.

Fedora bugzilla report

srakitnican avatar Jul 08 '15 07:07 srakitnican

Do you have such an output somewhere? I don't have a system with wayland here atm.

tfg13 avatar Jul 08 '15 14:07 tfg13

I can give you outputs of xrandr -q under wayland and X:

X:

Screen 0: minimum 8 x 8, current 1366 x 768, maximum 32767 x 32767
LVDS1 connected primary 1366x768+0+0 (normal left inverted right x axis y axis) 344mm x 194mm
1366x768      60.00*+
1280x720      60.00
1024x768      60.00
1024x576      60.00
960x540       60.00
800x600       60.32    56.25
864x486       60.00
640x480       59.94
720x405       60.00
680x384       60.00
640x360       60.00
DP1 disconnected (normal left inverted right x axis y axis)
HDMI1 disconnected (normal left inverted right x axis y axis)
VGA1 disconnected (normal left inverted right x axis y axis)
VIRTUAL1 disconnected (normal left inverted right x axis y axis)

Wayland:

Screen 0: minimum 320 x 200, current 1366 x 768, maximum 8192 x 8192
XWAYLAND0 connected 1360x768+0+0 340mm x 190mm
   [email protected]   0.00*+

I'm running Fedora 22 Workstation. Btw I don't know whether I can reproduce that issue, because I don't own Minecraft.

peterjeschke avatar Jul 10 '15 15:07 peterjeschke

Sure, X

Screen 0: minimum 8 x 8, current 1280 x 1024, maximum 32767 x 32767
DP1 disconnected (normal left inverted right x axis y axis)
DP2 disconnected (normal left inverted right x axis y axis)
DP3 disconnected (normal left inverted right x axis y axis)
HDMI1 connected primary 1280x1024+0+0 (normal left inverted right x axis y axis) 376mm x 301mm
   1280x1024     60.02*+  75.02  
   1152x864      75.00  
   1024x768      75.08    70.07    60.00  
   832x624       74.55  
   800x600       72.19    75.00    60.32  
   640x480       75.00    72.81    60.00  
   720x400       70.08  
HDMI2 disconnected (normal left inverted right x axis y axis)
HDMI3 disconnected (normal left inverted right x axis y axis)
VGA1 disconnected (normal left inverted right x axis y axis)
VIRTUAL1 disconnected (normal left inverted right x axis y axis)

Wayland

Screen 0: minimum 320 x 200, current 1280 x 1024, maximum 8192 x 8192
XWAYLAND0 connected 1280x1024+0+0 380mm x 300mm
   [email protected]   0.00*+

srakitnican avatar Jul 11 '15 00:07 srakitnican

Mode names are arbitrary, you cannot infer anything from them: https://bugs.freedesktop.org/show_bug.cgi?id=94589#c6

ppaalanen avatar Mar 17 '16 14:03 ppaalanen

The Xserver people were so kind to work around this issue in xserver 1.18.3: https://bugs.freedesktop.org/show_bug.cgi?id=94589 Anyway, the way how lwjgl handles mode names is still broken.

genodeftest avatar Apr 06 '16 11:04 genodeftest

The only correct solution is to use the libXrandr API instead of parsing the xrandr command output. This is what GLFW does in LWJGL 3.

Has anyone tried lwjglx with Minecraft? It'd be easier to fix that if something's missing or not working, instead of trying to make changes to LWJGL 2.

Spasi avatar Apr 06 '16 13:04 Spasi

LWJGL is well supported on XWayland 1.19 now. Any progress toward getting a native Wayland support ?

kilbith avatar Feb 06 '17 13:02 kilbith

This is becoming a larger problem for me with more distributions moving to Wayland. I'm using Fedora 30 and it defaults to Wayland. This is not just Minecraft but for my own projects that use LWJGL.

shartrec avatar May 28 '19 04:05 shartrec

Been having this issue lately. Oddly enough though, if I launch Minecraft in an X11 session, and then I go to a wayland session and launch it, it'll work. But if I try to fullscreen it, it'll crash, and then it'll refuse to launch from that point onward until I go back into an Xorg session and relaunch it there.

Charadon avatar Jan 17 '20 15:01 Charadon