I have some preliminary understanding of this aspect, I hope it can be helpful to you. For more information, please go to Baidu/Google and view the official documents.
1.Java’s JNI mechanism: Understanding JNI principles based on JAVA
JNI is an important function in the JAVA standard platform. It makes up for the shortcomings of JAVA's major advantage of being platform-independent. While JAVA is cross-platform, it can also be used with dynamic libraries in other languages (such as C, C++) Interact and give other languages a chance to take advantage.
My personal understanding is mainly that the Java level calls the .so (under Linux system) dynamic library compiled by the underlying C/C++. You can view Samples or write a Demo yourself
2.Android NDK: Android NDK development
NDK provides a series of tools to help developers quickly develop C (or C++) dynamic libraries, and can automatically package so and java applications into apk.
Other reference links: Android NDK official website Android NDK samples official example (GitHub address) Detailed explanation of Android Studio ndk-Jni development Getting started with Android Studio development - citing jar and so files
Please search for Android JNI related knowledge
Android Studio does not support C++ development well enough, you can use Eclipse
I have some preliminary understanding of this aspect, I hope it can be helpful to you. For more information, please go to Baidu/Google and view the official documents.
1.Java’s JNI mechanism: Understanding JNI principles based on JAVA
My personal understanding is mainly that the Java level calls the .so (under Linux system) dynamic library compiled by the underlying C/C++. You can view Samples or write a Demo yourself
2.Android NDK: Android NDK development
Other reference links:
Android NDK official website
Android NDK samples official example (GitHub address)
Detailed explanation of Android Studio ndk-Jni development
Getting started with Android Studio development - citing jar and so files