texture demo running problem

I follow the Xith3D tuturial to install Xith3D and Jogl. When I run the TextureDemo, I got the following error:

java.lang.NoClassDefFoundError: com/xith/utility/logs/Log

  at com.xith3d.loaders.texture.TextureLoader.findImageFile(TextureLoader.java)

  at com.xith3d.loaders.texture.TextureLoader.resolvePath(TextureLoader.java)

  at com.xith3d.loaders.texture.TextureLoader.loadImageFast(TextureLoader.java)

  at com.xith3d.loaders.texture.TextureLoader.loadTexture(TextureLoader.java)

  at com.xith3d.loaders.texture.TextureLoader.loadTexture(TextureLoader.java)

  at com.xith3d.loaders.texture.TextureLoader.getMinMapTexture(TextureLoader.java)

  at org.xith3d.gsg.TextureDemo.<init>(TextureDemo.java:46)

  at org.xith3d.gsg.TextureDemo.main(TextureDemo.java:28)

Exception in thread “main”

May I set up some libraries wrong? Any suggestions?

Thanks.

–Dot

"com/xith/utility/logs/Log "

The com.xith.utility package was removed (and integrated with the main library) a while back.

Are you sure you are running the latest (ie. November) version?
http://www.xith.org/download/builds/2003-11-13_cvs/

Or download this and put it in your class path - https://xith3d.dev.java.net/source/browse/xith3d/third-party/xith/

But I suggest you get the new version.

Will.

Will,

Thanks for your suggestions. I download the lateset version. Unfortunately, I got a new error with the TextureDemo.

java.lang.Error: Cannot load image glass.png

  at com.xith3d.loaders.texture.TextureLoader.loadImageFast(TextureLoader.java:293)

  at com.xith3d.loaders.texture.TextureLoader.loadTexture(TextureLoader.java:313)

  at com.xith3d.loaders.texture.TextureLoader.loadTexture(TextureLoader.java:348)

  at com.xith3d.loaders.texture.TextureLoader.getMinMapTexture(TextureLoader.java:636)

  at org.xith3d.gsg.TextureDemo.<init>(TextureDemo.java:46)

  at org.xith3d.gsg.TextureDemo.main(TextureDemo.java:28)

Exception in thread “main”

What’s the hack?

–Dot

How do you run the TextureDemo? You have to make sure the images are in your current path.

100% sure for this. I doubt there might be other reason to make it wrong.

Assuming you have glass.png, xith3d.jar and TextureDemo.jar in your current directory and use Linux, you can run:

java -cp .:xith3d.jar:TextureDemo.jar org.xith3d.gsg.TextureDemo

If you have xith3d.jar in /jre/lib/ext (this causes problems with webstart apps):

java -jar TextureDemo.jar

In the /gsg/examples/Textures/ directory, I run:

java -cp /path.to/xith3d/xith3d.jar:TextureDemo.jar org.xith3d.gsg.TextureDemo

Previously we assumed xith3d.jar in the lib/ext but now we must assume the reverse.

A Class-Path attribute in the manifest would be good but it’s hard since we arn’t distributing xith3d.jar ourselves (that would become a pain updating wise).

Will.