https://stackoverflow.com/questions/20201067/ffmpeg-executable-chmod-permissionandroid
Your Android app must have permissions to read and write to storage, in AndroidManifest.xml
:app
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />.
Another caveat is the path, /storage/emulated/0/
is not available on all devices, you should use Environment.getExternalStorageDirectory()
to find the actual path.code
Finally, there is an easy workaround instead of extracting ffmpeg from raw folder, rename ffmpeg
to lib...ffmpeg...so
and put it into directory libs/armeabi
in your project.xml
Naturally, you will later run Runtime.getRuntime().exec(getContext().getApplicationInfo().nativeLibraryDir + "/lib...ffmpeg...so" +
whatever)
get
System installer will unpack the executable into /data/data/your.package.full.name/lib
for you automagically.it