Class XRPlaneSubsystem.Provider
The API that derived classes must implement.
Namespace: UnityEngine.XR.ARSubsystems
Syntax
public abstract class Provider
Properties
currentPlaneDetectionMode
Get the current plane detection mode in use by the provider.
Declaration
public virtual PlaneDetectionMode currentPlaneDetectionMode { get; }
Property Value
Type | Description |
---|---|
PlaneDetectionMode |
requestedPlaneDetectionMode
Get or set the requested PlaneDetectionMode.
Declaration
public virtual PlaneDetectionMode requestedPlaneDetectionMode { get; set; }
Property Value
Type | Description |
---|---|
PlaneDetectionMode |
Methods
Destroy()
Destroy the plane subsystem. Stop() is always called first.
Declaration
public virtual void Destroy()
GetBoundary(TrackableId, Allocator, ref NativeArray<Vector2>)
Retrieves the boundary points of the plane with trackableId
.
Declaration
public virtual void GetBoundary(TrackableId trackableId, Allocator allocator, ref NativeArray<Vector2> boundary)
Parameters
Type | Name | Description |
---|---|---|
TrackableId | trackableId | The id of the plane. |
Allocator | allocator | An |
NativeArray<Vector2> | boundary | An existing |
GetChanges(BoundedPlane, Allocator)
Get the changes (added, updated, and removed) planes since the last call to GetChanges(BoundedPlane, Allocator).
Declaration
public abstract TrackableChanges<BoundedPlane> GetChanges(BoundedPlane defaultPlane, Allocator allocator)
Parameters
Type | Name | Description |
---|---|---|
BoundedPlane | defaultPlane | The default plane. This should be used to initialize the returned |
Allocator | allocator | An |
Returns
Type | Description |
---|---|
TrackableChanges<BoundedPlane> | TrackableChanges<T> describing the planes that have been added, updated, and removed
since the last call to GetChanges(BoundedPlane, Allocator). The changes should be allocated using
|
Start()
Start the plane subsystem, i.e., start tracking planes.
Declaration
public virtual void Start()
Stop()
Stop the subsystem, i.e., stop tracking planes.
Declaration
public virtual void Stop()