Abstract
Eye-tracking is an essential tool in many fields, yet existing solutions are often limited for customized applications due to cost or lack of flexibility. We present OpenIris, an adaptable and user-friendly open-source framework for video-based eye-tracking. OpenIris is developed in C# with a modular design that allows further extension and customization through plugins for different hardware systems, tracking, and calibration pipelines. It can be remotely controlled via a network interface from other devices or programs. Eye movements can be recorded online from a camera stream or offline by post-processing recorded videos. Example plugins have been developed to track eye motion in 3-D, including torsion. Currently implemented binocular pupil tracking pipelines can achieve frame rates of more than 500Hz. With the OpenIris framework, we aim to fill a gap in the research tools available for high-precision and high-speed eye-tracking, especially in environments that require custom solutions not currently well-served by commercial eye-trackers.
Introduction
Eye-tracking is a cornerstone of modern neuroscience, clinical diagnostics, and human-computer interaction. However, researchers often face a "pick two" dilemma: affordability, high performance, or flexibility. Commercial systems are typically expensive and closed-source, making it nearly impossible to integrate custom hardware or novel tracking algorithms. Conversely, existing open-source tools are often fragmented—some lack a graphical user interface (GUI), others are hard-coded to specific cameras, and many struggle to maintain the high frame rates (500Hz+) necessary to capture subtle eye movements like microsaccades or ocular torsion.
OpenIris aims to bridge this gap by providing a high-performance, "hardware-agnostic" framework that is easy to use but infinitely extensible. It breaks away from the "black box" nature of commercial systems by offering a plugin-based architecture that supports everything from standard pupil tracking to complex 3D ocular torsion analysis.
System Architecture and Methods
The framework is built using C# and the .NET Framework 4.8, leveraging OpenCV (via the emguC wrapper) for image processing. C# was selected to balance ease of development with the low-level performance required for real-time binocular tracking.
The core of OpenIris is its modular plugin architecture, which divides the eye-tracking process into three distinct pillars:
- Hardware Systems: Manages camera initialization, synchronization, and pre-processing (such as cropping or rotating).
- Tracking Pipelines: Contains the logic for extracting eye features, such as pupil center, corneal reflections, or iris patterns.
- Calibration Pipelines: Maps raw pixel data from the cameras into meaningful visual degrees or 3D coordinates.
To ensure high-speed reliability, OpenIris implements multi-threading and a first-in-first-out (FIFO) image buffer. This prevents frame drops even if the CPU temporarily spikes during complex processing tasks. It also features a network interface (UDP/TCP/HTTP) for remote control, allowing integration into experiments controlled by Python, Matlab, or other external software.
Advanced Tracking and Performance
While most trackers only look at X and Y pupil positions, OpenIris includes example plugins for ocular torsion—the eye rotating around the line of sight. This is a critical metric for vestibular research that is rarely supported by commercial or open-source alternatives.
The system was validated using a custom hardware setup featuring two Blackfly S USB3 industrial cameras. Key performance results include:
- High Speed: Successful binocular tracking at rates exceeding 500Hz.
- Low Latency: A baseline processing time of just 0.14 ms. Simple centroid pupil tracking required 0.79 ms, while complex pupil, corneal reflection, and torsion tracking took 9.70 ms.
- Reliability: In all test conditions, the system recorded 0% dropped frames, demonstrating the effectiveness of its multi-threaded buffering system.
Conclusion and Future Work
OpenIris provides a robust, developer-friendly environment for eye-tracking research. Its dedicated "debug tab" allows developers to visualize intermediate processing steps, such as thresholding or edge detection, without building custom UI elements.
Currently, OpenIris is a Windows-only application. Future development plans include migrating to newer versions of .NET (Core/5+) to enable cross-platform support for Linux and macOS. The authors envision OpenIris as a community-driven project, encouraging future contributions of plugins for deep-learning-based tracking and support for a wider variety of specialized hardware.
Summary updated