VR: Difference between revisions

Ardenet (talk | contribs)
Marked this version for translation
Remove services.wivrn.defaultRuntime from example configuration, WiVRn manages the active runtime configuration itself and having it set this way will hang apps if a headset is not connected
 
(4 intermediate revisions by 3 users not shown)
Line 139: Line 139:
   enable = true;
   enable = true;
   openFirewall = true;
   openFirewall = true;
  # Write information to /etc/xdg/openxr/1/active_runtime.json, VR applications
  # will automatically read this and work with WiVRn (Note: This does not currently
  # apply for games run in Valve's Proton)
    defaultRuntime = true;


   # Run WiVRn as a systemd service on startup
   # Run WiVRn as a systemd service on startup
   autoStart = true;
   autoStart = true;


   # Config for WiVRn (https://github.com/WiVRn/WiVRn/blob/master/docs/configuration.md)
   # If you're running this with an nVidia GPU and want to use GPU Encoding (and don't otherwise have CUDA enabled system wide), you need to override the cudaSupport variable.
  config = {
  package = (pkgs.wivrn.override { cudaSupport = true; });
    enable = true;
 
    json = {
  # You should use the default configuration (which is no configuration), as that works the best out of the box.
      # 1.0x foveation scaling
  # However, if you need to configure something see https://github.com/WiVRn/WiVRn/blob/master/docs/configuration.md for configuration options and https://mynixos.com/nixpkgs/option/services.wivrn.config.json for an example configuration.
      scale = 1.0;
};|name=configuration.nix|lang=nix}}
      # 100 Mb/s
      bitrate = 100000000;
      encoders = [
        {
          encoder = "vaapi";
          codec = "h265";
          # 1.0 x 1.0 scaling
          width = 1.0;
          height = 1.0;
          offset_x = 0.0;
          offset_y = 0.0;
        }
      ];
    };
  };
};}}


<translate>
<translate>
Line 259: Line 238:
}}
}}
{{file|/etc/nixos/bwrap.patch|diff|3=diff --git a/bubblewrap.c b/bubblewrap.c
{{file|/etc/nixos/bwrap.patch|diff|3=diff --git a/bubblewrap.c b/bubblewrap.c
index 8322ea0..4e20262 100644
index 69d319b..02e117d 100644
--- a/bubblewrap.c
--- a/bubblewrap.c
+++ b/bubblewrap.c
+++ b/bubblewrap.c
@@ -868,13 +868,6 @@ acquire_privs (void)
@@ -876,13 +876,6 @@ acquire_privs (void)
       /* Keep only the required capabilities for setup */
       /* Keep only the required capabilities for setup */
       set_required_caps ();
       set_required_caps ();