简体   繁体   English

使用FFmpeg和Android-NDK

[英]Using FFmpeg with Android-NDK

I want to use FFmpeg with Android-NDK and I am very basic in this section, I need some help and I research about this topic before on the net, but got no satisfactory solution. 我想将FFmpegAndroid-NDK一起使用,我在本节中非常基础,我需要一些帮助,我之前在网上研究这个主题,但没有得到满意的解决方案。

1 - How can I use FFmpeg through Windows OS. 1 - 如何通过Windows操作系统使用FFmpeg (I do not want to use Ubuntu, please do not suggest.) (我不想使用Ubuntu,请不要建议。)

2 - How can I inset FFmpeg commands via NDK ? 2 - 如何通过NDK插入FFmpeg命令?

Last notice : I using android-ndk-r7b and Cygwin . 最后通知:我使用的是android-ndk-r7bCygwin

Any suggestion would be appreciated. 任何建议将不胜感激。

From your question it is hard to tell what exactly you want/need... so here some general information: 从您的问题来看,很难说出您想要/需要什么......所以这里有一些一般信息:

If you need further help please explain exactly what you want to achieve and what is not working... 如果您需要进一步的帮助,请准确说明您想要实现的目标和不起作用的内容......

UPDATE - as per comments: 更新 - 根据评论:

To use ffmpeg via command line on Android you need to copy ffmpeg into your application's files directory and chmod 755 it using getRuntime.exec() then you can run ffmpeg with the following line for example: 要在Android上通过命令行使用ffmpeg,您需要将ffmpeg复制到应用程序的files目录中,然后使用getRuntime.exec() chmod 755 ,然后您可以使用以下行运行ffmpeg,例如:

Process p = Runtime.getRuntime().exec("/data/data/yourpackagename/files/ffmpeg -i infile.mp4 outfile.mp4")

I made a tutorial on how to build ffmpeg and x264 for android : http://db.tt/TjMqIF3u 我做了一个关于如何为android构建ffmpegx264的教程: http//db.tt/TjMqIF3u

You can also download the zip file containing the files you need to make an application on android and also an executable of lastest ffmpeg to run on android . 您也可以下载一个包含你需要在应用程序中的文件的zip文件android和最新的也是一个可执行ffmpeg上运行android

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM