From 3630a37dd5330fb1c681597b294abe41186362ba Mon Sep 17 00:00:00 2001 From: Spencer Whitt Date: Wed, 25 Mar 2015 18:10:08 -0400 Subject: [PATCH] x264: Add option to encode videos as bit depth 10 At compile time libx264 must be configured to encode videos in either 8 bit depth or 10 bit depth. It is not possible to compile libx264 to support both bit depths simultaneously. This exposes the bit depth compile option. --- pkgs/development/libraries/x264/default.nix | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/pkgs/development/libraries/x264/default.nix b/pkgs/development/libraries/x264/default.nix index c440493072e2..9422a8f9ab01 100644 --- a/pkgs/development/libraries/x264/default.nix +++ b/pkgs/development/libraries/x264/default.nix @@ -1,4 +1,4 @@ -{stdenv, fetchurl, yasm}: +{stdenv, fetchurl, yasm, enable10bit ? false}: stdenv.mkDerivation rec { version = "snapshot-20141218-2245-stable"; @@ -14,7 +14,8 @@ stdenv.mkDerivation rec { ''; configureFlags = [ "--enable-shared" ] - ++ stdenv.lib.optional (!stdenv.isi686) "--enable-pic"; + ++ stdenv.lib.optional (!stdenv.isi686) "--enable-pic" + ++ stdenv.lib.optional (enable10bit) "--bit-depth=10"; buildInputs = [ yasm ];