Hi,
I tried to implement the following coding to my program in C#. The way my program works is that when I press the button, labels will display the coordinates for parameters of the gaze data. But every time I run the program it keep displaying zero value. Is there anything I missed out??
public class GazePoint : IGazeListener
{
public GazePoint()
{
// Connect client
GazeManager.Instance.Activate(GazeManager.ApiVersion.VERSION_1_0, GazeManager.ClientMode.Push);
// Register this class for events
GazeManager.Instance.AddGazeListener(this);
Thread.Sleep(5000); // simulate app lifespan (e.g. OnClose/Exit event)
// Disconnect client
GazeManager.Instance.Deactivate();
}
public void OnGazeUpdate(GazeData gazeData)
{
double gX = gazeData.SmoothedCoordinates.X;
double gY = gazeData.SmoothedCoordinates.Y;
// Move point, do hit-testing, log coordinates etc.
}
}