Lock Screen Orientation with Virtual Reality Enabled (Cardboard).
Hi there!
I'm trying to lock the screen orientation for various scenes within my Cardboard app, but the following line isn't working for me.
Screen.orientation = ScreenOrientation.LandscapeLeft;
I believe this may have something to do with Virtual Reality Support being enabled, given it greys out all of the screen orientations in the build settings once enabled.
I've tried running VRSettings.enabled = false; prior to trying to lock the screen but that also doesn't seem to work.
Any advice please!?
Thanks
Answer by WelchCompositions · Oct 11, 2017 at 03:30 PM
I also have this problem. In my cardboard app some screens are ran in "none" for the virtual reality sdk setting and they need the orientation locked.
Your answer
Follow this Question
Related Questions
How do I create a Continuous Turn in XR for my VR Rig instead of Snap Turn Provider? 0 Answers
How do I lock hand movement through script in Unity oculus vr 1 Answer
c# - error CS0103: The name `hit' does not exist in the current context (cardboard switching) 1 Answer
Fix rotation skipping 0 Answers
How do I offset a camera when it's position is defined by a VR controller 0 Answers