-
Notifications
You must be signed in to change notification settings - Fork 48
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Errors such as java.lang.UnsatisfiedLinkError #16
Comments
Sounds like you did not include the natives jar on the classpath correctly. How are you including them? |
For my core project I add gdx-jnigen.jar, gdx-video-desktop-natives, gdx-video-desktop, and gdx-video to the buildpath, the last two being compiled from the project you provided.(In eclipse, I exported as a .jar file) For the android project, I only add gdx-video-android to the build path. I usually keep all of the libraries I use in a folder on my hard drive and add them in eclipse using the "Add External JARs..." option. For Android, I place the JARs in the libs folder and use the "Add JARs..." option. |
That sounds like the correct way of including libraries. Can I ask on what OS you're getting this error? It might be that some dynamic library needed by ffmpeg is causing problems... |
I'm using Mac OS X 10.10.2 |
That explains... The natives jar that you can find here is not compiled for a mac. This is because the buildserver is not functioning yet, and I myself don't have any mac to do the compile on. You can try compiling the natives yourself. (You'll have to edit the build.xml in the desktop/jni folder, and then execute the mac build with it). I wish I could do more, but I have no time to change the buildscript for you atm. Good luck! |
Tried running the project in Windows. Now, I get this error. (http://pastebin.com/PDF97Cz7) |
A quick google gives me this link: http://www.java-gaming.org/index.php?topic=31376.0 I can't really help with this issue, since it happens outside of my code. Something goes wrong with lwjgl opening the audio device. Maybe you're having issues with your audio driver? |
Ah! Thanks for the quick responses. When my speaker isn't connected, my audio devices are disabled. Plugging my speaker in fixes the OpenAL problem, but the "Could not open file!" remains. I'll try a different file format. |
The could not open file happens because ffmpeg (Which is used in the desktop project) can't load the videofile. The error suggests that your videofile is not a valid videofile. However, since the ffmpeg build in the project only supports ogg/theora and webm's, it could simply be that it gives this error because it cannot read the mp4 file format. The project is limited to these codecs because of licensing. You can try a webm, or you can try compiling the native library + ffmpeg yourself with different codecs for ffmpeg included. The second option does require you to check whether you fullfill all license agreements for the specific codecs. |
Thanks! It works! :D |
Good to hear! |
I apologize for my lack of experience, but can you create a video or a written tutorial about how to get this working? I tried to get this working, but I was just taking shots in the dark and ended up asking others in #libgdx on freenode and, after a few pointers, I was able to get rid of the "NoClassDefFoundError", but now i get this error. I don't know if the error is in the code that I am using(I am using your sample code) or in the .jar files that I added to the build path. It doesn't help that no one has ever tried using this.
The error: http://pastebin.com/T9RnjV5r
The code that I'm using: http://pastebin.com/MjxttDTN
The text was updated successfully, but these errors were encountered: