Libav directory structure

Libav is a fairly large project, and is divided fairly cleanly into various parts. Here's a brief description.

Root directory


Libav uses autoconf, and has a configure script and a Makefile, as well as arch.mak, common.mak, and library.mak.

Main tools

Libav ships with several tools, such as avplay and avconv, which serves as thin wrapper that makes use the library of the code. Files: avconv.c avconv_dxva2.c avconv_filter.c avconv.h avconv_opt.c avconv_vda.c avconv_vdpau.c avplay.c avprobe.c cmdutils.c cmdutils_common_opts.h cmdutils.h - and the deprecated avserver.c.


There's a License file, and COPYING.GPLv2, COPYING.GPLv3, COPYING.LGPLv2.1, and COPYING.LGPLv3.


As is conventional in a Unix-y open source project, there is a README file, an INSTALL file, and a Changelog. RELEASE contains the version. CREDITS is a no-longer-updated partial list of contributors. checks when the version has updated.


Bridge compatibility issues between various operating systems, including Windows, Plan 9, and AIX.


The source for some of Libav's documentation ( ) is here as texi files, as well as a git howto.

APIchanges avserver.texi decoders.texi fate.texi indevs.texi muxers.texi print_options.c swscale.txt avconv.texi avtools-common-opts.texi demuxers.texi encoders.texi filters.texi libavfilter.texi nut.texi protocols.texi t2h.init avplay.texi avutil.txt developer.texi eval.texi general.texi Makefile optimization.txt rate_distortion.txt tablegen.txt avprobe.texi bitstream_filters.texi doxy examples git-howto.texi metadata.texi outdevs.texi RELEASE_NOTES avserver.conf build_system.txt Doxyfile faq.texi git-howto.txt multithreading.txt platform.texi soc.txt viterbi.txt


Libav is mostly focused in providing libraries to be reused.


Code to implement various codecs, such as aac, ac3, h264, vorbis, wma, and many others. It also contains architecture-specific directories for optimized code, often in assembly.


Deals with various capture and playback pseudo-demuxers abstracting platform-specific interfaces, such as ALSA, Jack, OSS, and PulseAudio for sound and framebuffers and X11 for video.


Source for audio and video filters, chainable code which add to or alter the audio and/or video streams. See the libavfilter documentation of what individual filters do.


Support for various container formats, such as ASF, Ogg, Matroska, RealMedia, etc. By convention, source files that demux containers often end with dec.c, and muxers often end with enc.c. Formats are registered in allformats.c. Oddly, some utility code is also in this directory, for handling udp, unix sockets, urls, os_support.c, etc. A large amount of documentation is autogenerated by doxygen.


Resampling (changing the sample rate of audio streams), including platform-specific assembler to make it faster.


Utility code, for handling files, strings, logs, memory, random seeds, trees, hash functions, etc. Beware: not all utility code is in this subdirectory.


This deals with pixel formats (rgb and yuv), colorspaces, etc, as well as scaling. Soon superceeded by libavscale.


Encoding presets, most of them related to libvpx and libx264.


This is mainly FATE tests - see [FATE] for more details.


Various small tools. aviocat.c cws2fws.c graph2dot.c ismindex.c patcheck pktdumper.c probetest.c qt-faststart.c trasher.c