When WebVR is enabled, navigator.getVRDisplays resolves with an empty array
Reported by
mr.a...@gmail.com,
Dec 11 2016
|
||||
Issue descriptionSteps to reproduce the problem: 1. Call navigator.getVRDisplays 2. Watch the promise resolve 3. Inspect the promise value What is the expected behavior? The promise value should contain one VRDisplay for the phone What went wrong? The promise value is an empty array Did this work before? N/A Does this work in other browsers? N/A Chrome version: 56.0.2924.18 Channel: dev OS Version: 5.1.1 Flash Version:
,
Dec 11 2016
This is indeed expected behavior for now. The first thing to recognize is that the WebVR API may return an empty array at any time, even when you might think it should be guaranteed to get a VRDisplay back. Maybe the browser has a setting that lets users block certain pages or a whole session from using VR? Maybe your drivers are out of date? Maybe another app has been grated exclusive access to the device? Point is, there's no shortage of reasons why you may not get a VRDisplay back. Your page should be designed to handle it gracefully. Secondly, in this case the intent is that you WILL eventually get VRDisplays back for Cardboard-style use almost all the time, but that's not implemented yet. (It's dependent on the Google VR service being deployed more widely.) So at this point it only works with Daydream ready devices, though you can use said devices with a Cardboard headset. This is a temporary issue, and should be resolved in the near-ish future. Closing as WAI, with my apologies for the confusion.
,
Dec 11 2016
Thanks for the clarification - I was aware that it is always possible to resolve with an empty array, but it surprised me as the phone certainly should've shown up as a Cardboard device. Thank you very much for the quick response, I think this clarification is very useful indeed! Cheers! 2016-12-11 21:22 GMT+01:00 bajo… via monorail < monorail+v2.1572007341@chromium.org>:
,
Dec 16 2016
,
Jul 4
|
||||
►
Sign in to add a comment |
||||
Comment 1 by the.sp...@gmail.com
, Dec 11 2016