Example #1
0
 public GazeTrainingSnapshot(ARFaceAnchor anchor, CGPoint gazePoint, CMAttitude attitude)
 {
     this.SetGazeTarget(gazePoint);
     this.SetTransform(anchor.Transform);
     this.SetBlendingShapes(anchor.BlendShapes);
     this.SetAttitude(attitude);
 }
Example #2
0
 public static void SetAttitude(this IGazeSnapshot snapshot, CMAttitude attitude)
 {
     snapshot.qW = attitude.Quaternion.w;
     snapshot.qX = attitude.Quaternion.x;
     snapshot.qY = attitude.Quaternion.y;
     snapshot.qZ = attitude.Quaternion.z;
 }
Example #3
0
        public static GazePredictionInput FromAnchor(ARFaceAnchor faceAnchor, CMAttitude attitude)
        {
            var snapshot = new GazePredictionInput();

            snapshot.SetAttitude(attitude);
            snapshot.SetTransform(faceAnchor.Transform);
            snapshot.SetBlendingShapes(faceAnchor.BlendShapes);

            return(snapshot);
        }
Example #4
0
        void OnGyroscopeDataUpdate(CMDeviceMotion gyroData, NSError error)
        {
            if (error == null)
            {
                _attitude  = gyroData.Attitude;
                data.Angle = _attitude.Yaw;

                OnCompassDataChanged(this, data);
            }
        }