Suvarna Garge (Editor)

WebVR

Updated on
Edit
Like
Comment
Share on FacebookTweet on TwitterShare on LinkedInShare on Reddit

WebVR is an experimental JavaScript API that provides support for virtual reality devices, such as the HTC Vive, Oculus Rift or Google Cardboard, in a web browser.

Contents

This API is designed with the following goals in mind:

  • Detect available Virtual Reality devices.
  • Query the devices capabilities.
  • Poll the device’s position and orientation.
  • Display imagery on the device at the appropriate frame rate.
  • History

    WebVR was first conceived in spring 2014 by Vladimir Vukićević from Mozilla. The API's contributors include Brandon Jones, Boris Smus and others from the Mozilla team. On March 1, 2016, the Mozilla VR team and the Google Chrome team announced the version 1.0 release of the WebVR API proposal. The resulting API refactoring brought many improvements to WebVR.

    The last tagged version is 1.1, which was last edited on April 5, 2017. The editors of the document include members from Mozilla and Google teams. However some Microsoft members have joined, and are actively collaborating in the drafting process of version 2.0 for the WebVR API.

    Design

    The WebVR API exposes a few new interfaces (such as VR Display, VR pose) that allow web applications to present content in virtual reality, by using WebGL with the necessary camera settings and device interactions (such as controllers or point of view). The API has been designed to follow a certain path, which is very similar to other intrusive Web API like the Geolocation API. The necessary steps are:

    1. Request a list of the available VR devices.
    2. Checks to see if the desired device supports the presentation modes the application needs.
    3. If so, application advertises VR functionality to the user.
    4. User performs an action that indicates they want to enter VR mode.
    5. Request a VR session to present VR content with.
    6. Begin a render loop that produces graphical frames to be displayed on the VR device.
    7. Continue producing frames until the user indicates that they wish to exit VR mode.
    8. End the VR session.

    Support

    WebVR still relies on a special browser version with the API enabled in a special settings screen that most users would not be able to find easily. WebVR is currently supported in Firefox Nightly Build and custom build Chrome. WebVR v1.0 is in Android Chrome behind a flag. Until WebVR is actually supported most browsers still support part of the API through a polyfill. Microsoft announced in September 2016 that it had started development of WebVR in the Edge browser.

    Currently (April 8, 2017), the WebVR API is still in early development. As such, the defined APIs are changing frequently and cannot be considered stable. While the API is being finalized, version 1.1 may be found in some browsers: Chrome for Android, Firefox Nightly, Samsung Internet, Microsoft Edge, Chromium, Servo and Oculus Carmel.

    It should be noted, that support of WebVR doesn't imply that a certain browser supports a specific headset. But that it provides the necessary API, leaving to browsers to choose which headset to support.

    Notable uses

    Below are some notable companies or projects related to WebVR:

  • JanusVR JanusVR is a suite of software that makes it simple to create, share and experience spatially rich internet content.
  • A-Frame (VR) is an open-source web framework for building VR experiences with HTML from Mozilla.
  • Archilogic has successfully used WebVR to produce 3D models that can be visited in virtual reality.
  • Blend4Web is used for authoring WebVR-based applications such as heritage reconstruction and games.
  • Kokowa: Kokowa is a webVR publishing platform aimed at non-programmers. It provides a drag and drop editor to build and share webVR experiences on the web and on social media.
  • Goocreate: Goo Create is a cloud based 3D WebGL content creation editor. It can be used to create games, ads, campaign websites product showcases and scientific visualizations that run in a web browser.
  • PlayCanvas: PlayCanvas is an open source 3D game engine/interactive 3D application engine.
  • Vizor: Vizor is a platform for creating and sharing VR content on the web.
  • Sketchfab: allows people to display and share 3D content online. It provides a 3D model viewer that allows to display 3D models on any mobile, desktop webpage or VR headset.
  • X3DOM: is an open-source framework and runtime for 3D graphics on the Web including WebVR. It leverages X3D, the current ISO open standard for web3D.
  • Similar technologies

    Although WebVR is unique as an API, there are native applications on most hardware allowing for networked experiences and access to web content. Several key tools, such as Unity and Blender, are also able to export for the web and provide users a way to use their content without installing a dedicated application.

    References

    WebVR Wikipedia