Class ARPointCloudManager | AR Foundation | 2.2.0-preview.6
docs.unity3d.com
    Show / Hide Table of Contents

    Class ARPointCloudManager

    A manager for ARTrackedObjects. Uses the XRDepthSubsystem to recognize and track depth data in the physical environment.

    Inheritance
    Object
    SubsystemLifecycleManager<XRDepthSubsystem, XRDepthSubsystemDescriptor>
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>
    ARPointCloudManager
    Inherited Members
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.trackables
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.SetTrackablesActive(Boolean)
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.sessionOrigin
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.gameObjectName
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.GetPrefab()
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.m_Trackables
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.m_PendingAdds
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.Awake()
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.Update()
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.OnTrackablesChanged(List<ARPointCloud>, List<ARPointCloud>, List<ARPointCloud>)
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.OnCreateTrackable(ARPointCloud)
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.OnAfterSetSessionRelativeData(ARPointCloud, XRPointCloud)
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.CreateTrackableImmediate(XRPointCloud)
    ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>.DestroyPendingTrackable(TrackableId)
    SubsystemLifecycleManager<XRDepthSubsystem, XRDepthSubsystemDescriptor>.subsystem
    SubsystemLifecycleManager<XRDepthSubsystem, XRDepthSubsystemDescriptor>.descriptor
    SubsystemLifecycleManager<XRDepthSubsystem, XRDepthSubsystemDescriptor>.CreateSubsystem()
    SubsystemLifecycleManager<XRDepthSubsystem, XRDepthSubsystemDescriptor>.CreateSubsystemIfNecessary()
    SubsystemLifecycleManager<XRDepthSubsystem, XRDepthSubsystemDescriptor>.GetActiveSubsystemInstance()
    SubsystemLifecycleManager<XRDepthSubsystem, XRDepthSubsystemDescriptor>.OnEnable()
    SubsystemLifecycleManager<XRDepthSubsystem, XRDepthSubsystemDescriptor>.OnDisable()
    SubsystemLifecycleManager<XRDepthSubsystem, XRDepthSubsystemDescriptor>.OnDestroy()
    SubsystemLifecycleManager<XRDepthSubsystem, XRDepthSubsystemDescriptor>.OnBeforeStart()
    SubsystemLifecycleManager<XRDepthSubsystem, XRDepthSubsystemDescriptor>.OnAfterStart()
    Namespace: UnityEngine.XR.ARFoundation
    Syntax
    public class ARPointCloudManager : ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, ARPointCloud>, IRaycaster

    Properties

    gameObjectName

    The name to be used for the GameObject whenever a new Object is detected.

    Declaration
    protected override string gameObjectName { get; }
    Property Value
    Type Description
    String
    Overrides
    UnityEngine.XR.ARFoundation.ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, UnityEngine.XR.ARFoundation.ARPointCloud>.gameObjectName

    pointCloudPrefab

    Getter/setter for the Point Cloud Prefab.

    Declaration
    public GameObject pointCloudPrefab { get; set; }
    Property Value
    Type Description
    GameObject

    Methods

    GetPrefab()

    ARTrackableManager interface.

    Declaration
    protected override GameObject GetPrefab()
    Returns
    Type Description
    GameObject
    Overrides
    UnityEngine.XR.ARFoundation.ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, UnityEngine.XR.ARFoundation.ARPointCloud>.GetPrefab()

    OnAfterSetSessionRelativeData(ARPointCloud, XRPointCloud)

    Declaration
    protected override void OnAfterSetSessionRelativeData(ARPointCloud pointCloud, XRPointCloud sessionRelativeData)
    Parameters
    Type Name Description
    ARPointCloud pointCloud
    XRPointCloud sessionRelativeData
    Overrides
    UnityEngine.XR.ARFoundation.ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, UnityEngine.XR.ARFoundation.ARPointCloud>.OnAfterSetSessionRelativeData(UnityEngine.XR.ARFoundation.ARPointCloud, XRPointCloud)

    OnDisable()

    Declaration
    protected override void OnDisable()
    Overrides
    UnityEngine.XR.ARFoundation.SubsystemLifecycleManager<XRDepthSubsystem, XRDepthSubsystemDescriptor>.OnDisable()

    OnEnable()

    Declaration
    protected override void OnEnable()
    Overrides
    UnityEngine.XR.ARFoundation.SubsystemLifecycleManager<XRDepthSubsystem, XRDepthSubsystemDescriptor>.OnEnable()

    OnTrackablesChanged(List<ARPointCloud>, List<ARPointCloud>, List<ARPointCloud>)

    Invokes the pointCloudsChanged event.

    Declaration
    protected override void OnTrackablesChanged(List<ARPointCloud> added, List<ARPointCloud> updated, List<ARPointCloud> removed)
    Parameters
    Type Name Description
    List<ARPointCloud> added

    A list of objects added this frame.

    List<ARPointCloud> updated

    A list of objects updated this frame.

    List<ARPointCloud> removed

    A list of objects removed this frame.

    Overrides
    UnityEngine.XR.ARFoundation.ARTrackableManager<XRDepthSubsystem, XRDepthSubsystemDescriptor, XRPointCloud, UnityEngine.XR.ARFoundation.ARPointCloud>.OnTrackablesChanged(System.Collections.Generic.List<UnityEngine.XR.ARFoundation.ARPointCloud>, System.Collections.Generic.List<UnityEngine.XR.ARFoundation.ARPointCloud>, System.Collections.Generic.List<UnityEngine.XR.ARFoundation.ARPointCloud>)

    Raycast(Ray, TrackableType, Allocator)

    Implementation for the IRaycaster interface. Raycasts against every point cloud.

    Declaration
    public NativeArray<XRRaycastHit> Raycast(Ray rayInSessionSpace, TrackableType trackableTypeMask, Allocator allocator)
    Parameters
    Type Name Description
    Ray rayInSessionSpace

    A Ray, in session space.

    TrackableType trackableTypeMask

    The type of trackables to raycast against. If TrackableType.FeaturePoint is not set, this method returns an empty array.

    Allocator allocator

    The allocator to use for the returned NativeArray.

    Returns
    Type Description
    NativeArray<XRRaycastHit>

    A new NativeArray, allocated using allocator, containing a list of XRRaycastHits of points hit by the raycast.

    Events

    pointCloudsChanged

    Declaration
    public event Action<ARPointCloudChangedEventArgs> pointCloudsChanged
    Event Type
    Type Description
    Action<ARPointCloudChangedEventArgs>
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023