예제 #1
0
 static void Main()
 {
     Application.EnableVisualStyles();
     Application.SetCompatibleTextRenderingDefault(false);
     using (var engine = new EyeTrackingEngine())
     {
         Application.Run(new DemoForm(engine));
     }
 }
예제 #2
0
        public DemoForm(EyeTrackingEngine engine)
        {
            InitializeComponent();

            SetStyle(
                ControlStyles.AllPaintingInWmPaint |
                ControlStyles.UserPaint |
                ControlStyles.DoubleBuffer,
                true);

            _eyeTrackingEngine = engine;
            _eyeTrackingEngine.StateChanged += StateChanged;
            _eyeTrackingEngine.GazePoint    += GazePoint;
            _eyeTrackingEngine.Initialize();
        }