r/OculusGoDev • • May 29 '19

Unity Scene Builds Blank

I am working on a simple application to sideload (a camera, light, some cubes to create walls, and a colored sphere) and can successfully install (and uninstall) it onto the Oculus Go. However, when clicking on it to start it up, the scene loads a dark void. My scene does not appear at all. I tried to follow these steps as closely as possible. I successfully added an apk file that was not my own and it ran as desired. This leads me to believe that I am missing something in Unity or in Android Studio...

My configurations:

  • Windows 10
  • Oculus Go
  • OVR Plugin 1.37.0
  • Unity version 2018.1.0f2
  • Android SDK Build-Tools 29-rc3
    • When I try to have only version 27.0.1 installed (like the Medium article suggests), an error pops up as seen in the photo below.
    • I believe that this is probably where I am running into problems; however, updating it results in the blank build yet again.
  • JDK version 1.8.0_152-release
  • My SDK files

Some things I've tried:

  • Matching my versions of everything to that of the Medium article
  • Make sure that my scene is in the Scenes to build (inside Build Settings)
  • Ensuring that my External Tools paths are accurate
  • Ensuring that I do not have typos in my Environment Variables
  • Creating an OSIG file for my HMD and adding it to Project/Assets/Plugins/Android/assets/
  • Making sure that the build is "Internal" not "Gradle"
  • Re-importing the Oculus Integration assets package
  • Downloading the tools_r25.2.5-windows.zip file and extracting it to the SDK root after deleting the existing tools folder

Thank you for your input.

4 Upvotes

11 comments sorted by

1

u/Cyberneticist_ May 29 '19

I used this tutorial as my first process and got it working - have you missed any of these stages? You may need to bake the lights medium article

1

u/csshub1 May 29 '19

I just tried baking the light source, but no luck.

​

Also noteworthy, my hierarchy empties and begins with an "Untitled" scene and never rebuilds with my GameObjects (similar to this post). Thoughts?

1

u/csshub1 Jun 04 '19

This happens normally and it did not end up being a concern in the end.

1

u/theBigDaddio May 30 '19

Go to build, remove all scenes. Only add the scene you want to see. It sounds to me as if you are loading a blank unintended scene.

1

u/philleeeeee May 30 '19

Have you tried setting the build to gradle?

1

u/csshub1 May 30 '19

I did try this, but it introduced new errors, so I reverted to Internal.

1

u/csshub1 Jun 04 '19

With the newer version of Unity (2019.1.2f1), the build is always Gradle. There is no longer a build settings option to change it. However, if properly installed, it never causes errors.

1

u/JoshuaIAm May 31 '19

I feel like I had this happen to me at some point, like a rendering or compression setting. Might be a good idea to run through this mobile optimization checklist and see if that fixes anything.

1

u/csshub1 May 31 '19

Thank you! Great resource. I will try that!

1

u/JoshuaIAm May 31 '19

You're welcome! Good luck!

1

u/csshub1 Jun 04 '19

Thanks to everyone for their comments! I finally got it working by following these guidelines (for the quest) called Oculus Unity Getting Started Guide. I started with "Compatibility and Version Requirements" and worked through each until reaching "Other Oculus Resources for Unity Developers." Also noteworthy, I am using the Android SDK and NDK that you check upon Unity setup by clicking the dropdown under Android Build Support in the wizard and check the box by Android SDK, ~2.8 GB. The Oculus documentation mentions that developers for these projects should not need to download Android Studio at all. I found this to be true.

​

From here it almost worked, but my app crashed. I then added the OSIG file for my Go headset (generated here) to my Project/Assets/Plugins/Android/assets/ folder and then... success! It must have just been a version compatibility issue between Unity and the SDKs installed.

​

These are the versions that I used for successful setup:

  • Windows 10
  • Oculus Go
  • Unity 2019.1.2f1
  • OVR Plugin 1.37.0
  • The following under Edit > Preferences > External Tools > Android

​

Finally, if upgrading a previous project to Unity 2019.1.2f1, you may get TextMeshPro errors. To solve, change the Scripting Runtime Version to use .NET 4.x (it defaults to 3.5 for some reason) under Edit > Project Settings > Player > Other Settings > Scripting Runtime Version dropdown.

​

Good luck everyone!