From d8de19d4ae6d4ded8ba9ebcfa3f483b7d82c77a5 Mon Sep 17 00:00:00 2001 From: Christoph Haag Date: Thu, 25 Jun 2020 03:31:43 +0200 Subject: [PATCH] d/vive_controller: Add and set Index "Gen2" input names --- src/xrt/drivers/vive/vive_controller_driver.c | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/src/xrt/drivers/vive/vive_controller_driver.c b/src/xrt/drivers/vive/vive_controller_driver.c index 828e90bb7..2ec3b4e0a 100644 --- a/src/xrt/drivers/vive/vive_controller_driver.c +++ b/src/xrt/drivers/vive/vive_controller_driver.c @@ -99,6 +99,14 @@ enum vive_controller_input_index VIVE_CONTROLLER_INDEX_A_CLICK, VIVE_CONTROLLER_INDEX_B_CLICK, VIVE_CONTROLLER_INDEX_THUMBSTICK_CLICK, + VIVE_CONTROLLER_INDEX_THUMBSTICK_TOUCH, + VIVE_CONTROLLER_INDEX_SYSTEM_TOUCH, + VIVE_CONTROLLER_INDEX_A_TOUCH, + VIVE_CONTROLLER_INDEX_B_TOUCH, + VIVE_CONTROLLER_INDEX_SQUEEZE_VALUE, + VIVE_CONTROLLER_INDEX_SQUEEZE_FORCE, + VIVE_CONTROLLER_INDEX_TRIGGER_TOUCH, + VIVE_CONTROLLER_INDEX_TRACKPAD_FORCE, VIVE_CONTROLLER_MAX_INDEX, }; @@ -1177,6 +1185,15 @@ vive_controller_found(struct xrt_prober *xp, SET_INDEX_INPUT(THUMBSTICK, THUMBSTICK); SET_INDEX_INPUT(THUMBSTICK_CLICK, THUMBSTICK_CLICK); + SET_INDEX_INPUT(THUMBSTICK_TOUCH, THUMBSTICK_TOUCH); + SET_INDEX_INPUT(SYSTEM_TOUCH, SYSTEM_TOUCH); + SET_INDEX_INPUT(A_TOUCH, A_TOUCH); + SET_INDEX_INPUT(B_TOUCH, B_TOUCH); + SET_INDEX_INPUT(SQUEEZE_VALUE, SQUEEZE_VALUE); + SET_INDEX_INPUT(SQUEEZE_FORCE, SQUEEZE_FORCE); + SET_INDEX_INPUT(TRIGGER_TOUCH, TRIGGER_TOUCH); + SET_INDEX_INPUT(TRACKPAD_FORCE, TRACKPAD_FORCE); + SET_INDEX_INPUT(AIM_POSE, AIM_POSE); SET_INDEX_INPUT(GRIP_POSE, GRIP_POSE);