LWJGL
February 03, 2012, 23:31:33 *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: LWJGL 2.8.3 released!
 
   Home   Help Search Login Register  



Pages: [1]
  Print  
Author Topic: Fullscreen switch: Could not create context  (Read 1457 times)
DoubleG
Newbie
*
Posts: 1


« on: February 18, 2010, 09:16:30 »

Randomly while switching to fullscreen or windowed mode, I've got an LWGJLException inside the Display.create (with LWJGL 2.2.1):
Code:
Exception in thread "GL-Thread" org.lwjgl.LWJGLException: Could not create context
at org.lwjgl.opengl.WindowsContextImplementation.nCreate(WindowsContextImplementation.java)
at org.lwjgl.opengl.WindowsContextImplementation.create(WindowsContextImplementation.java:50)
at org.lwjgl.opengl.Context.<init>(Context.java:120)
at org.lwjgl.opengl.Display.create(Display.java:845)
at org.lwjgl.opengl.Display.create(Display.java:771)
at app.WorldView.createDisplay(WorldView.scala:404)
at app.WorldView.createWindowedDisplay(WorldView.scala:354)
at app.WorldView.run(WorldView.scala:171)

The code for switching to fullscreen and in windowed mode is:
Code:
Display.destroy();
if (fullscreen) {
  Display.setDisplayModeAndFullscreen(Display.getDesktopDisplayMode());
}
else {
  Display.setFullscreen(false);
  Display.setDisplayMode(Display.getDesktopDisplayMode());
  Display.setParent(canvas);
}
Display.create(new PixelFormat());

I can't find any reference to this bug on this forum (or the web). Did I do something wrong ?

Thanks,

Jérôme
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines
SMFAds for Free Forums
Valid XHTML 1.0! Valid CSS!