Skip to content

v3.6 crashes attempting to run example apps in fullscreen with LWJGL v2 #1890

Closed
@stephengold

Description

@stephengold

Investigating a possible regression in JME v3.6.0-alpha1, I tried to run some of the apps in jme3-examples in fullscreen mode ... for example jme3test.helloworld.HelloJME3 (though I ran into identical behavior with other example apps). Here's what happens:

  • The display settings dialog appears with "Fullscreen" not checked and "Refresh Rate" blank.
  • I check the box for "Fullscreen".
  • The "Screen Resolution" changes to1920x1080 and the "Refresh Rate" changes to 55 Hz. Unfortunately, 55 Hz isn't a valid refresh rate for my display adapter. I believe the valid rates are 24, 30, and 60 Hz.
  • When I try to select a different refresh rate, there are only 6 available options: 50 Hz, 51 Hz, 52 Hz, 53 Hz, 54 Hz, and 55 Hz. None of these are valid rates.
  • After I click the "Continue" button, I get two "Error in Application" dialogs and the app crashes.

The console output is:

Jan 03, 2023 10:59:04 AM com.jme3.system.JmeDesktopSystem initialize
INFO: Running on jMonkeyEngine 3.6.0-alpha1
 * Branch: master
 * Git Hash: 5b9fc87
 * Build Date: 2023-01-03
Jan 03, 2023 10:59:05 AM com.jme3.app.LegacyApplication handleError
SEVERE: Failed to create display
java.lang.RuntimeException: Unable to find fullscreen display mode matching settings
	at com.jme3.system.lwjgl.LwjglDisplay.createContext(LwjglDisplay.java:80)
	at com.jme3.system.lwjgl.LwjglAbstractDisplay.initInThread(LwjglAbstractDisplay.java:120)
	at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:221)
	at java.base/java.lang.Thread.run(Thread.java:833)

Jan 03, 2023 10:59:05 AM com.jme3.app.LegacyApplication handleError
SEVERE: Uncaught exception thrown in Thread[jME3 Main,5,main]
java.lang.IllegalMonitorStateException: current thread is not owner
	at java.base/java.lang.Object.notifyAll(Native Method)
	at com.jme3.system.lwjgl.LwjglAbstractDisplay.initInThread(LwjglAbstractDisplay.java:135)
	at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:221)
	at java.base/java.lang.Thread.run(Thread.java:833)


Exception: java.lang.NullPointerException thrown from the UncaughtExceptionHandler in thread "jME3 Main"

Excerpt from glxinfo (to document my graphics configuration):

OpenGL vendor string: NVIDIA Corporation
OpenGL renderer string: GeForce GT 545/PCIe/SSE2
OpenGL core profile version string: 4.6.0 NVIDIA 390.157
OpenGL core profile shading language version string: 4.60 NVIDIA

This was with "jme3-lwjgl" (LWJGL v2, which is currently the default jme3-examples build). Here's what happened when I switched the build to use "jme3-lwjgl3" (LWJGL v3):

  • The display settings dialog appears with "Fullscreen" not checked and "Refresh Rate" blank.
  • I check the box for "Fullscreen".
  • The "Screen Resolution" changes to1920x1080 and the "Refresh Rate" changes to 55 Hz.
  • When I try to select a different refresh rate, there are only 6 available options: 50 Hz, 51 Hz, 52 Hz, 53 Hz, 54 Hz, and 55 Hz.
  • After I click the "Continue" button, the application runs fullscreen.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething that is supposed to work, but doesn't. More severe than a "defect".

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions