astiav is yet another Golang library providing C bindings to ffmpeg

It’s only compatible with ffmpeg n4.4.1.

Its main goals are to:

  • export a more GO idiomatic API than any other Golang C bindings
  • provide the GO version of examples provided by ffmpeg
  • be fully tested


Examples are located in the examples directory and mirror the ffmpeg examples.

name astiav ffmpeg
Remuxing see see

Tip: you can use the video sample located in the testdata directory for your tests

Install ffmpeg

You can install ffmpeg with

$ make install-ffmpeg

ffmpeg will be built from source in a directory named tmp and located in you working directory

For your GO code to pick up ffmpeg dependency automatically, you’ll need to add the following environment variables:

(don’t forget to replace {{ path to your working directory }} with the absolute path to your working directory)

export CGO_LDFLAGS="-L{{ path to your working directory }}/tmp/n4.4.1/lib/",
export CGO_CXXFLAGS="-I{{ path to your working directory }}/tmp/n4.4.1/include/",
export PKG_CONFIG_PATH="{{ path to your working directory }}/tmp/n4.4.1/lib/pkgconfig",

Why astiav?

After maintaining for several years the most starred fork of goav, I’ve decided to write from scratch my own C bindings to fix most of the problems I still encountered using goav.


View Github