Search code examples
unity-game-engineaugmented-realityvirtual-realityarcoregoogle-vr

Render ARCore in cardboard


I tried to render ARCore stereoscopically through cardboard. Due to the misalignment between the field of view of the ARCore camera and VR, the object appears to be not being tracked.

To sort this out, I referred to this blog and implemented it by using a barrel distortion shader. However, it doesn't render stereoscopically.

Is there any other fix for this problem?


Solution

  • For stereo-vision you need two View Controllers i.e. two ArFragments, each running at 60 fps. Ideally you need a frame rate 120 fps but it's impossible in ARCore at this time.

    enter image description here

    Barrel distortion is just a special type of a warped distortion of a view.

    Also, for robust stereo experience you should shift views only along X-axis and never along Y-axis. In real life an effective distance between two camera lens is 64-200 mm.

    For further details look at Technicolor Paper: 15 Stereo Issues.

    And there are other visual implementations for stereo:

    enter image description here

    enter image description here

    It's up to you which one is more comfortable for watching.