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

Three.js r74 compatibility #115

Closed florianmaxim closed 8 years ago

florianmaxim commented 8 years ago

When I updated my project to Three.js' recent r70-Version the stereoscopic effect is gone. (Testet on iPhone 6)

It seems like the screen is something like splitted..

Thanks for your amazing work!

curti55 commented 8 years ago

same here. Seems the scene isnt rendererd per eye but stretched over whole width. just like there is no vreffect...

crookookoo commented 8 years ago

Same, one of the changes from r73 to r74 is breaking it.

florianmaxim commented 8 years ago

It works in Oculus Rift DK2 if that helps...

crookookoo commented 8 years ago

Tried updated VRControls and VREffect from this PR, doesn't seem to work on cardboard for me. https://github.com/mrdoob/three.js/pull/8221

cvan commented 8 years ago

I'm not sure, and I haven't tested, but does it work at mrdoob/three.js@65d161e or mrdoob/three.js@a17ea05?

crookookoo commented 8 years ago

@cvan neither show correct distortion for right and left eye. In fact, I've tested previous versions of VREffect and webvr-manager.js that used to work with r73 and they too produce the same result, so I'm guessing the issue might be elsewhere.

(I'm testing in safari on iOS)

florianmaxim commented 8 years ago

Do you have lights in your scene that cast shadows?

When I turned the shadow castings of all lights off the VREffect worked again...

rutkoski commented 8 years ago

Probably related to https://github.com/mrdoob/three.js/issues/7732 ?

crookookoo commented 8 years ago

Can confirm that stereoscopic view breaks on boilerplate code with r74, looks like this:

img_1420

Even though effect looks the same to what @rutkoski points, there are no lights or shadows in that code. Also tested without textures, and with freshly updated VRControls and VREffect.

@cheesyeyes can you share what you got working with r74?

rutkoski commented 8 years ago

Not working with r74, r75. Also, tried updating webvr-polyfill, not working either.

crookookoo commented 8 years ago

Try with polyfill and manager from 1.0 branch https://github.com/borismus/webvr-boilerplate/tree/webvr-1.0, the stereoscopic view works for me.

The VR-view UI scales in a weird way and is not interactive, but this is going to be fixed before the merge hopefully.

rutkoski commented 8 years ago

Good to know it's beying fixed.

Would like to see integration with the effects composer also (that broke VR). Has anyone been able to use post effects with the boilerplate?

borismus commented 8 years ago

@crookookoo Yes, there are some known issues with the 1.0 polyfill, but hopefully we will sort them soon: https://github.com/borismus/webvr-polyfill/issues/46. After that happens I will merge webvr-1.0 to master and things should be good again.

borismus commented 8 years ago

Alright, should be compatible now.