Exemple #1
0
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            datosCompartidos = new sharedData();

            wimuDevice = new HT.Wimu("COM56");//52 arduino

            if (!wimuDevice.serialPortConfigured)
            {
                MessageBox.Show("Head-tracking error!");
                return;
            }

            try
            {
                using (_eyeTrackingEngine = new EyeTrackingEngine())
                {
                    Application.Run(new EyeXWinForm(_eyeTrackingEngine, wimuDevice));
                }
            }

            catch (Exception e)
            {
                MessageBox.Show(e.ToString(), "Eye-tracking error!");
            }
        }
Exemple #2
0
        static void Main()
        {
            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);

            datosCompartidos = new sharedData();

            wimuDevice = new HT.Wimu("COM56");//52 arduino

            if (!wimuDevice.serialPortConfigured)
            {
                MessageBox.Show("Head-tracking error!");
                return;
            }

            try
            {
                using (_eyeTrackingEngine = new EyeTrackingEngine())
                {
                    Application.Run(new EyeXWinForm(_eyeTrackingEngine, wimuDevice));
                }
            }

            catch (Exception e)
            {
                MessageBox.Show(e.ToString(), "Eye-tracking error!");
            }
        }
        public EyeXWinForm(EyeTrackingEngine eyeTrackingEngine, HT.Wimu wimuDevice)
        {
            PseudoTimeStampMiliSecImu = 0;

            InitializeComponent();

            this.eyeTrackingEngine       = eyeTrackingEngine;
            eyeTrackingEngine.GazePoint += this.GazePoint;
            eyeTrackingEngine.OnGetCalibrationCompletedEvent += this.OnGetCalibrationCompleted;
            eyeTrackingEngine.Initialize();

            _llkhk             = new LowLevelKeyboardHook("Low-level Keyboard Hook");
            _llkhk.OnKeyPress += new EventHandler <KeyPressEventArgs>(OnKeyboardHookPress);

            clickDwell = new Dwell();

            this.wimuDevice       = wimuDevice;
            this.head2deltaCursor = new Head2deltaCursor(wimuDevice);
        }
Exemple #4
0
        public EyeXWinForm(EyeTrackingEngine eyeTrackingEngine, HT.Wimu wimuDevice)
        {
            PseudoTimeStampMiliSecImu = 0;

            InitializeComponent();

            this.eyeTrackingEngine = eyeTrackingEngine;
            eyeTrackingEngine.GazePoint += this.GazePoint;
            eyeTrackingEngine.OnGetCalibrationCompletedEvent += this.OnGetCalibrationCompleted;
            eyeTrackingEngine.Initialize();

            _llkhk = new LowLevelKeyboardHook("Low-level Keyboard Hook");
            _llkhk.OnKeyPress += new EventHandler<KeyPressEventArgs>(OnKeyboardHookPress);

            clickDwell = new Dwell();

            this.wimuDevice = wimuDevice;
            this.head2deltaCursor = new Head2deltaCursor(wimuDevice);
        }