Ever since I installed 1.4.2 I have had this error happen with my animation loop. What happens is that the first time I fire up my game it runs fine. But subsequent times it loads a white screen. If I alt - tab and then click on it again then the prog crashes giving me the following error:
An unexpected exception has been detected in native code outside the VM.
Unexpected Signal : EXCEPTION_ACCESS_VIOLATION (0xc0000005) occurred at PC=0x182D7D76
Function=Java_sun_print_Win32PrintJob_endPrintRawData+0x1D42
Library=C:\j2sdk1.4.2\jre\bin\awt.dll
Current Java thread:
at sun.awt.windows.Win32BackBufferSurfaceData.initSurface(Native Method)
at sun.awt.windows.Win32BackBufferSurfaceData.createData(Win32BackBufferSurfaceData.java:49)
at sun.awt.windows.Win32BackBuffer.createHWData(Win32BackBuffer.java:28)
at sun.awt.windows.WVolatileImage.initAcceleratedBackground(WVolatileImage.java:100)
at sun.awt.image.SunVolatileImage.(SunVolatileImage.java:86)
at sun.awt.windows.WVolatileImage.(WVolatileImage.java:72)
at sun.awt.windows.Win32BackBuffer.(Win32BackBuffer.java:20)
at sun.awt.windows.WComponentPeer.createBackBuffer(WComponentPeer.java:734)
- locked <0x1051f358> (a sun.awt.windows.WFramePeer)
at sun.awt.windows.WComponentPeer.replaceSurfaceData(WComponentPeer.java:324)
- locked <0x1051f358> (a sun.awt.windows.WFramePeer)
- locked <0x1050f7a8> (a java.awt.Component$AWTTreeLock)
at sun.awt.windows.WComponentPeer$2.run(WComponentPeer.java:333)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:178)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:454)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:151)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:145)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:137)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:100)
I am using a native timer so I think thats the problem. However I have been able to cause the same problem with JavaNoob’s code by changing the screen resolution from 16 bit to 32 bit color. Any ideas on how to fix this?