Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Resolved [SOLVED]Oculus Touch: Rotation of Player is around center

Discussion in 'VR' started by klartreumer, Jan 25, 2020.

  1. klartreumer

    klartreumer

    Joined:
    May 21, 2017
    Posts:
    3
    Hey , I'm sorry for my english and poor skill language, kinda newb here.

    I am trying to get a demo Scene working with the Oculus Integration (Version 12.0 ), and used the OVRPlayerController Prefab.

    When I Rotate the player via the touch controllers, the position of the player also rotates , he is not standing in the same spot, like he is moving around an object in the middle.
    rotbug.png


    Attached a hopefully understandable explanation, Even with a different Rotation Amount or Rotation Ratchet the same Position offset.

    I even tried the demo Scenes, same "bug"(?), I normally dont have problems with motion sickness, but a rotation like that make me dizzy


    Thank you for your help :)
     
    EvanG3D likes this.
  2. klartreumer

    klartreumer

    Joined:
    May 21, 2017
    Posts:
    3
    After Sleeping a night i found the correct option

    In the OVRCameraRig check the Option "Reset Tracker On Load" which Recenter the player to his current spot.
     
    EvanG3D and martyboren like this.
  3. EvanG3D

    EvanG3D

    Joined:
    Oct 22, 2018
    Posts:
    1
    Thank you so much for this. I was having the same exact issue and noticed it in the demo scene as well. I tried your solution and it fixed my issue. Thank you!
     
  4. fuzzy3d

    fuzzy3d

    Joined:
    Jun 17, 2009
    Posts:
    228
    I also had problems with OVRPlayerController rotation. The player did not rotate around its axis and is even occasionally "tunneled" through the walls becouse high speed movement to the side.
    Setting the rotation "around the guardian" on or off did not help.

    Finally, I had to change the OVRPlayerController.cs file "transform.RotateAround(CameraRig.centerEyeAnchor.position, Vector3.up, euler.y);" (line 489) to "transform.RotateAround(this.transform.position, Vector3.up, euler.y);"

    So far it looks good ...
     
    Last edited: Dec 24, 2021
    monoion, Nyveon and johningame like this.
  5. AleNavarro

    AleNavarro

    Joined:
    Dec 30, 2016
    Posts:
    7
    Still with issues.

    I implemented both solutions above, none seems to fix it...

    Someone has a better solution?
     
    Last edited: Jul 26, 2022
  6. fuzzy3d

    fuzzy3d

    Joined:
    Jun 17, 2009
    Posts:
    228
    Oculus Integration 47.0 update, new OVRPlayerController.cs, still the same problem, the rotation is off the axis of the head, I had to change line 504

    transform.RotateAround(CameraRig.centerEyeAnchor.position, Vector3.up, euler.y);
    to
    transform.RotateAround(this.transform.position, Vector3.up, euler.y);

    it seems to work...
     
    monoion likes this.
  7. monoion

    monoion

    Joined:
    Dec 28, 2014
    Posts:
    6
    Oculus Integration v50 - Problem still there; Your solution fixed it thank you :)
     
  8. FourMileFox

    FourMileFox

    Joined:
    Jun 21, 2018
    Posts:
    5
    This was driving me crazy. Snap turning would jump my OVRplayer in position and wild rotation. Sometimes it would be minimal and then I would run the app again and it would be extreme.

    THIS WORKED FOR ME TOO!:

    transform.RotateAround(CameraRig.centerEyeAnchor.position, Vector3.up, euler.y);
    to
    transform.RotateAround(this.transform.position, Vector3.up, euler.y);

    I used the above solution on line 509 of OVRPlayerController in Oculus Integration version 53.1

    THANK YOU! =)
     
  9. KuRiXY

    KuRiXY

    Joined:
    Aug 1, 2014
    Posts:
    4
    It worked! Thanks!!!