Gpu-screen-recorder: Difference between revisions

Add link to ShadowPlay
m Changed the ShadowPlay link to point to the English version of the Nvidia website, rather than German
 
(3 intermediate revisions by 3 users not shown)
Line 1: Line 1:
[https://git.dec05eba.com/gpu-screen-recorder/about/ gpu-screen-recorder] is a screen recorder that has minimal impact on system performance by recording your monitor using the GPU only, similar to [https://www.nvidia.com/de-de/geforce/geforce-experience/shadowplay/ ShadowPlay] on Windows.
[https://git.dec05eba.com/gpu-screen-recorder/about/ gpu-screen-recorder] is a screen recorder that has minimal impact on system performance by recording your monitor using the GPU only, similar to [https://www.nvidia.com/en-us/geforce/geforce-experience/shadowplay/ ShadowPlay] on Windows.


==== Supported codecs ====
==== Supported codecs ====
Line 17: Line 17:
== Installation ==
== Installation ==
<syntaxhighlight lang="nix">
<syntaxhighlight lang="nix">
  programs.gpu-screen-recorder.enable = true; # For promptless recording on both CLI and GUI
   environment.systemPackages = with pkgs; [
   environment.systemPackages = with pkgs; [
    gpu-screen-recorder # CLI
     gpu-screen-recorder-gtk # GUI app
     gpu-screen-recorder-gtk # GUI
   ];
   ];
</syntaxhighlight>
</syntaxhighlight>
Line 30: Line 31:
# Make sure your [[Nvidia|drivers]] are installed.
# Make sure your [[Nvidia|drivers]] are installed.
# Install the missing the NVENC patch for your card.  [https://github.com/icewind1991/nvidia-patch-nixos nvidia-patch] is a great overlay which you can use  
# Install the missing the NVENC patch for your card.  [https://github.com/icewind1991/nvidia-patch-nixos nvidia-patch] is a great overlay which you can use  
# Override the package build inputs and add the library to the wrapper.<syntaxhighlight lang="nix">
# Override the package build inputs and add the library to the wrapper.
     (gpu-screen-recorder.overrideAttrs (oldAttrs: rec {
 
       buildInputs = with pkgs; [
<syntaxhighlight lang="nix">
        xorg.libXcomposite
{
        libpulseaudio
  environment.systemPackages = [
        ffmpeg
     (pkgs.runCommand "gpu-screen-recorder" {
        wayland
       nativeBuildInputs = [ pkgs.makeWrapper ];
        libdrm
    } ''
        libva
      mkdir -p $out/bin
        xorg.libXrandr
      makeWrapper ${pkgs.gpu-screen-recorder}/bin/gpu-screen-recorder $out/bin/gpu-screen-recorder \
        linuxKernel.packages.linux_xanmod_stable.nvidia_x11
      ];
      postInstall = ''
        install -Dt $out/bin gpu-screen-recorder gsr-kms-server
        mkdir $out/bin/.wrapped
        mv $out/bin/gpu-screen-recorder $out/bin/.wrapped/
        makeWrapper "$out/bin/.wrapped/gpu-screen-recorder" "$out/bin/gpu-screen-recorder" \
         --prefix LD_LIBRARY_PATH : ${pkgs.libglvnd}/lib \
         --prefix LD_LIBRARY_PATH : ${pkgs.libglvnd}/lib \
         --prefix LD_LIBRARY_PATH : ${pkgs.linuxKernel.packages.linux_xanmod_stable.nvidia_x11}/lib \
         --prefix LD_LIBRARY_PATH : ${config.boot.kernelPackages.nvidia_x11}/lib
        --prefix PATH : $out/bin
    '')
      '';
  ];
    }))
}
</syntaxhighlight>
</syntaxhighlight>
[[Category:Applications]]