C FFMPEG Project to Apply GLSL Shaders to MP4 Video File in Command Line








Minimal example of an ffmpeg video filter which applies a pair of OpenGL shaders to each frame of its input, and emits the shaded frames.


  • You may want to pass --cc=clang on OS X.
  • There may slight variation in how GLEW and glfw are named (with regard to--extra-libs, above), e.g. -lglew or -lglfw3 – check pkg-config.
  • The above example builds a minimal FFmpeg binary with libx264, which you’ll need to build/install if that’s the route you go. There’s nothing codec-specific about the filter itself.



ffmpeg-opengl is free and unencumbered public domain software. For more information, see http://unlicense.org/ or the accompanying UNLICENSE file.

Leave a Reply