@nbtthief wrote:
Hi everyone,
I'm trying to use java to call C++ function, i follow online tuts using JNIEXPORT void JNICALL Java_org_cocos2dx_cpp_AppActivity_FunctionName.
But when i map it to android it said "Cannot resolve corresponding JNI...", i try to run it, it crashes.
According to my understands, the cause is it cannot regconize the new file i added (i added new file with name AndroidHelper.cpp and added it to android.mk, rebuild with cocos console).Do you know how to solve this problem?
edit: i added extern "C" in JNI function, fyi
Posts: 3
Participants: 2