1. Help us improve the editor usability and artist workflows. Join our discussion to provide your feedback.
    Dismiss Notice
  2. We're looking for feedback on Unity Starter Kits! Let us know what you’d like.
    Dismiss Notice
  3. We’re giving 2017.1 beta testers a chance to win t-shirts and a Nintendo Switch. Read more on the blog.
    Dismiss Notice
  4. Unity 2017.1 beta is now available for download.
    Dismiss Notice
  5. Unity 5.6 is now released.
    Dismiss Notice
  6. Get further faster with the Unity Plus Accelerator Pack, free for new Unity Plus subscribers for a limited time. Click here for more details.
    Dismiss Notice
  7. Check out all the fixes for 5.6 on the patch releases page.
    Dismiss Notice
  8. Learn how you'll soon be able to publish your games to China in four simple steps with Xiaomi. Sign up now for early access.
    Dismiss Notice

GVR 1.5 released

Discussion in 'Virtual Reality' started by Mistabullit, May 17, 2017.

  1. Mistabullit

    Mistabullit

    Joined:
    Aug 14, 2015
    Posts:
    8
    Hey guys,

    I just noticed this has now released. There are a few things missing I'm still testing things out.

    The old trusty prefab GvrViewerMain is gone completely. So if you were reliant on GvrViewer there might be some work arounds you need to put in place. These are not in the current tutorial on the google VR SDK site as yet.

    The latest can be gotten from their GIT.
     
  2. Selzier

    Selzier

    Joined:
    Sep 23, 2014
    Posts:
    413
    Liinnkk and Mistabullit like this.
  3. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    922
    Yeah looks to be some editor stuff as mentioned above, a few audio things, removing a ton of the old legacy scripts, and a much better keyboard. Looks to be all self contained as well, with no changes to the native assembly underneath.
     
  4. Mistabullit

    Mistabullit

    Joined:
    Aug 14, 2015
    Posts:
    8
    Ok. My camera issue was a simple fix. I have my camera as a child of another object and the mono camera was not taking the camera location I had. So I just set the parent object co-ordinates at the correct location and adjusted everything below it accordingly.
     
  5. SiliconDroid

    SiliconDroid

    Joined:
    Feb 20, 2017
    Posts:
    92
    I was setting up GVR in script:

    Code (CSharp):
    1.                    
    2.     //  LOAD PREFAB
    3.     const string sPrefabPath = "GoogleVR/MAIN_GOOGLEVR";
    4.     Object oPrefab = Resources.Load(sPrefabPath);
    5.     if (!oPrefab)
    6.     {
    7.         LOGW("CANT LOAD PREFAB " + sPrefabPath);
    8.         return false;
    9.     }
    10.    
    11.     //  INSTANTIATE PREFAB
    12.     v.oGVR = (GameObject)Instantiate(oPrefab);
    13.     if (!v.oGVR)
    14.     {
    15.         LOGW("CANT INSTANTIATE PREFAB!: " + sPrefabPath);
    16.         return false;
    17.     }
    18.    
    19.     //  GET CODE
    20.     v.cGVR = v.oGVR.GetComponent<GvrViewer>();
    21.     if (!v.cGVR)
    22.     {
    23.         LOGW("CANT GET GvrViewer SCRIPT!: " + sPrefabPath);
    24.         return false;
    25.     }
    26.    
    27.     //BIND GVR NECK TO PLAYERS NECK
    28.     v.oGVR.transform.parent = this.transform;
    29.    
    30.     //  DONE
    31.     v.oGVR.tag = main.K_TAG_CAMERA_GVR;
    32.     v.oGVR.name = main.K_TAG_CAMERA_GVR;
    33.     LOGM("ENABLED GVR");
    34.     return true;
    35.  
    Anyone know what I should do to setup via script now?
     
    Last edited: May 17, 2017
  6. Selzier

    Selzier

    Joined:
    Sep 23, 2014
    Posts:
    413
    - Prefab Path should be GoogleVR/Prefabs/GvrEditorEmulator
    - GvrViewer has been removed, I think this is essentially replaced now with Unity's VRSettings API:
    https://docs.unity3d.com/ScriptReference/VR.VRSettings.html

    I made a small video about some updates, but I don't have Daydream so I only cover Cardboard stuff:
     
    SiliconDroid likes this.
  7. SiliconDroid

    SiliconDroid

    Joined:
    Feb 20, 2017
    Posts:
    92
    Thx @Selzier

    For anyone wanting to instantiate GVR fully runtime. You've just got to addComponent GvrEditorEmulator and GvrController to some game object, I add them both to my VR neck root object, the object I child to avatar skeleton neck transform.

    I dont think GvrEditorEmulator is needed for Android build but you can include it and it just sits quietly. Then you call static member functions on the classes to access APIs same as before.
     
    Last edited: May 19, 2017