java.lang.UnsatisfiedLinkError: nglDrawRangeElements

After working through the first ‘HelloWorld’ program in the Starter.pdf document, I encounted this error after successfully compiling (therefore it is some sort of runtime error).



Platform: Mac OS X 10.3



The error is listed below:


java.lang.UnsatisfiedLinkError: nglDrawRangeElements
   at org.lwjgl.opengl.GL12.nglDrawRangeElements(Native Method)
   at org.lwjgl.opengl.GL12.glDrawRangeElements(Unknown Source)
   at com.jme.renderer.lwjgl.LWJGLRenderer.draw(Unknown Source)
   at com.jme.scene.TriMesh.draw(Unknown Source)
   at com.jme.scene.Spatial.onDraw(Unknown Source)
   at com.jme.scene.Node.draw(Unknown Source)
   at com.jme.scene.Spatial.onDraw(Unknown Source)
   at com.jme.renderer.lwjgl.LWJGLRenderer.draw(Unknown Source)
   at com.jme.app.SimpleGame.render(Unknown Source)
   at com.jme.app.BaseGame.start(Unknown Source)
   at jmetutorial.HelloWorld.main(HelloWorld.java:11)



Normally I would think this to be a path problem but both lwjgl.jar and jme.jar resides in /System/Library/Java/Extensions and therefore naturally included in any of my java compilation.

I am sure what to do.

I tried getting another distribution of jME from CVS, but it it had major problems building... so currently I am stuck.

Any help would be most appreciated. And any other information asked for can certainly be provided.

Best regards,

MJ Stahl

new drivers usually resolve those type of issues.



Try updating your driver, and see what happens.



DP

Although you are going to have issues in Mac OS X until LWJGL gets the Mac port working.

Which driver should I try and update?



And I have come to realize the current problems with LWJGL and OS X, as I had to install and compile LWJGL by hand because the distribution contained within jME caused a different problem (something to do with Display()).



Thanks for the extremely prompt reply.



-M

I do apologize for the lack of help we can provide for Mac OS X. We don’t have any devs that own a Mac and we are holding off on it until LWJGL officially supports it. Until then, if someone wants to give me $5000 I’ll see what I can do :slight_smile: A G5 with a 30" Studio display would give me incentive to get jME going… :slight_smile:

Of course, each dev will need one to compare notes properly… :wink:

If we are lucky once lwjgl support mac it will work with jme with no change to jme.

That’s my hope.

Well I guess, I will see what I can do with to help LWJGL along with there Mac port.



Necessity is the mother of invention, or the nagging wife that yells at you to get off your ass and do some work. :slight_smile:



-M.

I’m not certain on the status of the LWJGL effort, I know they raised the money to buy a machine, so they at least have the tools (or will soon). Hopefully, we’ll have something before too long.

lwjgl had a campaign to raise the money to bye a mac so they can make lwjgl work on Mac. They got the money. Now they are trying to get the mac.

Definitely, what the error in the first post signifies is that the native JNI piece is missing. In the case of windows, this means it can’t find the lwjgl.dll file. Place this in your PATH (not CLASSPATH) or simply in your working directory and all should be well. Make sure you use lwjgl.94 as that is what we are using at the moment.

If the dlls are in place and you still get the missing function error, it means your native driver dlls don’t contain the function. In which case your card doesn’t support nglDrawRangeElements. Which is odd, because we do a check before using it. So, it appears to be a case where your card (or LWJGL) reports that it supports range elements, but in reality does not.

No, I doubt it.

well, a nice little hack to get OpenGL 1.5 specs is to copy the Mesa library dlls from Milkshape and place em in your driver directory. That way, jme (and lwjgl) will think you have 1.5 supported! (all demos will run in software mode, but is it as slow as a snail or what!)



PS. Ive never actually tried this myself, but some people at javagaming.org have and it worked quite nicely.



DP