h-shirakami 1 Posted September 28, 2020 Share Posted September 28, 2020 How can I temporarily rotate and move the HMD camera by myself in VIU?I wanted to rotate the HMD's camera when an event occurred, so I rotated the ViveCameraRig, but I couldn't get the correct results.I referred to Teleport in Examples.It rotates the x-axis after moving forward, which is not the intended result. I think the cause is the movement of the camera. How can I change the camera transform directly? Link to post Share on other sites
lawwong 2 Posted September 28, 2020 Share Posted September 28, 2020 Do you mean you want to rotate camera root around HMD? public static void RotateAroundHMD(Transform vrOrigin, Transform hmd, Quaternion rot) { vrOrigin.position = rot * (vrOrigin.position - hmd.position) + hmd.position; vrOrigin.rotation = rot * vrOrigin.rotation; } public static void OnSomeRightTurnEventOcurred() { // Turn right around Y axis for 45 degree RotateAroundHMD(vrOrigin, hmd, Quaternion.Euler(new Vector3(0f, 45f, 0f))); } 1 Link to post Share on other sites
h-shirakami 1 Posted September 28, 2020 Author Share Posted September 28, 2020 Ah! I see. I'll give it a try. Thank you Link to post Share on other sites
Asish 1 Posted April 6 Share Posted April 6 (edited) Hello @lawwong @h-shirakami How can I get head rotation value using VIVE pro eye while watching object in the scene? Any idea to get standard head rotation value? Thanks in advance Edited April 6 by Asish add more person to tag Link to post Share on other sites
Recommended Posts
Please sign in to comment
You need to be a member in order to leave a comment
Sign in
Already have an account? Sign in here.
Sign In Now