Store eye gaze relative to view

This commit is contained in:
Patrick Nicolas
2026-02-04 09:37:26 +01:00
parent 02b212483c
commit 67f4ced505
8 changed files with 58 additions and 54 deletions
+6 -2
View File
@@ -34,13 +34,13 @@
namespace wivrn
{
wivrn_eye_tracker::wivrn_eye_tracker(xrt_device * hmd, wivrn_session & cnx) :
wivrn_eye_tracker::wivrn_eye_tracker(wivrn_session & cnx) :
xrt_device{
.name = XRT_DEVICE_EYE_GAZE_INTERACTION,
.device_type = XRT_DEVICE_TYPE_EYE_TRACKER,
.str = "WiVRn Eye Tracker",
.serial = "WiVRn Eye Tracker",
.tracking_origin = hmd->tracking_origin,
.tracking_origin = &origin,
.input_count = 1,
.inputs = &gaze_input,
.supported = {
@@ -50,6 +50,10 @@ wivrn_eye_tracker::wivrn_eye_tracker(xrt_device * hmd, wivrn_session & cnx) :
.get_tracked_pose = method_pointer<&wivrn_eye_tracker::get_tracked_pose>,
.destroy = [](xrt_device *) {},
},
origin{
.type = XRT_TRACKING_TYPE_ATTACHABLE,
.initial_offset = XRT_POSE_IDENTITY,
},
gaze_input{
.active = true,
.name = XRT_INPUT_GENERIC_EYE_GAZE_POSE,