This commit is contained in:
parent
00f0381893
commit
ed1a4501f7
2 changed files with 22 additions and 5 deletions
|
@ -18,5 +18,16 @@ in
|
||||||
sha256 = "x/X4HyyHdQUxn3CdMbWj5cfLvV7UyQe1D01H93UCk+M=";
|
sha256 = "x/X4HyyHdQUxn3CdMbWj5cfLvV7UyQe1D01H93UCk+M=";
|
||||||
fetchLFS = true;
|
fetchLFS = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
xdg.configFile."openxr/1/active_runtime.json".source = "${pkgs.monado}/share/openxr/1/openxr_monado.json";
|
||||||
|
|
||||||
|
xdg.configFile."openvr/openvrpaths.vrpath".text = builtins.toJSON {
|
||||||
|
config = [ "${config.xdg.dataHome}/Steam/config" ];
|
||||||
|
external_drivers = null;
|
||||||
|
jsonid = "vrpathreg";
|
||||||
|
log = [ "${config.xdg.dataHome}/Steam/logs" ];
|
||||||
|
runtime = [ "${pkgs.opencomposite}/lib/opencomposite" ];
|
||||||
|
version = 1;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
|
@ -20,6 +20,14 @@ in
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
# https://wiki.nixos.org/wiki/VR
|
# https://wiki.nixos.org/wiki/VR
|
||||||
# https://github.com/NixOS/nixpkgs/issues/258196
|
# https://github.com/NixOS/nixpkgs/issues/258196
|
||||||
|
#
|
||||||
|
# Monado can be run with the following commands:
|
||||||
|
# systemctl --user start monado.service
|
||||||
|
# systemctl --user stop monado.{service,socket}
|
||||||
|
# journalctl --user --follow --unit monado.service
|
||||||
|
# Games require LAUNCH OPTIONS: "env PRESSURE_VESSEL_FILESYSTEMS_RW=$XDG_RUNTIME_DIR/monado_comp_ipc %command%"
|
||||||
|
#
|
||||||
|
# Requires also `configs.monado.enable = true;` in home.nix for the user to work well
|
||||||
services.monado = {
|
services.monado = {
|
||||||
enable = true;
|
enable = true;
|
||||||
defaultRuntime = true;
|
defaultRuntime = true;
|
||||||
|
@ -29,12 +37,10 @@ in
|
||||||
systemd.user.services.monado.environment = {
|
systemd.user.services.monado.environment = {
|
||||||
STEAMVR_LH_ENABLE = "1";
|
STEAMVR_LH_ENABLE = "1";
|
||||||
XRT_COMPOSITOR_COMPUTE = "1";
|
XRT_COMPOSITOR_COMPUTE = "1";
|
||||||
};
|
|
||||||
|
|
||||||
environment.variables = {
|
|
||||||
STEAMVR_LH_ENABLE = "1";
|
|
||||||
XRT_COMPOSITOR_COMPUTE = "1";
|
|
||||||
WMR_HANDTRACKING = "0";
|
WMR_HANDTRACKING = "0";
|
||||||
|
|
||||||
|
# Enable debugging if needed
|
||||||
|
XRT_DEBUG_GUI = "0";
|
||||||
};
|
};
|
||||||
|
|
||||||
boot.kernelPatches = mkIf cfg.enableAmdgpuPatch [
|
boot.kernelPatches = mkIf cfg.enableAmdgpuPatch [
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue