예제 #1
0
 // Use this for initialization
 void Start()
 {
     _eyeXHost          = EyeXHost.GetInstance();
     _gazePointProvider = _eyeXHost.GetGazePointDataProvider
                              (Tobii.EyeX.Framework.GazePointDataMode.LightlyFiltered);
     _gazePointProvider.Start();
 }
예제 #2
0
파일: Level1.cs 프로젝트: Floppi003/pro4_EN
    void Awake()
    {
        eyexHost = EyeXHost.GetInstance();
        gazePointDataProvider   = eyexHost.GetGazePointDataProvider(GazePointDataMode.LightlyFiltered);
        eyePositionDataProvider = eyexHost.GetEyePositionDataProvider();

        timeTillWallSoundStarts = 0.0f;         //3.0f;
        timeEyesAreClosed       = 0.0f;
        blinkingLightCounter    = 0.0f;

        wakeupSoundPlayed             = false;
        openFirstDoorAnimationStarted = false;
        wallTriggerStarted            = false;
        waitForEyeClose = false;

        // load the blinking lights
        blinkingLights = new ArrayList();
        blinkingLights.Add(GameObject.Find("Panel_01"));
        blinkingLights.Add(GameObject.Find("Panel_02"));
        blinkingLights.Add(GameObject.Find("Panel_03"));
        blinkingLights.Add(GameObject.Find("Panel_04"));
        blinkingLights.Add(GameObject.Find("Panel_05"));
        blinkingLights.Add(GameObject.Find("Panel_06"));

        // set a deafult name for lastGazedWallLightName
        this.lastGazedWallLightName = "";
    }
예제 #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();
     gaze   = host.GetGazePointDataProvider(Tobii.EyeX.Framework.GazePointDataMode.LightlyFiltered);
     player = gameObject.GetComponentInParent <PlayerController>();
     gaze.Start();
 }
예제 #5
0
    void Awake()
    {
        eyexHost = EyeXHost.GetInstance();
        gazePointDataProvider   = eyexHost.GetGazePointDataProvider(GazePointDataMode.LightlyFiltered);
        eyePositionDataProvider = eyexHost.GetEyePositionDataProvider();

        timeTillFirstDoorOpens    = 0.0f;       //9.0f;
        timeTillWallSoundStarts   = 0.0f;       //3.0f;
        timeTillWakeupSoundStarts = 0.0f;       //2.0f;
        timeEyesAreClosed         = 0.0f;
        blinkingLightCounter      = 0.0f;

        wakeupSoundPlayed             = false;
        openFirstDoorAnimationStarted = false;
        wallTriggerStarted            = false;
        wallSoundPlayed = false;


        // load the blinking lights
        blinkingLights = new ArrayList();
        blinkingLights.Add(GameObject.Find("Panel_Colored_01"));
        blinkingLights.Add(GameObject.Find("Panel_Colored_02"));
        blinkingLights.Add(GameObject.Find("Panel_Colored_03"));
        blinkingLights.Add(GameObject.Find("Panel_Colored_04"));
        blinkingLights.Add(GameObject.Find("Panel_Colored_05"));
        blinkingLights.Add(GameObject.Find("Panel_Colored_06"));
        blinkingLights.Add(GameObject.Find("Panel_Colored_07"));
        blinkingLights.Add(GameObject.Find("Panel_Colored_08"));
        blinkingLights.Add(GameObject.Find("Panel_Colored_09"));
        currentBlinkingLightRemoved = false;

        Debug.Log("Awake: " + this.ToString());
    }
예제 #6
0
    private bool showEyePosition = false;     //indicates whether the point indicating the eyeposition should be visible


    void Awake()
    {
        Debug.Log("EyePositionScript: Awake()");

        this.eyexHost = EyeXHost.GetInstance();
        this.gazePointDataProvider = eyexHost.GetGazePointDataProvider(GazePointDataMode.LightlyFiltered);
        this.lastGazePoints        = new Queue <Vector2> ();
    }
예제 #7
0
    public void Awake()
    {
        _eyeXHost = EyeXHost.GetInstance();
        _gazePointProvider = _eyeXHost.GetGazePointDataProvider(gazePointMode);

#if UNITY_EDITOR
        _oldGazePointMode = gazePointMode;
#endif
    }
예제 #8
0
    public void Awake()
    {
        _eyeXHost          = EyeXHost.GetInstance();
        _gazePointProvider = _eyeXHost.GetGazePointDataProvider(gazePointMode);

#if UNITY_EDITOR
        _oldGazePointMode = gazePointMode;
#endif
    }
예제 #9
0
    void Start()
    {
        host = EyeXHost.GetInstance();
        //eyePos = host.GetEyePositionDataProvider();
        gazePos = host.GetGazePointDataProvider(Tobii.EyeX.Framework.GazePointDataMode.LightlyFiltered);
        gazePos.Start();

        ResetHealth();
    }
    public void Awake()
    {
        ScenedataCapt = new sceneTrackdata();

        _eyeXHost          = EyeXHost.GetInstance();
        _gazePointProvider = _eyeXHost.GetGazePointDataProvider(gazePointMode);

#if UNITY_EDITOR
        _oldGazePointMode = gazePointMode;
#endif
    }
예제 #11
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);
    }
예제 #12
0
	// Use this for initialization
	void Start ()
    {
		_eyeXHost = EyeXHost.GetInstance ();
		_gazePointProvider = _eyeXHost.GetGazePointDataProvider (Tobii.EyeX.Framework.GazePointDataMode.LightlyFiltered);
		onEnable ();
        _tr = transform;
        GameObject[] _tempCalStats = GameObject.FindGameObjectsWithTag("Stats");
        if (_tempCalStats.Length > 1)
        {
            for (int i = 1; i < _tempCalStats.Length; i++)
            {
                Destroy(_tempCalStats[i]);
            }
        }

        _calStats = _tempCalStats[0].GetComponent<CalibrationStats>();
        _calStats._calibrationSize = 0;
	}
예제 #13
0
 public void Awake()
 {
     _eyeXHost          = EyeXHost.GetInstance();
     _dataProvider      = _eyeXHost.GetEyePositionDataProvider();
     _gazePointProvider = _eyeXHost.GetGazePointDataProvider(GazePointDataMode.LightlyFiltered);
 }
예제 #14
0
 public void Awake()
 {
     _eyeXHost = EyeXHost.GetInstance();
     _gazePointProvider = _eyeXHost.GetGazePointDataProvider(GazePointDataMode.LightlyFiltered);
 }
예제 #15
0
 protected void Awake()
 {
     _eyexHost     = EyeXHost.GetInstance();
     _dataProvider = _eyexHost.GetGazePointDataProvider(gazePointDataMode);
     buttonList    = new List <ButtonTimeToLive> ();
 }
예제 #16
0
 public void Start()
 {
     host    = EyeXHost.GetInstance();
     gazePos = host.GetGazePointDataProvider(Tobii.EyeX.Framework.GazePointDataMode.LightlyFiltered);
     Player.transform.localScale = new Vector3(StartingPlayerSize, StartingPlayerSize, StartingPlayerSize);
 }
 protected void Awake()
 {
     _eyexHost = EyeXHost.GetInstance();
     _dataProvider = _eyexHost.GetGazePointDataProvider(gazePointDataMode);
 }
 protected void Awake()
 {
     _eyexHost     = EyeXHost.GetInstance();
     _dataProvider = _eyexHost.GetGazePointDataProvider(gazePointDataMode);
 }
예제 #19
0
 // Use this for initialization
 void Awake()
 {
     _eyeXHost             = EyeXHost.GetInstance();
     _gazePointProvider    = _eyeXHost.GetGazePointDataProvider(gazePointMode);
     userPresenceComponent = GetComponent <UserPresenceComponent>();
 }