From 193b98084a08ed2b8b55880f77f0525ed915e16e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=A9clairevoyant?= <848000+eclairevoyant@users.noreply.github.com> Date: Thu, 25 Jul 2024 20:28:46 -0400 Subject: [PATCH] ffmpeg-headless: enable additional encoders by default MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This adds some extremely helpful and popular encoders in by default: * openjpeg * celt * libwebp * libaom On the `master` branch, closure size for ffmpeg-headless went up 18.5 MiB. ``` $ nix store diff-closures nixpkgs#ffmpeg-headless^bin .#ffmpeg-headless^bin celt: ∅ → 0.11.3, +168.4 KiB ffmpeg-headless: +70.0 KiB giflib: ∅ → 5.2.2, +398.7 KiB lcms2: ∅ → 2.16, +466.2 KiB lerc: ∅ → 4.0.0, +840.2 KiB libaom: ∅ → 3.9.0, +8047.8 KiB libdeflate: ∅ → 1.20, +427.0 KiB libtiff: ∅ → 4.6.0, +655.9 KiB libvmaf: ∅ → 3.0.0, +2665.0 KiB libwebp: ∅ → 1.4.0, +2559.7 KiB openjpeg: ∅ → 2.5.2, +1525.1 KiB zstd: ∅ → 1.5.6, +1158.0 KiB $ nvd diff $(nix build nixpkgs#ffmpeg-headless^bin --print-out-paths --no-link) $(nix build .#ffmpeg-headless^bin --print-out-paths --no-link) <<< /nix/store/4n60lnj3zkjpasd4c56bzhpx2m8lc1sx-ffmpeg-headless-6.1.1-bin >>> /nix/store/884f487w5hac6rs94jq6hq5zqkxdv666-ffmpeg-headless-6.1.1-bin Added packages: [A.] #01 celt 0.11.3 [A.] #02 giflib 5.2.2 [A.] #03 lcms2 2.16 [A.] #04 lerc 4.0.0 [A.] #05 libaom 3.9.0 [A.] #06 libdeflate 1.20 [A.] #07 libtiff 4.6.0 [A.] #08 libvmaf 3.0.0 [A.] #09 libwebp 1.4.0 x2 [A.] #10 openjpeg 2.5.2 [A.] #11 zstd 1.5.6 Closure size: 66 -> 78 (15 paths added, 3 paths removed, delta +12, disk usage +18.5MiB). ``` --- pkgs/development/libraries/ffmpeg/generic.nix | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pkgs/development/libraries/ffmpeg/generic.nix b/pkgs/development/libraries/ffmpeg/generic.nix index 32e9b9d895fd..4f2be05fc522 100644 --- a/pkgs/development/libraries/ffmpeg/generic.nix +++ b/pkgs/development/libraries/ffmpeg/generic.nix @@ -34,7 +34,7 @@ # Feature flags , withAlsa ? withHeadlessDeps && stdenv.isLinux # Alsa in/output supporT -, withAom ? withFullDeps # AV1 reference encoder +, withAom ? withHeadlessDeps # AV1 reference encoder , withAppKit ? withHeadlessDeps && stdenv.isDarwin # Apple AppKit framework , withAribcaption ? withFullDeps && lib.versionAtLeast version "6.1" # ARIB STD-B24 Caption Decoder/Renderer , withAss ? withHeadlessDeps && stdenv.hostPlatform == stdenv.buildPlatform # (Advanced) SubStation Alpha subtitle rendering @@ -45,7 +45,7 @@ , withBs2b ? withFullDeps # bs2b DSP library , withBzlib ? withHeadlessDeps , withCaca ? withFullDeps # Textual display (ASCII art) -, withCelt ? withFullDeps # CELT decoder +, withCelt ? withHeadlessDeps # CELT decoder , withChromaprint ? withFullDeps # Audio fingerprinting , withCodec2 ? withFullDeps # codec2 en/decoding , withCoreImage ? withHeadlessDeps && stdenv.isDarwin # Apple CoreImage framework @@ -88,7 +88,7 @@ , withOpencoreAmrwb ? withFullDeps && withVersion3 # AMR-WB decoder , withOpengl ? withFullDeps && !stdenv.isDarwin # OpenGL rendering , withOpenh264 ? withFullDeps # H.264/AVC encoder -, withOpenjpeg ? withFullDeps # JPEG 2000 de/encoder +, withOpenjpeg ? withHeadlessDeps # JPEG 2000 de/encoder , withOpenmpt ? withFullDeps # Tracked music files decoder , withOpus ? withHeadlessDeps # Opus de/encoder , withPlacebo ? withFullDeps && !stdenv.isDarwin # libplacebo video processing library @@ -121,7 +121,7 @@ , withVpl ? false # Hardware acceleration via intel libvpl , withVpx ? withHeadlessDeps && stdenv.buildPlatform == stdenv.hostPlatform # VP8 & VP9 de/encoding , withVulkan ? withSmallDeps && !stdenv.isDarwin -, withWebp ? withFullDeps # WebP encoder +, withWebp ? withHeadlessDeps # WebP encoder , withX264 ? withHeadlessDeps && withGPL # H.264/AVC encoder , withX265 ? withHeadlessDeps && withGPL # H.265/HEVC encoder , withXavs ? withFullDeps && withGPL # AVS encoder