Unsatisfied Link Error when swiching rendering modes.

Started by Raven, October 31, 2005, 11:00:06 PM

Previous topic - Next topic

Raven

Hello all again.
Since the new library spawned some issues on switching renderers in the demos, I thought it was a good time to ask for help regarding my issue.

It's when I press 'x' in the FPS demo (try to switch between rendering modes) that I get this error:

Java version is: 1.4.2_09
-> support for BufferedImage
-> using BufferedImage
Software renderer (legacy mode) initialized
Software renderer disposed
Software renderer (OpenGL mode) initialized
108-123 -> using splitted buffer access!
Adding Lightsource: 0
Exception in thread "main" java.lang.UnsatisfiedLinkError: no lwjgl in java.library.path
       at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1517)
       at java.lang.Runtime.loadLibrary0(Runtime.java:788)
       at java.lang.System.loadLibrary(System.java:834)
       at org.lwjgl.Sys.<clinit>(Sys.java:61)
       at org.lwjgl.opengl.Display.<clinit>(Display.java:96)
       at com.threed.jpct.GLRenderer.init(Unknown Source)
       at com.threed.jpct.FrameBuffer.enableRenderer(Unknown Source)
       at com.threed.jpct.FrameBuffer.enableRenderer(Unknown Source)
       at JPCTDemo.switchOptions(JPCTDemo.java:1007)
       at JPCTDemo.gameLoop(JPCTDemo.java:909)
       at JPCTDemo.<init>(JPCTDemo.java:511)
       at JPCTDemo.main(JPCTDemo.java:188)


I did a search for this error on the forum, but found nothing except something regarding WebStart which I really made no sense of.

My run command specifies the path to the lwjgl library, so I don't get it>

java -mx700m -cp .:/Users/raven/Dev/3D/JPCT/jpctapi/lib/lwjgl-0.97/lwjgl.jar:/Users/raven/Dev/3D/JPCT/jpctapi/lib/jpct/jpct.jar JPCTDemo

I'm running on OS X 10.4.
Any ideas?

Cheers,
-Raven

EgonOlsen

You have to include the native libs too. Either put them in the current directory (should work...) or use the -Djava.library.path=<your dir>-switch to tell the VM where to look for the native libs.

Raven

Sorry if I'm being a bother about this, but  tried both with no luck.


java -Djava.library.path=/Users/raven/Dev/3D/JPCT/jpctapi/lib/lwjgl-0.97/ -cp .:/Users/raven/Dev/3D/JPCT/jpctapi/lib/lwjgl-0.97/lwjgl.jar:/Users/raven/Dev/3D/JPCT/jpctapi/lib/jpct/jpct.jar JPCTDemo


Same problem. Are the native libs not the ones stored in the lwjgl folder? the .dll's?

Thank you for your patience.
-Raven

EgonOlsen

They are, but for Windows. You have to use native libs for Mac. They can be found here: https://sourceforge.net/project/showfiles.php?group_id=58488
You may either upgrade the whole LJWGL-stuff (including the jars) that comes with jPCT (from 0.97 to 0.98 ) or simply download the 0.97 version for Mac and use the libs in the native-folder instead.

Hope this helps.

Raven

Oh, wow!
That worked! Thanks!
Actually I should have figured that the dll's were windows files  :oops:

Now my framerate is *alot* higher.

Thanks!
-Raven