mjbWorld - Troubleshooting

Are you getting the following error messages:

  1. java.lang.UnsatisfiedLinkError: no jogl in java.library.path
  2. java.lang.NoClassDefFoundError: net/java/games/jogl/GL
  3. 'out of environment space'
  4. Exception in thread "main" java.lang.NoClassDefFoundError: mjbWorld/mjbWorld
  5. OutOfMemoryError
  6. 'java' is not recognized as an internal or external command, operable program or batch file.
  7. ZipException
  8. Windows 95/98/ME issues
  9. Java Runtime Environment\CurrentVersion' has value '1.4', but '1.3' is required
  10. Exception in thread "main" java.lang.NoClassDefFoundError: org/w3c/dom/Element
  11. mjbModel.readX3d org.xml.sax.SAXException: System property org.xml.sax.driver not specified

Java Runtime Environment Java5 (JRE 1.5 or JDK 1.5) is now required

If you are using mjbWorld version 6 or higher then Java Runtime Environment 1.5 is now required.


java.lang.UnsatisfiedLinkError: no jogl in java.library.path

This error is saying that it cant find the jogl.dll file in the library path. Try copying this file from the directory where you installed mjbWorld to the lib\ext subdirectry where you installed Java. This will be a path something like this:

C:\j2sdk1.4.0_01\jre\lib\ext

See message from Karol.

Full error message:

java.lang.UnsatisfiedLinkError: no jogl in java.library.path
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1410)
at java.lang.Runtime.loadLibrary0(Runtime.java:772)
at java.lang.System.loadLibrary(System.java:832)
at net.java.games.jogl.impl.NativeLibLoader$1.run(NativeLibLoader.java:60)
at java.security.AccessController.doPrivileged(Native Method)
at net.java.games.jogl.impl.NativeLibLoader.<clinit>(NativeLibLoader.java:46)
at net.java.games.jogl.impl.GLContext.<clinit>(GLContext.java:51)
at net.java.games.jogl.impl.windows.WindowsGLContextFactory.createGLContext(WindowsGLContextFactory.java:52)
at net.java.games.jogl.GLCanvas.<init>(GLCanvas.java:72)
at net.java.games.jogl.GLDrawableFactory.createGLCanvas(GLDrawableFactory.java:117)
at net.java.games.jogl.GLDrawableFactory.createGLCanvas(GLDrawableFactory.java:80)
at mjbWorld.frame3d.<init>(frame3d.java:53)
at mjbWorld.internalFrame.setLayout(internalFrame.java:199)
at mjbWorld.frameLayout.actionPerformed(frameLayout.java:82)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1767)
at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1820)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:419)
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:257)
at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:258)
at java.awt.Component.processMouseEvent(Component.java:5021)
at java.awt.Component.processEvent(Component.java:4818)
at java.awt.Container.processEvent(Container.java:1525)
at java.awt.Component.dispatchEventImpl(Component.java:3526)
at java.awt.Container.dispatchEventImpl(Container.java:1582)
at java.awt.Component.dispatchEvent(Component.java:3367)
at javax.swing.plaf.basic.BasicInternalFrameUI$GlassPaneDispatcher.retargetMouseEvent(BasicInternalFrameUI.java:1379)
at javax.swing.plaf.basic.BasicInternalFrameUI$GlassPaneDispatcher.forwardMouseEvent(BasicInternalFrameUI.java:1305)
at javax.swing.plaf.basic.BasicInternalFrameUI$GlassPaneDispatcher.mouseReleased(BasicInternalFrameUI.java:1279)
at java.awt.Component.processMouseEvent(Component.java:5021)
at java.awt.Component.processEvent(Component.java:4818)
at java.awt.Container.processEvent(Container.java:1525)
at java.awt.Component.dispatchEventImpl(Component.java:3526)
at java.awt.Container.dispatchEventImpl(Container.java:1582)
at java.awt.Component.dispatchEvent(Component.java:3367)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3359)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3074)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3004)
at java.awt.Container.dispatchEventImpl(Container.java:1568)
at java.awt.Window.dispatchEventImpl(Window.java:1581)
at java.awt.Component.dispatchEvent(Component.java:3367)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:445)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:191)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:144)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:130)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:98)


java.lang.NoClassDefFoundError: net/java/games/jogl/GL

I have not been able to reproduce this, see message from Karol.


'out of environment space'

Is the 'out of environment space' message happening after the classpath like this:

C:\mjbWorld>SET CLASSPATH=;C:\mjbWorld\mjbWorld.jar
Out of environment space

If so, someone else had this problem, and they were running windows 9x, are you running windows 95 or 98 ?
If so I think windows 9x has limited space for classpaths.
A possible solution for this is to take out the classpath lines and put a -cp argument for the java command as follows:

SET PATH=%PATH%;C:\mjbWorld
SET
PATH=%PATH%;C:\jdk1.2.2\jre\bin;C:\jdk1.2.2\jre\lib;C:\jdk1.2.2\jre\lib\ext
CD C:\mjbWorld
java -cp C:\mjbWorld\mjbWorld.jar;C:\ProgramFiles\JavaSoft\jre\1.2\lib\rt.jar;C:\ProgramFiles\JavaSoft\jre\1.2\lib\ext\j3dcore.jar;C:\jdk1.2.2\jre\lib\ext\vecmath.jar;C:\jdk1.2.2\jre\lib\ext\j3dutils.jar;C:\mjbWorld\bsh0_96.jar
mjbWorld.mjbWorld

Note: in above script C:\mjbWorld\mjbWorld.jar;C:\Pr... is on the same line as java -cp, ie

java -cp C:\mjbWorld\mjbWorld.jar;C:\Pro...

when this is displayed in html it puts it on a separate line

 


Exception in thread "main" java.lang.NoClassDefFoundError: mjbWorld/mjbWorld

Tthe java command does not seem to be able to find mjbWorld.jar in C:\mjbWorld or the directory that you are using to store it.Check the location of mjbWorld.jar and can that directory be seen, ie CD C:\mjbWorld


java.lang.OutOfMemoryError.

I think the problem is likely to be due to the amount of memory allocated to the Java VM, see the following quote from the Java3D FAQ

Out of memory problems
If you get an error message about your Java 3D program (or any Java program for that matter). The Java virtual machine allocates a certain amount of memory to use, and it's much less than people typically have on their systems. To increase this limit, use the -Xmx option when you run the program. For example, the command:

java -Xmx64m program

will allocate 64 meg of memory space

I suggest you try various memory sizes.


'java' is not recognized as an internal or external command, operable program or batch file.

The operating system cannot find the Java runtime. You need to have the path set to point to the directory where java is installed.

SET PATH=C:\jdk3.1.3\bin


ZipException

Exception in thread "main" java.util.zip.ZipException: The system cannot find the file specified
at java.util.zip.ZipFile.open(Native Method)
at java.util.zip.ZipFile.<init>(Unknown Source)
at java.util.jar.JarFile.<init>(Unknown Source)
at java.util.jar.JarFile.<init>(Unknown Source)

Although I have not been able to reproduce this myself, the following people have kindly sent me an explanation:

Correspondance about this error:


Java Runtime Environment\CurrentVersion' has value '1.4', but '1.3' is required

C:\mjbWorld>java mjbWorld.mjbWorld
Registry key 'Software\JavaSoft\Java Runtime Environment\CurrentVersion' has value '1.4', but '1.3' is required.
Error: could not find java.dll
Error: could not find Java 2 Runtime Environment.

This seems to happen when you have a version of Java installed on your machine, then you install Jbuilder with a different version. I have checked the value is 1.4 in the registary as shown here,


so why does the program want to use version 1.3? I don't know can anyone help?

see stefanh


Exception in thread "main" java.lang.NoClassDefFoundError: org/w3c/dom/Element

C:\mjbWorld>java mjbWorld.mjbWorld
Exception in thread "main" java.lang.NoClassDefFoundError: org/w3c/dom/Element
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:486)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:111)

at java.net.URLClassLoader.defineClass(URLClassLoader.java:248)
at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:297)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:286)
at java.lang.ClassLoader.loadClass(ClassLoader.java:253)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:313)
at mjbWorld.mjbWorld.<init>(mjbWorld.java:31)
at mjbWorld.mjbWorld.main(mjbWorld.java:50)

From 5.14 of mjbWorld it requires version 1.4 or greater of Java to run on. If you are getting this error then you need to upgrade to JDK1.4.

If it is not possible to upgrade to Java 1.4 then you should use version 5.13 of mjbWorld.


mjbModel.readX3d org.xml.sax.SAXException: System property org.xml.sax.driver not specified

mjbWorld.mjbWorld -Dorg.apache.crimson.parser.XMLReaderImpl
mjbModel.readX3d org.xml.sax.SAXException: System property org.xml.sax.driver not specified


Windows 95/98/ME issues

You may have to change all references to "Program Files" to "PROGRA~1" to avoid "bad command or file name" messages from DOS.


metadata block
see also:

 

Correspondence about this page

Book Shop - Further reading.

Where I can, I have put links to Amazon for books that are relevant to the subject, click on the appropriate country flag to get more details of the book or to buy it from them.

 

cover Beginning Java 2 SDK 1.4 Edition - A good book for learning java

 

Commercial Software Shop

Where I can, I have put links to Amazon for commercial software, not directly related to this site, but related to the subject being discussed, click on the appropriate country flag to get more details of the software or to buy it from them.

cover JBuilder - There is also a free version of Jbuilder at borland website . However its licence conditions are quite restrictive so you may prefer another java IDE.

This site may have errors. Don't use for critical systems.

Copyright (c) 1998-2017 Martin John Baker - All rights reserved - privacy policy.