API reference
API reference
Select your platform
No SDKs available
No versions available

OVRRayHelper Class

Extends MonoBehaviour
Helper script that can be placed on any game object that will cast a visible ray cast out from the object and places a cursor on a canvas if it intersects one.

Fields

Reference to the mesh renderer that is used to render the visible ray cast.
The default material used for the ray cast object.
The material used for the ray cast object when it's active.
Being active can come from button or trigger input from controllers or pinch input from hand tracking.
The game object used to represent the cursor which is placed on the canvas where the ray intersects it.
The sprite object that will be displayed on the cursor when the ray cast is active.
Being active can come from button or trigger input from controllers or pinch input from hand tracking.
The default length of the ray cast object.

Member Functions

Updates the ray cast pointer with the provided ray data.
This function will update properties on the ray and cursor based on OVRInputRayData.IsActive and OVRInputRayData.IsOverCanvas.
Parameters
rayData
Did you find this page helpful?
Thumbs up icon
Thumbs down icon