Can FFmpeg be used as a library, instead of a standalone program?

You need libavcodec and libavformat. The FAQ tells you:

4.1 Are there examples illustrating how to use the FFmpeg libraries, particularly libavcodec and libavformat?

Yes. Read the Developers Guide of the FFmpeg documentation. Alternatively, examine the source code for one of the many open source projects that already incorporate FFmpeg at (projects.html).

The FFmpeg documentation guide can be found at ffmpeg.org/documentation.html, including the Developer’s guide. I suggest looking at libavformat/output-example.c or perhaps the source of the ffmpeg command line utility itself.

Leave a Comment