vvuk / gecko-dev

Other
41 stars 5 forks source link

Bug: WebGL canvas size and getEyeParameters().renderRect size! #30

Open krpano opened 8 years ago

krpano commented 8 years ago

Hi,

when using the getEyeParameters().renderRect size to set the size of the WebGL canvas, then Firefox renders the WebVR output wrong (Firefox Nightly 47.0a1, Windows 7, Oculus Rift DK2, SDK 0.8.0).

The VR rendering is currently only correct when using the screen/window size for the canvas size, but this is WRONG - because this way the VR rendering resolution depends on the resolution of the normal desktop screen - and this one can be lower or higher than the one from the VR device (which could cause too low rendering res for VR or waste of rendering power when higher).

You can see the problem here in the Quake 3 WebGL Demo from Brandon Jones: http://media.tojicode.com/q3bsp/

or here in the krpano WebVR example: http://krpano.com/krpanocloud/webvr/index.html?v=119pr3

See also the WebVR spec and example there: http://mozvr.github.io/webvr-spec/webvr.html#dom-vreyeparameters-renderrect That means when implementing WebVR by following the specs, Firefox currently behaves wrong.

For the moment I will add a special workaround for Firefox in krpano, but it would be nice when this would get fixed soon.

Best regards, Klaus

cvan commented 8 years ago

Thanks for filing. (The links on http://webvr.info/ are out of date. I've opened a PR to change them.)

Would you be willing to file a bug here instead?

Sorry about that. Thanks for your understanding :smile: