docs.unity.cn
    Show / Hide Table of Contents

    Class XRReferencePointSubsystem

    Base class for a reference point subsystem.

    Inheritance
    Object
    SubsystemWithProvider
    UnityEngine.SubsystemsImplementation.SubsystemWithProvider<XRReferencePointSubsystem, XRReferencePointSubsystemDescriptor, XRReferencePointSubsystem.Provider>
    TrackingSubsystem<XRReferencePoint, XRReferencePointSubsystem, XRReferencePointSubsystemDescriptor, XRReferencePointSubsystem.Provider>
    XRReferencePointSubsystem
    Inherited Members
    TrackingSubsystem<XRReferencePoint, XRReferencePointSubsystem, XRReferencePointSubsystemDescriptor, XRReferencePointSubsystem.Provider>.GetChanges(Allocator)
    UnityEngine.SubsystemsImplementation.SubsystemWithProvider<UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystemDescriptor, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem.Provider>.OnCreate()
    UnityEngine.SubsystemsImplementation.SubsystemWithProvider<UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystemDescriptor, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem.Provider>.OnStart()
    UnityEngine.SubsystemsImplementation.SubsystemWithProvider<UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystemDescriptor, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem.Provider>.OnStop()
    UnityEngine.SubsystemsImplementation.SubsystemWithProvider<UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystemDescriptor, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem.Provider>.OnDestroy()
    UnityEngine.SubsystemsImplementation.SubsystemWithProvider<UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystemDescriptor, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem.Provider>.subsystemDescriptor
    UnityEngine.SubsystemsImplementation.SubsystemWithProvider<UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystemDescriptor, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem.Provider>.provider
    SubsystemWithProvider.Start()
    UnityEngine.SubsystemsImplementation.SubsystemWithProvider.OnStart()
    SubsystemWithProvider.Stop()
    UnityEngine.SubsystemsImplementation.SubsystemWithProvider.OnStop()
    SubsystemWithProvider.Destroy()
    UnityEngine.SubsystemsImplementation.SubsystemWithProvider.OnDestroy()
    SubsystemWithProvider.running
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: UnityEngine.XR.ARSubsystems
    Syntax
    [Obsolete("XRReferencePointSubsystem has been deprecated. Use XRAnchorSubsystem instead (UnityUpgradable) -> UnityEngine.XR.ARSubsystems.XRAnchorSubsystem", false)]
    public class XRReferencePointSubsystem : TrackingSubsystem<XRReferencePoint, XRReferencePointSubsystem, XRReferencePointSubsystemDescriptor, XRReferencePointSubsystem.Provider>, ISubsystem
    Remarks

    A reference point is a pose in the physical environment that is tracked by an XR device. As the device refines its understanding of the environment, reference points will be updated, allowing you to keep virtual content connected to a real-world position and orientation.

    This abstract class should be implemented by an XR provider and instantiated using the SubsystemManager to enumerate the available XRReferencePointSubsystemDescriptors.

    Methods

    GetChanges(Allocator)

    Get the changes to reference points (added, updated, and removed) since the last call to GetChanges(Allocator).

    Declaration
    public override TrackableChanges<XRReferencePoint> GetChanges(Allocator allocator)
    Parameters
    Type Name Description
    Allocator allocator

    An allocator to use for the NativeArrays in TrackableChanges<T>.

    Returns
    Type Description
    TrackableChanges<XRReferencePoint>

    Changes since the last call to GetChanges(Allocator).

    Overrides
    UnityEngine.XR.ARSubsystems.TrackingSubsystem<UnityEngine.XR.ARSubsystems.XRReferencePoint, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystemDescriptor, UnityEngine.XR.ARSubsystems.XRReferencePointSubsystem.Provider>.GetChanges(Unity.Collections.Allocator)

    TryAddReferencePoint(Pose, out XRReferencePoint)

    Attempts to create a new reference point with the provide pose.

    Declaration
    [Obsolete("XRReferencePointSubsystem.TryAddReferencePoint() has been deprecated. Use XRAnchorSubsystem.TryAddAnchor() instead (UnityUpgradable) -> UnityEngine.XR.ARSubsystems.XRAnchorSubsystem.TryAddAnchor(Pose, XRAnchor)", true)]
    public bool TryAddReferencePoint(Pose pose, out XRReferencePoint referencePoint)
    Parameters
    Type Name Description
    Pose pose

    The pose, in session space, of the new reference point.

    XRReferencePoint referencePoint

    The new reference point. Only valid if this method returns true.

    Returns
    Type Description
    Boolean

    true if the new reference point was added, otherwise false.

    TryAttachReferencePoint(TrackableId, Pose, out XRReferencePoint)

    Attempts to create a new reference attached to the trackable with id trackableToAffix. The behavior of the reference point depends on the type of trackable to which this reference point is attached.

    Declaration
    [Obsolete("XRReferencePointSubsystem.TryAttachReferencePoint() has been deprecated. Use XRAnchorSubsystem.TryAttachAnchor() instead (UnityUpgradable) -> UnityEngine.XR.ARSubsystems.XRAnchorSubsystem.TryAttachAnchor(TrackableId, Pose, XRAnchor)", true)]
    public bool TryAttachReferencePoint(TrackableId trackableToAffix, Pose pose, out XRReferencePoint referencePoint)
    Parameters
    Type Name Description
    TrackableId trackableToAffix

    The id of the trackable to which to attach.

    Pose pose

    The pose, in session space, of the reference point to create.

    XRReferencePoint referencePoint

    The new reference point. Only valid if this method returns true.

    Returns
    Type Description
    Boolean

    true if the new reference point was added, otherwise false.

    TryRemoveReferencePoint(TrackableId)

    Attempts to remove an existing reference point with TrackableId referencePointId.

    Declaration
    [Obsolete("XRReferencePointSubsystem.TryRemoveReferencePoint() has been deprecated. Use XRAnchorSubsystem.TryRemoveAnchor() instead (UnityUpgradable) -> UnityEngine.XR.ARSubsystems.XRAnchorSubsystem.TryRemoveAnchor(*)", true)]
    public bool TryRemoveReferencePoint(TrackableId referencePointId)
    Parameters
    Type Name Description
    TrackableId referencePointId

    The id of an existing reference point to remove.

    Returns
    Type Description
    Boolean

    true if the reference point was removed, otherwise false.

    Back to top Copyright © 2023 Unity Technologies — Terms of use
    Generated by DocFX
    on Monday, May 22, 2023