Open Android-Unknown opened 1 year ago
It's a good question, and an open request (see this issue: https://github.com/sz3/cfc/issues/17)
Right now to encode on Android you have to download the cimbar.html file to your phone and open it in the web browser. But I admit this is not great (some phones won't even you do it...).
What I'd like to do if I eventually get some time is either (1) add a WebView to the CFC app that loads the encoder, or (2) add native jni bindings for the encoder code.
@sz3 JNI is a great way! Can you tell me which functions to use and in what format should I send data from the Java layer? I think there will be problems when building source codes for Clang compiler.
The two places to start are probably:
One possibility with a jni interface for encoding would be to dump the RGB (or is it BGR...) results from the cv::Mat
into a shared uint8* buffer for each frame, and have the android app worry about dumping that to the screen.
Just saying, if you install termux (as far as I can tell, the google play version is depreciated, so you'll need to install f-droid or download the apk from f-droid), you can build this from source and encode with the terminal. I'm doing it now, seems to be working.
Just saying, if you install termux (as far as I can tell, the google play version is depreciated, so you'll need to install f-droid or download the apk from f-droid), you can build this from source and encode with the terminal. I'm doing it now, seems to be working.
Cool! I didn't know that worked!
Interesting that it says the apk/play store version is deprecated(?), I haven't seen that on my end.
Just saying, if you install termux (as far as I can tell, the google play version is depreciated, so you'll need to install f-droid or download the apk from f-droid), you can build this from source and encode with the terminal. I'm doing it now, seems to be working.
Can you tell me how to do this please? I have termux installed
It didn't compile, but (and this isn't tested, but when I get motivated I will) you can use something like AnLinux (don't know if it's on play store, but it is on fdroid) to set up a ""VM"" (really just a chroot jail type thing) and compile in that. I might make some sort of script to do all that automatically later.
Edit: Keep in mind, it won't just pop up a window with the animated code, you need a vnc for that. If you use AnLinux, it has scripts for that.
Hi! How can I build an encoder in an android application?