Class XRBoundingBoxSubsystem
This subsystem provides information regarding the detection of 3D bounding boxes in the physical environment.
Inheritance
Implements
Inherited Members
Namespace: UnityEngine.XR.ARSubsystems
Assembly: Unity.XR.ARSubsystems.dll
Syntax
public class XRBoundingBoxSubsystem : TrackingSubsystem<XRBoundingBox, XRBoundingBoxSubsystem, XRBoundingBoxSubsystemDescriptor, XRBoundingBoxSubsystem.Provider>, ISubsystem
Remarks
This is a base class with an abstract provider type to be implemented by provider plug-in packages. This class itself does not implement bounding box detection.
Constructors
XRBoundingBoxSubsystem()
Do not invoke this constructor directly.
Declaration
public XRBoundingBoxSubsystem()
Remarks
If you are implementing your own custom subsystem Lifecycle management, use the SubsystemManager to enumerate the available XRBoundingBoxSubsystemDescriptors, then call XRBoundingBoxSubsystemDescriptor.Register() on the desired descriptor.
Methods
GetChanges(Allocator)
Gets a TrackableChanges<T> struct containing any changes to detected bounding boxes since the last
time you called this method. You are responsible to Dispose() the returned
TrackableChanges
instance.
Declaration
public override TrackableChanges<XRBoundingBox> GetChanges(Allocator allocator)
Parameters
Type | Name | Description |
---|---|---|
Allocator | allocator | An |
Returns
Type | Description |
---|---|
TrackableChanges<XRBoundingBox> | The TrackableChanges<T>. |
Overrides
Remarks
The TrackableChanges<T> struct returned by this method contains separate
NativeArray_1 objects for the added, updated, and removed bounding boxes. These arrays are created
using the Allocator type specified by allocator
.