Welcome to the Oculus Developer Forums!

Your participation on the forum is subject to the Oculus Code of Conduct.

In general, please be respectful and kind. If you violate the Oculus Code of Conduct, your access to the developer forums may be revoked at the discretion of Oculus staff.

Virtual Reality SDK Oculus failed to initialize

markLaurelmarkLaurel Posts: 10
NerveGear
edited September 2018 in Oculus Go Development
Hello everyone,

I'm trying to do my first VR project using Unity developing with GearVR. The problem is, I keep getting the alert "Virtual Reality SDK Oculus failed to initialize".

I've got the Oculus SDK installed, as well as the OSIG in my asset folder.

What other steps am I missing?

Comments

  • HalfspacerHalfspacer Posts: 80 Oculus Start Member
    You're getting this error when you "build & run" to the phone? Does it end up just displaying one eye? Does it refuse to run all together?
  • markLaurelmarkLaurel Posts: 10
    NerveGear
    Refuses to run in play test.
  • HalfspacerHalfspacer Posts: 80 Oculus Start Member
    edited September 2018
    In the Unity Editor or in the GearVR? The Unity Editor will naturally throw a "Virtual Reality SDK Oculus failed to initialize" unless you have a PC-VR headset connected to your PC. You need to build and run your project over to your phone.
    The "Failed to initialize" errors don't usually result in a refusal to run though. It should just default to standard monoscopic rendering - So I'm questioning whether I'v really understood what you meant. 
  • markLaurelmarkLaurel Posts: 10
    NerveGear
    Yes @Tolin93 , you understood perfectly- thank you. I'll try the build & run to see if I can get the project on the phone.
  • HalfspacerHalfspacer Posts: 80 Oculus Start Member
    It still shouldn't refuse to run in the Editor though. When you hit play, aside from the (yellow) warning in the console, do you get any (red) errors?
  • markLaurelmarkLaurel Posts: 10
    NerveGear
    no crit errors, just alerts
  • HalfspacerHalfspacer Posts: 80 Oculus Start Member
    Then just ignore it :-) It's just a Unity warning letting you know it's not finding a connected VR headset. When you deploy and run on the phone the Oculus SDK will run as it should as well.
  • markLaurelmarkLaurel Posts: 10
    NerveGear
    edited September 2018
    Interestingly, I'm able to build regular android APKs.

    But when I try to build for gearVR I get the following.


    This is my project setting

  • HalfspacerHalfspacer Posts: 80 Oculus Start Member
    Under "Player Settings", try setting your Target API to Level 23. That should fix it. 
    It sounds like you might have an older version of the Android Build Tools installed. 
  • markLaurelmarkLaurel Posts: 10
    NerveGear
    I went all the way back to API 21, it doesn't work for VR- just regular APK
  • HalfspacerHalfspacer Posts: 80 Oculus Start Member
    Hmh, if you open up Android Studio, what version of Android SDK and what API Levels have you installed? 
  • markLaurelmarkLaurel Posts: 10
    NerveGear
    WOW! Thank you for pointing out what I missed- I was under the impression the API levels were good to go when I installed android studio because I was able to build regular APKs. I'll try another VR test.
Sign In or Register to comment.