Boundary visibility
The Meta Quest Boundary Visibility feature enables you to suppress the visibility of the boundary so users can move freely with Passthrough enabled.
When boundary visibility isn't suppressed, the system may warn the user when they leave the boundary.
Enable boundary visibility
To enable boundary visibility in your app:
- Go to Project Settings > XR Plug-in Management > OpenXR.
- Select either the Windows, Mac, Linux settings tab to configure Quest Link on Windows, or the Android settings tab to configure builds.
- Under the OpenXR Feature Groups heading, select the Meta Quest feature group.
- If disabled, enable the Meta Quest: Boundary Visibility OpenXR feature.
The Meta Quest feature group, shown with all features enabled.
Example code
Refer to the following example code to understand how to suppress boundary visibility:
var feature = OpenXRSettings.Instance.GetFeature<BoundaryVisibilityFeature>();
var result = feature.TryRequestBoundaryVisibility(
XrBoundaryVisibility.VisibilitySuppressed);
if ((int)result ==
BoundaryVisibilityFeature.XR_BOUNDARY_VISIBILITY_SUPPRESSION_NOT_ALLOWED_META)
{
// The runtime did not accept the request to suppress the boundary.
// Your app must render passthrough to suppress boundary visibility.
}
if (result < 0)
{
// XrResult values less than zero are errors.
// Handle error here.
}