C/C++ include in B4A (CDT, Android NDK)

js1234

Member
Licensed User
Longtime User
hi
I'm beginer .....
is possible to include some C source code to B4A?
I have few subrutines wich I want to include in B4A...is this possible on some way?
 

warwound

Expert
Licensed User
Longtime User
Search the internet for basic tutorials on using the Android NDK.

If you can create a java class that interfaces the native C functions - allowing the C functions to be called from java - then you can compile both the C and java class into a B4A library.

You can then call the java class methods from B4A and the java class will call the native C functions.

It might be helpful if you looked at the source code of an existing B4A library that does this - i have various libraries i could let you have the source code for if you are interested.

Martin.
 

Wayne Polny

New Member
Licensed User
Longtime User
Search the internet for basic tutorials on using the Android NDK.

If you can create a java class that interfaces the native C functions - allowing the C functions to be called from java - then you can compile both the C and java class into a B4A library.

You can then call the java class methods from B4A and the java class will call the native C functions.

It might be helpful if you looked at the source code of an existing B4A library that does this - i have various libraries i could let you have the source code for if you are interested.

Martin.
I would be interested in obtaining a sample library to give this a try thanks.

Wayne Polny
 

wonder

Expert
Licensed User
Longtime User
Top