borismus / webvr-boilerplate

A starting point for web-based VR experiences that work on all VR headsets.
Apache License 2.0
1.8k stars 451 forks source link

Not entering Cardboard mode #153

Open s-thom opened 8 years ago

s-thom commented 8 years ago

Device: Nexus 6P Android Version: Nougat Dev Preview Chrome Version: 53.0.2782.2 (current Chrome Dev release) WebVR flag enabled in chrome://flags

Steps to reproduce:

  1. Clone repository
  2. Open page on device
  3. Tap Cardboard icon

Exception text:

webvr-manager.js:488 
Uncaught (in promise) TypeError: Failed to execute 'requestPresent' on 'VRDisplay': The 1st argument is neither an array, nor does it have indexed properties.(…)
WebVRManager.enterVRMode_ @ webvr-manager.js:488
WebVRManager.onVRClick_   @ webvr-manager.js:550
Emitter.emit              @ webvr-manager.js:176
(anonymous function)      @ webvr-manager.js:131
s-thom commented 8 years ago

According to the spec, [VRDisplay].requestPresent() requires a sequence of VRLayers.

Wrapping the object literal in an array results in a different exception:

webvr-manager.js:525 
Uncaught (in promise) DOMException: VRDisplay cannot present
WebVRManager.enterVRMode_ @ webvr-manager.js:525
WebVRManager.onVRClick_   @ webvr-manager.js:587
Emitter.emit              @ webvr-manager.js:205
(anonymous function)      @ webvr-manager.js:155
borismus commented 8 years ago

This will be fixed in the next release. requestPresent as spec'ed now takes an array layers.

On Sat, Jul 2, 2016 at 12:42 AM secret_online notifications@github.com wrote:

Device: Nexus 6P Android Version: Nougat Dev Preview Chrome Version: 53.0.2782.2 (current Chrome Dev release) WebVR flag enabled in chrome://flags

Steps to reproduce:

  1. Clone repository
  2. Open page on device
  3. Tap Cardboard icon

Exception text:

webvr-manager.js:488 Uncaught (in promise) TypeError: Failed to execute 'requestPresent' on 'VRDisplay': The 1st argument is neither an array, nor does it have indexed properties.(…) WebVRManager.enterVRMode @ webvr-manager.js:488 WebVRManager.onVRClick @ webvr-manager.js:550 Emitter.emit @ webvr-manager.js:176 (anonymous function) @ webvr-manager.js:131

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/borismus/webvr-boilerplate/issues/153, or mute the thread https://github.com/notifications/unsubscribe/AAQ8gCcfLkMeaG2CYJ_53F-YVYT5QoUVks5qRhZrgaJpZM4JDn4q .