Hi,
I decided to try JSMFL. I use Ubuntu 13.04, Eclipse, and of course Java. All of them are 64 bits.
I created a project in Eclipse and I added jsfml.jar in the classpath.
I copied the following code from the tutorial.
package ca.USERNAME.sandbox.jsfml;import org.jsfml.graphics.Color;import org.jsfml.graphics.RenderWindow;import org.jsfml.window.VideoMode;import org.jsfml.window.event.Event;public class JSFMLTest
{ /**
* @param args
*/ public static void main
(String[] args
) { System.
out.
println("JSFMLTest"); RenderWindow window
= new RenderWindow
(); window.
create(new VideoMode
(640,
480),
"Hello JSFML!"); window.
setFramerateLimit(30); while (window.
isOpen()) { window.
clear(Color.
RED); window.
display(); for (Event event
: window.
pollEvents()) { if (event.
type == Event.
Type.
CLOSED) { window.
close(); } } } }} Eclipse doesn't report any error, except when I run the code. This happens :
JSFMLTest
Exception in thread "main" java.lang.UnsatisfiedLinkError: /home/USERNAME/.jsfml/linux_x64/libsfml-graphics.so: libGLEW.so.1.6: cannot open shared object file: No such file or directory
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary1(ClassLoader.java:1935)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1860)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1821)
at java.lang.Runtime.load0(Runtime.java:792)
at java.lang.System.load(System.java:1059)
at org.jsfml.internal.SFMLNative.loadNativeLibraries(Unknown Source)
at org.jsfml.internal.SFMLNativeObject.<init>(Unknown Source)
at org.jsfml.window.Window.<init>(Unknown Source)
at org.jsfml.graphics.RenderWindow.<init>(Unknown Source)
at ca.mfcochauxlaberge.sandbox.jsfml.JSFMLTest.main(JSFMLTest.java:16)
The .jsfml folder does exist in my user directory. According to my package manager, libGLEW 1.9 is installed. Could this be the problem? It needs 1.6? If I remember correctly, I read in another post that libGLEW is already inside jsfml.jar, so I don't know what to do.
When I run the test application, I get the exact same error.
Thanks for you help.