KitwareMedical / SlicerVirtualReality

A Slicer extension that enables user to interact with a Slicer scene using virtual reality.
Apache License 2.0
119 stars 58 forks source link

Update the terminology and API from "XR Runtime" to "XR Backend" #152

Closed jcfr closed 8 months ago

jcfr commented 10 months ago

In light of the official description of OpenXR on the Khronos website^7 and the loader specification overview^8, it has been suggested by @sankhesh that we disambiguate by not using the term Runtime.

Within the context of OpenXR, what is traditionally referred to as a "Runtime" is the software that integrates with specific platforms and hardware, implementing an OpenXR API that can be queried and interacted with. Examples^1 of these OpenXR Runtimes include Windows Mixed Reality (WMR), Oculus, SteamVR, and Varjo.

The usage of the term "Runtime" is corroborated by the vtkOpenXRManager::GetXrRuntimeInstance()^3 docstring, confirming that communication occurs with a runtime instance.

  ///@{
  /**
   * Return the instance used to communicate with the runtime
   */
  const XrInstance& GetXrRuntimeInstance() { return this->Instance; }
  ///@}

Conclusion: The proposal is to transition to the term "Environment," as indicated in the "Overview" section of the OpenXR Loader Specifications^8. Similarly, in the context of OpenVR, the term "Environment" is used to describe a comparable concept.

:zap: UPDATE :zap:: Following https://github.com/KitwareMedical/SlicerVirtualReality/issues/152#issuecomment-1881705311 from @LucasGandel, we will transition to the term Backend

In the sections below, you will find supporting material and references, along with information related to dealing with multiple environments and observations regarding the "incorrect" use of the "Runtime" qualifier from an OpenXR perspective.

Dealing with Multiple Runtimes

Considering that multiple OpenXR Environments may be installed on one system, users of OpenXR applications, such as the SlicerVirtualReality extension, must ensure that the correct one is activated. The xrsetenvironment tool^2 may assist in streamlining this process.

"Incorrect" use of the Runtime qualifier

While documentation from projects like Unity appropriately describes OpenXR Runtimes^4, there are instances of oversimplification in terminology, as seen in articles like "Steam VR vs OpenXR: Which Environment is Best?"^5.

Description of OpenXR by khronos

OpenXR provides cross-platform [...] access directly into diverse XR device runtimes across multiple platforms. OpenXR enables applications and engines, including WebXR, to run on any system that exposes the OpenXR APIs.

Source: https://www.khronos.org/openxr/

Overview section of the OpenXR Loader Specs

https://registry.khronos.org/OpenXR/specs/1.0/loader.html#Overview
image
LucasGandel commented 10 months ago

I agree, the runtime is what implements the OpenXR API (SteamVR, WMR ...). Environment sounds good to me. I also like "XR backend".