Results 1 to 8 of 8
- 02-13-2010, 08:31 PM #1
Member
- Join Date
- Feb 2010
- Posts
- 5
- Rep Power
- 0
Using libraries that others dont have(j3d)
hi
i have made a 3d model viewing applet that works fine on my computer(since i have the j3d library installed) but 99% of the people doesnt.
i was wondering if there is a way to embed the applet without forcing the viewer to install new plugin.
i tried creating the catalog tree in my web server, according to the imports
e.g javax.media.j3d. ....etc and the java console shows that its trying to download the necessary classes but cant find them.
-------------------------
Caused by: java.io.IOException: open HTTP connection failed:http://xxx.xxx.xx/~xxx/javax/media/j3d/Node.class
-------------------------
i have tried the jnlp but its too uncomfortable for the web page viewer.
how could i make it work?
- 02-14-2010, 12:21 AM #2
Senior Member
- Join Date
- Jun 2008
- Posts
- 2,366
- Rep Power
- 7
- 02-14-2010, 03:40 PM #3
Member
- Join Date
- Feb 2010
- Posts
- 5
- Rep Power
- 0
hi
thanks for the reply.
well...i tried adding all the classes i used into the jar, but the browser still fails to launch the applet on a client that doesnt have the libraries.
and it also looks the classes from the import directories not from the jar.
- 02-15-2010, 07:58 AM #4
Senior Member
- Join Date
- Jun 2008
- Posts
- 2,366
- Rep Power
- 7
No! I did not say to add the third parties libraries class files to your jar. I said to look at the archive attribute. You'll notice that you can provide a list of jars to that attribute. Just make sure that they all exist at the location you provide and are accessable through the web server (i.e. readable).
- 02-16-2010, 12:12 PM #5
Member
- Join Date
- Feb 2010
- Posts
- 5
- Rep Power
- 0
thanks again
it changed some errors into these ones
Exception in thread 'thread applet-Embed3D.class-1' java.lang.ExceptionInInitializerError
at javax.media.j3d.VirtualUniverse.(VirtualUniverse.j ava:259)
at Display3D.(Display3D.java:92)
at Embed3D.LoadParam(Embed3D.java:90)
at Embed3D.start(Embed3D.java:77)
at sun.plugin2.applet.Plugin2Manager$AppletExecutionR unnable.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Caused by: java.security.AccessControlException: access denied (java.lang.RuntimePermission modifyThreadGroup)
at java.security.AccessControlContext.checkPermission (Unknown Source)
at java.security.AccessController.checkPermission(Unk nown Source)
at java.lang.SecurityManager.checkPermission(Unknown Source)
at sun.plugin2.applet.Applet2SecurityManager.checkAcc ess(Unknown Source)
at java.lang.ThreadGroup.checkAccess(Unknown Source)
at java.lang.ThreadGroup.getParent(Unknown Source)
at javax.media.j3d.MasterControl$15.run(MasterControl .java:3462)
at java.security.AccessController.doPrivileged(Native Method)
at javax.media.j3d.MasterControl.(MasterControl.java: 3455)
so...now its about security?
i have the jars signed and folders and files have 777 rights.
- 02-17-2010, 07:38 AM #6
Senior Member
- Join Date
- Jun 2008
- Posts
- 2,366
- Rep Power
- 7
It looks as though the library manipulates the ThreadGroup it uses in ways that Applets are not allowed to. Possibly even signed. I don't do all that much with Applets myself, so all I can do about it is to Google Applet and SecurityManager and see what I can find out about how they work together and what can be done to change that behaviour, and you can do that as well as I can, so ....
- 02-17-2010, 10:37 AM #7
Member
- Join Date
- Feb 2010
- Posts
- 5
- Rep Power
- 0
thanks for the reply.
im on it
----------------------Last edited by scorpion9; 02-19-2010 at 11:25 AM.
- 02-19-2010, 11:24 AM #8
Member
- Join Date
- Feb 2010
- Posts
- 5
- Rep Power
- 0
sorry for the bump, but i couldnt find a solution to it by googling.
i found some examples about security manager and policy´s.
i used the following line to set permissions for the applet
and in the policy file,System.setProperty( "java.security.policy", codebase+"java.policy.applet" );
but it wont change anything, same error.grant {
permission java.security.AllPermission;
};
Similar Threads
-
i dont understand why i cant run my program please help
By kungfu in forum New To JavaReplies: 3Last Post: 07-28-2010, 02:49 PM -
Hello! and I need help. I dont know were to start
By Fall0ut in forum New To JavaReplies: 10Last Post: 05-19-2010, 06:26 PM -
Sometimes get the right results sometimes dont
By Battlefeldt in forum New To JavaReplies: 0Last Post: 12-18-2009, 01:03 AM -
Dont use this program, Im warning you!
By Addez in forum JCreatorReplies: 3Last Post: 11-28-2009, 07:18 PM -
FileOutputStream, I dont know what Im doing wrong...
By Addez in forum New To JavaReplies: 6Last Post: 09-14-2009, 10:46 PM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks