Search Unity

Question How does Unity get the distance between the eyes for Hololens stereo rendering?

Discussion in 'AR' started by jaclemoe, Oct 28, 2020.

  1. jaclemoe

    jaclemoe

    Joined:
    May 10, 2020
    Posts:
    2
    I have a use-case that involves remote rendering, this means I need the camera positions/rotation (cameraToWorldMatrix) for each eye.

    I have tried several approaches which have all come up short, but Unity must know this information to do it's own stereographic render for each eye with the Hololens eye calibration data, for example, the interpupillary distance (horizontal offset between left and right eye pupil).

    Approaches I have tried and results so far:
    • MRTK GazeProvider, gives only a single center-eye gaze origin.
    • Unity
      camera.stereoSeparation
      which comes back at 2.2cm (a constant set by MRTK somewhere, seems too small, with average IPD being 63mm for a male)
    • Unity
      UnityEngine.SpatialTracking.PoseDataSource.TryGetDataFromSource(UnityEngine.SpatialTracking.TrackedPoseDriver.TrackedPose.LeftEye, ...
      which returns the left and right eye offset as zero.