Skip to content

Commit

Permalink
Move configuration to a seperate documentation file
Browse files Browse the repository at this point in the history
  • Loading branch information
rblenkinsopp committed Apr 8, 2024
1 parent e013f74 commit c6d7420
Show file tree
Hide file tree
Showing 5 changed files with 91 additions and 67 deletions.
91 changes: 25 additions & 66 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,33 @@
# Ultraleap SteamVR Driver
<p align="center">
<a href="https://ultraleap.com#gh-light-mode-only"><img height="33%" width="33%" style="margin-bottom: -60px" alt="Ultraleap" src="doc/UltraleapLogoColor.png" /></a>
<a href="https://ultraleap.com#gh-dark-mode-only"><img height="33%" width="33%" style="margin-bottom: -60px" alt="Ultraleap" src="doc/UltraleapLogoDarkMode.png" /></a>
</p>

This is the official Ultraleap driver for SteamVR, supporting using your hands as a first class input system.
<span align="center">

# SteamVR Driver

</span>

[![Build](https://github.com/rblenkinsopp/driver_ultraleap/actions/workflows/build.yml/badge.svg)](https://github.com/rblenkinsopp/driver_ultraleap/actions/workflows/build.yml)
<p align="center">
<img height="32px" width="32px" alt="LMC" src="ultraleap/resources/icons/[email protected]" />
<img height="32px" width="32px" alt="SIR170" src="ultraleap/resources/icons/[email protected]" />
<img height="32px" width="32px" alt="3di" src="ultraleap/resources/icons/[email protected]" />
<img height="32px" width="32px" alt="LMC2" src="ultraleap/resources/icons/[email protected]" />
</p>

<p align="center">
This is the official Ultraleap driver for SteamVR, supporting using your hands as a first class input system.
</p>

## Supported devices

This driver supports the follow Ultraleap/Leap Motion devices

| Device Name | Icon |
|:-------------------------|-------------------------------------------------------------------------------------|
| Leap Motion Controller | ![Leap Motion Controller icon](ultraleap/resources/icons/lmc_status_ready.png) |
| Leap Motion Controller 2 | ![Leap Motion Controller 2 icon](ultraleap/resources/icons/lmc2_status_ready.png) |
| Ultraleap 3di | ![Leap Motion Controller 2 icon](ultraleap/resources/icons/3di_status_ready.png) |
| Ultraleap StereoIR 170 | ![Leap Motion Controller 2 icon](ultraleap/resources/icons/sir170_status_ready.png) |
* Leap Motion Controller
* Leap Motion Controller 2
* Ultraleap 3di
* Ultraleap StereoIR 170

## Installation

Expand All @@ -27,63 +41,8 @@ This driver supports the follow Ultraleap/Leap Motion devices

## Configuration

The driver comes with some configurable options and predefined defaults which the user can change if desired.
To overwrite the defaults navigate to `${SteamInstallFolder}/config` and edit the `steamvr.vrsettings` file
whilst SteamVR **isn't** open.

When adding the following key value pair configurations, ensure that they are only added under the
`driver_ultraleap` section. Any values that aren't defined in `steamvr.vrsettings` will fallback to defaults,
so you should only redefine the ones you actively want changed.

### Valid Configuration Keys

| Key | Description | Type/Values | Default |
|-------------------------|----------------------------------------------------|------------------|---------|
| `tracker_mode` | Sets the requested tracking mode | `hmd`, `desktop` | `hmd` |
| `hmd_offset_x` | X-axis tracker offset for HMD mode | _meters_ | `0.0` |
| `hmd_offset_y` | Y-axis tracker offset for HMD mode | _meters_ | `0.0` |
| `hmd_offset_z` | Z-axis tracker offset for HMD mode | _meters_ | `-0.08` |
| `desktop_offset_x` | X-axis tracker offset for desktop mode | _meters_ | `0.0` |
| `desktop_offset_y` | Y-axis tracker offset for desktop mode | _meters_ | `-0.2` |
| `desktop_offset_z` | Z-axis tracker offset for desktop mode | _meters_ | `-0.35` |
| `enable_elbow_trackers` | Enable elbow trackers | `true`/`false` | `true` |
| `external_input_only` | Disable driver input (for external input) | `true`/`false` | `false` |
| `extended_hand_profile` | Extended hand-profile support (for external input) | `true`/`false` | `false` |

> **NOTE:** HMD offsets follow
> the [OpenXR View space convention](https://openxr-tutorial.com/windows/opengl/_images/ViewSpace.png).
### Example

A simplified example of the `steamvr.vrsettings` would look like the following:

```json
{
"DesktopUI": {
"controllerbinding_desktop": "151,39,1920,1073,0"
},
"GpuSpeed": {
"gpuSpeedRenderTargetScale": 1.5,
"gpuSpeedVendor": "NVIDIA GeForce RTX 3080 Ti Laptop GPU"
},
"LastKnown": {
"ActualHMDDriver": "holographic",
"HMDManufacturer": "WindowsMR",
"HMDModel": "Perception Simulation Headset0"
},
"driver_ultraleap": {
"blocked_by_safe_mode": false,
"orientation": "Desktop"
},
"steamvr": {
"showAdvancedSettings": true
}
}
```

> **NOTE**: This settings file _must_ be valid JSON. Errors like additional trailing commas will cause issues
> when loading settings, resulting in default values being used instead. Ensure you check your JSON with a suitable
> [JSON validator](https://jsonlint.com/) before saving.
The SteamVR driver supports a number of configuration options which are details in
the [configuration guide](doc/Configuration.md).

## Uninstallation

Expand Down
59 changes: 59 additions & 0 deletions doc/Configuration.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
# Configuration

The driver comes with some configurable options and predefined defaults which the user can change if desired.
To overwrite the defaults navigate to `${SteamInstallFolder}/config` and edit the `steamvr.vrsettings` file
whilst SteamVR **isn't** open.

When adding the following key value pair configurations, ensure that they are only added under the
`driver_ultraleap` section. Any values that aren't defined in `steamvr.vrsettings` will fallback to defaults,
so you should only redefine the ones you actively want changed.

## Valid Configuration Keys

| Key | Description | Type/Values | Default |
|-------------------------|----------------------------------------------------|------------------|---------|
| `tracker_mode` | Sets the requested tracking mode | `hmd`, `desktop` | `hmd` |
| `hmd_offset_x` | X-axis tracker offset for HMD mode | _meters_ | `0.0` |
| `hmd_offset_y` | Y-axis tracker offset for HMD mode | _meters_ | `0.0` |
| `hmd_offset_z` | Z-axis tracker offset for HMD mode | _meters_ | `-0.08` |
| `desktop_offset_x` | X-axis tracker offset for desktop mode | _meters_ | `0.0` |
| `desktop_offset_y` | Y-axis tracker offset for desktop mode | _meters_ | `-0.2` |
| `desktop_offset_z` | Z-axis tracker offset for desktop mode | _meters_ | `-0.35` |
| `enable_elbow_trackers` | Enable elbow trackers | `true`/`false` | `true` |
| `external_input_only` | Disable driver input (for external input) | `true`/`false` | `false` |
| `extended_hand_profile` | Extended hand-profile support (for external input) | `true`/`false` | `false` |

> **NOTE:** HMD offsets follow
> the [OpenXR View space convention](https://openxr-tutorial.com/windows/opengl/_images/ViewSpace.png).
## Example

A simplified example of the `steamvr.vrsettings` would look like the following:

```json
{
"DesktopUI": {
"controllerbinding_desktop": "151,39,1920,1073,0"
},
"GpuSpeed": {
"gpuSpeedRenderTargetScale": 1.5,
"gpuSpeedVendor": "NVIDIA GeForce RTX 3080 Ti Laptop GPU"
},
"LastKnown": {
"ActualHMDDriver": "holographic",
"HMDManufacturer": "WindowsMR",
"HMDModel": "Perception Simulation Headset0"
},
"driver_ultraleap": {
"blocked_by_safe_mode": false,
"orientation": "Desktop"
},
"steamvr": {
"showAdvancedSettings": true
}
}
```

> **NOTE**: This settings file _must_ be valid JSON. Errors like additional trailing commas will cause issues
> when loading settings, resulting in default values being used instead. Ensure you check your JSON with a suitable
> [JSON validator](https://jsonlint.com/) before saving.
3 changes: 3 additions & 0 deletions doc/UltraleapLogoColor.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions doc/UltraleapLogoDarkMode.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion ultraleap/resources/settings/default.vrsettings
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
"desktop_tracker_offset_x": 0.0,
"desktop_tracker_offset_y": -0.2,
"desktop_tracker_offset_z": -0.35,
"enable_elbow_trackers": true,
"enable_elbow_trackers": false,
"external_input_only": false,
"extended_hand_profile": false
},
Expand Down

0 comments on commit c6d7420

Please sign in to comment.