Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qt3dxr-pcvr.qdoc
Go to the documentation of this file.
1// Copyright (C) 2024 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only
3
4/*!
5 \page qt3dxr-pcvr.html
6 \title PCVR
7
8 \brief Details on supporting non-standalone VR headsets.
9
10 \section1 Overview
11
12 With standalone devices, all rendering and processing happens on the headset itself.
13 With non-standalone devices, also referred to as \c PCVR, all rendering and most of the
14 related processing happens on a computer connected to the headset either via a
15 physical cable, or wirelessly.
16
17 For developers, working in a PCVR-based environment can be simpler and more productive
18 than continuously deploying and testing on a standalone VR device. This is because
19 development, testing, debugging, and profiling methods and tools are mostly the same
20 as with regular desktop Windows or Linux applications, which the VR application still
21 is, even though it may not render anything on-screen on the desktop.
22
23 For end-users, however, setting up and running with PCVR can be more convoluted than
24 simply installing the application on a standalone device.
25
26 With devices where both approaches are possible (for example, the Meta Quest 3), it
27 can be useful for productivity to combine the two. Use PCVR (or even the Meta XR
28 Simulator) during development when it makes sense, but focus on the standalone
29 (Android) build for AR features and for final delivery to end-users.
30
31 \note The performance aspects of running the same Qt application on Android in
32 Standalone mode and on Windows in PCVR mode may vary wildly since it means running on
33 a completely different CPU, GPU, and software stack. Performance profiling conclusions
34 should always be drawn by running natively in the appropriate environment and
35 profiling using platform-specific tools.
36
37 When it comes to input, data from the headset's controller is delivered to the
38 application running on the PC via the OpenXR API, no differently than with
39 applications running on the headset directly. In addition, the application may still
40 rely on peripherals connected to the PC for further input methods, although this
41 should be considered carefully since relying on keyboard or mouse input has a number
42 of potential pitfalls.
43
44 \section1 Further considerations
45
46 With PCVR, the quality and performance depends heavily on the host PC's capabilities,
47 but the streaming technology and associated factors, such as the wireless network
48 bandwidth, can affect the results as well. This also means that the visual experience
49 may vary between runs and between environments, especially if wireless streaming is
50 used.
51
52 Some features may not be available or may be limited compared to standalone devices,
53 especially AR-related ones. Consider passthrough, for example. In standalone mode, the
54 application and the underlying software stack have easy access to the headset's camera
55 feed. When streaming from a remote computer, passthrough may become expensive and
56 could involve a lot of additional data transfer to the PC. Therefore it is not
57 uncommon that AR and spatial-related features are not available in PCVR systems.
58
59 In the PCVR ecosystem, there are multiple solutions that provide an OpenXR
60 implementation and wired or wireless streaming, with varying availability, depending
61 on the device used. Some runtimes are tied to a specific streaming solution, and each
62 of them may provide a different set of features.
63
64 Support for 3D APIs varies too. Generally, Direct 3D 11, Direct 3D 12, and Vulkan can
65 be expected to be supported by all OpenXR implementations on Windows. OpenGL support
66 is rare and has not been tested by Qt with PCVR.
67
68 \note Using Direct 3D 11 is not recommended, since important features such as
69 \l{Multiview Rendering} are not supported with that API. Prefer Direct 3D 12 instead.
70
71 Changing the 3D API used is no different from any Qt Quick or Qt Quick 3D application:
72 set the environment variable \c{QSG_RHI_BACKEND} (for example, to \c d3d12) or call
73 QQuickWindow::setGraphicsApi().
74
75 \section1 Choosing the OpenXR Implementation
76
77 With the standard Khronos OpenXR loader, there are multiple ways to change what
78 implementation gets loaded:
79
80 \list
81
82 \li Set the environment variable \c{XR_RUNTIME_JSON}. For example, setting
83 \c{XR_RUNTIME_JSON=c:\MetaXRSimulator\meta_openxr_simulator.json} makes the \qxr
84 application launched afterwards to pick the Meta XR Simulator's OpenXR
85 implementation.
86
87 \li Alternatively, the setting can be made permanent via the registry. (on Windows)
88 Check/change the value of \c{ActiveRuntime} under
89 \c{Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Khronos\OpenXR\1}
90
91 \li Some streaming solutions may have options in their settings to force using a
92 given OpenXR implementations.
93
94 \endlist
95
96 \section1 Wireless streaming solutions for the Meta Quest 3
97
98 \list
99 \li \l{https://www.meta.com/en-gb/help/quest/articles/headsets-and-accessories/oculus-link/connect-with-air-link/}{Meta Quest Link and Air Link}
100 \li \l{https://www.meta.com/en-gb/experiences/steam-link/5841245619310585/}{Steam Link VR} is a solution similar to Air Link
101 \li \l{https://www.vrdesktop.net/}{Virtual Desktop} is a remote desktop tool with wireless streaming as well.
102 \endlist
103
104 \section1 Tables of Tested Configurations
105
106 Meta Quest 3
107
108 \list
109 \li Wired connection (USB-C), Oculus OpenXR runtime
110 \li Wired connection (USB-C), SteamVR OpenXR runtime
111 \li Wireless connection via AirLink, Oculus OpenXR runtime
112 \li Wireless connection via AirLink, SteamVR OpenXR runtime
113 \li Wireless connection via SteamLink, SteamVR OpenXR runtime
114 \li Wireless connection via Virtual Desktop, SteamVR OpenXR runtime
115 \li Wireless connection via Virtual Desktop, VDXR OpenXR runtime
116 \endlist
117
118 Special
119
120 \list
121 \li Meta XR Simulator (Windows and macOS)
122 \endlist
123
124 \section1 Further reading
125
126 This page cannot possibly dive into all the details, configuration issues,
127 and possibilities around PCVR. For a good summary and introduction on the
128 topic of streaming and OpenXR implementations, it is recommended to take a
129 look at the \l{https://github.com/mbucchia/VirtualDesktop-OpenXR/wiki}{the
130 VDXR wiki}.
131
132*/