- Home /
How to get order-independent transparency to work in VR?
I'm using This github project and Unity 2018.2.0f2 to create order independent transparency in my projects. It's working fine with a normal camera {no OIT} {OIT}, but when I try to use it with a VR setup, it just doesn't render any object on the "transparent" layer that is using the above project. {VR without OIT} {VR not working with OIT}.
On top of just not rendering anything marked as transparent, the left and right cameras become offset in a way that they shouldn't, so you get a disorienting effect as if your eyes are in the wrong place.
I was occassionally getting a weird effect where the spheres would render all black and remain centered on my left eye, and the rest of the scene was rendered upside down. The right eye would render everything not marked as transparent correctly. I believe I was using the single camera setting in the OVR camera rig when this happened, but I couldn't get it to produce the same error to record.
I'm using the Oculus SDK, but I don't think it has to do with that. The same thing happens if I just use a camera that feeds to the Oculus headset.
Here is the Unity project, if you want to see for yourself.
Thank you