Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Vive, child camera of "Camera (eye)" having local position/angle set to same as parent

Discussion in 'AR/VR (XR) Discussion' started by Dreamwriter, Jan 5, 2017.

  1. Dreamwriter

    Dreamwriter

    Joined:
    Jul 22, 2011
    Posts:
    472
    We've got a camera that's a child of the Vive "Camera (eye)" VR camera (from the [CameraRig]). For some odd reason the local position and rotation of this child camera are set to the same local position and rotation values as the Camera (eye) - but since it's a child of the Camera (eye), that means this child camera is offset from the Camera (eye) by that amount. Meaning, if the Camera (eye) is rotated to -50, the child camera is rotated an additional -50 from that, for a total of -100. But we need it maintain its (0,0,0) local position and rotation so it is looking in the same direction as the Camera (eye).

    Any idea what's going on, how to fix this?
     
  2. Dreamwriter

    Dreamwriter

    Joined:
    Jul 22, 2011
    Posts:
    472
    Figured it out :) I had forgotten to set the child camera as not a VR camera (Target eye None); having it have a Target Eye makes it act like a camera on the headset.