Questions tagged [webvr]

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.

Note: WebVR is deprecated and has been superseded by WebXR; see .


The burgeoning WebVR APIs provide sensor information from virtual reality devices (such as the Oculus Rift) which, in conjunction with WebGL, allows for the creation of VR web applications.

More information at:

596 questions
3
votes
2 answers

A-frame check variable with function and show different gltf depending on the value

I am wondering how I can create something like this using JavaScript and A-frame (https://aframe.io). I would like to create an onload function called load() that will check the value of a variable x and if x is one, the gltf with the id of 1 will…
Aidan Young
  • 554
  • 4
  • 15
3
votes
2 answers

A-frame button onClick changes object

I'm trying to create something in A-frame (aframe.io) where when a button onclick event happens, a cube will change colors. Here is my current code:
3
votes
0 answers

How to fix the Threejs webxr examples for wide FOV displays?

Threejs has some webxr examples but they all seem to assume the user will be using a small FOV headset and use parallel projections. When you view them on a wide FOV headset with canted displays (like a Pimax) the 3D objects for the left/right eye…
cecil
  • 317
  • 2
  • 8
3
votes
0 answers

A-frame / other js lib, changing VR eye angles or eye camera position

In VR mode of A-frame library, is it possible to change view angles for the eyes? I mean, set both eyes not to look at the same point but look at different items. I am aware of the fact that it may create a discomfort for the user. Changing camera…
Tukkan
  • 1,574
  • 2
  • 18
  • 33
3
votes
1 answer

How to get a both side colored plane in A-Frame

When I create an a-plane and assign an attribute color="red", the color is applied to one side only. I added rotation animation to the plane and the back of the plane is white: fiddle. What would be the method to get a plane colored from both sides?…
yeniv
  • 1,589
  • 11
  • 25
3
votes
3 answers

How to load 3D object at runtime in aframe?

I am working on an aframe project where runtime loading of 3D object is required. I have read A-Frame documentations, and aframe doesn't seem to support runtime assets loading at all. I discovered this aframe-asset-on-demand-component by protyze…
Felix
  • 77
  • 1
  • 9
3
votes
1 answer

Is it possible to register a custom gamepad in javascript with the Gamepad API?

Quick background I am currently working on a VR application with A-frame to showcase VR hardware. We use custom controllers that connects through websocket/bluetooth and would like to make them compatible with the tracked-controls. Those A-Frame…
WilBros
  • 31
  • 1
3
votes
1 answer

Three.js + WebVR set "height" of camera viewing position

Developing in ThreeJS r87 using the standard example WebVR script. Got a 3D scene successfully rendering in VR through Chrome on my phone with a Google cardboard. When I am using VR the camera/viewer's point of view is at the centre of the world (0,…
Martin Joiner
  • 3,529
  • 2
  • 23
  • 49
3
votes
1 answer

Event handling in ReactVR

Been experimenting with ReactVR and i have few doubts in handling events.As per the documentation in Cusors and Input,finding out the type of event is as easy as reading type of the event. Events coming into onInput can be further filtered by…
semuzaboi
  • 4,972
  • 5
  • 20
  • 35
3
votes
0 answers

Cursor fuse is not working in aframe

I am trying to display the cursor only for VR mode.The problem is I am unable to change the cursor color and also cursor is not getting fusing. This is the code I have tried. Example code: JS AFRAME.registerComponent('bar', { init: function() { …
Chuva
  • 31
  • 2
3
votes
3 answers

three.js WebVR example code works on threejs.org but not on my local server

When I try out the example: https://threejs.org/examples/webvr_cubes.html on my Android 7.0 Samsung Galaxy 7 phone using the Chrome browser and the Utopia360 headset, everything works and I can enter VR mode. When I try the exact same thing with…
SomeoneElse
  • 486
  • 1
  • 6
  • 22
3
votes
1 answer

How do you tile a texture across a surface in React VR?

I have a box 100m x 100m to act as a floor in a reactVR test I am working on, I'd like to add a texture to it but the tile texture just stretches over the entire surface rather than tile, as desired. Here is my component code, nothing special: …
Anthony Cregan
  • 960
  • 11
  • 25
3
votes
4 answers

Sorry, firefox.exe/chrome.exe is taking a while to load | (unresponsive) firefox.exe/chrome.exe

I'm making an application with WebVR using React VR. I'll test the application with my Oculus Rift and HTC-Vive. I'm using the browser Firefox Nightly to access the WebVR API's. If I browse to my application using Firefox Nightly or Chromium, I…
H. Pauwelyn
  • 13,575
  • 26
  • 81
  • 144
3
votes
3 answers

How to create react-vr "enter vr button/cardboard"?

I'm playing around with the react-VR framework and can't seem to find anything in the docs about entering vr mode on chrome/cardboard ? Any help or pointers much appreciated.
Chris O
  • 712
  • 2
  • 9
  • 20
3
votes
1 answer

How do I rotate a box in A-Frame by moving or dragging the mouse?

How do I rotate a box in A-Frame by moving or dragging the mouse? I trying to do something like this: http://codepen.io/jordizle/pen/haIdo/ https://jsfiddle.net/MadLittleMods/n6u6asza/ Here is my code. Rotation