You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Screen 0: minimum 320 x 200, current 1920 x 1080, maximum 16384 x 16384
HDMI-0 connected 1920x1080+0+0 (normal left inverted right x axis y axis) 16mm x 9mm
1920x1080i 60.00*+ 50.00 59.94
1920x1080 24.00 23.98
1280x720 60.00 50.00 59.94
1024x768 75.08 70.07 60.00
1440x480i 59.94
832x624 74.55
800x600 72.19 75.00 60.32 56.25
720x576 50.00
720x576i 50.00
720x480 60.00 59.94
720x480i 60.00 59.94
640x480 75.00 72.81 66.67 60.00 59.94
DVI-0 disconnected (normal left inverted right x axis y axis)
VGA-0 disconnected (normal left inverted right x axis y axis)
The error encountered was an ArrayIndexOutOfBoundsException in XRandR.findPrimary.
This is a second-hand error report because my own monitors don't support interlaced display modes, but the person who I'm helping is testing this with Minecraft, which is notoriously hard to replace libraries in nowadays (due to integrity checks and automatic re-downloading). For that reason I can't really test a solution to this, but I suspect it may be as simple as:
diff --git a/src/java/org/lwjgl/opengl/XRandR.java b/src/java/org/lwjgl/opengl/XRandR.java
index 6630f97..586b611 100644
--- a/src/java/org/lwjgl/opengl/XRandR.java+++ b/src/java/org/lwjgl/opengl/XRandR.java@@ -259,7 +259,7 @@ public class XRandR {
}
private static final Pattern SCREEN_HEADER_PATTERN = Pattern.compile("^(\\d+)x(\\d+)[+](\\d+)[+](\\d+)$");
- private static final Pattern SCREEN_MODELINE_PATTERN = Pattern.compile("^(\\d+)x(\\d+)$");+ private static final Pattern SCREEN_MODELINE_PATTERN = Pattern.compile("^(\\d+)x(\\d+)i?$");
private static final Pattern FREQ_PATTERN = Pattern.compile("^(\\d+)[.](\\d+)(?:\\s*[*])?(?:\\s*[+])?$");
/**
I gave my friend an entirely different workaround, and one which is laughably hacky. I sent a tar.gz file containing a directory with these two scripts inside, then instructed them to run ./stupid-hack minecraft in that directory. It worked.
https://bugs.mojang.com/browse/MC-68732
(It is highly infuriating that even the moderators in that bug report point to the red herring error ~~ERROR~~ RuntimeException: No OpenGL context found in the current thread., which is caused by Display.<clinit> failing and contains no useful information of its own.)
On an almost-related note, does Java support non-capturing groups in regexes? It's been a long, long time since I used Java's particular flavour of regex, but in many dialects you could write it like this: "^(?:\\S*\\D)?(\\d+)x(\\d+)(?:\\D\\S*)?$"
This would remove the need for switching the group numbers around.
Has this issue been fixed in LWJGL yet? This issue is still occuring in programs such as Minecraft. https://bugs.mojang.com/browse/MC-79573 (main bug page, there are also 11 duplicates).
This is the output of
xrandr -q
The error encountered was an ArrayIndexOutOfBoundsException in XRandR.findPrimary.
This is a second-hand error report because my own monitors don't support interlaced display modes, but the person who I'm helping is testing this with Minecraft, which is notoriously hard to replace libraries in nowadays (due to integrity checks and automatic re-downloading). For that reason I can't really test a solution to this, but I suspect it may be as simple as:
I gave my friend an entirely different workaround, and one which is laughably hacky. I sent a tar.gz file containing a directory with these two scripts inside, then instructed them to run
./stupid-hack minecraft
in that directory. It worked.Probably related to:
(It is highly infuriating that even the moderators in that bug report point to the red herring error
~~ERROR~~ RuntimeException: No OpenGL context found in the current thread.
, which is caused byDisplay.<clinit>
failing and contains no useful information of its own.)The text was updated successfully, but these errors were encountered: