Skip to content

funnymanva/ffmpeg-with-ac4

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Build FFmpeg 6.1 with AC4 Audio Support (static or Docker image)

This is based on the original project here. Those files were updated with newer packages, FFmpeg 6.1 and the AC4 decoding patches.

build-ffmpeg

The FFmpeg build script provides an easy way to build a static FFmpeg on macOS and Linux with optional non-free and GPL codecs (--enable-gpl-and-non-free, see https://ffmpeg.org/legal.html) included.

How-To build FFmpeg on MacOS

Youtube: How-To build and install FFmpeg on macOS

Disclaimer And Data Privacy Notice

This script will download different packages with different licenses from various sources, which may track your usage. These sources are out of control by the developers of this script. Also, this script can create a non-free and unredistributable binary. By downloading and using this script, you are fully aware of this.

Use this script at your own risk.

Common installation (macOS, Linux)

$ git clone https://git.home.oriley.net/apps/ffmpeg.git
$ cd ffmpeg-build-script
$ ./build-ffmpeg --build

Supported Codecs

  • x264: H.264 Video Codec (MPEG-4 AVC)
  • x265: H.265 Video Codec (HEVC)
  • libsvtav1, SVT-AV1 Encoder and Decoder
  • aom: AV1 Video Codec (Experimental and very slow!)
  • fdk_aac: Fraunhofer FDK AAC Codec
  • xvidcore: MPEG-4 video coding standard
  • VP8/VP9/webm: VP8 / VP9 Video Codec for the WebM video file format
  • AC4: AC4 Audio Codec (used by ATSC 3.0)
  • mp3: MPEG-1 or MPEG-2 Audio Layer III
  • ogg: Free, open container format
  • vorbis: Lossy audio compression format
  • theora: Free lossy video compression format
  • opus: Lossy audio coding format
  • srt: Secure Reliable Transport
  • webp: Image format both lossless and lossy

HardwareAccel

  • vaapi: Video Acceleration API. These encoders/decoders will only be available if a libva driver installation was found while building the binary. Follow these instructions for installation. Supported codecs in vaapi:
    • Encoders
      • H264 h264_vaapi
      • H265 hevc_vaapi
      • Motion JPEG mjpeg_vaapi
      • MPEG2 video mpeg2_vaapi
      • VP8 vp8_vaapi
      • VP9 vp9_vaapi

Apple M1 (Apple Silicon) Support

The script also builds FFmpeg on a new MacBook with an Apple Silicon M1 processor.

LV2 Plugin Support

If Python is available, the script will build a ffmpeg binary with lv2 plugin support.

Requirements

macOS

  • XCode 10.x or greater

Linux

  • Debian >= Buster, Ubuntu => Focal Fossa, other Distributions might work too
  • A development environment and curl is required
# Debian and Ubuntu
$ sudo apt install build-essential curl tcl

# Fedora
$ sudo dnf install @development-tools curl tcl

Build in Docker (Linux)

With Docker, FFmpeg can be built reliably without altering the host system.

Default

If you're running an operating system other than the one above, a completely static build may work. To build a full statically linked binary inside Docker, just run the following command:

$ docker build --tag=ffmpeg:default --output type=local,dest=build -f Dockerfile .

Run with Docker (macOS, Linux)

You can also run the FFmpeg directly inside a Docker container.

Default - Without CUDA (macOS, Linux)

A dockerized FFmpeg build can be executed with the following command:

$ sudo docker build --tag=ffmpeg .
$ sudo docker run ffmpeg -i https://files.coconut.co.s3.amazonaws.com/test.mp4 -f webm -c:v libvpx -c:a libvorbis - > test.mp4

Common build (macOS, Linux)

If you want to enable Vaapi, please refer to these and install the driver.

$ ./build-ffmpeg --build

Vaapi installation

You will need the libva driver, so please install it below.

# Debian and Ubuntu
$ sudo apt install libva-dev vainfo

# Fedora and CentOS
$ sudo dnf install libva-devel libva-intel-driver libva-utils

Usage

Usage: build-ffmpeg [OPTIONS]
Options:
  -h, --help                     Display usage information
      --version                  Display version information
  -b, --build                    Starts the build process
      --enable-gpl-and-non-free  Enable non-free codecs  - https://ffmpeg.org/legal.html
  -c, --cleanup                  Remove all working dirs
      --full-static              Complete static build of ffmpeg (eg. glibc, pthreads etc...) **only Linux**
                                 Note: Because of the NSS (Name Service Switch), glibc does not recommend static links.

Notes of static link

Original Project

About

FFMpeg build script that adds AC4 decoder patches

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published