Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice

Access to left/right cameras for stereo effect

Discussion in 'VR' started by lucidbard, Dec 5, 2016.

  1. lucidbard

    lucidbard

    Joined:
    Jun 4, 2013
    Posts:
    3
    I'm creating a specific effect by rendering a different graphic for left and right cameras. Hololens, in the deployed application, doesn't seem to respect the left or right designation for cameras, and instead simply looks for the MainCamera.

    I also attempted to find if there was a generated Camera object by enumerating all of the cameras at runtime (Camera.allCameras), but it appears the stereo rendering is happening in a shader of some sort. Does anyone know if there's a way to get access to the left and right cameras at runtime?
     
  2. pfreese

    pfreese

    Unity Technologies

    Joined:
    Feb 23, 2015
    Posts:
    85
    Rendering on the HoloLens happens to a single render target with a single camera which uses a texture array.
     
  3. BrandonFogerty

    BrandonFogerty

    Joined:
    Jan 29, 2016
    Posts:
    83
    If you put two cameras in your scene and then assign one camera's "Target Eye" property to "Left" and the other camera to "Right", what happens on device? Are you running into issues with this?
     
  4. osamahchoudhry

    osamahchoudhry

    Joined:
    Jan 29, 2017
    Posts:
    3
    Hi @BrandonFogerty , reviving this topic. Is it possible to have two cameras in a Unity scene and have access to the right and left lens in the HoloLens to customize the stereo?