StereoKit
More actions
StereoKit is an open-source library for developing XR applications with C# and OpenXR. It provides rendering, input, spatial user interfaces and asset loading for mixed reality and virtual reality applications. Its implementation has a native core exposed through a C-compatible API, with C# as the project's primary supported language binding.[1][2]
StereoKit is distributed under the MIT License, which permits modification, redistribution and commercial use subject to retaining its copyright and permission notice. The license provides the software without warranty.[3]
Application structure
A C# application initializes StereoKit and supplies a function that runs each frame. That function can draw models, update application logic and declare interactive controls. The getting-started guide distributes project templates through StereoKit.Templates; its multiplatform template includes a separate Android project for deployment to a connected device. Applications can be developed with the .NET command-line tools or Visual Studio.[4]
C and C++ applications access the same core through stereokit.h and stereokit_ui.h. The native guide supplies a CMake template and a C test project, while noting that the documentation and examples primarily target C#. Bindings developed by the community, including a Rust implementation, are separate from the official C# binding.[2]
Platforms and runtime requirements
The project README lists packaged native binaries for Windows desktop, Universal Windows Platform (UWP), Linux and Android. Its documented device and runtime examples include Meta Quest, HoloLens 2, SteamVR, Varjo and Monado. On a desktop computer, immersive operation requires an available OpenXR runtime, such as SteamVR, Quest Link or Monado; the built-in simulator provides a separate development mode.[5][4]
Device features have separate availability checks. An application cannot infer the presence of eye tracking, environmental geometry or persistent anchors from OpenXR initialization alone.[6][7][8]
| Capability | Documented condition or fallback |
|---|---|
| Eye gaze | Requires suitable hardware, application permission and an active tracking state. A previously returned pose can remain available after tracking is lost.[6] |
| Articulated hands | Hand data may come from tracked joints or from simulation based on a mouse or controller. Input.HandSource distinguishes the source.[6]
|
| Environmental occlusion and raycasting | Require the corresponding system capabilities and explicit enabling. Environmental data loads asynchronously.[7] |
| Persistent spatial anchors | Depend on the anchoring backend. A stage-relative fallback does not necessarily provide the stability of a spatially tracked anchor.[8] |
Input and spatial interfaces
The Input API exposes head pose, hand and eye tracking, controller data, pointers, keyboard input and mouse input. Hand information is available through a common representation even when its joints are simulated. Raw controllers have their own API, but controller availability and individual buttons depend on the hardware. Eye input includes a tracking-state check so applications can distinguish a current measurement from an old pose.[6]
StereoKit's user interface uses an immediate-mode system: the application calls the relevant UI functions on each frame when an element should appear. Identifiers retain an element's state between frames and are scoped to its window. The API includes buttons, sliders, text entry, toggles and windows, as well as handles for moving objects. A handle can apply a pose transform to content drawn within it, so the interface and its contents move together.[9]
The project's StereoKit Ink tutorial demonstrates these APIs in a small painting application. Its examples include finger drawing, radial hand menus, automatically laid-out windows and file selection. The repository identifies it as a learning example rather than a complete painting product.[10]
Assets, rendering and interaction
A StereoKit Model groups meshes, materials and transforms. Models can be loaded at runtime from glTF/GLB, OBJ, STL and PLY files, or assembled from generated meshes. The model API exposes nodes, bounds and animation playback. Version 0.3.11 added binary PLY loading, extending the ASCII PLY support described in the model reference.[11][12]
The library includes shaders and materials for physically based rendering, an instanced rendering pipeline and skeletal animation. Its supported texture formats include PNG, JPEG, HDR and KTX2.[1] Version 0.3.10 added compressed KTX2 textures, support for the glTF EXT_meshopt_compression extension and a RenderList API for rendering offscreen.[13]
File selection uses a native operating-system picker when available and a StereoKit interface as a fallback. UWP file permissions can restrict access to files referenced by a selected asset, such as external textures used by a glTF model; selecting the model file does not automatically remove those restrictions.[14]
Physics objects use the Solid API, which can combine boxes, capsules and spheres into a collision shape. A solid supplies its simulated pose but does not draw a visible object itself. The Sound API loads WAV and MP3 audio, supports generated or streamed samples and plays sound at a specified three-dimensional position with spatial audio cues.[15][16]
Real-world geometry and anchors
The World API provides information about the physical environment where the runtime supplies it. This includes play boundaries, reference-space information and optional environmental meshes for occlusion or ray intersection. Its documented scene-understanding raycast implementation uses low-resolution environmental geometry from the HoloLens runtime; applications must check availability before using it.[7]
A spatial anchor associates a virtual pose with a physical location. StereoKit exposes anchor tracking and persistence through its Anchor class. Support varies with the underlying extensions and backend. When a dedicated anchoring system is unavailable, a stage-relative fallback can locate content relative to the stage, but changes to the stage can change that relationship. Requests to persist an anchor can fail, including when the runtime reports a persistence capability.[8]
Desktop simulator
StereoKit's simulator runs in a conventional two-dimensional window without requiring a headset or an OpenXR runtime. Mouse input moves a simulated articulated hand; mouse buttons produce pinch and grip gestures. Keyboard and mouse controls move or rotate the viewpoint, change the controlled hand and emulate a gaze ray. These are simulated inputs rather than measurements from hand- or eye-tracking hardware.[17]
By default, the library can fall back to this mode if OpenXR initialization fails. Applications can explicitly request simulator mode or disable the fallback through initialization settings. The input API also allows a hand pose to be overridden and later restored, supporting repeatable input tests and demonstrations.[17]
Releases
As of 21 October 2026, NuGet lists 0.3.11 as the latest non-prerelease package, dated 28 June 2025, alongside newer 0.4.0 preview packages. Its listed preview versions include 0.4.0-preview.3818, dated 8 October 2026.[18]
| Version | Release date | Selected changes |
|---|---|---|
| 0.3.9 | 27 February 2024 | Added an anchor API, new UI theming options and application modes for a plain window or offscreen rendering.[19] |
| 0.3.10 | 22 February 2025 | Added XR multisample anti-aliasing, compressed texture support, offscreen render lists and C# easing helpers.[13] |
| 0.3.11 | 28 June 2025 | Added binary PLY support and statically linked the Visual C++ runtime in Win32 binaries; also corrected initialization and window-handling issues.[12] |
Research use
Microsoft Research's 2024 SIGMA system paper describes StereoKit as the rendering and interface library in its HoloLens 2 client. SIGMA displays conversation history and procedural task instructions, with additional world-positioned text, models and timers. A separate server processes sensor streams and sends interface commands back to the headset. The paper describes a research system for mixed-reality task assistance and does not benchmark StereoKit against other libraries.[20]
The authors identify unresolved questions in SIGMA's interface design, including panels obscuring the task area or moving outside the user's field of view, and call for further usability testing.[20]
References
- ↑ 1.0 1.1 "StereoKit". StereoKit Documentation. https://stereokit.net/. Retrieved 2026-10-21.
- ↑ 2.0 2.1 "Getting Started with StereoKit - Native Code". StereoKit Documentation. https://stereokit.net/Pages/Guides/Getting-Started-Native.html. Retrieved 2026-10-21.
- ↑ "StereoKit: MIT License". StereoKit on GitHub. https://github.com/StereoKit/StereoKit/blob/master/LICENSE. Retrieved 2026-10-21.
- ↑ 4.0 4.1 "Getting Started with StereoKit". StereoKit Documentation. https://stereokit.net/Pages/Guides/Getting-Started.html. Retrieved 2026-10-21.
- ↑ "StereoKit: README and platform support". StereoKit on GitHub. https://github.com/StereoKit/StereoKit. Retrieved 2026-10-21.
- ↑ 6.0 6.1 6.2 6.3 "Input". StereoKit Documentation. https://stereokit.net/Pages/StereoKit/Input.html. Retrieved 2026-10-21.
- ↑ 7.0 7.1 7.2 "World". StereoKit Documentation. https://stereokit.net/Pages/StereoKit/World.html. Retrieved 2026-10-21.
- ↑ 8.0 8.1 8.2 "Anchor". StereoKit Documentation. https://stereokit.net/Pages/StereoKit/Anchor.html. Retrieved 2026-10-21.
- ↑ "UI". StereoKit Documentation. https://stereokit.net/Pages/StereoKit/UI.html. Retrieved 2026-10-21.
- ↑ "StereoKit Ink: mixed reality inking tutorial". StereoKit on GitHub. https://github.com/StereoKit/StereoKit-PaintTutorial. Retrieved 2026-10-21.
- ↑ "Model". StereoKit Documentation. https://stereokit.net/Pages/StereoKit/Model.html. Retrieved 2026-10-21.
- ↑ 12.0 12.1 "StereoKit v0.3.11". StereoKit on GitHub. 2025-06-28. https://github.com/StereoKit/StereoKit/releases/tag/v0.3.11. Retrieved 2026-10-21.
- ↑ 13.0 13.1 "StereoKit v0.3.10". StereoKit on GitHub. 2025-02-22. https://github.com/StereoKit/StereoKit/releases/tag/v0.3.10. Retrieved 2026-10-21.
- ↑ "Platform.FilePicker". StereoKit Documentation. https://stereokit.net/Pages/StereoKit/Platform/FilePicker.html. Retrieved 2026-10-21.
- ↑ "Solid". StereoKit Documentation. https://stereokit.net/Pages/StereoKit/Solid.html. Retrieved 2026-10-21.
- ↑ "Sound". StereoKit Documentation. https://stereokit.net/Pages/StereoKit/Sound.html. Retrieved 2026-10-21.
- ↑ 17.0 17.1 "Using the Simulator". StereoKit Documentation. https://stereokit.net/Pages/Guides/Using-The-Simulator.html. Retrieved 2026-10-21.
- ↑ "StereoKit package and version history". NuGet Gallery. https://www.nuget.org/packages/StereoKit. Retrieved 2026-10-21.
- ↑ "StereoKit v0.3.9". StereoKit on GitHub. 2024-02-27. https://github.com/StereoKit/StereoKit/releases/tag/v0.3.9. Retrieved 2026-10-21.
- ↑ 20.0 20.1 Dan Bohus et al. (2024-05-16). "SIGMA: An Open-Source Interactive System for Mixed-Reality Task Assistance Research". arXiv. https://arxiv.org/html/2405.13035v1. Retrieved 2026-10-21.