introduction to the vr web

24
Intro to the VR Web JUST A/VR SHOW

Upload: liv-erickson

Post on 16-Jan-2017

420 views

Category:

Technology


1 download

TRANSCRIPT

Page 1: Introduction to The VR Web

Intro to the VR WebJUST A/VR SHOW

Page 2: Introduction to The VR Web

Overview

WebVR: The API A under-development browser

interface to interact with hardware Abstract out the types of VR devices

to be handled by the browser so developers can focus on content, not supporting specific devices

The VR Web Build out experiences for virtual

reality on the internet Include VR-enabled content into the

web as it exists today

Page 3: Introduction to The VR Web

Benefits of WebVR

No installation of application is needed – run in the browser on any device

Automatically support mobile and desktop devices Utilize the current set of tools and libraries for JavaScript Easily switch between VR and non-VR mode Offload interfacing with hardware to the browser

Page 4: Introduction to The VR Web

Downsides of WebVR

Performance hits for non-native graphics Non-standard support for some browsers Less insight and control into bugs with hardware Relies on browser detection of devices

Page 5: Introduction to The VR Web

How it works

Desktop VR Web page is rendered without VR support Browser detects that there is a VR device

attached to the computer and stores the information about it

Web page is put into VR mode by the user and the site queries the browser for information about the device

This information is then applied to render the page stereoscopically

Mobile VR Web page is rendered without VR support Browser detects that the device is a phone Web page is put into VR mode by the user

and special code included in the website creates a stereoscopic rendering by querying the device size and splitting down the middle with an offset on each eye

The phone gyroscope updates orientation, view, and position of the camera

Page 6: Introduction to The VR Web

WebVR Sample Code

Page 7: Introduction to The VR Web

WebVR Template

Hardware management is offloaded to the web browser (detection of device, position state, attributes, field of view)

JavaScript code manages the changes in the hardware as the browser sees the device

VR Effect is applied to a WebGL canvas item Updates loop in the browser similar to with a game logic loop Boilerplate code made available from a Google engineer

http://github.com/borismus/webvr-boilerplate

Page 8: Introduction to The VR Web

What’s in a VR App?

Scene: Environment rendered through WebGL VRControls: Listen for hardware position changes and use them to

manipulate the camera within the scene VREffect / VR-Polyfill: Render your scene with two side by side cameras

(stereoscopic rendering) VRManager: Query for devices and apply hardware transforms

Page 9: Introduction to The VR Web
Page 10: Introduction to The VR Web
Page 11: Introduction to The VR Web
Page 12: Introduction to The VR Web
Page 13: Introduction to The VR Web
Page 14: Introduction to The VR Web

Demo

Page 15: Introduction to The VR Web
Page 16: Introduction to The VR Web

Three.JS A BASIC OVERVIEW

Page 17: Introduction to The VR Web

What is Three.JS?

A (very powerful!) JavaScript library for building immersive 3D content The primary building block of WebVR scenes Utilize WebGL, the JavaScript abstraction layer of OpenGL

Page 18: Introduction to The VR Web
Page 19: Introduction to The VR Web

Building Scenes

Primitive Shapes Textures & Materials The 3D coordinate system Lights Cameras Characters Hardware

Three.JS supports these all, right in the browser

Page 20: Introduction to The VR Web

Let’s Look at Some Examples!

http://threejs.org/examples

Page 21: Introduction to The VR Web

Looking Ahead

A-Frame is a new project for integrating virtual reality content directly into markup on a webpage

Aframe.io

Page 22: Introduction to The VR Web

Recap

Page 23: Introduction to The VR Web

WebVR is an insanely cool, new technology that has the potential to help completely reshape the web

You can build for VR even if you don’t have a desktop VR headset yet Create beautiful experiences with Three.JS

Page 24: Introduction to The VR Web

BRING WEBVR TO EDGE!

http://livi.link/WebVREdge