5 Benefits of WebXR
Trying to decide whether to build on WebXR or rather build a native app? Here are five reasons why you might choose WebXR.
Trying to decide whether to build on WebXR or rather build a native app? Here are five reasons why you might choose WebXR.
1 - Cross Platform
With native apps, you need to decide on which platform you want to target. If you choose OpenXR, then your code will be mostly independent of the headset, but you still have to build for various platforms.
If you want to target Quest, you need your app to run on Android, if you want to target Windows Mixed reality, you compile/package/build for Windows. If you support HTC Vive, Valve Index, the Razor HDK or similar headets that run on Linux, too, you would miss out on users if you don’t provide a linux build.
All this can be solved with WebXR, since you now target the Web, a ubiquitous platform which does not care which operating system is on.
And the best part: if a new headset is released, browsers will figure out support for it for you.
2 - Accessibile
Cross platform already helps with accessibility for your users. More people will be able to access your app.
Publishing is also easier, though. Setting up a webserver or hosting on a static website (through GitLab Pages or GitHub Pages) is very easy! There are no restrictions on what and when you publish.
3 - Automatic Improvement
The web is getting better every day. Not just the browsers, but the Web as Standard is getting better, allowing you to do more on your websites.
Some upcoming improvements are WebGPU and Web Payments for example.
The former will allow for higher performance and more optimizations in 3D rendering, but also using the GPU for new use cases, like running Deep Neural Networks. The later will allow incredibly easy integration of payments on your websites.
4 - Low Entry Barrier
Since content is expected to load quickly on the web and no installation is needed, the user can be in your 3D web app in no time. Once you convince him, you can still allow installing your app as PWA (Progressive Web App).
5 - Rapid Development
The web is known for efficient workflows. You change an html file and your preview is updated immediately in the browser. Hot-reloading tools speed up development times.
The 3D Web supports these workflows as well. Code based frameworks like Three.js and A-Frame work with the same tools that are used for 2D websites. Tools like Wonderland Engine provide their own hot-reloading tools that enable this rapid development.
Summary
There are many reasons to choose Web over native. One of the biggest disadvantages so far is that optimizing VR apps on the Web is even harder than on native. With WebAssembly and WebGPU, the future brings the performance of Web closer and closer to native performance. In the long run, this gap will be closed.
Wonderland Engine already runs on WebAssembly and allows you to think less about optimization and instead spend your time on the app itself.