Class RoomPlanBoundingBoxSubsystem
The implementation of the XRBoundingBoxSubsystem
. Do not create this directly. Use the SubsystemManager
instead.
Inheritance
SubsystemWithProvider<XRBoundingBoxSubsystem, XRBoundingBoxSubsystemDescriptor, XRBoundingBoxSubsystem.Provider>
TrackingSubsystem<XRBoundingBox, XRBoundingBoxSubsystem, XRBoundingBoxSubsystemDescriptor, XRBoundingBoxSubsystem.Provider>
XRBoundingBoxSubsystem
RoomPlanBoundingBoxSubsystem
Implements
Inherited Members
SubsystemWithProvider<XRBoundingBoxSubsystem, XRBoundingBoxSubsystemDescriptor, XRBoundingBoxSubsystem.Provider>.subsystemDescriptor
Namespace: UnityEngine.XR.ARKit
Assembly: Unity.XR.ARKit.dll
Syntax
[Preserve]
public sealed class RoomPlanBoundingBoxSubsystem : XRBoundingBoxSubsystem, ISubsystem
Methods
GetRoomCaptureInstruction(out XRBoundingBoxInstructions)
Receive the instruction during room capture.
Declaration
public void GetRoomCaptureInstruction(out XRBoundingBoxInstructions instruction)
Parameters
Type | Name | Description |
---|---|---|
XRBoundingBoxInstructions | instruction | The instruction from room capture process. |
Examples
void UpdateRoomCaptureInstruction()
{
if (!CheckRoomCaptureSupport(out RoomPlanBoundingBoxSubsystem subsystem))
return;
subsystem.GetRoomCaptureInstruction(out XRBoundingBoxInstructions instruction);
// display the instruction to guide users for room capture
}
IsRoomCapturing()
Check the status of room capture process.
Declaration
public bool IsRoomCapturing()
Returns
Type | Description |
---|---|
bool |
|
Examples
void CheckRoomCapturingStatus()
{
if (!CheckRoomCaptureSupport(out RoomPlanBoundingBoxSubsystem subsystem))
return;
if (subsystem.IsRoomCapturing())
{
// Room capture is in progress
}
}
SetupRoomCapture()
Set up room capture.
Declaration
public bool SetupRoomCapture()
Returns
Type | Description |
---|---|
bool |
|
Examples
void RoomCaptureSetup()
{
if (!CheckRoomCaptureSupport(out RoomPlanBoundingBoxSubsystem subsystem))
return;
if (subsystem.SetupRoomCapture())
{
// The room capture has been successfully set up
}
}
StartRoomCapture()
Start the room capture process.
Declaration
public void StartRoomCapture()
Examples
void RoomCaptureStart()
{
if (!CheckRoomCaptureSupport(out RoomPlanBoundingBoxSubsystem subsystem))
return;
subsystem.StartRoomCapture();
}
StopRoomCapture()
Stop the room capture process.
Declaration
public void StopRoomCapture()
Examples
void RoomCaptureStop()
{
if (!CheckRoomCaptureSupport(out RoomPlanBoundingBoxSubsystem subsystem))
return;
subsystem.StopRoomCapture();
}