예제 #1
0
 void Start()
 {
     host   = EyeXHost.GetInstance();
     gaze   = host.GetGazePointDataProvider(Tobii.EyeX.Framework.GazePointDataMode.LightlyFiltered);
     player = gameObject.GetComponentInParent <PlayerController>();
     gaze.Start();
 }
예제 #2
0
 // Use this for initialization
 void Start()
 {
     _eyeXHost          = EyeXHost.GetInstance();
     _gazePointProvider = _eyeXHost.GetGazePointDataProvider
                              (Tobii.EyeX.Framework.GazePointDataMode.LightlyFiltered);
     _gazePointProvider.Start();
 }
예제 #3
0
    /// <summary>
    /// Draw a GUI.Box at the user's gaze point.
    /// </summary>
    public void OnGUI()
    {
#if UNITY_EDITOR
        if (_oldGazePointMode != gazePointMode)
        {
            _gazePointProvider.Stop();
            _oldGazePointMode  = gazePointMode;
            _gazePointProvider = _eyeXHost.GetGazePointDataProvider(gazePointMode);
            _gazePointProvider.Start();
        }
#endif
        var gazePoint = _gazePointProvider.Last;
        //filter nan values.
        if (!System.Single.IsNaN(gazePoint.Screen.x))
        {
            //update
            if (trackObserver_eye != null)
            {
                trackObserver_eye.updateEyeTrack(gazePoint);
                ScenedataCapt.storeTrackPoint(gazePoint);
                DrawGUI(gazePoint, pointSize, pointColor);
            }
            if (trackObserver_eyemouse != null)
            {
                trackObserver_eyemouse.updateEyeTrack(gazePoint);
                ScenedataCapt.storeTrackPoint(gazePoint);
                DrawGUI(gazePoint, pointSize, pointColor);
            }
        }
    }
예제 #4
0
    void Start()
    {
        host = EyeXHost.GetInstance();
        //eyePos = host.GetEyePositionDataProvider();
        gazePos = host.GetGazePointDataProvider(Tobii.EyeX.Framework.GazePointDataMode.LightlyFiltered);
        gazePos.Start();

        ResetHealth();
    }
예제 #5
0
    /// <summary>
    /// Draw a GUI.Box at the user's gaze point.
    /// </summary>
    public void OnGUI()
    {
#if UNITY_EDITOR
        if (_oldGazePointMode != gazePointMode)
        {
            _gazePointProvider.Stop();
            _oldGazePointMode  = gazePointMode;
            _gazePointProvider = _eyeXHost.GetGazePointDataProvider(gazePointMode);
            _gazePointProvider.Start();
        }
#endif

        var gazePoint = _gazePointProvider.Last;
        DrawGUI(gazePoint, pointSize, pointColor, string.Empty);
    }
예제 #6
0
    /// <summary>
    /// Draw a GUI.Box at the user's gaze point.
    /// </summary>
    public void OnGUI()
    {
#if UNITY_EDITOR
        if (_oldGazePointMode != gazePointMode)
        {
            _gazePointProvider.Stop();
            _oldGazePointMode = gazePointMode;
            _gazePointProvider = _eyeXHost.GetGazePointDataProvider(gazePointMode);
            _gazePointProvider.Start();
        }
#endif

        var gazePoint = _gazePointProvider.Last;
        DrawGUI(gazePoint, pointSize, pointColor, string.Empty);
    }
    /// <summary>
    /// Draw a GUI.Box at the user's fixation point.
    /// </summary>
    public void OnGUI()
    {
#if UNITY_EDITOR
        if (_oldFixationDataMode != fixationDataMode)
        {
            _fixationDataProvider.Stop();
            _oldFixationDataMode  = fixationDataMode;
            _fixationDataProvider = _eyeXHost.GetFixationDataProvider(fixationDataMode);
            _fixationDataProvider.Start();
        }
#endif

        var fixationPoint = _fixationDataProvider.Last;
        if (fixationPoint.IsValid)
        {
            if (FixationDataEventType.Begin == fixationPoint.EventType)
            {
                _fixationCount++;
            }

            //DrawGUI(fixationPoint.GazePoint, pointSize, pointColor, _fixationCount.ToString());
        }
    }
예제 #8
0
    /// <summary>
    /// Draw a GUI.Box at the user's fixation point.
    /// </summary>
    public void OnGUI()
    {
#if UNITY_EDITOR
        if (_oldFixationDataMode != fixationDataMode)
        {
            _fixationDataProvider.Stop();
            _oldFixationDataMode = fixationDataMode;
            _fixationDataProvider = _eyeXHost.GetFixationDataProvider(fixationDataMode);
            _fixationDataProvider.Start();
        }
#endif

        var fixationPoint = _fixationDataProvider.Last;
        if (fixationPoint.IsValid)
        {
            if (FixationDataEventType.Begin == fixationPoint.EventType)
            {
                _fixationCount++;
            }

            DrawGUI(fixationPoint.GazePoint, pointSize, pointColor, _fixationCount.ToString());
        }
    }
 protected void OnEnable()
 {
     _dataProvider.Start();
 }
예제 #10
0
 public void OnEnable()
 {
     _gazePointProvider.Start();
 }
 public void OnEnable()
 {
     _fixationDataProvider.Start();
 }
예제 #12
0
    private bool currentBlinkingLightRemoved;     // bool that is set when the current blinkin light was already removed (to avoid double-removing)

    protected void OnEnable()
    {
        eyePositionDataProvider.Start();
        gazePointDataProvider.Start();
    }
        public override void OnEnter()
        {
            _dataProvider = EyeXHost.GetInstance().GetGazePointDataProvider(lightlyFiltered.Value?GazePointDataMode.LightlyFiltered:GazePointDataMode.Unfiltered);

            _dataProvider.Start();
        }
예제 #14
0
        public override void OnEnter()
        {
            _dataProvider = EyeXHost.GetInstance().GetGazePointDataProvider(lightlyFiltered.Value?GazePointDataMode.LightlyFiltered:GazePointDataMode.Unfiltered);

            _dataProvider.Start();
        }