Class ARRaycastManager
Manages an XRRaycastSubsystem
, exposing raycast functionality in AR Foundation. Use this component
to raycast against trackables (that is, detected features in the physical environment) when they do not have
a presence in the Physics world.
Inheritance
Inherited Members
Namespace: UnityEngine .XR.ARFoundation
Assembly: solution.dll
Syntax
[DefaultExecutionOrder(-2147483647)]
[DisallowMultipleComponent]
[RequireComponent(typeof(ARSessionOrigin))]
[HelpURL("https://docs.unity3d.com/Packages/com.unity.xr.arfoundation@4.2/api/UnityEngine.XR.ARFoundation.ARRaycastManager.html")]
public sealed class ARRaycastManager : ARTrackableManager<XRRaycastSubsystem, XRRaycastSubsystemDescriptor, XRRaycastSubsystem.Provider, XRRaycast, ARRaycast>
Properties
Name | Description |
---|---|
game |
The name of the |
raycast |
If not null, this prefab will be instantiated for each ARRaycast. |
Methods
Name | Description |
---|---|
Add |
Creates an ARRaycast that updates automatically. ARRaycasts will
continue to update until you remove them with Remove |
Get |
Gets the Prefab that should be instantiated for each ARRaycast. Can be |
On |
Invoked just after a ARRaycast has been updated. |
On |
Invoked just after the subsystem has been |
Raycast(Ray, List<ARRaycast |
Cast a |
Raycast(Vector2, List<ARRaycast |
Cast a ray from a point in screen space against trackables, that is, detected features such as planes. |
Remove |
Removes an existing ARRaycast. |