Login  Register

Re: Initialising Joal

Posted by TheLittleP on Apr 10, 2014; 2:07pm
URL: https://forum.jogamp.org/Initialising-Joal-tp4032105p4032145.html

I now have sound and video working in my project.

Using the above JNILibLoaderBase code with the addition of...


 public static boolean addNativeJarLibs(Class<?>[] classesFromJavaJars, String singleJarMarker, String[] stripBasenameSuffixes) {

boolean ok=unpackNatives();
if(ok&&classesFromJavaJars[0]==jogamp.openal.ALDynamicLibraryBundleInfo.class)
 {
 try{
  String s=getNativeJoalName();
  if(s!="")System.load(s);
  }catch(Throwable t){
  ok=false;
  }

the unpackNatives routine ensures TempCache is initialiased and all the natives are unpacked and placed appropriately using PlatformPropsImpl.os_and_arch

There are a few other bits and pieces but I am sure it shouldn't be too difficult to work out.

I would of preferred to use the build in native loader but it simply didn't work.

Regards
P