"View in VR" gives a really small render buffer resulting in LQ VR Experiences on Daydream
Reported by
kevin.mo...@gmail.com,
Jun 25 2018
|
|||||||
Issue descriptionSteps to reproduce the problem: 1. Open a WebVR site in 2d mode on a Daydream capable phone. 2. Click on "View in VR" 3. The VR experience is very Low Quality as chrome returns a very small render buffer when using Daydream A workaround exists: IF however, you put on the headset, enter Chrome from VR, and then click "view in VR," it will the WebVR enabled sites will appear correctly. More info can be found in a bug log (inc video of the issue) on the React360 github a/c here: https://github.com/facebook/react-360/issues/508 What is the expected behavior? A larger render buffer would be expected on daydream compatible phones to allow rendering of HQ graphics on daydream. What went wrong? Low quality VR experiences only on daydream Did this work before? N/A Does this work in other browsers? N/A Chrome version: 67.0.3396.87 Channel: stable OS Version: 8.1.0 Flash Version:
,
Jun 25 2018
Klaus, can you take a look? We really shouldn't be giving different render target sizes based on whether you were in the VR browser -- I don't think this is intentional.
,
Jun 26 2018
,
Jun 26 2018
,
Jun 26 2018
I'm strongly suspecting that this is due to the application misusing window.devicePixelRatio. The render buffer dimensions in WebVR are raw pixel counts, they aren't supposed to be scaled by a pixel ratio. They should be used as-is for sizing the render canvas. Other WebVR applications aren't affected by this scaling issue. When starting in regular 2D Chrome, window.devicePixelRatio is 3.5. When starting in VR Browser, window.devicePixelRatio was 1.7 when I just tested. That's a 2x difference and could easily explain the quality difference.
,
Jun 26 2018
It's an application bug, it's resizing based on window dimensions in a way that overrides the provided recommended render resolution. For context, I could reproduce the issue for http://vr.digitour.co.nz/ as mentioned in the original bug report. Inspector shows that it's using a canvas size of 576x385 pixels on a Pixel 2 XL. For comparison, https://webvr.info/samples/03-vr-presentation.html works normally on the same browser version, and uses a canvas size of 2288x1133 on the same device. With some logging added, you can see that it's calling this._renderer.setSize with the recommended size, then overriding that: resize 2288 1133 false setPixelRatio 2288 1133 false resize 2288 1133 false resizeCanvas 576 385 true The override happens here: key: "frame", value: function(e) { var t = e || 0; 0 === this._lastFrameTime && (this._lastFrameTime = t); var i = Math.min(t - this._lastFrameTime, 100); if (this._lastFrameTime = t, this._needsResize) { var a = window.innerHeight , r = this._parent.clientWidth; this._parent.style.height = a + "px", this.resize(r, a), this._needsResize = !1 Here, this._parent.clientWidth is 576 and window.innerHeight is 385, leading to very pixelated rendering.
,
Jul 4
|
|||||||
►
Sign in to add a comment |
|||||||
Comment 1 by dtapu...@chromium.org
, Jun 25 2018