Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

Question [portal VR - steamVR] Unity depth buffer in VR / IPD issue ?

Discussion in 'VR' started by Yoirgla, Mar 27, 2022.

  1. Yoirgla


    Jan 2, 2015
    Hello everyone.

    I'm resuming work on "Pathmaker", a portal-like game in VR.
    I'm having a weird issue maybe you fellas can help me with.
    I'm using steamVR plugin.

    I created a custom rig to manage both eyes separately with the objective of having the possibility to have one eye on each side of the portal for more "realism"


    when going sideways trough a portal, here's how it unfolds from the left eye point of view :

    1 : portal on my left
    2 : left eye went trough portal, head center didn't yet.
    3 : left eye trough portal, head center trough portal

    and here's the video :

    My theory is that while the eye itself is trough the portal, the head center is still the place where the depth buffer gets computed from. and here's my question :

    how can i force a per-eye (per camera) depth buffer with the correct eye position ?

    Any help is welcome :)