Search Unity

Invert gyroscope to adapt to front camera

Discussion in 'Vuforia' started by Spooklight, Dec 13, 2017.

  1. Spooklight

    Spooklight

    Joined:
    Dec 22, 2015
    Posts:
    3
    I have a project with Vuforia that works well.

    The camera is set in "DEVICE_TRACKING" and we have enabled the device tracker in "HANDHELD".

    While using the back camera of the phone, our 3D objets are perfectly aligned with the ground. Using the phone gyroscope.

    We want to add a new feature. I scripted the swapcamera behaviour that switched from the back to the front camera and vice versa.

    My problem is the gyroscope behaviour is still the same with the front camera, so my 3D objects don't react correclty. I see the head of my characters instead of its feet. How can I change my axis for the gyroscope, or if you have any other idea, I'm intereseted. I may have missed something in the Vufo' library by the way.

    Thank you by advance