I've got a program I'm working on, when it's run in a window everything is fine, but once I run the program in fullscreen and make a texture with TextureIO.newTexture(File) I get the following error. I'm afraid I don't have code to provide, I've been unable to reproduce the error in a smaller program, but I hoped the following stack trace and my OS(Windows 7) might be enough to suggest a direction for me to go in. I found one link in google that mentions this error, but the solution there was to download the latest jogl, and I just got my copy off of the website today.
javax.media.opengl.GLException: Thread[AWT-EventQueue-0,6,main] glGetError() returned the following error codes after a call to glTexParameteri(<int> 0xDE1, <int> 0x8191, <int> 0x1): GL_INVALID_ENUM ( 1280 0x500), Exception in thread "Timer-0" javax.media.opengl.GLException: java.lang.NullPointerException at jogamp.opengl.awt.AWTThreadingPlugin.invokeOnOpenGLThread(AWTThreadingPlugin.java:98) at jogamp.opengl.ThreadingImpl.invokeOnOpenGLThread(ThreadingImpl.java:197) at javax.media.opengl.Threading.invokeOnOpenGLThread(Threading.java:164) at javax.media.opengl.awt.GLCanvas.maybeDoSingleThreadedWorkaround(GLCanvas.java:767) at javax.media.opengl.awt.GLCanvas.display(GLCanvas.java:388) at com.jogamp.opengl.util.AWTAnimatorImpl.display(AWTAnimatorImpl.java:74) at com.jogamp.opengl.util.AnimatorBase.display(AnimatorBase.java:140) at com.jogamp.opengl.util.FPSAnimator$1.run(FPSAnimator.java:125) at java.util.TimerThread.mainLoop(Timer.java:512) at java.util.TimerThread.run(Timer.java:462) Caused by: java.lang.NullPointerException at org.curious.felidae.media.Renderer.setTexture(Renderer.java:145) at org.curious.felidae.actors.Box.render(Box.java:64) at org.curious.felidae.media.RenderListener.display(RenderListener.java:44) at jogamp.opengl.GLDrawableHelper.display(GLDrawableHelper.java:191) at javax.media.opengl.awt.GLCanvas$DisplayAction.run(GLCanvas.java:873) at jogamp.opengl.GLDrawableHelper.invokeGL(GLDrawableHelper.java:363) at javax.media.opengl.awt.GLCanvas$DisplayOnEventDispatchThreadAction.run(GLCanvas.java:890) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:199) at java.awt.EventQueue.dispatchEvent(EventQueue.java:597) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:269) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:184) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:174) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:169) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:161) at java.awt.EventDispatchThread.run(EventDispatchThread.java:122) |
Whenever I resort to posting a question on the internet I'm sure I can't get any further on my own, but I just figured out my problem. In my program I save the resolution I want in a(an?) xml file, then I iterate over all my available display modes and pick a display which matches the resolution I want, with no regard for the bit depth of the display mode. As a result, when I ran my program in fullscreen I had a bit depth of 8 bits. Selecting a display mode which gives the resolution I want and the maximum bit depth solves my problem.
|
Free forum by Nabble | Edit this page |