diff --git a/OSC-Parameters.md b/OSC-Parameters.md index 720607c..ee0b090 100644 --- a/OSC-Parameters.md +++ b/OSC-Parameters.md @@ -1,33 +1,54 @@ -For compatibility, WlxOverlay-S implements all of the OSC parameters used by [XSOverlay](https://xsoverlay.vercel.app/OSC), as well as several more based on the same format for extended functionality. -The port used by WlxOverlay-S can be configured by setting `osc_out_port: ` inside the .yaml files inside `~/.config/wlxoverlay` +For compatibility, WlxOverlay-S implements all of the OSC parameters from [XSOverlay](https://xsoverlay.vercel.app/OSC) and most from [OVR Toolkit](https://wiki.ovrtoolkit.co.uk/#/OSC), as well as several more for extended functionality. This requires WlxOverlay-S to be built with the `osc` feature, which is enabled by default. -### Overlay Parameters +# Configuration -- `/avatar/parameters/isOverlayOpen` (bool): True if any overlay window is shown. -- `/avatar/parameters/isKeyboardOpen` (bool): True if the keyboard is shown. -- `/avatar/parameters/isWristVisible` (bool): True if the watch overlay is visible. -- `/avatar/parameters/openOverlayCount` (int 0-255): The amount of open overlay windows. +The port used by WlxOverlay-S can be configured with the `osc_out_port` config value: +```yaml +# ~/.config/wlxoverlay/conf.d/osc_out_port.yaml -### Headset Parameters +osc_out_port: 9000 +``` -- `/avatar/parameters/headsetBattery` (float 0-1): The battery level of the headset. -- `/avatar/parameters/headsetCharging` (bool): True when the headset is charging. -- `/avatar/parameters/hmdBattery` (int 0-100): Legacy OVR Toolkit style: The battery level of the headset. - - This may change in the future, as [OVR Toolkit's docs](https://wiki.ovrtoolkit.co.uk/#/OSC?id=how-do-i-use-it-1) state this parameter is a float 0-1 despite it being an int in the software. - - It is included for compatibility and should not be used for new systems. +# VRChat Parameters -### Controller Parameters +All of the following parameters are prefixed with `/avatar/parameters/` for use with VRChat; keep this in mind when using these parameters for other programs. -- `/avatar/parameters/leftControllerBattery` `rightControllerBattery` (float 0-1): The battery level of the controller. -- `/avatar/parameters/leftControllerCharging` `rightControllerCharging` (bool): True when the controller is charging. -- `/avatar/parameters/averageControllerBattery` (float 0-1): Average battery level of controllers. +## Overlay Parameters -### Tracker Parameters +- `isOverlayOpen` or `ToggleWindows` (bool): True if any overlay window is shown. +- `isKeyboardOpen` or `ToggleKeyboard` (bool): True if the keyboard is shown. +- `isWristVisible` (bool): True if the watch overlay is visible. +- `openOverlayCount` (int >= 0): The amount of open overlay windows in the current working set. +- `isEditModeActive` or `ToggleEditMode` (bool) - Whether "Working Set Edit Mode" is currently active. +- `currentWorkingSet` or `CurrentProfile` (int >= 0) - The currently active working set, 0-indexed. (todo: check if this is 1 or 0-indexed in OVR Toolkit) +- `totalWorkingSets` (int >= 0) - The total amount of working sets that have been created. -Tracker parameters are dynamic, and increase in number for as many tracker devices are connected. For example with 3 trackers connected, parameters for trackers 1, 2, and 3 will be sent. +## Headset Parameters -- `/avatar/parameters/tracker1Battery`, `/avatar/parameters/tracker2Battery`, etc (float 0-1): 1-indexed tracker device battery level. -- `/avatar/parameters/tracker1Charging`, `/avatar/parameters/tracker2Charging`, etc (bool): 1-indexed tracker device charging state. -- `/avatar/parameters/averageTrackerBattery` (float 0-1): Average battery level of all trackers. +- `hmdBattery` (float 0-1): The battery level of the headset. +- `hmdCharging` (bool): True when the headset is charging. + +## Controller Parameters + +- `leftControllerBattery` `rightControllerBattery` (float 0-1): The battery level of the controller. +- `leftControllerCharging` `rightControllerCharging` (bool): True when the controller is charging. +- `averageControllerBattery` (float 0-1): Average battery level of controllers. + +## Tracker Parameters + +Tracker parameters dynamically increase in number for as many tracker devices exist. For example, with 3 trackers WlxOverlay-S will send parameters for `tracker1`, `tracker2`, and `tracker3`. + +- `trackerBattery` or `tracker1Battery`, etc (float 0-1): 1-indexed tracker device battery level. +- `trackerCharging` or `tracker1Charging`, etc (bool): 1-indexed tracker device charging state. +- `averageTrackerBattery` (float 0-1): Average battery level of all trackers. +- `lowestBattery` or `LowestBattery` (float 0-1): The lowest battery level out of all devices, including the HMD, controllers, and trackers. + +## Excluded Parameters + +The following parameters are currently missing for full parity: + +### OVR Toolkit +- `MediaPlaying` (bool) - Whether the overlay is currently playing media. + - WlxOverlay-S does not directly support controlling media playback, however it should be possible to create a button which sends this parameter as an `::OscSend` Button Action alongside a command to play or pause media.