C# Class ATUAV_RT.EyetrackerConnector

Connects to an eyetracker. Use a new EyetrackerConnector for each eyetracker connection. GazeData and Framerate change events should be subscribed to through the AddGazeDataHandler(1) and AddFramerateChangedHandler(1) methods which check if eyetracker is connected yet and will delay connection if it isn't.
Afficher le fichier Open project: ATUAV/ATUAV Class Usage Examples

Méthodes publiques

Méthode Description
AddFrameRateChangedHandler ( EventHandler handler ) : void

Adds a frame rate changed event handler to connected eyetracker. If eyetracker is not connected subscription is delayed until eyetracker is connected. Method returns immediately.

AddGazeDataHandler ( EventHandler handler ) : void

Adds a gaze data event handler to connected eyetracker. If eyetracker is not connected, subscription is delayed until eyetracker is connected. Method returns immediately.

Connect ( ) : void

Connects to eyetracker and subscribes to events. Events are received on background thread.

Disconnect ( ) : void

Unsubscribes from events and disconnects eyetracker.

EyetrackerConnector ( EyetrackerInfo info ) : System
RemoveFrameRateChangedHandler ( EventHandler handler ) : void

Removes a frame rate changed event handler from connected eyetracker.

RemoveGazeDataHandler ( EventHandler handler ) : void

Removes a gaze data event handler from connected eyetracker.

Private Methods

Méthode Description
ConnectionError ( object sender, ConnectionErrorEventArgs e ) : void

Disconnects from eyetracker on error.

Method Details

AddFrameRateChangedHandler() public méthode

Adds a frame rate changed event handler to connected eyetracker. If eyetracker is not connected subscription is delayed until eyetracker is connected. Method returns immediately.
public AddFrameRateChangedHandler ( EventHandler handler ) : void
handler EventHandler
Résultat void

AddGazeDataHandler() public méthode

Adds a gaze data event handler to connected eyetracker. If eyetracker is not connected, subscription is delayed until eyetracker is connected. Method returns immediately.
public AddGazeDataHandler ( EventHandler handler ) : void
handler EventHandler
Résultat void

Connect() public méthode

Connects to eyetracker and subscribes to events. Events are received on background thread.
public Connect ( ) : void
Résultat void

Disconnect() public méthode

Unsubscribes from events and disconnects eyetracker.
public Disconnect ( ) : void
Résultat void

EyetrackerConnector() public méthode

public EyetrackerConnector ( EyetrackerInfo info ) : System
info EyetrackerInfo
Résultat System

RemoveFrameRateChangedHandler() public méthode

Removes a frame rate changed event handler from connected eyetracker.
public RemoveFrameRateChangedHandler ( EventHandler handler ) : void
handler EventHandler
Résultat void

RemoveGazeDataHandler() public méthode

Removes a gaze data event handler from connected eyetracker.
public RemoveGazeDataHandler ( EventHandler handler ) : void
handler EventHandler
Résultat void