I hope you can help me, I have a problem with a little 360° Virtual Reality Player I made with Unity 5.6 f03 for Cardboard.
I use one scene as navigation and other scenes where 5 diffrent movies are played in a sphere. I change the scenes with a small UI and with a script on a Button: SceneManager.LoadScene(sceneName, LoadSceneMode.Single);
I imported the GVR SDK 1.40 and I use the GvrViewerMain, GvrEventSystem, GvrRecticlePointer from the SDK in my scenes for virtual reality.
On Android it works fine, but I unfortunately have a probleme with the app on iOS. Under iOS the app crashes when I click a button to change the scene. Xcode tells me: Thread 1: EXC_BAD_ACCESS(code=1, address=0xd8)
If I deactivate the “Virtual Reality Support” in Unitys Player Settings the app does not crash and the scene change works fine, but I have no virtual reality of course.
Can someone help to solve this problem? I already work for some days on this issue but I don’t have an idea why this happens.
Can you provide more details on the crash log beyond just the bad access? You might also want to try to build a debug build to see if you can get anymore information.
If none of that helps can you do the following:
Make a copy of your project folder
Open that copy in Unity and remove anything at all that does not pertain to the repro problem. Delete assets, remove unnecessary scenes, remove unnecessary game objects, etc. This will allow us to focus on the issue more quickly. It may also have the side benefit of pointing the root cause of the issue out to you that you didn’t see before.
Close Unity.
In that copy delete everything but Assets and ProjectSettings
Zip up the copy and post it with a reply to this thread.
Are you changing VR Settings from enabled to disabled? I noticed that if one scene had VRSettings set to true or false and you changed them in the next scene it crashed on iOS. However if I set the VR settings on and off in the same scene the crash did not occur. This issue does not happen on Android.