Stereoscopic Cubemap Support

I wanted to know if there is a way to use stereoscopic cubemaps in playcanvas for use in VR/XR?
I was thinking about a per Eye layer to use a different mapped sphere on each layer and display the corresponding cubemap. But I don’t know if this can be achieved.


Hmmm, I’ve not come across this myself. There’s no layer on a per eye level on the public API level. You may have to start digging into the engine internals at that point

I agree, there’s no direct support for this.

In the engine, when rendering each draw call, we swap some uniforms (mostly camera related) for each view (eye). See the code here:

Perhaps you could do a custom shader / chunk and use the viewPos to detect left vs right, and output color from different cubemap or similar.

1 Like