Jump to content

Getting Screen Position of the Gaze in Unity

Recommended Posts

  • 1 month later...



I have recently started working with unity and Sranipal.  I have tried to follow the steps described in the recent posts here but still have a few questions related to the conversion between gaze direction screen and world coordinates...

1. In what way gaze direction is related to the screen coordinates in unity? is this the correct conversion to pixels?

  Left_E_gaze_direction_normalized = verboseData.left.gaze_direction_normalized;

x_pix_resolution=1440;  y_pix_resolution=1600;

 left_eye_x_pixels = Left_E_gaze_direction_normalized.x / x_pix_resolution;
  left_eye_z_pixels = Left_E_gaze_direction_normalized.z / y_pix_resolution;

2. Conversion to world coordinates:

Left_eye_position_world_coordinates= Camera.ScreenToWorldPoint( left_eye_x_pixels, left_eye_z_pixels, left_eye_y_pixels);

3. In what way gaze origin is related to these transformations? /or if it isn't why is it provided? 

I would greatly appreciate your help:)






  • Like 1
Link to post
Share on other sites

Please sign in to comment

You need to be a member in order to leave a comment

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...