OpenXR is an open, royalty-free standard for access to virtual reality and augmented reality platforms and devices. It is developed by a working group managed by the Khronos Group consortium. Varjo has been an active contributing member in OpenXR standardization. Varjo headsets have preliminary support for OpenXR, so that you can use your OpenXR applications with Varjo headsets.

Developing OpenXR applications with Varjo

Enable OpenXR Compatibility

For VR-1, VR-2, and VR-2 Pro, you can develop using OpenXR API as you would for any other VR device. To use OpenXR on Varjo device, just make sure “OpenXR compatibility” has been enabled in Varjo Base/System (enabled by default). You can use either Vive or Index controllers with any Varjo device through OpenXR.

Human eye resolution

In order to take advantage of Varjo’s human eye resolution displays you must use XR_VARJO_quad_views extension described in the official OpenXR documentation. Using XR_VARJO_QUAD_VIEWS_EXTENSION_NAME extension allows you to have two viewports per eye, like what you can see in Varjo Base analytics window. You must pass parameters to the xrBeginSession function identifying that you want to use Varjo’s extension.

If an app does not ask for an extension, it won’t get it. It will work in low quality mode, using only base resolution of context displays. An app built with the extension, such as any Unreal app built with the Unreal OpenXR plugin will detect at run-time if the quad-view extension is available and automatically enable Varjo human eye resolution.

Note that it is way easier for an OpenXR application to add support for quad-view than rewriting the entire application from OpenVR to Varjo Native API.

Mixed reality support

For XR-1 Developer Edition you can enable mixed reality by enabling blend mode. It is done with a XR_ENVIRONMENT_BLEND_MODE_ALPHA_BLEND flag. Detailed specifications could be found in OpenXR specifications.

XrFrameEndInfo frameEndInfo{XR_TYPE_FRAME_END_INFO};         
frameEndInfo.displayTime = frameState.predictedDisplayTime;         
frameEndInfo.layerCount = 1;         
frameEndInfo.layers = layers;  

OpenXR is a new and evolving standard. Please check the OpenXR official specifications for any recent changes.

Eye tracking with OpenXR

Eye tracking cannot currently be used with Varjo OpenXR but we are looking into supporting the incoming OpenXR eye tracking extension in the future.