Dear all,
we developed an 3D applet, which perfectly runs under Windows and Linux. But under Mac OSX 10.6.8 I got the error below. I extracted jogamp-all-platforms.7z and j3d-1_5_2-macosx.zip and set the CLASSPATH and the DYLD_LIBRARY_PATH to the folders as described in the Userguide: export CLASSPATH=/usr/local/lib/ext/j3dcore.jar:/usr/local/lib/ext/j3dutils.jar:/usr/local/lib/ext/vecmath.jar export CLASSPATH=${CLASSPATH}:/usr/local/jogamp-all-platforms/jar/jogl-all.jar:/usr/local/jogamp-all-platforms/jar/gluegen-rt.jar export DYLD_LIBRARY_PATH=/usr/local/jogamp-all-platforms/lib/macosx-universal I included these variables in the /etc/profile as root. Do you have any idea why the InvocationTargetException is thrown and is it necessary to change the java code of the applet or the html page from which the applet is called so that the jogl classes are recognized? Thank you for your help. Dietrich ... cache: Adding MemoryCache entry: http://vm53200-5.scidom.de:8080/MouseIDGenes/classes/graphicDisplay2/ObjectLoad.class network: Cache-Eintrag nicht gefunden [URL: http://vm53200-5.scidom.de:8080/MouseIDGenes/classes/, Version: null] network: Cache-Eintrag nicht gefunden [URL: http://vm53200-5.scidom.de:8080/MouseIDGenes/classes/, Version: null] security: Blacklist-Widerrufungsprüfung ist aktiviert security: Prüfung der Liste vertrauenswürdiger Bibliotheken ist aktiviert java.lang.reflect.InvocationTargetException at com.sun.deploy.util.DeployAWTUtil.invokeAndWait(DeployAWTUtil.java:116) at sun.plugin2.applet.Plugin2Manager.runOnEDT(Plugin2Manager.java:3657) at sun.plugin2.applet.Plugin2Manager.createApplet(Plugin2Manager.java:3182) at sun.plugin2.applet.Plugin2Manager$AppletExecutionRunnable.run(Plugin2Manager.java:1536) at java.lang.Thread.run(Thread.java:695) Caused by: java.security.AccessControlException: access denied (java.lang.RuntimePermission accessClassInPackage.javax.media.j3d) at java.security.AccessControlContext.checkPermission(AccessControlContext.java:376) at java.security.AccessController.checkPermission(AccessController.java:549) at java.lang.SecurityManager.checkPermission(SecurityManager.java:532) at sun.plugin2.applet.Applet2SecurityManager.checkPermission(Applet2SecurityManager.java:236) at java.lang.SecurityManager.checkPackageAccess(SecurityManager.java:1512) at sun.plugin2.applet.Applet2SecurityManager.checkPackageAccess(Applet2SecurityManager.java:319) at java.lang.ClassLoader$1.run(ClassLoader.java:336) at java.security.AccessController.doPrivileged(Native Method) at java.lang.ClassLoader.checkPackageAccess(ClassLoader.java:334) at java.lang.Class.getDeclaredConstructors0(Native Method) at java.lang.Class.privateGetDeclaredConstructors(Class.java:2446) at java.lang.Class.getConstructor0(Class.java:2756) at java.lang.Class.newInstance0(Class.java:328) at java.lang.Class.newInstance(Class.java:310) at sun.plugin2.applet.Plugin2Manager$13.run(Plugin2Manager.java:3170) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:199) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:715) at java.awt.EventQueue.access$400(EventQueue.java:82) at java.awt.EventQueue$2.run(EventQueue.java:676) at java.awt.EventQueue$2.run(EventQueue.java:674) at java.security.AccessController.doPrivileged(Native Method) at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:86) at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:97) at java.awt.EventQueue$3.run(EventQueue.java:690) at java.awt.EventQueue$3.run(EventQueue.java:688) at java.security.AccessController.doPrivileged(Native Method) at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:86) at java.awt.EventQueue.dispatchEvent(EventQueue.java:687) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188) at java.awt.EventDispatchThread.run(EventDispatchThread.java:122) Ausnahme: java.lang.reflect.InvocationTargetException Ignored exception: java.lang.reflect.InvocationTargetException network: CleanupThread used 1604605 us |
Administrator
|
Hi
Epic fail... You make a confusion between Java 3D 1.5.2 which has been discontinued by Oracle/Sun and Java 3D 1.6.0 which is actively maintained by the JogAmp community. Please look at the wiki, especially here: http://jogamp.org/wiki/index.php/Java3D_Tutorial Best regards. Edit.: Java 3D 1.5.2 is not compatible with JOGL 2.x, it uses JOGL 1 which isn't maintained whereas Java 3D 1.6 uses JOGL 2.x. Where is the user guide you mention?
Julien Gouesse | Personal blog | Website
|
Hi, thank you for your hint. In the meantime I could clarify the InvocationTargetException. This error was caused by wrong settings of the manifest file in the jar file of
our applet. The Permissions attribute must be set to “all-permissions” and not to “sandbox”. Then it works. After copying the three Java 3D files (version 1.6.0), the jogl-all.jar, the gluegen-rt.jar as well as the *.jnilib files (for macosx) into the
folder /Library/Java/Extensions I was able to start our applet correctly. One question still remains. In the User guidance, copying installation files into /Library/Java/Extensions folder is stated as bad praxis because
conflicts with third party Java Web Start applications may occur. But only setting the CLASSPATH and the DYLD_LIBRARY_PATH did not work in our case at which the applet is called by Javascript/HTML in the Browser.
Is there any other possibility for installation of JOGL and JAVA3D instead of copying installation files into /Library/Java/Extensions or setting
environmental variables? Best regards, Dietrich Von: gouessej [via jogamp] [mailto:ml-node+[hidden email]]
Hi Dietrich wrote j3d-1_5_2 Epic fail... You make a confusion between Java 3D 1.5.2 which has been discontinued by Oracle/Sun and Java 3D 1.6.0 which is actively maintained by the JogAmp community. Please look at the wiki, especially here:
Julien Gouesse |
Personal blog |
Website | Follow me on Identi.ca
If you reply to this email, your message will be added to the discussion below: http://forum.jogamp.org/Do-JOGL-and-JAVA-3D-work-on-Mac-OSX-10-6-tp4030673p4030674.html
To unsubscribe from Do JOGL and JAVA 3D work on Mac OSX 10.6.?,
click here. Helmholtz Zentrum München Deutsches Forschungszentrum für Gesundheit und Umwelt (GmbH) Ingolstädter Landstr. 1 85764 Neuherberg www.helmholtz-muenchen.de Aufsichtsratsvorsitzende: MinDir´in Bärbel Brumme-Bothe Geschäftsführer: Prof. Dr. Günther Wess, Dr. Nikolaus Blum, Dr. Alfons Enhsen Registergericht: Amtsgericht München HRB 6466 USt-IdNr: DE 129521671 |
In reply to this post by gouessej
Hi,
thank you for your hint. In the meantime I could clarify the InvocationTargetException. This error was caused by wrong settings of the manifest file in the jar file of our applet. The Permissions attribute must be set to “all-permissions” and not to “sandbox”. Then it works. After copying the three Java 3D files (version 1.6.0), the jogl-all.jar, the gluegen-rt.jar as well as the *.jnilib files (for macosx) into the folder /Library/Java/Extensions I was able to start our applet correctly. One question still remains. In the User guidance, copying installation files into /Library/Java/Extensions folder is stated as bad praxis because conflicts with third party Java Web Start applications may occur. But only setting the CLASSPATH and the DYLD_LIBRARY_PATH did not work in our case at which the applet is called by Javascript/HTML in the Browser. Is there any other possibility for installation of JOGL and JAVA3D instead of copying installation files into /Library/Java/Extensions or setting environmental variables? Best regards, Dietrich |
Administrator
|
Of course copying JARs into /Library/Java/Extensions is a bad practice too. Please follow these instructions: http://jogamp.org/jogl/doc/deployment/JOGL-DEPLOYMENT.html Just add the 3 JARs of Java3D into the value of the "archive" parameter. If you put all JOGL and Java3D JARs including those containing the native libraries into the same directory, it will probably work. Edit.: You don't need to install libraries. You provide them with your application to avoid conflicts and you don't need to extract the native libraries anymore, JOGL 2 does it for you: http://jogamp.org/jogl/doc/userguide/index.html#automatednativelibraryloading Look at that example too: http://jogamp.org/deployment/jogamp-current/jogl-demos/applet-gears.html
Julien Gouesse | Personal blog | Website
|
Free forum by Nabble | Edit this page |