Tobii Pro SDK C API
get_track_box.c
#include <stdio.h>
void get_track_box_example(TobiiResearchEyeTracker* eyetracker){
char* serial_number;
TobiiResearchStatus status = tobii_research_get_track_box(eyetracker, &track_box);
if (status != TOBII_RESEARCH_STATUS_OK)
return;
tobii_research_get_serial_number(eyetracker, &serial_number);
printf("Got track box from tracker with serial number %s with corners:\n", serial_number);
printf("Back Lower Left: (%f,%f,%f)\n",
track_box.back_lower_left.x,track_box.back_lower_left.y, track_box.back_lower_left.z);
printf("Back Lower Right: (%f,%f,%f)\n",
track_box.back_lower_right.x, track_box.back_lower_right.y, track_box.back_lower_right.z);
printf("Back Upper Left: (%f,%f,%f)\n",
track_box.back_upper_left.x, track_box.back_upper_left.y, track_box.back_upper_left.z);
printf("Back Upper Right: (%f,%f,%f)\n",
track_box.back_upper_right.x, track_box.back_upper_right.y, track_box.back_upper_right.z);
printf("Front Lower Left: (%f,%f,%f)\n",
track_box.front_lower_left.x, track_box.front_lower_left.y, track_box.front_lower_left.z);
printf("Front Lower Right: (%f,%f,%f)\n",
track_box.front_lower_right.x, track_box.front_lower_right.y, track_box.front_lower_right.z);
printf("Front Upper Left: (%f,%f,%f)\n",
track_box.front_upper_left.x, track_box.front_upper_left.y, track_box.front_upper_left.z);
printf("Front Upper Right: (%f,%f,%f)\n",
track_box.front_upper_right.x, track_box.front_upper_right.y, track_box.front_upper_right.z);
}