Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. We have updated the language to the Editor Terms based on feedback from our employees and community. Learn more.
    Dismiss Notice
  3. Join us on November 16th, 2023, between 1 pm and 9 pm CET for Ask the Experts Online on Discord and on Unity Discussions.
    Dismiss Notice
  4. Dismiss Notice

Resolved Google cardboard SDK on android > package Initialization not completed

Discussion in 'VR' started by tree_arb, Dec 4, 2020.

Thread Status:
Not open for further replies.
  1. tree_arb

    tree_arb

    Joined:
    Dec 30, 2019
    Posts:
    306
    (Hi, sorry slightly a crosspost from general)

    I'm having problems loading the google cardboard sdk / sample:

    Instructions:
    https://developers.google.com/cardboard/develop/unity/quickstart
    https://github.com/googlevr/cardboard-xr-plugin

    When I import this package, I get error:

    Cardboard XR Plugin package Initialization not completed. You will need to create any instances of the loaders and settings manually before you can use the intended XR Plug-in Package.
    UnityEditor.EditorApplication:Internal_CallUpdateFunctions()


    If I look in:
    Edit>project settings> XR plug-in Management

    picture:
    https://ibb.co/HDTxJ5M

    When you check/uncheck Cardboard XR plugin, it blinks the message:
    "assigning all requested loaders" and nothing happens, it will not appear under the XR plug-in Management drop down on the bottom left.

    In comparison, the ARCore and Oculus if clicked will load up some stuff, and then appear under XR plug-in Management, as show in the image

    If anyone can suggest anything please do, thanks.


    All the old info and tutorials I see are using cardboard by way of the Google VR SDK...maybe I should just do that? According to google:
    We recommend that all developers actively building for Google Cardboard migrate to the new Cardboard SDK:

    The status im in right now is, I can launch the app error free to the device if "initialize XR on startup" is not checked. (no vr) If it is checked, it crashes out black screen any never connects to a debugger

     
  2. tree_arb

    tree_arb

    Joined:
    Dec 30, 2019
    Posts:
    306
    UGGGG! ok i messed up.

    I had OpenGLES3 instead of OpenGLES2

    it is working now, but the FPS on the sample Hello Cardboard scene is very bad on pixel xl4, which normally handles plenty of VR and AR stuff...on to figure that out next i suppose
     
  3. tree_arb

    tree_arb

    Joined:
    Dec 30, 2019
    Posts:
    306
    ok, the very choppy FPS or tracking (unusable on my pixel 4xl)...whatever is going on there in the Hello Cardboard scene is fixed by:

    project settings > player > resolution and presentation.
    you want to uncheck optimize frame pacing.

    It is now appearing to be smooth.:)

    apparently this option was already unchecked in unity 2019.x but now is enabled be default in 2020.1.13f1, which I am currently using.

    source
    https://github.com/googlevr/cardboard/issues/165#issuecomment-736847787
     
  4. Roman_Keivan

    Roman_Keivan

    Joined:
    May 31, 2019
    Posts:
    21
    Thanks for advise
     
  5. tree_arb

    tree_arb

    Joined:
    Dec 30, 2019
    Posts:
    306
    I killed much of a day on that mistake, I mean really burned up some time. Then finally got it working with the required OpenGLES2

    ...Later that same night, I S*** you not, I was looking at github and saw the Cardboard SDK was updated to OpenGLES3 literally within the exact time I had been last pulling the repo in to my project...I was probably the last jerk to pull that version in haha.

    Anyway, I updated it using that last SDK from 12/4/2020. And now it works with OpenGLES3

    This is important because I believe AR foundation requires it. My next step is to attempt to blend my AR foundation project w Cardboard SDK, and I believe that is not possible with that OpenGLES2 version.

    Also note, no "frame pacing" is also still required...or, alternately I think I read you can set to 30fps

    project settings > player > resolution and presentation.
    you want to uncheck optimize frame pacing.


    ...also note the official google cardboard SDK instructions have not been updated to include OpenGLES3, but I just confirmed it does work

    ...and a question...I'm having a hard time finding an answer but, is this cardboard SDK like, dead? I mean it is not because they just updated it, but have most people abandoned it? I feel like I'm the only one on this whole unity forum even mentioning it
     
  6. mfuad

    mfuad

    Unity Technologies

    Joined:
    Jun 12, 2018
    Posts:
    334
    Google Cardboard is no longer directly supported by Unity. If you have any issues related to Google's latest Cardboard XR plugin for Unity, the Google team has requested you open issues on Github here where their team will address.
     
Thread Status:
Not open for further replies.