Nicolas Trussart <[EMAIL PROTECTED]> on 06/23/99 08:42:31 AM
To: [EMAIL PROTECTED]
cc:  (bcc: Gary Moss/arl)
Subject: Running applet in a browser



I have the same problem as Vladimir.
I would like to run an applet in a browser. I have installed
jdk1.2.1, javasoft runtime and java3d in the jdk1.2.1 directory.

When I try to load an applet, this is the message that the Java console
tells :

    # Verifier error HelloUniverse.<init>()V: Cannot find class
javax/media/j3d/Canvas3D
# Applet exception: class HelloUniverse got a security violation: method
verification error

java.lang.VerifyError: HelloUniverse

 [blah, blah, blah]

 Actually Nicolas, it doesn't look like the same error.  Vladimir's error
explicitly stated:

> java.security.AccessControlException: access denied
> (java.lang.RuntimePermission modifyThread )

 The key words are "access denied", that should point you right to the
java.policy file, and the stuff in parenthesis is what you need to enable.

 What you have is a "method verification error" because it can't find your
Canvas3D class.  This is a classic error one gets when there path is not set
properly so that the wrong java VM is executed.  Not sure that this applies in
the context of running an applet in a browser, but make sure that your
jdk1.2.1/bin is the first thing in your Path variable (OS search path for
finding programs).  Beyond that, it could just be that you haven't completed
all steps in running J3d in a browser, see the note from Paul on this subject
in today's mail. Wait here's an excerpt:

To: [EMAIL PROTECTED]
cc:  (bcc: Gary Moss/arl)
Subject: Re: Java3D....write once, run nowhere?!

___________________________
I loaded the HelloUniverse class converted html and java files on our
server, performed the following steps and was able to run the HelloUniverse
applet in IE5 and NE4.6 via the web but not directly?.


Here is what I had to do to get the 3D applets to run:
1    Install JDK1.2.2    (jdk1_2_1-win.exe)
2    Install 3D API        (java3d1_1_2-win32-opengl-sdk.exe)
3    Run Java Plugin Control Panel    (either under accessories or directly
        under Start->Programs)
        Under advanced tab set the Java Run Time to:
        JDK1.2 in C:\jdk1.2.1 and hit "Apply"
4    Copy the *.jar file(s) up one directory to the lib directory from
        C:\ jdk1.2.1\jre\lib\ext to the lib directory  and
        C:\Program Files\JavaSoft\JRE\1.2\lib\ext to the lib directory

I had to do step 4 to get flicker free performance on my machine (400
Mhz/128mb) at 1280X1024 32 bit color).  I also did these steps on and older
166mhz machine with 64mb. I got the info for steps 3 & 4 from the
Ready-to-Run book.
Good Luck, I'm just starting as well.
________________________



I followed your advice : I have added in the java.policy file the two
lines :
 permission java.lang.RuntimePermission "modifyThread";
 permission java.lang.RuntimePermission "modifyThreadGroup";

Secondly, in the Java Plug-in Control Panel, which appears after the
Javasoft runtime is installed,
I enabled the Java Plug-in (Must I do it ?) and I have tried with all
Java Runtime Environment.

 You need to use the Java Plug-in, how you enable it has to do with converting
your HTML to envoke it.  There is an HTML converter available for download
where you get the plug-in I believe.  If you haven't run that, it's probably
part of your problem.

And thirdly, I put the j3d.dll and j3daudio.dll files in the C:\Program
Files\Javasoft\Jre\1.2\bin directory
(in reference to an other advice given in the j3d mailing list).

But unfortunatly, it doen't work.

Could you help me ?

 If you've done everything above,  I don't know what else to tell you.   I
haven't been running 3d applets much at all given the impracticality of
deploying them that way at this time.

Good luck,
-Gary

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to