You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Google's Cardboard VR sample scene in Unity gives an error.
Issue is in HelloCardboard sample scene from the Google Cardboard imported plugin.
Error message:
Please initialize Cardboard XR loader before calling this function.
UnityEngine.Debug:LogError (object)
Google.XR.Cardboard.Api:UpdateScreenParams () (at Library/PackageCache/com.google.xr.cardboard@891dec0b1a/Runtime/Api.cs:295)
CardboardStartup:Update () (at Assets/Samples/Google Cardboard XR Plugin for Unity/1.11.0/Hello Cardboard/Scripts/CardboardStartup.cs:70)
Unity 2020.3.20f1, android build
Packages installed: XR Plugin management, Google Cardboard XR Plugin for Unity (installed through GIT, import package via URL)
Google Cardboard imported as it is described here: https://developers.google.cn/cardboard/develop/unity/quickstart
SMARTPHONE (please complete the following information):
Device: Samsung Galaxy S8+
OS
Android
OS version: Android 9, API level 27
STEPS TO REPRODUCE THE ISSUE
Have GIT installed on your PC
Create empty 3D project in Unity
in the project go to Package Manager > + > import with URL > paste the given URL from the "Google's Quickstart for Google Cardboard" (the link to import package: https://github.com/googlevr/cardboard-xr-plugin.git)
In Package Manager > XR Plugin management > import
In Assets > Samples > ... > Hello Cardboard > Scenes > open the HelloCardboard scene
Editor > Project settings > XR Plug-in Management > Android > check "Initialize XR on startup" & check "Cardboard XR Plugin" in the Plug-in providers section
Back in the HelloCardboard scene hit Play button and the error message shows up "Please initialize Cardboard XR loader before calling this function.
UnityEngine.Debug:LogError (object)
Google.XR.Cardboard.Api:UpdateScreenParams () (at Library/PackageCache/com.google.xr.cardboard@891dec0b1a/Runtime/Api.cs:295)
CardboardStartup:Update () (at Assets/Samples/Google Cardboard XR Plugin for Unity/1.11.0/Hello Cardboard/Scripts/CardboardStartup.cs:70)"
EXPECTED BEHAVIOR
HelloCardboard scene can be played without any errors.
Thanks @KristynaPavlatova for reaching out to us! I confirm that I could reproduce your issue.
Currently, Editor Play mode is not supported by the Cardboard SDK. That is why the error message appears when the play button is pressed.
At the moment, the Cardboard XR Plugin can only be executed on Android and iOS devices as it is pointed out in the Quickstart.
Issue #51 is currently tracking the feature request for adding Editor Play mode support. I’m closing this issue now as it is a duplicate of the aforementioned one.
SPECIFIC ISSUE ENCOUNTERED
Google's Cardboard VR sample scene in Unity gives an error.
Issue is in HelloCardboard sample scene from the Google Cardboard imported plugin.
Error message:
Please initialize Cardboard XR loader before calling this function.
UnityEngine.Debug:LogError (object)
Google.XR.Cardboard.Api:UpdateScreenParams () (at Library/PackageCache/com.google.xr.cardboard@891dec0b1a/Runtime/Api.cs:295)
CardboardStartup:Update () (at Assets/Samples/Google Cardboard XR Plugin for Unity/1.11.0/Hello Cardboard/Scripts/CardboardStartup.cs:70)
Unity 2020.3.20f1, android build
Packages installed: XR Plugin management, Google Cardboard XR Plugin for Unity (installed through GIT, import package via URL)
Google Cardboard imported as it is described here: https://developers.google.cn/cardboard/develop/unity/quickstart
SMARTPHONE (please complete the following information):
STEPS TO REPRODUCE THE ISSUE
UnityEngine.Debug:LogError (object)
Google.XR.Cardboard.Api:UpdateScreenParams () (at Library/PackageCache/com.google.xr.cardboard@891dec0b1a/Runtime/Api.cs:295)
CardboardStartup:Update () (at Assets/Samples/Google Cardboard XR Plugin for Unity/1.11.0/Hello Cardboard/Scripts/CardboardStartup.cs:70)"
EXPECTED BEHAVIOR
HelloCardboard scene can be played without any errors.
VERSIONS USED
Cardboard SDK/Cardboard XR Plugin 1.11.0
Unity 2020.3.20f1, android build
The text was updated successfully, but these errors were encountered: