Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
880 views
in Technique[技术] by (71.8m points)

how to use ffmpeg on android

I want to create video file from Jpeg and audio file. I've compiled FFMpeg to android and I've got libffmpeg.so, and obj folder with ithers resources.

But how to use it? What I need to do for use command like: "ffmpeg -i image.jpeg -i audio.mp3 out.avi" Please help.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

From the FFmpeg docs on images:

The following example shows how to use ffmpeg for creating a video from the images in the file sequence ‘img-001.jpeg’, ‘img-002.jpeg’, ..., assuming an input frame rate of 10 frames per second:

ffmpeg -i 'img-%03d.jpeg' -r 10 out.mkv

To actually run it from Android, look at the documentation for Runtime.exec().


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...