Hello. I had a question while I was practicing ndk. Usually, when you build ndk using android.mk files, you need a C language header file. That's when the method statement is
JNIEXPORT void JNICALL Java_com_msi_ibm_ndk_CameraSurfaceView_convertToGray(JNIEnv * env, jobject obj, jobject bitmapcolor,jobject bitmapgray)
It's a bit different from the C language method. But do I have to automatically create this method with javah? For ffmpeg open source, there are too many .h files.
ndk
Headers that are automatically generated as javah generate only the part of the function declared native in the Java source code you are developing.
Traditional C sources (such as open sources) can be used as they are (just set the source and library path well), and a few simple settings (
And if you know the C language response rule for functions in Java (how to define JNI functions), you don't have to use javah. However, it is recommended to use automatic generation because it reduces the possibility of errors (human errors).
Use javah again when:
Please refer to this article.
617 Uncaught (inpromise) Error on Electron: An object could not be cloned
574 Who developed the "avformat-59.dll" that comes with FFmpeg?
912 When building Fast API+Uvicorn environment with PyInstaller, console=False results in an error
610 GDB gets version error when attempting to debug with the Presense SDK (IDE)
© 2024 OneMinuteCode. All rights reserved.