Monado OpenXR Runtime
rift_radio.c File Reference

Radio state machine functions for the Oculus Rift. More...

#include "util/u_device.h"
#include "util/u_var.h"
#include "rift_radio.h"
#include "rift_bindings.h"
Include dependency graph for rift_radio.c:

Macros

#define SET_INPUT(NAME)
 
#define SET_INPUT(NAME, ACTIVE)
 

Functions

static void rift_update_input (struct xrt_device *device, size_t index, union xrt_input_value value, int64_t now)
 
static xrt_result_t rift_touch_controller_get_tracked_pose (struct xrt_device *xdev, const enum xrt_input_name name, int64_t at_timestamp_ns, struct xrt_space_relation *out_relation)
 
static void rift_touch_controller_destroy (struct xrt_device *xdev)
 
static xrt_result_t rift_touch_controller_update_inputs (struct xrt_device *xdev)
 
static xrt_result_t rift_remote_get_tracked_pose (struct xrt_device *xdev, const enum xrt_input_name name, int64_t at_timestamp_ns, struct xrt_space_relation *out_relation)
 
static void rift_remote_destroy (struct xrt_device *xdev)
 
static xrt_result_t rift_remote_update_inputs (struct xrt_device *xdev)
 
static struct rift_remoterift_remote_create (struct rift_hmd *hmd)
 
static struct rift_touch_controllerrift_touch_controller_create (struct rift_hmd *hmd, enum rift_radio_device_type device_type)
 
int rift_radio_handle_read (struct rift_hmd *hmd)
 
int rift_radio_handle_command (struct rift_hmd *hmd)
 

Detailed Description

Radio state machine functions for the Oculus Rift.

Author
Beyley Cardellio ep1cm.nosp@m.1n10.nosp@m.n123@.nosp@m.gmai.nosp@m.l.com

Macro Definition Documentation

◆ SET_INPUT [1/2]

#define SET_INPUT (   NAME)
Value:
do { \
remote->base.inputs[RIFT_REMOTE_INPUT_##NAME].name = XRT_INPUT_RIFT_REMOTE_##NAME##_CLICK; \
} while (0)

◆ SET_INPUT [2/2]

#define SET_INPUT (   NAME,
  ACTIVE 
)
Value:
do { \
if (ACTIVE) { \
controller->base.inputs[RIFT_TOUCH_CONTROLLER_INPUT_##NAME].name = XRT_INPUT_TOUCH_##NAME; \
controller->base.inputs[RIFT_TOUCH_CONTROLLER_INPUT_##NAME].active = ACTIVE; \
} \
} while (0)