Tobii Ocumen Configuration Sample

The Configuration sample shows how you can configure your eye tracker, include customized calibration flows and evaluate calibration quality.

This sample uses the ConfigurationManager class to interface with the API.

Table of Contents


Here, you can download the prebuilt sample for your device. Source code access for the sample is provided as a part of Tobii Ocumen.

Device Download
Pico Neo 2 Eye
Pico Neo 3 Pro Eye
HP Reverb G2 Omnicept Edition

Getting Started

Make sure you follow our installation instructions for Tobii Ocumen.

The example scene contains the TobiiCalibration prefab which is an example prefab with a customized calibration flow. By placing the prefab in your scene, you will get a calibration flow which you can customize and trigger from within the Unity application.

You can find more detailed guidance of calibration flows in the /Doc/ folder.

Unity Sample

The Configuration sample contains the configuration prefab TobiiCalibration, allowing you to setup a customized configuration flow containing:

  • Position Guide
  • Calibration
  • Post-Calibration Visualizer


To trigger and control the calibration flow you need to manually press the Configured Button, which is arbitrary set and can be changed at any point.

The Configured Button is any of the following:

  • Spacebar
  • Pico headset button
  • Controller trigger button

This can be changed from the ControllerManager script.

Step 1: Position Guide

The position guide instructs the user to position their headset and tighten the straps in such a way that their eyes end up in the sweet spot for both eye tracking and rendering quality. This should be done immediately before calibrating.

The user should try to align the blue crosses with the black crosses.

By default, the horizontal adjustment is locked. This is because some headsets do not have a hardware adjustable lens cup separation, such as the Pico Neo 2 Eye. This can be configured by changing the Lock X bool in the PositionGuideView script attached to the TobiiCalibration prefab.

When the user has positioned their headset in a good spot, they can press the Configured Button to move on to the next step.

Step 2: Calibration

The calibration step shows a stimulus point which moves to different locations at different angles to calibrate the eye tracker to the user’s eyes. This is crucial for accurate eye tracking quality.

The CalibrationView script attached to the TobiiCalibration prefab displays user instructions and handles the movement, timing, and collection of eye data at each point. The most commonly customized parameters are exposed in the inspector, and more advanced customizable properties are inside the script.

The example calibration is set up to be a 5-point calibration on a medium luminosity background in a cross-like pattern. For more details on calibration patterns, see the bundled documentation in the /Doc/ folder.

Step 3: Post-Calibration Visualizer

As the last step of the calibration process, the user can check how accurate their eye tracking calibration is by looking around in the Post-Calibration Visualizer, handled by the PostCalibrationVisualizerView script..

By pressing the Configured Button in this step, the configuration flow finishes.