Gvr-unity-sdk: GvrPointerGraphicRaycaster requires GvrPointer to have a Camera when in Direct mode.

Created on 27 Jul 2017  路  14Comments  路  Source: googlevr/gvr-unity-sdk

I'm unable to use the play function in unity. Whenever i click the play button, this error comes up and stops rendering. I'm using the controller emulator app in the phone connected to the computer via usb.
bug

bug

Most helpful comment

Select GvrReticlePointer and change the RaycastMode to Camera in the inspector, that should fix it. Thanks for pointing out this bug!

All 14 comments

What version of the SDK are you using? If 1.7, What is the raycast mode set to on the GvrLaserPointer script?

The 1.7 SDK made some changes to the structure of the GvrControllerPointer prefab, if you've modified that prefab based on a previous version of the SDK, that could cause this problem.

I haven't made any changs to the sdk. I'm simply running the demo. The sdk I use is 5.7. Raycast mode seems to be direct.

Thanks, have you set the demo to Cardboard mode or Daydream mode?

Cardboard

Select GvrReticlePointer and change the RaycastMode to Camera in the inspector, that should fix it. Thanks for pointing out this bug!

I'll check that out. Thanks

That worked Well. Thanks.

I have the same error happening every frame (it's saturating he logs). I've tried the solution, but it seems to be already set up to "Camera".

Using Unity 2017.1 and GVR 1.7.0
I think i'm using Cardboard mode (is that here? Player Settings > Other Settings >聽Virtual Reality SDKs)

In the demo scene hierarchy, I select the element:
Player > Main Camera > GvrControllerPointer > Laser

In the inspector, under Gvr Laser Pointer, Raycast Mode is already set to "Camera"

This error is happening on the cardboard reticle (GvrReticlePointer), not the controller (GvrControllerPointer). Do you have the demo set to use the the cardboard reticle or the daydream controller?

Thanks,

Dan

I was refering to that other element above because that's the only place I could find a "Raycast Mode" option.

I don't have GvrReticlePointer in my hierarchy
The closer I have to reticle is:
Player > Main Camera > Laser > Reticle
it's only a quad mesh with a shader

I'm using the stock demo of 1.7.0 asset package without any changes /Assets/GoogleVR/Demos/Scenes/GVRDemo.

Try looking for it under Player->MainCamera->GvrReticlePointer, or in the search bar type "t:GvrReticlePointer".

In the stock demo of 1.7.0, there should be both of the following:

Player->MainCamera->GvrReticlePointer
Player->GvrControllerPointer->Laser->Reticle

DemoInputManager automatically switches between using GvrReticlePointer (gaze-based cardboard reticle) and GvrControllerPointer (Daydream controller) based on what you have set in the "Virtual Reality SDKs" player settings.

Oh boy.. it was there all the time.
It was set to "direct". Setting it to "camera" fixes the errors.
Thanks

The GvrReticlePointer prefab has the wrong (Direct) default raycast mode in 1.70.0.
This should be fixed in the next release. The GvrReticlePointer prefab default will be Camera raycast mode.

Fixed in v1.100.

Was this page helpful?
0 / 5 - 0 ratings