Tobii Pro SDK C API
notifications.c
#include <stdio.h>
#include <inttypes.h>
void notification_callback(TobiiResearchNotification* notification, void* user_data) {
printf("Enter calibration mode notification received at time stamp %" PRId64 ".\n", notification->system_time_stamp);
}
printf("Left calibration mode notification received at time stamp %" PRId64 ".\n", notification-> system_time_stamp);
}
(void)(user_data); // Is NULL, see subscription call
}
void notifications_example(TobiiResearchEyeTracker* eyetracker) {
tobii_research_subscribe_to_notifications(eyetracker, notification_callback, NULL);
/* Trigger some notifications */
/* Unsubscribe from notifications. */
tobii_research_unsubscribe_from_notifications(eyetracker, notification_callback);
}
TobiiResearchNotification
Definition: tobii_research_streams.h:484
tobii_research_calibration.h
Functionality for implementing calibration.
TobiiResearchNotification::system_time_stamp
int64_t system_time_stamp
Definition: tobii_research_streams.h:488
TOBII_RESEARCH_NOTIFICATION_CALIBRATION_MODE_ENTERED
@ TOBII_RESEARCH_NOTIFICATION_CALIBRATION_MODE_ENTERED
Definition: tobii_research_streams.h:431
tobii_research_subscribe_to_notifications
TOBII_RESEARCH_API TobiiResearchStatus TOBII_RESEARCH_CALL tobii_research_subscribe_to_notifications(TobiiResearchEyeTracker *eyetracker, tobii_research_notification_callback callback, void *user_data)
Subscribes to notifications for the eye tracker.
tobii_research_streams.h
Functionality for eye tracker streams.
tobii_research_unsubscribe_from_notifications
TOBII_RESEARCH_API TobiiResearchStatus TOBII_RESEARCH_CALL tobii_research_unsubscribe_from_notifications(TobiiResearchEyeTracker *eyetracker, tobii_research_notification_callback callback)
Unsubscribes from notifications for the eye tracker.
TobiiResearchEyeTracker
struct TobiiResearchEyeTracker TobiiResearchEyeTracker
Definition: tobii_research.h:310
tobii_research_screen_based_calibration_enter_calibration_mode
TOBII_RESEARCH_API TobiiResearchStatus TOBII_RESEARCH_CALL tobii_research_screen_based_calibration_enter_calibration_mode(TobiiResearchEyeTracker *eyetracker)
Enters the screen based calibration mode and the eye tracker is made ready for collecting data and ca...
tobii_research_screen_based_calibration_leave_calibration_mode
TOBII_RESEARCH_API TobiiResearchStatus TOBII_RESEARCH_CALL tobii_research_screen_based_calibration_leave_calibration_mode(TobiiResearchEyeTracker *eyetracker)
Leaves the screen based calibration mode.
TOBII_RESEARCH_NOTIFICATION_CALIBRATION_MODE_LEFT
@ TOBII_RESEARCH_NOTIFICATION_CALIBRATION_MODE_LEFT
Definition: tobii_research_streams.h:436
TobiiResearchNotification::notification_type
TobiiResearchNotificationType notification_type
Definition: tobii_research_streams.h:492