Couldn't run your app -- kept bombing the JVM ;-(
1) Setting the display size in showDisplay()
The intent is that each 'display' that you add through the panel=
keyword will have it's own size set. There is no explicit 'overall' size.
So, if you want both 'displays' to be equal in size, then when you do
the showDisplay() for each of them, use exactly the same values for
height= and width= keywords. This will work fine (until the user
resizes the window, of course ;-)
If you need something to set the overall size, or to make the JFrame not
resizable, then you can modify the 'myFrame' class inside subs.py.
2) Errors when switching between Sim3DAudio and web browser
What do you mean "switch to/from" the browser? Just bringing it to the
focus on your desktop? If so, this looks like a Java3D bug...
3) Optional extra: converting from .py to .java
jythonc is the only thing I know to do this. I would recommend making a
JAR file, and using the 'core' option -- this will then put everything
related to Jython into the JAR file.
If you haven't seen the page at:
I would recommend it.
I'd like to turn Sim3DAudio into a Java app. Yes, I know about
jythonc. I've tried invoking it on sim3Daudio.py (via changing
directory to the jythonc folder) but that didn't work. Here comes the
dreaded classpath question...mine looks like this:
Is that wrong?
Yes. You need to have the jython.jar in your CLASSPATH as well. I
always leave my CLASSPATH unset, and use the -cp (or -classpath) option
on the command line. For example, my script (in Win2K) to run jythonc is:
java -mx256m -D"python.home=c:\jython-21"
org.python.util.jython "\jython-21\Tools\jythonc\jythonc.py" %1 %2 %3 %4
%5 %6 %7 %8 %9
(all one line).
How do you go about compiling a .py file that imports from other .py
files (as this does with subs.py) into a .java file? Is it possible to
turn Jython 'scripts' into .class files? And how/where do you include
The 'core' option should compile everything needed. visad.jar should be
in the classpath, both when you compile and when you run. Again, best
to put the output into a JAR file.
Tom Whittaker (tomw@xxxxxxxxxxxxx)
University of Wisconsin-Madison
Space Science and Engineering Center
Cooperative Institute for Meteorological Satellite Studies