Home › Forums › XR Discussions › How to get eye coordinates from HTC Vive Pro Eye › Reply To: How to get eye coordinates from HTC Vive Pro Eye
Yes, I tried using the eye origin but it doesn’t seem to working as expected. Let me explain what I am trying to do. I need the gaze coordinates on a 2D plane i.e. on the viewport of the camera. I am just trying to move a sphere gameobject with user’s gaze. Now, if I try to keep the sphere at TobiiXR.EyeTrackingData.GazeRay.Origin it doesn’t seem to follow the gaze and if I move my head it goes out of the field of view. I used these coordinates for the sphere’s position :
var rayOrigin = TobiiXR.EyeTrackingData.GazeRay.Origin;
sphere.transform.position = new Vector3( rayOrigin.x, rayOrigin.y, (camPosition.z + camForward.z * 1f));
Do you have any suggestions for me Grant? Thanks in advance.