void Start() { host = EyeXHost.GetInstance(); gaze = host.GetGazePointDataProvider(Tobii.EyeX.Framework.GazePointDataMode.LightlyFiltered); player = gameObject.GetComponentInParent <PlayerController>(); gaze.Start(); }
// Use this for initialization void Start() { _eyeXHost = EyeXHost.GetInstance(); _gazePointProvider = _eyeXHost.GetGazePointDataProvider (Tobii.EyeX.Framework.GazePointDataMode.LightlyFiltered); _gazePointProvider.Start(); }
/// <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); } } }
void Start() { host = EyeXHost.GetInstance(); //eyePos = host.GetEyePositionDataProvider(); gazePos = host.GetGazePointDataProvider(Tobii.EyeX.Framework.GazePointDataMode.LightlyFiltered); gazePos.Start(); ResetHealth(); }
/// <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()); } }
/// <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(); }
public void OnEnable() { _gazePointProvider.Start(); }
public void OnEnable() { _fixationDataProvider.Start(); }
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(); }