Hi,
I tried again Java 3D 1.6 pre5 with JOGL 2.0 RC 11 under Windows and I still get a crash even with the simplest following example: import java.awt.*; import javax.media.j3d.*; import com.sun.j3d.utils.geometry.ColorCube; import com.sun.j3d.utils.universe.SimpleUniverse; public class Java3DSimpleTest { public static void main(String [] args) { BranchGroup root = new BranchGroup(); root.addChild(new ColorCube(0.5f)); Canvas3D canvas = new Canvas3D( SimpleUniverse.getPreferredConfiguration()); SimpleUniverse universe = new SimpleUniverse(canvas); universe.getViewingPlatform().setNominalViewingTransform(); universe.addBranchGraph(root); Frame frame = new Frame("Java3DSimpleTest"); frame.add(canvas); frame.setSize(200, 200); frame.setVisible(true); } } Here's the log I get: # # A fatal error has been detected by the Java Runtime Environment: # # EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x0336b992, pid=1108, tid=1068 # # JRE version: 6.0_37-b06 # Java VM: Java HotSpot(TM) Client VM (20.12-b01 mixed mode, sharing windows-x86 ) # Problematic frame: # C [prl_gl.dll+0xb992] # # If you would like to submit a bug report, please visit: # http://java.sun.com/webapps/bugreport/crash.jsp # The crash happened outside the Java Virtual Machine in native code. # See problematic frame for where to report the bug. # --------------- T H R E A D --------------- Current thread (0x02fc3400): JavaThread "J3D-Renderer-1" [_thread_in_native, id=1068, stack(0x039f0000,0x03a40000)] siginfo: ExceptionCode=0xc0000005, writing address 0x00000004 Registers: EAX=0x000000a5, EBX=0x0000000c, ECX=0x00000000, EDX=0x32e0b6b8 ESP=0x03a3f7b0, EBP=0x03a3f7b8, ESI=0x00000000, EDI=0x02fc3400 EIP=0x0336b992, EFLAGS=0x00010206 Top of Stack: (sp=0x03a3f7b0) 0x03a3f7b0: 32d38530 32d38530 03a3f7c8 03372caf 0x03a3f7c0: 000000a5 00000008 03a3f7e8 64517a56 0x03a3f7d0: 000081f8 000081fa 00000006 00000008 0x03a3f7e0: 02fc3400 32ae9fea 03a3f834 00959fc7 0x03a3f7f0: 02fc3528 03a3f854 000081f8 000081fa 0x03a3f800: 03372c90 00000000 00000202 00000001 0x03a3f810: 03a3f810 03a3f814 00000000 03a3f854 0x03a3f820: 32e0b6b8 00000000 32d38530 00000000 Instructions: (pc=0x0336b992) 0x0336b972: c6 5e 5b 5d c2 08 00 cc cc cc cc cc cc cc 8b ff 0x0336b982: 55 8b ec 8b 45 08 53 8b 5d 0c 56 83 c3 04 8b f1 0x0336b992: 89 46 04 81 fb 00 00 10 00 73 37 8b cb 83 c3 03 0x0336b9a2: c1 e1 0c 01 4d 08 83 e3 fc 3b 5e 10 76 0a 8b 16 Register to memory mapping: EAX=0x000000a5 is an unknown value EBX=0x0000000c is an unknown value ECX=0x00000000 is an unknown value EDX=0x32e0b6b8 is an oop {constant pool cache} - klass: {other class} ESP=0x03a3f7b0 is pointing into the stack for thread: 0x02fc3400 EBP=0x03a3f7b8 is pointing into the stack for thread: 0x02fc3400 ESI=0x00000000 is an unknown value EDI=0x02fc3400 is a thread Stack: [0x039f0000,0x03a40000], sp=0x03a3f7b0, free space=317k Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code) C [prl_gl.dll+0xb992] C [prl_gl.dll+0x12caf] C [jogl_desktop.dll+0x17a56] Java_jogamp_opengl_gl4_GL4bcImpl_dispatch_1glLightModeli1__IIJ+0x16 j jogamp.opengl.gl4.GL4bcImpl.dispatch_glLightModeli1(IIJ)V+0 j jogamp.opengl.gl4.GL4bcImpl.glLightModeli(II)V+35 j javax.media.j3d.JoglPipeline.updateSeparateSpecularColorEnable(Ljavax/media/j3d/Context;Z)V+25 j javax.media.j3d.Canvas3D.updateSeparateSpecularColorEnable(Ljavax/media/j3d/Context;Z)V+5 j javax.media.j3d.Canvas3D.enableSeparateSpecularColor()V+21 j javax.media.j3d.Renderer.doWork(J)V+3780 j javax.media.j3d.J3dThread.run()V+19 v ~StubRoutines::call_stub V [jvm.dll+0xfb7cb] V [jvm.dll+0x18d3d1] V [jvm.dll+0xfb971] V [jvm.dll+0xfb9cb] V [jvm.dll+0xb5e99] V [jvm.dll+0x119ab4] V [jvm.dll+0x14209c] C [msvcr71.dll+0x9565] endthreadex+0xa0 C [KERNEL32.dll+0xb729] GetModuleFileNameA+0x1ba Java frames: (J=compiled Java code, j=interpreted, Vv=VM code) j jogamp.opengl.gl4.GL4bcImpl.dispatch_glLightModeli1(IIJ)V+0 j jogamp.opengl.gl4.GL4bcImpl.glLightModeli(II)V+35 j javax.media.j3d.JoglPipeline.updateSeparateSpecularColorEnable(Ljavax/media/j3d/Context;Z)V+25 j javax.media.j3d.Canvas3D.updateSeparateSpecularColorEnable(Ljavax/media/j3d/Context;Z)V+5 j javax.media.j3d.Canvas3D.enableSeparateSpecularColor()V+21 j javax.media.j3d.Renderer.doWork(J)V+3780 j javax.media.j3d.J3dThread.run()V+19 v ~StubRoutines::call_stub --------------- P R O C E S S --------------- Java Threads: ( => current thread ) 0x02fe4800 JavaThread "J3D-InputDeviceScheduler-1" [_thread_blocked, id=1452, stack(0x13e50000,0x13ea0000)] 0x02fe3400 JavaThread "J3D-SoundSchedulerUpdateThread-1" [_thread_blocked, id=3176, stack(0x13e00000,0x13e50000)] 0x02fbb000 JavaThread "J3D-RenderStructureUpdateThread-1" [_thread_blocked, id=3020, stack(0x13db0000,0x13e00000)] 0x03097800 JavaThread "J3D-BehaviorScheduler-1" [_thread_blocked, id=3720, stack(0x13d60000,0x13db0000)] 0x03096000 JavaThread "J3D-TransformStructureUpdateThread-1" [_thread_blocked, id=3032, stack(0x13d10000,0x13d60000)] 0x02ffb400 JavaThread "J3D-RenderingEnvironmentStructureUpdateThread-1" [_thread_blocked, id=2380, stack(0x13cc0000,0x13d10000)] 0x02fec800 JavaThread "J3D-SoundStructureUpdateThread-1" [_thread_blocked, id=892, stack(0x13c70000,0x13cc0000)] 0x02fe7400 JavaThread "J3D-GeometryStructureUpdateThread-1" [_thread_blocked, id=1172, stack(0x13c20000,0x13c70000)] 0x02fde400 JavaThread "J3D-BehaviorStructureUpdateThread-1" [_thread_blocked, id=1104, stack(0x13bd0000,0x13c20000)] 0x02fd3800 JavaThread "D3D Screen Updater" daemon [_thread_blocked, id=2084, stack(0x13b80000,0x13bd0000)] 0x003f6800 JavaThread "DestroyJavaVM" [_thread_blocked, id=1736, stack(0x008d0000,0x00920000)] =>0x02fc3400 JavaThread "J3D-Renderer-1" [_thread_in_native, id=1068, stack(0x039f0000,0x03a40000)] 0x02fb3000 JavaThread "J3D-MasterControl-1" [_thread_blocked, id=3704, stack(0x039a0000,0x039f0000)] 0x02fb5000 JavaThread "J3D-NotificationThread" [_thread_blocked, id=3996, stack(0x03950000,0x039a0000)] 0x02fb1400 JavaThread "J3D-TimerThread" [_thread_blocked, id=3568, stack(0x03900000,0x03950000)] 0x02fdd800 JavaThread "J3D-RenderingAttributesStructureUpdateThread" [_thread_blocked, id=1020, stack(0x038b0000,0x03900000)] 0x02f2f800 JavaThread "main-SharedResourceRunner" daemon [_thread_blocked, id=1140, stack(0x030d0000,0x03120000)] 0x02f0a400 JavaThread "AWT-EventQueue-0" [_thread_blocked, id=1180, stack(0x03300000,0x03350000)] 0x02fa8800 JavaThread "AWT-Windows" daemon [_thread_in_native, id=3392, stack(0x03250000,0x032a0000)] 0x02ed0000 JavaThread "AWT-Shutdown" [_thread_blocked, id=2360, stack(0x03200000,0x03250000)] 0x02ee9c00 JavaThread "Java2D Disposer" daemon [_thread_blocked, id=2476, stack(0x031b0000,0x03200000)] 0x02b98400 JavaThread "Low Memory Detector" daemon [_thread_blocked, id=2792, stack(0x02e10000,0x02e60000)] 0x02b92800 JavaThread "C1 CompilerThread0" daemon [_thread_blocked, id=2336, stack(0x02dc0000,0x02e10000)] 0x02b91000 JavaThread "Attach Listener" daemon [_thread_blocked, id=3976, stack(0x02d70000,0x02dc0000)] 0x02b8fc00 JavaThread "Signal Dispatcher" daemon [_thread_blocked, id=2252, stack(0x02d20000,0x02d70000)] 0x02b8b400 JavaThread "Finalizer" daemon [_thread_blocked, id=2580, stack(0x02cd0000,0x02d20000)] 0x02b86800 JavaThread "Reference Handler" daemon [_thread_blocked, id=300, stack(0x02c80000,0x02cd0000)] Other Threads: 0x02b4a400 VMThread [stack: 0x02c30000,0x02c80000] [id=1084] 0x02ba3c00 WatcherThread [stack: 0x02e60000,0x02eb0000] [id=2056] VM state:not at safepoint (normal execution) VM Mutex/Monitor currently owned by a thread: None Heap def new generation total 4928K, used 2175K [0x229f0000, 0x22f40000, 0x27f40000) eden space 4416K, 45% used [0x229f0000, 0x22be4d08, 0x22e40000) from space 512K, 33% used [0x22e40000, 0x22e6b000, 0x22ec0000) to space 512K, 0% used [0x22ec0000, 0x22ec0000, 0x22f40000) tenured generation total 10944K, used 1742K [0x27f40000, 0x289f0000, 0x329f0000) the space 10944K, 15% used [0x27f40000, 0x280f3b50, 0x280f3c00, 0x289f0000) compacting perm gen total 12288K, used 7252K [0x329f0000, 0x335f0000, 0x369f0000) the space 12288K, 59% used [0x329f0000, 0x33105118, 0x33105200, 0x335f0000) ro space 10240K, 51% used [0x369f0000, 0x36f20500, 0x36f20600, 0x373f0000) rw space 12288K, 55% used [0x373f0000, 0x37a8bd40, 0x37a8be00, 0x37ff0000) Code Cache [0x00950000, 0x00a38000, 0x02950000) total_blobs=664 nmethods=263 adapters=337 free_code_cache=32615808 largest_free_block=0 Dynamic libraries: 0x00400000 - 0x00425000 C:\Program Files\Java\jre6\bin\javaw.exe 0x7c910000 - 0x7c9c9000 C:\WINDOWS\system32\ntdll.dll 0x64d00000 - 0x64d3c000 C:\Program Files\Alwil Software\Avast5\snxhk.dll 0x7c800000 - 0x7c906000 C:\WINDOWS\system32\KERNEL32.dll 0x77da0000 - 0x77e4c000 C:\WINDOWS\system32\ADVAPI32.dll 0x77e50000 - 0x77ee3000 C:\WINDOWS\system32\RPCRT4.dll 0x77fc0000 - 0x77fd1000 C:\WINDOWS\system32\Secur32.dll 0x7e390000 - 0x7e421000 C:\WINDOWS\system32\USER32.dll 0x77ef0000 - 0x77f39000 C:\WINDOWS\system32\GDI32.dll 0x76320000 - 0x7633d000 C:\WINDOWS\system32\IMM32.DLL 0x62dc0000 - 0x62dc9000 C:\WINDOWS\system32\LPK.DLL 0x753c0000 - 0x7542b000 C:\WINDOWS\system32\USP10.dll 0x7c340000 - 0x7c396000 C:\Program Files\Java\jre6\bin\msvcr71.dll 0x6d7f0000 - 0x6daa0000 C:\Program Files\Java\jre6\bin\client\jvm.dll 0x76ae0000 - 0x76b0f000 C:\WINDOWS\system32\WINMM.dll 0x6d7a0000 - 0x6d7ac000 C:\Program Files\Java\jre6\bin\verify.dll 0x6d320000 - 0x6d33f000 C:\Program Files\Java\jre6\bin\java.dll 0x6d7e0000 - 0x6d7ef000 C:\Program Files\Java\jre6\bin\zip.dll 0x637c0000 - 0x637ca000 C:\Documents and Settings\Emmanuel\workspace\SweetHome3D\lib\macosx\java3d-1.6\gluegen-rt.dll 0x77be0000 - 0x77c38000 C:\WINDOWS\system32\msvcrt.dll 0x6d000000 - 0x6d14c000 C:\Program Files\Java\jre6\bin\awt.dll 0x72f50000 - 0x72f76000 C:\WINDOWS\system32\WINSPOOL.DRV 0x774a0000 - 0x775de000 C:\WINDOWS\system32\ole32.dll 0x77390000 - 0x77493000 C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.2600.6028_x-ww_61e65202\COMCTL32.dll 0x77f40000 - 0x77fb6000 C:\WINDOWS\system32\SHLWAPI.dll 0x5b090000 - 0x5b0c8000 C:\WINDOWS\system32\uxtheme.dll 0x74690000 - 0x746dc000 C:\WINDOWS\system32\MSCTF.dll 0x75140000 - 0x7516e000 C:\WINDOWS\system32\msctfime.ime 0x6d350000 - 0x6d356000 C:\Program Files\Java\jre6\bin\jawt.dll 0x6a440000 - 0x6a44a000 C:\Documents and Settings\Emmanuel\workspace\SweetHome3D\lib\macosx\java3d-1.6\nativewindow_awt.dll 0x6d230000 - 0x6d27f000 C:\Program Files\Java\jre6\bin\fontmanager.dll 0x4fcf0000 - 0x4fe96000 C:\WINDOWS\system32\d3d9.dll 0x6de60000 - 0x6de66000 C:\WINDOWS\system32\d3d8thk.dll 0x77bd0000 - 0x77bd8000 C:\WINDOWS\system32\VERSION.dll 0x7c9d0000 - 0x7d1f5000 C:\WINDOWS\system32\shell32.dll 0x6c100000 - 0x6c110000 C:\Documents and Settings\Emmanuel\workspace\SweetHome3D\lib\macosx\java3d-1.6\nativewindow_win32.dll 0x5f070000 - 0x5f13c000 C:\WINDOWS\system32\OpenGL32.dll 0x6cef0000 - 0x6cf11000 C:\WINDOWS\system32\GLU32.dll 0x736b0000 - 0x736fb000 C:\WINDOWS\system32\DDRAW.dll 0x73b10000 - 0x73b16000 C:\WINDOWS\system32\DCIMAN32.dll 0x64500000 - 0x6456a000 C:\Documents and Settings\Emmanuel\workspace\SweetHome3D\lib\macosx\java3d-1.6\jogl_desktop.dll 0x03360000 - 0x03391000 C:\WINDOWS\system32\prl_gl.dll 0x76ba0000 - 0x76bab000 C:\WINDOWS\system32\PSAPI.DLL VM Arguments: jvm_args: -Djava.ext.dirs=../SweetHome3D/lib/macosx/java3d-1.6 -Djava.library.path=../SweetHome3D/lib/macosx/java3d-1.6 -Djogamp.gluegen.UseTempJarCache=false -Dfile.encoding=Cp1252 java_command: Java3DSimpleTest Launcher Type: SUN_STANDARD Environment Variables: PATH=C:/Program Files/Java/jre6/bin/client;C:/Program Files/Java/jre6/bin;C:/Program Files/Java/jre6/lib/i386;C:\Program Files\Parallels\Parallels Tools\Applications;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\QuickTime\QTSystem\ USERNAME=Emmanuel OS=Windows_NT PROCESSOR_IDENTIFIER=x86 Family 6 Model 30 Stepping 5, GenuineIntel --------------- S Y S T E M --------------- OS: Windows XP Build 2600 Service Pack 3 CPU:total 2 (2 cores per cpu, 1 threads per core) family 6 model 30 stepping 5, cmov, cx8, fxsr, mmx, sse, sse2, sse3, ssse3, sse4.1, sse4.2, popcnt Memory: 4k page, physical 1048044k(408560k free), swap 2519016k(2034724k free) vm_info: Java HotSpot(TM) Client VM (20.12-b01) for windows-x86 JRE (1.6.0_37-b06), built on Sep 24 2012 12:44:35 by "java_re" with MS VC++ 7.1 (VS2003) time: Thu Jan 10 10:09:51 2013 elapsed time: 2 seconds Hope this will help. Don't hesitate to ask for more information. My environment is Windows XP SP3 running under a Parallels Desktop Virtual Machine. No problem to run the program with Java 3D 1.5.2. Happy New Year to everyone
Emmanuel Puybaret
|
Administrator
|
Hi
Do you reproduce this bug without this desktop virtual machine?
Julien Gouesse | Personal blog | Website
|
I don't have any PC running natively Windows around me, so I can't tell you.
But it's the same error as the one I previously reported for Sweet Home 3D, and in december, I could check on an other Windows PC that the error didn't happen in Sweet Home 3D running Java 3D 1.6 with JOGL 2.0 RC 11. Anyway, even if it's a driver issue, it would be nice to avoid at least the crash of the program and better find a fix, since I didn't have any problem with Java 3D 1.5.2.
Emmanuel Puybaret
|
Administrator
|
My big brother uses your software, his teachers too. He's under Windows XP, it works very well. I tested it under Mandriva Linux 2010 and Mageia Linux 2 too.
Sometimes we can find a workaround but driver bugs should be fixed in drivers themselves. I think there is still a problem with shininess, when the value is very high, only on some drivers. Please debug the code and check the value passed to glLightModeli. Java3D 1.5.2 is not the golden age of Java3D, it has some bugs too, I succeeded in crashing some games based on it. Maybe this particular bug was not happening in Java3D 1.5.2.
Julien Gouesse | Personal blog | Website
|
Is there a jogl-all.jar compiled in debug mode available somewhere? It's really annoying because it happens at Java 3D initialization even if you don't add any BranchGroup to the universe!
Emmanuel Puybaret
|
Could you try just disabling the separate specular color enable when invoking the VM?
-Dj3d.disableSeparateSpecular=true Harvey |
Sorry that option didn't help.
Emmanuel Puybaret
|
Hmm, you're not running this under parallels desktop are you? It seems there are a lot of weird OpenGL bugs
in that stack. Likely 1.5.2 works simply because it uses the d3d backend. Harvey |
....and then I re-read you original report instead of the stack trace, yes, you are under parallels,
not sure there's much I can do here, it's crashing at the first opengl call of any kind, the code in that area looks like: if (enable) { gl.glLightModeli(GL2.GL_LIGHT_MODEL_COLOR_CONTROL, GL2.GL_SEPARATE_SPECULAR_COLOR); } else { gl.glLightModeli(GL2.GL_LIGHT_MODEL_COLOR_CONTROL, GL2.GL_SINGLE_COLOR); } It apparently crashes for you no matter which path gets taken, it's not a shininess issue as Julien suspected, this is another issue. Sorry I can't help. |
Yes, I'm running it under Parallels Desktop and no, it's not bound to d3d since I've got the same issue under Linux, and even under Windows the auto switch to d3d never worked in my case. Could it be an issue with the OpenGL version supported by the Parallels Desktop drivers? I just checked with OpenGL Extensions Viewer and it passed all rendering tests until version 2.1.
I hope you'll reconsider this. I fear that other users may encounter the same error and I don't want to buy a PC to test Sweet Home 3D under Windows and Linux. Anyway, the first emergency is to get onscreen Canvas3D work under Mac OS X (with antialiasing). By the way, could you remove from Java 3D the text "Java 3D: implicit antialiasing enabled" logged in System.out?
Emmanuel Puybaret
|
Administrator
|
Please check whether it comes from Parallels drivers (which is probably the case). Harvey said that it crashes on the first OpenGL call, it has probably nothing to do with our code and I was wrong about shininess.
Julien Gouesse | Personal blog | Website
|
There must have been a change in Java 3D 1.6 that provokes this crash, since it works with Java 3D 1.3 to 1.5.2.
Is the call to javax.media.j3d.Canvas3D#updateSeparateSpecularColorEnable absolutely necessary? If you don't get any valuable information from this call, isn't it possible to set some default value about the tested value? In all cases, a program using native DLLs should never crash, so isn't it possible to catch some exception?
Emmanuel Puybaret
|
Administrator
|
If it crashes on the first OpenGL call whatever it is, removing the call to updateSeparateSpecularColorEnable won't fix anything. I assume you didn't force the use of JOGL with previous versions of Java3D.
Julien Gouesse | Personal blog | Website
|
In reply to this post by Manu
Your opengl driver is segfaulting....just what the heck do you expect to catch? Once the fault happens in
native code, we never even return to Java, the process just gets killed. Please look at the code I quoted, _either_ of those pathways provokes a crash on your driver (under parallels) and once it does, there's nothing we can do, the OS is busy tearing down the process by that point. |
Free forum by Nabble | Edit this page |