Open neurospeech opened 8 years ago
Release Apk with different cpu architecture and delete the rest of libraries (as neurospeech mentioned) try reading this, http://developer.android.com/google/play/publishing/multiple-apks.html
Hi guys. Sorry about the noob question, but is there a way for this lib to work as Facebook's Fresco lib? A simple split on gradle (as http://frescolib.org/docs/multiple-apks.html) would not ship the ffmpeg executables from another architectures.
Is there any tutorial how to remove libraries for ffmpeg? I'm not familiar with NDK
Yes, if anyone could share some document for doing this, then that would be great as I am using FFmpegAndroid but not very familiar with NDK.
I agree with the above statements. A lot of us here probably aren't familiar with the NDK. A simple document detailing how to split the binaries would be very helpful.
I personally find it frustrating having spent weeks optimizing all assets in my APK only for it to become 5x larger after including this library...
same problem here. i removed those files from x86 and armv7 and output is in forcestoping app. can any one help us and above mate?
I was able to remove unused architecture. If somebody is wonder, I can share it with you.
please share it with me.
thanks for sharing the lib. all are working. i replaced your file with my larger file. but apk size is still >35 mb. apk size not reducing. i also tried clean and rebuild project after replacing your lib.
You shouldn't use both aar files, only one. As for me, I use gradle to make flavor for different architectures, one for x86 and another one for arm. AFAIK, x86 is not popular architecture so I decided to not publish build for it.
ok thanks a lot for helping. thanks again.
i am using nexus device for testing. and still confused about app size.
On 27-Dec-2016, at 3:03 PM, sashatinkoff notifications@github.com wrote:
You shouldn't use both aar files, only one. As for me, I use gradle to make flavor for different architectures, one for x86 and another one for arm. AFAIK, x86 is not popular architecture so I decided to not publish build for it.
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/WritingMinds/ffmpeg-android-java/issues/66#issuecomment-269300884, or mute the thread https://github.com/notifications/unsubscribe-auth/AXo7cD6Bvqzs6oATVutw47gXd3DvJFmEks5rMNtQgaJpZM4HX4as.
@sashatinkoff do you mind if you upload the file again? thank you
@zoedevelopers i've just created a repo on github https://github.com/sashatinkoff/ffmpeg-for-Android-compiled
@sashatinkoff pretty soon, Thank you so much!!!
@zoedevelopers I've just updated a readme file. Using this short guide you can assemble a project for certain architecture
@sashatinkoff do you know how to speed up the conversion using this lib? I just want to convert m4a and mp4 to mp3 but it is taking too long. Thanks. This library does not have enough support from theirs developers
@zoedevelopers I guess ffmpeg has couple of flags that can affect on speed conversion. Unfortunately I faced that native ffmpeg library seems a little outdated and doesn't support them (such as -preset ultrafast). If you'll find any way to do it please share your solution here =)
As for me, conversion seems too slow. To make it a little faster I reduce a size of input video / images. In fact, you'll get a video with low quality but it's a best way that I found how to handle it. Honestly speaking, I didn't spend a much time to find a solution that really works.
This is kind of a hack but the initial apk size can drastically be reduced by downloading the .so files after installation.
@gulzar1996 So you mean no need to create different apks for different archs? And if it so, can you please tell where one can find those ".so" files and how any resource which can show how to implement ffmpeg using ".so" files? Help Appreciated :) Thank You.
@gulzar1996 how to do it ?
@sashatinkoff I saw ur aar file in github. If I want to make app for video to audio conversation bso which aar file is best for it from those three aar file and how it can be implement in my project?
This project leads to apk of size > 40mb, this is huge waste of space and download time as most of the time, device has only one cpu architecture. Most android phones are armv7, so no need to ship x86 libraries along with the app. And as very few phones support armv7-neon, so no need to ship armv7-neon as well, you can always create three different apps for three different platforms.
Manually, I was able to delete x86 and armv7-neon, and brought down size of app to 10mb. So if there are three different libraries,
ffmpeg-android-java-x86 ffmpeg-android-java-armv7 ffmpeg-android-java-armv7-neon
It will be of great help to developers.
UPDATE
It turns out that you can use cdn.jsdelivr to directly download ffmpeg binaries when user tries to use ffmpeg first time. There is no need to package this inside apk. See https://github.com/neurospeech/xamarin-android-ffmpeg