trouble running the demos

When I try to run the demos for Xith3D I get this error:

Exception in thread “main” java.lang.NoClassDefFoundError: net/java/games/jogl/GLEventListener
at java.lang.ClassLoader.defineClass0(Native Method)
at java.lang.ClassLoader.defineClass(Unknown Source)
at java.security.SecureClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.defineClass(Unknown Source)
at java.net.URLClassLoader.access$100(Unknown Source)
at java.net.URLClassLoader$1.run(Unknown Source)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClass(Unknown Source)
at java.lang.ClassLoader.loadClassInternal(Unknown Source)
at com.xith3d.render.jogl.RenderPeerImpl.makeCanvas(RenderPeerImpl.java)

at com.xith3d.test.Xith3DTerrainTest.init(Xith3DTerrainTest.java)
at com.xith3d.test.Xith3DTerrainTest.main(Xith3DTerrainTest.java)

I’m using the Sun compiler(SDK v1.4.2) on a Windows ME compooter. If I do get the programs to run, (usually by using the cmdline c:\j2sdk1.4.2\bin\java com.xith3d…etc…
a box pops up (with the title bar saying “Xith3D”), but doesn’t display anything. I’m guessing that it’s because I need to do something else with the JOGL libraries and such, but can anyone confirm this? I didn’t make any additions to 1.4.2 until now, and I only followed the instructions in the Xith3D installation tute.

Are you sure you placed all the necessary libraries in the appropriate directories? It looks like Jogl can’t be found.

Can you run any of the JWS demo’s?

That will give you a good indication of whether your OpenGL is setup to handle Xith3D. (make sure xith3d.jar isn’t in your jre/lib/ext).

I assume you have installed using the http://xith.org/installing.php guide?

I agree it sounds like your JOGL native library (jogl.jar) isn’t in your classpath.

Will.

Ok, I was an idiot and didn’t fix the runtest.bat file to comply with the locations of the files after i downloaded them. Now I get this error:

Exception in thread “main” java.lang.NoClassDefFoundError: com/xith3d/scenegraph/Node

Err… I sorta had a clue as to what was wrong w/ the last message, what the heck’s up with this one?

Did you set the classpath to the appropriate folder?

Wow, that was dumb. It a wonder what fixing your classpath variable will do.

Aight, so now I get the box to pop up, but nothing’s displayed… aren’t I a pain in the ass? Anytime I run a file, the window opens and has the title “Xith3D” but only is filled with a dark gray background… I think this is more than a classpath variable… any ideas?

update your graphics card drivers (you need OpenGL1.2+)

Post all output in these forums so that we can help.

Will.

How would I got about checking my graphics card? I’m a software guy, not a hardware guy.

When I run any Xith3D program I get this output:


[divzero@localhost xith3d]$ java -cp libs/xith3d.jar com.xith3d.test.CubeTest
starting frame speed test
Init GL is net.java.games.jogl.impl.x11.X11GLImpl
OpenGL Renderer = Mesa X11
OpenGL Version = 1.4 Mesa 5.0.1
OpenGL Vendor = Brian Paul

That tells me I am running OpenGL 1.4. OpenGL 1.2 is the minimum for Xith3D.

Will.

What brand video card are you using?

Go to their web site and download the latest software windows drivers for your card

Will.

Sorry about the delay, it took a while to figure out what was going wrong here and why and then I had a history essay, so I didn’t get on much. Here is the output!

C:\Xith3D>java -cp libs/xith3d.jar com.xith3d.test.CubeTest
starting frame speed test
Init GL is net.java.games.jogl.impl.windows.WindowsGLImpl
OpenGL Renderer = GeForce2 MX/AGP/SSE2
OpenGL Version = 1.2.2
OpenGL Vendor = NVIDIA Corporation
OpenGL Extensions = GL_ARB_imaging GL_ARB_multitexture GL_ARB_texture_compressio
n GL_ARB_texture_cube_map GL_ARB_texture_env_add GL_ARB_texture_env_combine GL_A
RB_texture_env_dot3 GL_ARB_transpose_matrix GL_S3_s3tc GL_EXT_abgr GL_EXT_bgra G
L_EXT_blend_color GL_EXT_blend_minmax GL_EXT_blend_subtract GL_EXT_compiled_vert
ex_array GL_EXT_draw_range_elements GL_EXT_fog_coord GL_EXT_packed_pixels GL_EXT
_paletted_texture GL_EXT_point_parameters GL_EXT_rescale_normal GL_EXT_secondary
_color GL_EXT_separate_specular_color GL_EXT_shared_texture_palette GL_EXT_stenc
il_wrap GL_EXT_texture_compression_s3tc GL_EXT_texture_edge_clamp GL_EXT_texture
env_add GL_EXT_texture_env_combine GL_EXT_texture_env_dot3 GL_EXT_texture_cube
map GL_EXT_texture_filter_anisotropic GL_EXT_texture_lod GL_EXT_texture_lod_bias
GL_EXT_texture_object GL_EXT_vertex_array GL_EXT_vertex_weighting GL_IBM_textur
e_mirrored_repeat GL_KTX_buffer_region GL_NV_blend_square GL_NV_evaluators GL_NV
_fence GL_NV_fog_distance GL_NV_light_max_exponent GL_NV_packed_depth_stencil GL
_NV_register_combiners GL_NV_texgen_emboss GL_NV_texgen_reflection GL_NV_texture
_env_combine4 GL_NV_texture_rectangle GL_NV_vertex_array_range GL_NV_vertex_arra
y_range2 GL_NV_vertex_program GL_SGIS_generate_mipmap GL_SGIS_multitexture GL_SG
IS_texture_lod GL_WIN_swap_hint WGL_EXT_swap_control

All I get is a blank window grrr…

Please download and install the current NVidia drivers.

Thanks, that fixed it. The demos look really nice now!