I'm trying to run c++ code within my titanium application. there for i use the post of Chris moore http://developer.appcelerator.com/question/87681/is-it-possible-to-use-a-c-library-inside-titanium-mobile-
This got me quite far but the application can't seem to find where the c++ files are located.
The c++ are build with the Android-ndk and the files are put in a zip which can be found in the lib folder of the module.
this is de code i'm using in my java module: static {
System.loadLibrary("test");
}
private native int cCode(int a,int b);
@Kroll.method
public int getCCode() {
Log.d(LCAT, "cCode called");
return cCode(1,5);
}
my titanium code looks like this:
var qcar = require('com.logica.wtarnhem.qcar');
label.text = qcar.getCCode();
Your Answer
Think you can help? Login to answer this question!