XR for Universal Blue and Fedora Atomic Desktops
vr fedora-atomic linux
3
fork

Configure Feed

Select the types of activity you want to include in your feed.

Support using steamvr-lh/console with native steam

+25 -7
+25 -7
src/atomic-xr/steamvr-lh.nu
··· 17 17 export def calibrate [] { 18 18 # TODO: Support using native steam installation 19 19 log warning "This is intended for Flatpak Steam, if you're using native Steam, please use Envision instead." 20 - log warning "If you'd like to see native Steam functionality in AtomicXR, please open an issue on Tangled." 20 + log warning "If you'd like to use this feature with native Steam, please open an issue on Tangled." 21 21 22 22 if (ask yn "Do you own a lighthouse-tracked HMD? (e.g. Index, Vive Pro)") { 23 23 input -sn 1 "Please connect your headset and place it on the floor, then press any key to start the calibration." ··· 44 44 if not ("~/.steam/root/config/lighthouse/" | path exists) { 45 45 error make { 46 46 msg: "Could not find lighthouse configuration directory." 47 - help: "Make sure you have SteamVR installed, and .steam points to the correct location. You may need to select \"Symlink .steam directory\" in `axr icfg` if you're using the Steam Flatpak." 47 + help: "Make sure you have SteamVR installed, and .steam points to the correct location. You may need to run `axr flatpak steam enable-xr` if you're using the Steam Flatpak." 48 48 } 49 49 } 50 50 ··· 60 60 } 61 61 } 62 62 63 + # Run lighthouse console natively or via flatpak depending on which is installed 64 + def lh-console [...args]: any -> any { 65 + if (which lighthouse_console | length) > 0 { 66 + log debug "Running lighthouse_console from PATH" 67 + run-external lighthouse_console 68 + } else if not ("~/.steam" | path exists) and ( 69 + "~/.var/app/com.valvesoftware.Steam/.steam/root/steamapps/common/SteamVR/tools/lighthouse/bin/linux64/lighthouse_console" 70 + | path exists 71 + ) or (ls -lD ~/.steam).0.target == ("~/.var/app/com.valvesoftware.Steam/.steam/" | path expand) { 72 + log debug "Running lighthouse_console from steam flatpak" 73 + flatpak run --command=$"($env.HOME)/.var/app/com.valvesoftware.Steam/.steam/root/steamapps/common/SteamVR/tools/lighthouse/bin/linux64/lighthouse_console" com.valvesoftware.Steam ...$args 74 + } else if ("~/.steam" | path exists) { 75 + log debug "Running lighthouse_console from steam native" 76 + run-external $"($env.HOME)/.steam/root/steamapps/common/SteamVR/tools/lighthouse/bin/linux64/lighthouse_console" ...$args 77 + } else { 78 + error make { 79 + msg: "Could not find lighthouse_console" 80 + help: "Please make sure SteamVR is installed" 81 + } 82 + } 83 + } 84 + 63 85 # Open SteamVR's lighthouse_console 64 86 # 65 87 # Useful for pairing, dumping device configs, etc. 66 88 export def console [ 67 89 ...args # Arguments to pass to lighthouse_console 68 90 ] { 69 - # TODO: Support using native steam installation 70 - log warning "This is intended for Flatpak Steam, if you're using native Steam, please use Envision instead." 71 - log warning "If you'd like to see this functionality in AtomicXR, please open an issue on Tangled." 72 - 73 - flatpak run --command=$"($env.HOME)/.steam/root/steamapps/common/SteamVR/tools/lighthouse/bin/linux64/lighthouse_console" com.valvesoftware.Steam ...$args 91 + lh-console ...$args 74 92 }