shotcut: use vaapi_device /dev/dri/renderD128 instead of ":0"

This fixes the auto-detection of VAAPI hardware encoders
provided by Intel chipsets. Be sure to define

  hardware.opengl.extraPackages = [pkgs.vaapiIntel];

in configuration.nix to make the necessary OpenGL drivers
available.
This commit is contained in:
Peter Simons 2019-09-18 21:53:40 +02:00
parent 713fda2eb5
commit cde50a4fab

View File

@ -33,6 +33,8 @@ mkDerivation rec {
sed 's_qApp->applicationDirPath(), "ffmpeg"_"${mlt.ffmpeg}/bin/ffmpeg"_' -i src/docks/encodedock.cpp
NICE=$(type -P nice)
sed "s_/usr/bin/nice_''${NICE}_" -i src/jobs/meltjob.cpp src/jobs/ffmpegjob.cpp
# Fix VAAPI auto-config: https://github.com/mltframework/shotcut/issues/771
sed 's#"-vaapi_device" << ":0"#"-vaapi_device" << "/dev/dri/renderD128"#' -i src/docks/encodedock.cpp
'';
qtWrapperArgs = [