android-transcoder
android-transcoder copied to clipboard
Non-baseline AVC video profile is not supported by Android OS (Android 9.0)
Hi,
I am getting this error when trying to compress a video file with Android 9.0.
Fatal error while transcoding, this might be invalid format or bug in engine or Android.
net.ypresto.androidtranscoder.engine.InvalidOutputFormatException: Non-baseline AVC video profile is not supported by Android OS, actual profile_idc: 100
With other versions it works as expected. Any idea why is this happening? Thanks
Same issue here :( Edit: I compiled the project myself, allowing the profile_idc 100 manually (instead of 66 only) and it seems to work. Would there be any sideeffects to this @ypresto or is this safe to use?
@tipa can you share the .jar
file or show me how to do that by myself? I'm not native to Java environments.
Sure, you simply need to change this line: https://github.com/ypresto/android-transcoder/blob/e9c411c22897fad41a21c3f05f65b0dfe2fc327e/lib/src/main/java/net/ypresto/androidtranscoder/engine/MediaFormatValidator.java#L39
to
if (profileIdc != PROFILE_IDC_BASELINE && profileIdc != 100) {
This is the resulting .jar lib-release.zip
https://github.com/ypresto/android-transcoder/pull/73#issuecomment-475871771
(Main profile looks supported for now by Android itself, so we can remove restriction by checking Android version.)
Thank you so much @ypresto for your time - sounds like you are quite busy.
Does that mean we can remove the if
statement entirely?
Hi there, any updates on this?
Thanks
any update on this?
any update?
The issue seems to be fixed in the latest version of the master. While it's not perfect, you can get the latest build via JitPack as mentioned in #86.